A Geometric Approach To Isoperimetric Problems And The Semigeostrophic System