Thermodynamics of Water Splitting