Aaah, the joy of a Popsicle on a hot summer day.
One theory places the source for the brain freeze in the sinuses, where the pain may be caused by the rapid cooling of air in the frontal sinuses. This triggers local pain receptors.
Another theory postulates that the constriction of blood vessels in the roof and rear of the mouth causes pain receptors to overload and refer the pain to your head. There is a nerve center there, in the back of your mouth, called the sphenopalatine ganglion, and this is the most likely source of the dreaded ice cream headache.
A friend of ours suggested a quick cure of rapidly rubbing your tongue on the roof of your mouth to warm it up. Her demonstration included a bizarre clucking sound. Leyner tried this and found himself followed by a large goose of whom he seems to have become inordinately fond.