title: Google Static Maps Dimension Discrepancy
body: <p>I've been using the code shown in the answer to this question:</p>
  
  <p><a href="https://stackoverflow.com/questions/6048975/google-maps-v3-how-to-calculate-the-zoom-level-for-a-given-bounds">Google Maps V3 - How to calculate the zoom level for a given bounds</a></p>
  
  <p>but I can't seem to get my static maps to line up correctly. </p>
  
  <p>In this link, I can calculate the width correctly, but not the height.</p>
  
  <p><a href="http://maps.googleapis.com/maps/api/staticmap?center=30.42997,-91.179745&amp;zoom=11&amp;size=500x600&amp;scale=1&amp;format=png32&amp;maptype=roadmap&amp;sensor=false" rel="nofollow noreferrer">http://maps.googleapis.com/maps/api/staticmap?center=30.42997,-91.179745&amp;zoom=11&amp;size=500x600&amp;scale=1&amp;format=png32&amp;maptype=roadmap&amp;sensor=false</a></p>
  
  <p>From the SO post earlier, the height should be</p>
  
  <p><code>size * 360 / 256 / 2^Zoom</code></p>
  
  <p>so we plug in...</p>
  
  <p><code>600 * 360 / 256 / 2^11 = 0.41199</code></p>
  
  <p>This means that we expect top latitude of the image to be at <code>30.42997 + (0.41199 / 2) = 30.63596</code>. But when you plot that latitude on Google Maps and zoom to the same zoom level, the point is much higher than what our image is receiving. </p>
  
  <p>Any ideas on how I can calculate the height of the image that Google is sending back?</p>