Public Member Functions | Static Public Attributes
GeographicLib::TransverseMercator Class Reference

Transverse Mercator Projection. More...

#include <GeographicLib/TransverseMercator.hpp>

List of all members.

Public Member Functions

 TransverseMercator (double a, double invf, double k0) throw ()
void Forward (double lon0, double lat, double lon, double &x, double &y, double &gamma, double &k) const throw ()
void Reverse (double lon0, double x, double y, double &lat, double &lon, double &gamma, double &k) const throw ()

Static Public Attributes

static const TransverseMercator UTM

Detailed Description

Transverse Mercator Projection.

This uses Krüger's method which evaluates the projection and its inverse in terms of a series. See

Krüger's method has been extended from 4th to 6th order. The maximum errors is 5 nm (ground distance) for all positions within 35 degrees of the central meridian. The error in the convergence is 2e-15" and the relative error in the scale is 6e-12%%. (See Accuracy of transverse Mercator projection for the weasel words.) The speed penalty in going to 6th order is only about 1%. GeographicLib::TransverseMercatorExact is an alternative implementation of the projection using exact formulas which yield accurate (to 8 nm) results over the entire ellipsoid.

See TransverseMercator.cpp for more information on the implementation.

See Transverse Mercator Projection for a discussion of this projection.


Constructor & Destructor Documentation

GeographicLib::TransverseMercator::TransverseMercator ( double  a,
double  invf,
double  k0 
) throw ()

Constructor for a ellipsoid radius a (meters), inverse flattening invf, and central scale factor k0. Setting invf <= 0 implies invf = inf or flattening = 0 (i.e., a sphere).

Definition at line 57 of file TransverseMercator.cpp.


Member Function Documentation

void GeographicLib::TransverseMercator::Forward ( double  lon0,
double  lat,
double  lon,
double &  x,
double &  y,
double &  gamma,
double &  k 
) const throw ()

Convert from latitude lat (degrees) and longitude lon (degrees) to transverse Mercator easting x (meters) and northing y (meters). The central meridian of the transformation is lon0 (degrees). Also return the meridian convergence gamma (degrees) and the scale k. No false easting or northing is added. lat should be in the range [-90, 90]; lon and lon0 should be in the range [-180, 360].

Definition at line 177 of file TransverseMercator.cpp.

References GeographicLib::Constants::degree(), and GeographicLib::Constants::pi().

Referenced by main(), and GeographicLib::UTMUPS::Forward().

void GeographicLib::TransverseMercator::Reverse ( double  lon0,
double  x,
double  y,
double &  lat,
double &  lon,
double &  gamma,
double &  k 
) const throw ()

Convert from transverse Mercator easting x (meters) and northing y (meters) to latitude lat (degrees) and longitude lon (degrees) . The central meridian of the transformation is lon0 (degrees). Also return the meridian convergence gamma (degrees) and the scale k. No false easting or northing is added. The value of lon returned is in the range [-180, 180).

Definition at line 338 of file TransverseMercator.cpp.

References GeographicLib::Constants::pi(), and GeographicLib::Constants::degree().

Referenced by main(), and GeographicLib::UTMUPS::Reverse().


Member Data Documentation

A global instantiation of TransverseMercator with the WGS84 ellipsoid and the UTM scale factor. However, unlike UTM, no false easting or northing is added.

Definition at line 122 of file TransverseMercator.hpp.


The documentation for this class was generated from the following files: