Quality modern hot tubs have significant insulation. I can't see surrounding the outside with foam would do much other than make it look like an eye sore.
Well you could say the same thing about homes - that the typical R-38 is enough in your walls and R-60 in the ceiling. But if you want to be super efficient and use as little energy as possible (especially in cold climates), you could make it R-60 in the walls and R-90 or even R-140 in the ceiling. Maine gets COLD.
Except that the volume of a hot tub and the thermal capacity of water is orders-of-magnitude different between a home and a hot tub. modern hot tubs already use closed-cell foam inside the shell as well as throughout the cabinet, and when the hot tub remains closed the heat loss is fairly minimal given its surface-area:volume.
When you are using the hot tub, heat-loss is going to be very high due to the fact that the top will be off and the water will be in motion (convection).
When its not in use, the majority of the heat loss is through the cover (analogous to the roof in your example), so having a high quality cover is key. Next up is adding a bubble-mat to the water's surface (which slows down thermal loss from the water to the air space above) and (if you really want) placing an additional level of rigid foam on the top.
Ultimately further insulation efforts won't amount to much if you are using the hot tub even semi-frequently (e.g. 2-3x per week or more), as >90% of heating costs come during use and not while the hot tub is closed and in stand-by. If you aren't using it much in the winter, a simpler solution would be to either drain the tub completely or let the temperature drop to the lowest the unit will allow (usually 64ºF). The latter is only energy efficient if you use the tub infrequently, once-per-week or less (depending on volume).
experience: someone who used to service hot tubs and who also lives in Maine.