He has long been praised as one of the finest artists of the Renaissance, working far ahead of his time and producing some of the world’s most recognisable works.

But Leonardo da Vinci has finally received the credit he deserves for his “startling” medical accuracy hundreds of years in advance of his peers, as scientists match his anatomical drawings with modern day MRI scans.

The project, which will be unveiled at the Edinburgh International Festival in August, compares the work directly for the very first time, unveiling the minute details recorded by the artist.

The drawings, which were hundreds of years ahead of their time in some areas, remained among the artist’s personal papers when he died, effectively “lost” for several hundred years.

Had they been published at the time, the exhibition curators believe, they would have “formed the most influential work on the human body ever produced”.

“Five hundred years on, comparisons with CT and MRI scans show that Leonardo’s work is still relevant to scientists today,” they said.

Martin Clayton, exhibition curator, said the project was intended to examine the medical relevance of Leonardo's “astonishing” drawings for the first time.

Speaking at the launch of the Edinburgh International Festival, he admitted it had been a “voyage into the unknown”, which could have led to the conclusion Leonardo’s work was simply of historic curiosity, irrelevant to modern day anatomists”.

Instead, he revealed, doctors found the detailed drawings were “startling” in their accuracy.

The pictures, largely produced in the winter of 1510- 1511 when Leonardo completed around 20 dissections, show the muscles, bones and sinews of the human body.

One, of the heart, comes “agonisingly close” to showing how the pump action worked, with the movement of blood remarkably similar to that in a modern day medical video.

The artist also produced the first accurate depiction of the spine, as well as drawing a child in the womb in the correct position.

The Leonardo da Vinci: The Mechanics of Man exhibition, part of the festival showing the influence of technology on art, will open at The Queen’s Gallery, Palace of Holyroodhouse, in August.

It will be based on Leonardo’s ‘Anatomical Manuscript A’, on which he crammed more than 240 individual drawings and notes running to more than 13,000 words in his distinctive mirror-writing.

It has never before been displayed in its entirety in the UK.

Mr Clayton said: “Royal Collection Trust’s association with the Edinburgh International Festival, in a year when its programme focuses on the theme of technology, has prompted us to examine the modern relevance of Leonardo’s astonishing drawings.

“For the first time we will be displaying the artist’s works alongside stunning examples of medical imaging, showing how the concerns and methods of the world’s leading anatomists have changed little in 500 years, and how truly groundbreaking Leonardo’s investigations were.”

Jonathan Mills, director of the Edinburgh International Festival, said: “In a year when the Edinburgh International Festival is focusing on the myriad of ways in which technology seizes and shifts the imaginations of artists, there is no better example of that than the genius of Leonardo da Vinci and his sophisticated and poetic understanding of the human condition.”