A Variational Approach To The Prediction Of The Three-Dimensional Geometry Of Hydraulic Fractures