What quantity of freezing water could generate 300,000 joules of mechanical energy from expansion - enough to boil an electric kettle? When water freezes, it expands with considerable force - enough to break glass and burst through copper water pipes.
If this material expansion was harnessed  - e.g. liquid water placed in a container that can withstand the pressure, and the expansion upon freezing used to pressurise air or some other gas - what volume of water would be needed to capture 300,000 joules - equivalent to a small kettle (2kWh rating boiling for 2.5 minutes) - worth of usable energy?
 A: Consider the following apparatus. A mass $m$ of pure water sits in a strong cylinder. We cool it down to $\text{O}^{\circ}C$ and then close it off. At that point and that temperature the headspace above the water is a volume $V$ of an ideal gas (air is close enough). Assume for simplicity's sake $V\gg m$:

The water will now freeze to ice at $\text{O}^{\circ}C$ and the gas will be slightly compressed, due to expansion of the water/ice.
The expansion of the water to ice can be found from the densities of water and ice at $\text{O}^{\circ}C$ (see Wikipedia) and I leave that to you. I'll call the expansion $\delta V$.
The work (this is actual energy i.e. $\mathrm{J}$) done on the gas is now:
$$W=\int_0^{\delta V}P\text{d}V=P\delta V$$
where $P$ is the pressure. Because $\delta V$ is small I've assumed here that $P\approx \text{constant}$ (e.g. atmospheric pressure).
Play with some numbers to get a feel for how much energy this expansion could deliver.

What quantity of freezing water could generate 300,000 joules of
mechanical energy - enough to boil an electric kettle?

As seen above the quantity of water isn't the only factor: the pressure at which the process takes place strongly influences how much work the freezing work will do.
