RIO DE JANEIRO (AP) — It has been a terrific Olympics for USA Track and Field. The team already has 31 medals with only Sunday's marathon remaining.

LaShawn Merritt anchored the U.S. 4x400-meter relay team to Olympic gold. The Americans finished with a time of 2 minutes 57.30 seconds, more than eight-tenths of a second faster than runner-up Jamaica. Arman Hall, Tony McQuay, and Gil Roberts set up Merritt for the win.

Allyson Felix set a women's track record with her sixth career gold medal, helping the United States win the 4x400-meter relay. She ran the final leg of the race as the Americans won in 3 minutes, 19.06 seconds, finishing just ahead of Jamaica and Britain. Felix also won gold in the 4x100 relay and silver in the 400 meters.

The gold medal in the men's 1,500 meters goes to American Matt Centrowicz, whose final lap was 50.62 seconds. Centrowitz won the silver medal at the 2013 world championships and took fourth at the 2012 London Games. He is the first American to win the event since Mel Sheppard at the 1908 London Olympics.

Mo Farah of Britain became the first runner in 40 years to win back-to-back long-distance doubles at the Olympics, taking gold in the men's 5,000 meters after winning the 10,000. Paul Chelimo finished second and was later disqualified for a lane infringement before being reinstated.

Elsewhere in Rio:

The U.S. women's basketball team captured gold for a sixth consecutive time by rolling to a 101-72 rout of Spain. Diana Taurasi and Lindsay Whalen each scored 17 points for the U.S., which has won 49 straight Olympic games with just one decided by single digits. The Americans shook off a slow start by reeling off a 16-3 run after coach Geno Auriemma (ahr-ee-EH'-muh) put five of his former UConn Huskies on the floor.

— Brazil earned its first gold medal in men's soccer with a 5-4 shootout win following a 1-1 draw with Germany. Neymar scored once in regulation and buried the final penalty kick to set off a wild, flag-waving celebration in Maracana Stadium. The game-winning kick came after Brazilian goalkeeper Weverton stopped Nils Petersen's shot. Brazil took a 1-0 lead on Neymar's tally in the 27th minute, but the Germans got a goal from Max Meyer to square the match in the 59th minute.

— The U.S. has its first gold medal in women's triathlon as former University of Wisconsin product Gwen Jorgensen finished first in Rio with a time of 1:56.16, 40 seconds ahead of the silver medalist. The only previous medal for the U.S. in triathlon came in 2004 when Susan Williams won the silver.

— The American women's volleyball team came away with bronze following a four-sets victory against the Netherlands, two days after an agonizing five-set defeat to Serbia in the semifinals.

— Cuban Robeisy Ramirez won the gold in the bantamweight division with a win over American Shakur Stevenson. Ramirez used a strong third round to finish off Stevenson, who lost an international bout for the first time.

— U.S. wrestler J'den Cox took the bronze in the 86 kilogram division.

— David Boudia took bronze in the 10-meter platform diving competition at 525.25. The American was second going into his last dive but missed on a forward 4 ½ somersaults.

— South African Caster Semenya has won gold in the women's 800 meters. Semenya won in a South African national-record 1 minute, 55.28 seconds. She has become the unwilling face of track's dilemma dealing with hyperandrogenism.

— A U.S. protest in the men's 4x100 meter relay has been rejected, allowing Canada to keep the bronze medal. The Americans were disqualified from the final for an illegal baton exchange in the first passing zone.

— South Korean Inbee Park is the women's golf champion following a five-stroke victory over Lydia Ko of New Zealand. Park closed with a 5-under 66 for a 16-under total, showing no signs of the thumb injury that has hampered her LPGA season. Shanshan Feng of China captured the bronze at minus-10, one stroke ahead of American Stacy Lewis and two others.

— Simone Biles has been selected to carry the U.S. flag during Sunday's closing ceremony. Biles is the first female gymnast to receive the honor, which comes after she won four gold medals and five overall at the Rio Games.

— The United States continues to lead all medal counts with 43 gold, 37 silver and 36 bronze. The 116 total medals break the previous U.S. record for an Olympics on foreign soil. The Americans took home 110 medals from Beijing in 2008.