Prosecutors at alleged Chelsea bomber Ahmad Khan Rahimi’s trial Thursday dramatically unveiled the twisted hulk of a garbage dumpster catapulted across West 23rd Street by a pressure cooker bomb as a police expert described the lethal “frag blanket” he found in a second bomb.

“There is a whole blanket of ball bearings and lead balls where the purpose is just to cause pure devastation,” said Jason Hallik, the NYPD bomb squad cop who disabled a bomb left on West 27th Street. “There’s no other purpose to putting a frag blanket in the device . . . Picture it like a thousand guns going off at the same time.”

Hallik was the leadoff for the government on the fourth day of trial in Manhattan federal court, where Rahimi, 29, of Elizabeth, New Jersey, is charged with planting one bomb on West 23rd Street that detonated at 8:30 p.m. on Sept. 17, 2016, that injured 30 when it exploded, and another bomb on West 27th Street.

Rahimi, an Afghan-American who worked at a family chicken restaurant, is separately charged in New Jersey with planting bombs there and with a shootout with police in Linden, New Jersey, when he was caught. Prosecutors say he wanted to bring jihad to the streets of America.

Hallik testified that the seat of the blast was on the north side of West 23rd Street, near a series of dark green construction trash bins. The remains of one were found more than 100 feet away, on the south side of West 23rd.

Over objections from Rahimi’s defense team, which complained that bringing the damaged dumpster into court was all for show, prosecutor Shawn Crowley pulled off a white quilt and wheeled the 100-pound hunk of metal on a wood dolly from a corner of the courtroom to the front of the jury box.

It had a hole in what appeared to be the back, with bent edges and wheels twisted to the inside and a huge bulge in the front. Warning labels still visible said “Not Responsible for Injury” and “Do Not Play in or Around,” and white paint with the lettering “BIC” on the side.

“On one side you can see it’s pushed in, and it’s pushed out on the other side,” said Hallik. “This means the explosive device had to be placed next to the dumpster.”

Hallik also described for jurors how he manipulated a remote robot arm from a screen inside a command vehicle to first tug on the cellphone detonator attached to the West 27th Street bomb until the wires snapped, and then to pick up the pressure cooker and put it in a TCV — Total Containment Vessel — for transport.

At the NYPD range on Rodman’s Neck, said Hallik, an Iraq vet who disarmed Roadside bombs there, he worked on the bomb from behind a shield and while wearing a bomb-resistant suit.

After X-raying the pressure cooker, Hallik said he first tried to take the top off using a winch, but it was so tightly secured by silicon sealant that eventually he had to use a high-pressure water cannon to remove the top and spill out explosives, nuts, BBS, the frag blanket and Christmas lights that were part of the trigger.

“It’s like taking bullets out of a gun,” Hallik said.