Areaquad, latitude and longitude angles do not give the same answer when exchanged
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Dear people,
I'm trying to find the area of patch defined by a rectangle projected onto a sphere. I do this by finding the angles between the origin of the sphere and the edges of the rectangle. These angles can be used as the latitude and longitudes for defining the dimensions of the patch on the sphere.
Now the maximum angles for this in both the X and Y direction are therefor -+90. This would give you half a sphere and thus the function areaquad would result in 0.5, which it does. Now the issue is that if I swap the angles for latitude and longitude or X and Y, I do not get the same area. -+63.43 and -+75.96, does not give the same as -+75.96 and -+63.43 (X,Y respectively), the first one gives an areaquad of 0.3419 and the second of 0.3775.
However if I plot these it can also be seen that they should have the same area, see code and images below.
%points=2;
%for ii=1:points
%overlap=zeros(1,points);
%set latitudes and longitude limits
lat1=-beta(2); %-63.43 or -75.96
lat2=beta(1); %63.43 or 75.96
long1=-alpha(2); %-75.96 or -63.43
long2=alpha(1); %75.96 or 63.43
lat=[lat1, lat1, lat2, lat2, lat1];
long=[long1, long2, long2, long1, long1];
latm=[-90, 90, 90, -90, -90];
longm=[-90, -90, 90, 90, -90];
figure
geoshow(long,lat)%,'DefaultFaceColor','red')
geoshow(longm*0.95,latm*0.95)%,'FaceColor','blue','FaceAlpha',0.3)
axis equal
overlap(ii)=areaquad(long1,lat1, long2, lat2);
%end
please explain me what I'm doing wrong or what's going on here.
0 comentarios
Respuestas (1)
jean-luc martin
el 15 de Jul. de 2017
Hello,
Sorry for reading your question so late, hope you already find an answer. The area of the quadrangle is spherical (not rectangle) and delimited by a "lune" and its intersection by 2 parallels. So that the both quadrangles are not equivalent if you swap lat and lon values. Try for example with lats (-2,+2) and lons (-85,+85) : a thin band almost rectangular around equator, then opposite (-85,+85) and (-2,+2): a thin lune around greenwich meridian. You may also wish to use Google Earth Pro to visualize on the globe.
Hope this helps,
0 comentarios
Ver también
Categorías
Más información sobre Geographic Plots en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!