How do the following statements show that Hawthorne had psychological insights that were far in advance of his time?
A. "Wherever there is a heart and an intellect, the diseases of the physical frame are tinged with the peculiarities of these."
B. "A bodily disease..may, after all, be but a symptom of some ailment in the spiritual part."
Hawthorne's understanding of human psychology and the relationship between mind and body is clearly manifested in the development of his major characters in the novel. The passages you cite show that Hawthorne recognized in his own time what science has now clearly established: Prolonged, unrelieved psychological stress impacts the body in physical ways that are detrimental to good health. His understanding of this fact is seen in the characters of both Arthur Dimmesdale and Roger Chillingworth.
Dimmesdale is plagued with guilt and self-loathing that grows only stronger as the novel progesses. As he continues to suffer psychologically, he fails physically. He grows pale; he becomes weaker and more infirm with each passing day. He walks with his hand over his heart, as if in response to a physical pain located there. It is this shocking decline in his health that finally prompts Hester to tell him Chillingworth's true identity. The minister is dying, and she acts to save his life.
The physical effects of Chillingworth's psychological state are equally pronounced. The old physician is consumed with hatred and lives to avenge himself upon Dimmesdale. He seeks not just to torture, but to destroy the young minister, slowly and deliberately, inflicting as much pain as possible upon him. As his malevolent psychological state continues and intensifies, the physical effects become obvious in Chillingworth. He becomes a stooped, twisted creature, frightening to behold. Although he never had been a handsome man, Chillingworth had once been a scholar and a scientist, gentle and distinguished. As his mind and spirit deteriorate, however, he takes on the appearance of a monster.
Hawthorne's physical characterizations of Dimmesdale and Chillingworth are extreme, to be sure. From a thematic standpoint, they serve to reflect outwardly and symbolically the inner spiritual state of each man. Our present knowledge of human psychology and the role it plays in physical health establishes that Hawthorne's characterizations are sound, not only in literary terms, but also in scientific ones.
We now understand what is often called the "Mind-Body Connection," which explains how our physical conditions might be affected by our emotional or spiritual states. Even though Hawthorne did not have our modern vocabulary to discuss this, there is no question that he was explaining what Freud would have called the subconscious or the unconscious. He had insight into the results of a puritanical and sexually repressive society, many years before Freud posed his theories, and an understanding that physical manifestations might be rooted in our minds and hearts.
There is considerable research to substantiate Hawthorne's statements. For example, people who are depressed are more prone to physical ailments, and people who are prayed for seem to recover more quickly. These are just two examples that come to my mind quickly, and I am sure others will be able to offer examples, too.
I do want to caution you, though, that this idea can be taken too far and be damaging in its application. For example, women were often accused of being witches when they had unusual physical characteristics, which were thought to be reflections of spiritual deficiencies. Hawthorne's ancestors played a large part in earlier witch trials, something that we think troubled Hawthorne considerably. Similarly, today, people who get cancer are often accused of not having enough good thoughts, of not being able to visualize good health, or of becoming sick because they insist on being depressed. So you see, there is a certain amount of blame that can be attached to this "Mind-Body Connection."
Nevertheless, it is important to bear in mind that our bodies, minds, and hearts are inextricably intertwined and that the connections should be respected. In this, Hawthorne anticipated the great theorists to come.