A newly-discovered map of the Battle of Antietam has shown that thousands of fallen soldiers were temporarily buried on the Civil War Battleground in a stunning visualization of the devastation of the battle. 

The map, recently digitized by the New York Public Library, shows the location of more than 5,800 graves in an area of just 12 square miles and adds another visual representation of one of the bloodiest battles in the Civil War that thousands of Irish soldiers fought in. 

Both Union and Confederate soldiers were buried close to where they were slain, according to the map.

The bodies of 300 Confederate soldiers, for instance, were buried near Hog Trough Road, a sunken farm lane where they had fought earlier that day. 

Around 200 Union soldiers were buried only a few yards away, where they had died attacking their Confederate counterparts. 

The battle is infamous in the annals of the Civil War with more than 3,500 dying during the 12-hour battle in September 1862, the single bloodiest day in the history of the war when the Union Army was trying to halt the Confederate advance in Maryland.

Another 17,300 soldiers were wounded in the battle, according to the Smithsonian Magazine, with one in seven of the wounded soldiers dying in the days immediately following the battle. Another 1,800 soldiers were captured or went missing in the battle outside Sharpsburg, Maryland. 

The Irish Brigade, led by General Francis Meagher, played a central role in the battle and suffered heavy casualties while attacking Confederate troops. Around 60% of Irish soldiers who went into battle died on that fateful day. 

There were so many Confederate and Union casualties on the sunken road that the Irish Brigade was attacking, for example, that the road has since been renamed "Bloody Lane". 

Read more: Celebrating the Irish who fought in the Civil War this Memorial Day

And now, this newly-discovered map highlights the untold carnage and devastation that took place in the battle like no other document has been able to do. 

Prominent mapmaker Simon G. Elliott drew the map about two years after the battle, just before Union soldiers were reinterred in the newly-established Antietam National Cemetery and before Confederate soldiers were moved from their temporary resting place on the battlefield to several nearby cemeteries. 

More than 150 years later, historian Timothy Smith chanced upon the map while searching the New York Public Library's digital collection for a similar map of the Battle of Gettysburg. 

"When I opened up the file, I was utterly taken aback and knew I was looking at something extraordinary," Smith told the Culpeper Star-Exponent. 

He told the Washington Post that the map was startling to look at and a visual representation of the carnage of the battle. 

Gerry Adelman, chief historian at the American Battlefield Trust, said that the discovery would "reverberate for decades." 

"Every one of us who’s looked at this absolutely flips out," he told the Washington Post. 

The unique map was digitized by the New York Public Library several years ago but its significance was only recognized when Smith stumbled upon it a few weeks ago. 

Read more: On this day: Irish Brigade suffers mass casualties at The Battle of Antietam