How can I use multiple zones for one defaultm?
2 ビュー (過去 30 日間)
古いコメントを表示
Is there a way to define a single defaultm with several zones (for instance 6 adjacent UTM zones - say 22E, 22F, 23E, 23F, 24E and 24F)?
Some context:
I am working with a project where I need to go through different UTM zones. I am using the Mapping Toolbox for that.
As my original coordinates are [Lon Lat] I must first transform the coordinate to coordinates in the relevant UTM zone. I do this using the following code (for instance Lat = -50 and Lon = -40 - I picked these randomly just for the context):
z1 = utmzone([Lat Lon]); % choose zone according to the GPS position
[ellipsoid, estr]=utmgeoid(z1); % choose a geoid according to the zone
utmstruct = defaultm('utm'); % create a default UTM structure
utmstruct.zone = z1; % set the UTM zone in the UTM structure
utmstruct.geoid = ellipsoid; % set the ellipsoid in the UTM structure
utmstruct = defaultm(utmstruct); % set the new UTM structure as default (again?!)
[X, Y] = mfwdtran(utmstruct,Lat, Lon);
If I need to find Lat, Lon I then use:
[newLat, newLon] = minvtran(utmstruct, newX, newY);
0 件のコメント
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Map Display についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!