"I hate to split hairs but the energy savings from the tankless is that
you don't keep 40 gallons of water hot and on standby. The energy used
to fill flush the pipe is the same with either, unless you get the
tankless close to the tap. Maybe that is what you are talking about. "
Yes, that is what I pictured in my mind, because the tankless ones I've
seen have been close to the point of use. If you just replace a
regular water heater with a tankless, then I agree, the same amount of
energy is wasted due to the pipe runs.