From the point
long: 16.499050771335575, lat: -30.882
I want to find the corresponding latitude and longitude values that would result in a 200 km by 200 km square in which the aforementioned point would be the bottom left (southwest) corner of the square.
I stumbled upon Understanding terms in Length of Degree formula? that gave the corresponding formulas. So I used this to come up with the points of my square:
16.499050771335575,-29.07796275949132
18.584367695114103,-29.07796275949132
18.584367695114103,-30.882
16.499050771335575,-30.882
However, when using the following code to download the corresponding image from the Modis NDVI 1km data set through Google Earth Engine, I got a 233 by 201 image.
path = img.getDownloadUrl({
'scale': 1000,
'bands': [{'id':'NDVI'}],
'region': '[[16.499050771335575,-29.07796275949132],[18.584367695114103,-29.07796275949132],[18.584367695114103,-30.882],[16.499050771335575,-30.882],[16.499050771335575,-29.07796275949132]]'
})
I have double checked that the distances between the four points are indeed ~200 km.
I don't understand why the code is producing a 233 by 201 km image instead of the expected 200 by 200 km image?
Furthermore, when I moved the latitude up to the equator, I got an image returned by Google Earth engine that was 201 by 203, even though the distances between the points was ~200 (plus minus 1).
Update: After further investigation I've noticed that the distance between two neighboring pixels of the same latitude is 858 meters and not 1000 meters. This is odd, as I specified in the code the spatial resolution of 1000 meters.