Modeling and Optimizing the Integrated Energy-Water Nexus for Hydrogen Generation