Brazilian soldiers make a convoy during the inauguration of the BRT TransOlímpica, an express road that connects Deodoro and Barra da Tijuca in Rio de Janeiro on July 9, 2016. (Tasso Marcelo/AFP/Getty Images)

The 22-mile trip from the center of Rio to the Athletes’ Village should have taken about 70 minutes. But on a recent Friday afternoon, taxi driver Ricardo de Andrade spent 2  1 /2 hours snarled in traffic as he traveled the route.

“I’m never coming to Barra again,” he vowed, referring to the neighborhood — Barra da Tijuca — where the athletes are staying.

For Rio locals like him, journeys to Barra, which is also the site of the main Olympic Park, mean one thing: endless traffic jams. And Barra isn’t the only neighborhood with such problems: Rio might offer heavenly beach views, but it can be traffic hell.

In fact, according to an annual survey of 295 cities known as the TomTom Traffic Index, Rio is the fourth most congested metropolis in the world – after Mexico City, Bangkok and Istanbul.

Many people fear this will only get worse with up to half a million visitors descending on the city for the Games. If a crucial new metro line connecting Barra to popular tourist neighborhoods like Ipanema and Copacabana is not functioning by Monday as promised, these may become known as the Congestion Games.

Under Mayor Eduardo Paes, the city has developed three new bus rapid-transit lines to serve the Barra area from different directions and a light-rail service in the city center. The state government — which is so broke that in June it declared a “state of calamity” and was rescued by a federal government bailout — is building the metro.

The question for visitors is whether these new works can save their Olympic commute – or whether they will spend hours in traffic in this city of 6 million people.

Rio’s traffic chaos stems from a lack of long-term planning, experts say.

“We don’t look forward and are always trying to resolve things at the last minute,” said Carlos Murdoch, an architect and urbanist who lectures at the Federal University of Rio de Janeiro and the Getulio Vargas Foundation, a leading business school.

In the 1950s, under President Juscelino Kubitschek, Brazil built a car-centric new capital, Brasilia, and encouraged foreign manufacturers to build automobile factories. But trains were neglected. Today, there is no passenger train line between Brazil’s two biggest cities — Sao Paulo and Rio — nor does either have a train or metro to its international airport.

“All the chaos we see in the traffic is based on this,” said Gisele Barbosa, a professor of urban engineering at the Federal University of Rio de Janeiro.

Rio has a limited suburban rail network and two metro lines. Most public transport, said Barbosa, involves buses, which commuters often criticize for being slow.

Rio’s Olympic sites are spread across the city. Some, like the Rodrigo de Freitas Lagoon, where rowing and some canoeing events will be held, can be reached only by road or on foot. Traffic on the highway around the lagoon regularly grinds to a halt.

Other sites are accessible by suburban rail, like a second Olympic Park in Deodoro and the athletics stadium in the Engenho de Dentro neighborhood. Some venues, such as the Maracanã Stadium, where opening and closing ceremonies will be held, and Copacabana Beach, the site for volleyball and triathlon competitions, can be reached by metro.

The main Olympic Park is in Barra da Tijuca – a traffic-clogged suburb of condominiums and malls that have shot up in recent decades.

“Barra is all by car. You go to the bakery to buy bread, you go by car,” said Murdoch.

Athletes and technical teams are supposed to whiz in and out of Barra using special Olympic lanes. Rio wants to fine motorists who breach them $460 – a heavy deterrent in a country whose minimum monthly wage is just $270.

Visitors will be relying on the new metro line, which will link Barra to popular tourist areas such as Ipanema and Copacabana and the rest of Rio’s limited metro system. Originally promised for 2014, it is due to open Monday.

A spokeswoman for the state government’s transport secretariat, who spoke on the condition of anonymity in accordance with internal regulations, said the new metro line will operate a limited, manually operated service during the Games, with trains every eight minutes that will carry only those with Olympic tickets or credentials. After the Olympics, it will shut down for upgrades.

The manual operation will limit capacity, said Fernando MacDowell, a professor of urban and environmental engineering at Rio’s Pontifical Catholic University.

He oversaw the implementation of Rio’s first metro network in the late 1970s and has criticized the fact that the new line will not connect directly with Rio’s existing network. Instead, passengers must ride a 30-foot escalator to change trains, further complicating the service.

“It was badly planned,” said MacDowell. “Things are not completely ready.”

The state transportation spokeswoman said that next January, after more work is done, the two lines will connect.

Rio has also built three bus rapid-transit (BRT) lines, which allow the vehicles to travel on lines exclusively for their use and connect to different points in the city.

One goes to the international airport, cutting through outlying, low-income Rio neighborhoods, and a second one provides a link to the Deodoro Olympic Park, far from Rio’s center and its beach areas, and will carry only those with tickets for the Olympics. A third serves more-remote suburbs farther west.

Barbosa, the urban engineering professor, said the BRT lines serve long-neglected neighborhoods and have eased some of Rio’s traffic stress.

“It was not the best option, but as the city was in such need, it is a gain,” she said. Rio’s international airport, only reached by buses, taxis or the BRT, is a potential congestion trouble spot during the Games, she said.

Greg Lindsay, a visiting scholar at New York University’s Rudin Center for Transportation Policy and Management, said that setting up a bus rapid-transit system is less expensive and faster than building metro lines. But the buses carry fewer people – 17,000 an hour, compared with 80,000 or more an hour for a metro line.

“The costs are cheaper at the beginning, but maintenance costs over time are higher than rail,” he said. “You need to take BRT routes and eventually turn them into rail.”

In June, a light-rail system — or tram — called a VLT began operating in Rio’s city center, connecting the bus station to the domestic airport and crossing a renovated port area.

While some transport specialists have criticized it as a slow-moving solution aimed at tourists, passengers said it has helped ease congestion.

Barbosa said Rio failed to encourage cycling to the Games. “This is one of the biggest points that was not achieved,” she said.

For the 2012 Olympics, London built new routes and parks for cyclists. Rio 2016 offers no bicycle parks. However, the city has built nearly 280 miles of new cycle paths after promising in its Olympic bid to expand its network of cycle routes to Game zones. Some, though, are shared with cars, said Barbosa. And in April, a section of a newly opened, elevated cycle path along the shore from Barra to Ipanema and Copacabana fell into the sea, killing two people. It’s been closed ever since.