| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Mapping Toolbox |
| Contents | Index |
| Learn more about Mapping Toolbox |
km = deg2km(deg)
nm = deg2nm(deg)
sm
= deg2sm(deg)
km = deg2km(deg,radius)
nm = deg2nm(deg,radius)
sm
= deg2sm(deg,radius)
km = deg2km(deg,sphere)
nm = deg2nm(deg,sphere)
sm
= deg2sm(deg,sphere)
km = deg2km(deg) converts distances from degrees to kilometers as measured along a great circle on a sphere with a radius of 6371 km, the mean radius of the Earth.
nm = deg2nm(deg) and sm = deg2sm(deg) work identically, except that the output units are nautical miles and statute miles, respectively.
km = deg2km(deg,radius) converts distances from degrees to kilometers as measured along a great circle on a sphere having the specified radius. radius must be in units of kilometers.
For nm = deg2nm(deg,radius) and sm = deg2sm(deg,radius), make sure your input radius is in the appropriate units.
km = deg2km(deg,sphere) converts distances from degrees to kilometers, as measured along a great circle on a sphere approximating an object in the Solar System. sphere may be one of the following strings: 'sun', 'moon', 'mercury', 'venus', 'earth', 'mars', 'jupiter', 'saturn', 'uranus', 'neptune', or 'pluto', and is case-insensitive.
nm = deg2nm(deg,sphere) and sm = deg2sm(deg,sphere) work identically, except that the output units are nautical miles and statute miles, respectively.
A degree of arc length is about 60 nautical miles:
deg2nm(1) ans = 60.0405
This is not true on Mercury, of course:
deg2nm(1,'mercury') ans = 22.9852
deg2nm, degtorad, deg2sm, km2deg, sm2deg
![]() | defaultm | degrees2dm | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |