I just recently replaced the heater in my 1987 45C. Same as mentioned above, mine was outside of the Port motor. I took a few measurements and quickly realized removal would not be possible without cutting it up. The one I was removing was 12 gallons I think and based on my measurements I purchased a 6 gallon one from Westmarine, since it would fit without taking apart half of the engine.
Removal was "easier" than I expected, since the heater was so rusted that everything basically fell apart and the tank itself fit around the exhaust and out benind the engine. Installation of the new, smaller one was straight forward, only had to loosen an ER over head light and a water filter base that were in the way.
Good luck,
JCG