In Chapter X of "The Scarlet Letter" when Roger Chillingworth apparently drugs the minister and pushes away his vestment, the physician turns away. "But with what a wild look of wonder, joy, and honor! With what a ghastly rapture, ...too mighty to be expressed only by the eye...in ecstasy..." This passage suggests to many readers that as a result of the insidious mental torture from the physician and the agony in his soul from guilt, the Reverend Dimmesdale's scarlet letter on his chest becomes a physical manifestation of this guilt(simply appearing). It seems rather unlikely that Chillingworth would be as ecstatic as he is had Dimmesdale merely carved the letter onto his chest.
However, since he did punish himself by self-flagellation in an attempt to atone for his sin, many readers feel that Dimmesdale may also have made a self-inflicted letter upon his chest. And, it is because he has made this mark himself that Dimmesdale stands "with a look of triumph in his face, as one who, in the crisis of acutest pain, had won a victory." Dimmesdale has put the mark upon himself and has stood like Hester upon the scaffold. Scourged like a Christ-figure, he then dies.
In the final scaffold scene, some people do not see the letter "A" on Dimmesdale's chest at all. So, for them, it never existed. For those that did see it, some surmise that Dimmesdale had put it there himself, others that Chillingworth's medicine had somehow caused the "A" to emerge. Others suggested it was God's mark of sin. The most likely theory is that Dimmesdale put it there in order to punish himself. Chillingworth had discovered the "A" there earlier and seemed surprised and it is doubtful that any medicine would mark a person with a specific letter.