Officials and advocates are demanding answers after hundreds of commuters were stuck for about 45 minutes in a sweltering, pitch-black F train that lost power underground on Monday evening.

Without working air conditioners, passengers on the train shed their coats and layers, pried at doors and fanned themselves with papers in total darkness as the MTA recharged the southbound Manhattan train enough to pull it into the Broadway-Lafayette station. In the condensation collecting on a train door window, one passenger used his finger to spell out a message: “I will survive.”

“I thought, ‘This must be what it’s like to hike Machu Picchu,’” said Georgia Frances King, a deputy editor at Quartz who was on the train. “The air was feeling thinner and you had to take these deeper breaths. You were really aware that you were running out of oxygen.”

To make matters worse, the MTA left straphangers without a proper explanation for nearly half the time they spent in the tunnel, according to some riders. An incorrect announcement came over the train’s public address system several times within the first few minutes of the train delay, offering the agency’s boiler plate excuse familiar to any regular rider: “train traffic ahead.”

“People were sort of laughing at that and then getting really angry,” said Leslie Engel, a writer, who was also on the train. “There were a lot of expletives.”

A MTA service supervisor arrived in the tunnel within 10 minutes of the outage, according to the agency. The train was recharged at about 6:45 p.m. and moved “at slow speed” into the station, the agency said. The train was not “pushed” by another train into the station, as some riders believed.

At that point, the MTA’s Rail Control Center ordered the beleaguered train to pull two cars ahead of the Broadway-Lafayette platform, leaving room for the train stuck behind it to let its passengers off as well.

The problem with that strategy is that car doors had be opened manually because the train was not properly aligned on the platform. So once passengers could see the station, they were still left without any escape for about five minutes.

“Beads of sweat began rolling down people’s faces,” wrote Michael Sciaraffo in a Facebook post detailing his experience on the train. “Claustrophobia, panic and heat exhaustion began to set in for many folks.”

King used her umbrella to pry the doors open slightly — just enough to get a fresh breeze from the platform. “Even an inch made all the difference,” she said.

The NYPIRG Straphangers Campaign has called for an “in-depth investigation of [the MTA’s] handling of all aspects of last night’s hellish train delay.”

City Hall pressed the state-run agency for answers as well.

“This was an unacceptable failure on many levels. The MTA has to do a better job of communicating with straphangers during an emergency,” said Austin Finan, a mayoral spokesman. “The MTA must work to prevent these incidents in the future by prioritizing basic maintenance and laying out a clear-cut plan to aid and assist stranded passengers.”

John Raskin, the executive director at the Riders Alliance, said he wants the governor’s office to put forth a plan that outlines how the MTA will combat delays and service interruptions.

“It used to be that subway delays are inconvenient. It’s now becoming clear that they are also dangerous,” Raskin said. “Governor Cuomo did not invent the idea of underinvesting in transit, but he’s the only person in the position to turn that around and he needs to take aggressive action.”

Steve Morello, an MTA spokesman, said addressing the mounting delays “is the very goal of the six-point plan announced last month.” The plan offers mitigation strategies such as expedited delivery of new cars and the creation of “rapid response teams” to address track and signal problems.

The agency is currently investigating the cause of the power failure, he said.

“While the rail control center and service supervisor responded promptly to this problem, we need to continue the push to minimize both the frequency and the duration of system failures and delays,” Morello continued.

“When I hear something like this, I just roll my eyes. Like there we go again, another train meltdown,” said Ashley Cranston, 25, of the Upper West Side. “I’m late to work by five to 20 minutes almost every single day but if I hop on one train earlier I’m there 20 minutes early.”

To some witnesses, the affair was just part of another Monday. Several commuters on the platform at Broadway-Lafayette actually attempted to board the stuffed train once its doors were finally opened.

“They very confusingly tried to board,” King said. “It is New York and people have to get where they’re going.”