Rank: 936 based on 147 downloads (last 30 days) and 1 file submitted
photo

Mike Craymer

E-mail
Lat/Long
45.400288, -75.704575

Personal Profile:
Professional Interests:
geodesy, earth sciences, astronomy

 

Watch this Author's files

 

Files Posted by Mike
Updated   File Tags Downloads
(last 30 days)
Comments Rating
13 Feb 2013 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer geodesy, geodetic, angle, date, julian, gps week 147 33
  • 4.8
4.8 | 15 ratings
Comments and Ratings by Mike View all
Updated File Comments Rating
12 Apr 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer

Many thanks to Kyle for reporting the error in utm2ell for points in the southern hemisphere. The function will be fixed in the next release following his suggestion to use negative zone values for such points. For now users should subtract 1e7 m from southern hemisphere northings.

03 Mar 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer

Another error was discovered in the ell2utm function. The test for UTM zones less than zero should be a test for zones less than OR EQUAL TO zero. Replace

Zone=Zone+(Zone<0)*60-(Zone>60)*60;

with

Zone=Zone+(Zone<=0)*60-(Zone>60)*60;

The error occurs only for zone 60 (longitudes 174 - <180 east).

Thanks to Mohammad Ali Goudarzi for pointing out the error. I will post a new version of the toolbox with this correction and the ones given in my 27 Jul 2013 comment as soon as possible.

03 Mar 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer

Dear Dmitry,
Sorry I didn't see your post sooner. Here is an example of converting geocentric Cartesian coordinates to ellipsoidal with xyz2ell3 and then back again with ell2xyz:

>> [X,Y,Z]=ell2xyz(deg2rad(45),deg2rad(-79),300);
>> [lat3,lon3,h3]=xyz2ell3(X,Y,Z);
>> [X3,Y3,Z3]=ell2xyz(lat3,lon3,h3);
>> [X3-X;Y3-Y;Z3-Z]

ans =

1.0e-06 *

-0.1377
0.7087
0.7227

As you can see, the differences are less than a micron.

27 Jul 2013 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer

Two errors were discovered in the ell2utm.m and utm2ell.m functions. In ell2utm.m there is a vectorized calculation error for variable E2. Replace

E2=lam.^3.*cos(lat).^3/6*(1-t.^2+h2);

with

E2=lam.^3.*cos(lat).^3/6.*(1-t.^2+h2);

Thanks to John Marcovici for reporting this error.

And in utm2ell.m the function name on lines 1 & 2 is incorrect. Replace

function [lat,lon]=ell2utm(N,E,Zone,a,e2,lcm)
% ELL2UTM Converts UTM coordinates to ellipsoidal coordinates.

with

function [lat,lon]=utm2ell(N,E,Zone,a,e2,lcm)
% UTM2ELL Converts UTM coordinates to ellipsoidal coordinates.

Thanks to Andreas Wuestefeld for pointing out this error.

25 Sep 2011 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer

Re: 23 Jul 2011 post by muhammad faiz pa'suya

Dear Muhammad: The ell2utm function will automatically determine and output the standard UTM zone in which your input coordinates fall. To also have it output the central meridian for the zone(s), change the first line of the ell2utm.m function from

function [N,E,Zone]=ell2utm(lat,lon,a,e2,lcm)
to
function [N,E,Zone,lcm]=ell2utm(lat,lon,a,e2,lcm)

This will be implemented in the next version of the Toolbox. To understand how the zones are determined, see the Wikipedia entry for UTM.

Comments and Ratings on Mike's Files View all
Updated File Comment by Comments Rating
03 Jul 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer cai

大地主题正反算是关于测地线,而不是直线。
因此你的"direct"和"inverse"不是真正在解大地主题正反算。
"Geodetic problems" are about Geodesics on an ellipsoid, not straight line.
So your "direct" and "inverse" functions seems not working on "Geodetic problems".

12 Apr 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer Craymer, Mike

Many thanks to Kyle for reporting the error in utm2ell for points in the southern hemisphere. The function will be fixed in the next release following his suggestion to use negative zone values for such points. For now users should subtract 1e7 m from southern hemisphere northings.

10 Apr 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer Kyle

Great work Mike.

Small problem with utm2ell I think though; it doesn't work for the southern hemisphere.

Specifically, this line does not modify the false northing for the southern hemisphere:

No(N>1e7)=1e7;

I would suggest perhaps using a signed Zone to denote southern hemisphere and then:

No(Zone<0)=1e7;

03 Mar 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer Craymer, Mike

Another error was discovered in the ell2utm function. The test for UTM zones less than zero should be a test for zones less than OR EQUAL TO zero. Replace

Zone=Zone+(Zone<0)*60-(Zone>60)*60;

with

Zone=Zone+(Zone<=0)*60-(Zone>60)*60;

The error occurs only for zone 60 (longitudes 174 - <180 east).

Thanks to Mohammad Ali Goudarzi for pointing out the error. I will post a new version of the toolbox with this correction and the ones given in my 27 Jul 2013 comment as soon as possible.

03 Mar 2014 Geodetic Toolbox Toolbox for angle, coordinate and date conversions and transformations. Version 2.97. Author: Mike Craymer Craymer, Mike

Dear Dmitry,
Sorry I didn't see your post sooner. Here is an example of converting geocentric Cartesian coordinates to ellipsoidal with xyz2ell3 and then back again with ell2xyz:

>> [X,Y,Z]=ell2xyz(deg2rad(45),deg2rad(-79),300);
>> [lat3,lon3,h3]=xyz2ell3(X,Y,Z);
>> [X3,Y3,Z3]=ell2xyz(lat3,lon3,h3);
>> [X3-X;Y3-Y;Z3-Z]

ans =

1.0e-06 *

-0.1377
0.7087
0.7227

As you can see, the differences are less than a micron.

Contact us