How does a heat pump work?
Like solar hot water systems, heat pumps absorb heat from the air by drawing the air through fins on a radiator like device.
Heat is absorbed by refrigerant running through coils inside the tank which then heats the water in the tank to produce hot water very efficiently.
The pump collects energy from the surrounding air and transfers that thermal energy into the water in the storage tank.
With a heat pump you get 3-5 times as much energy out as you put in. With gas or electric heaters you get out only what you put in.