A calendar that was created by hunter gatherers around 8,000 BC has been discovered in Scotland. Archaeologists believe that this "ancient lunar calendar" might be the oldest calendar in the world, about 5,000 years older than the previously discovered formal calendars near Mesopotamia.

The calendar was originally discovered nearly a decade back, in 2004, at Aberdeenshire, Scotland, by the National Trust for Scotland.  But it is only now that study team, led by University of Birmingham, has analyzed data from the calendar site.

The site has 12 pits, each of which represents a lunar month. The pits are arranged in an arc facing a dip from where the sun aligns on the Midwinter's day, The Independent reported.

The archaeological site at Warren Field also provides an astronomical correction by aligning with the Midwinter sunrise- the start of a new solar year- helping the people re-calibrate the calendar every year. The calendar was in use between 8,000 BC (Mesolithic period) and 4,000 BC (Neolithic BC).

The pits have been marked and cut several times during its use. Also, researchers found that each lunar month was subdivided into a period of ten days depending on the phases of the moon, the independent reported.

 "The evidence suggests that hunter gatherer societies in Scotland had both the need and sophistication to track time across the years, to correct for seasonal drift of the lunar year and that this occurred nearly 5,000 years before the first formal calendars known in the Near East," said Dr Richard Bates, of the University of St Andrews in a news release.

"The site did not mark particular moonrises as the changing patterns of moonrise are far too complex - the argument is that it represents a combination of several different cycles which can be used to track time symbolically and practically. There are certainly hunter-gatherer societies who use the phase cycles of the moon to help synchronise different seasonal activities but it is remarkable that this could have been monumentalised at such an early period," said Clive Ruggles, Emeritus Professor of Archaeoastronomy at the University of Leicester.

The site was discovered by the Royal Commission on the Ancient and Historical Monuments of Scotland (RCAHMS) during an aerial survey.

The analysis of the site is published in the journal Internet Archaeology.