(CNN) -- A tiny message hidden in Edvard Munch's famous painting "The Scream" was written by the artist himself, a new investigation of the work has found, finally resolving one of modern art's most enduring mysteries.
The message "Can only have been painted by a madman," scrawled and barely visible in the top left-hand corner of the painting, has been the subject of debate for decades and was widely believed to have been an act of vandalism by a viewer of the piece.
But extensive research by the National Museum of Norway has revealed that Munch wrote the phrase himself.
The Expressionist masterpiece is one of the most celebrated works of modern times, heralded as a timeless depiction of human anxiety. The subject's anguished face has become so familiar that it was recently given its own emoji.
Curators used infrared technology to analyze the message, which was added on top of the finished painting, comparing it with Munch's notes and letters and studying events around the time of the work's first public showing.
"The writing is without a doubt Munch's own," Mai Britt Guleng, the museum's curator, concluded. "The handwriting itself, as well as events that happened in 1895, when Munch showed the painting in Norway for the first time, all point in the same direction."
The work has been undergoing extensive conservation at the museum ahead of a public showing. It has rarely been exhibited since it was briefly stolen in 2004, and damage to the piece has become more apparent in recent years.
After its first public unveiling, some critics dismissed the unnerving painting and there was frenzied discussion about Munch's mental state, lending credence to the idea that an outraged third party scribbled their own damning review onto the work itself.
But curators said that reaction is probably what caused Munch to make the addition, with the artist upset about the critical response to the painting when he showed it in his hometown of Kristiania (now Oslo) for the first time.
"At a discussion night at the Students Association, where Munch is believed to have been present, the young medical student Johan Scharffenberg questioned Munch's mental health claiming that his paintings proved he was not of sound mind," the museum said. "It is likely that Munch added the inscription in 1895, or shortly after in response to the judgment on his work."
They added that Munch was hurt by the accusation and referred to it again in his own diary entries.
"The Scream" is understood to have been inspired by a walk Munch took through the city while in a state of mental and physical unease.
A pastel version of the painting fetched nearly $120 million from an anonymous buyer at a Sotheby's auction in New York in 2012 -- at that time a world record for a work of art sold at auction.
The-CNN-Wire & 2021 Cable News Network, Inc., a WarnerMedia Company. All rights reserved.
'Painted by a madman': Hidden message in 'The Scream' came from the artist himself
More TOP STORIES News