org.cts.datum
Class Ellipsoid

java.lang.Object
  extended by org.cts.IdentifiableComponent
      extended by org.cts.datum.Ellipsoid
All Implemented Interfaces:
Identifiable

public class Ellipsoid
extends IdentifiableComponent

An ellipsoid is a mathematical surface used to describe the Earth surface.

It is only an approximation of the Earth surface, but it is used as a reference surface for the expression of coordinates as a latitude and a longitude.

The definition of an ellipsoid is based on two parameters :

Note on the precision of some algorithms :

Author:
Michaël Michaud, Jules Party

Nested Class Summary
static class Ellipsoid.SecondParameter
          The second parameter use to create the ellipsoid, this parameter can be the inverse flattening, the semi-minor axis or the eccentricity.
 
Field Summary
static Ellipsoid AIRY
          Airy 1830.
static Ellipsoid AIRYMOD
          Airy Modified 1849.
static Ellipsoid AustSA
          GRS 1967 (SAD 1969) ellipsoid, used in Australian Geodetic Datum and in South American Datum 1969.
static Ellipsoid BESSEL1841
          Bessel 1841.
static Ellipsoid BESSNAM
          Bessel Namibia (GLM).
static Ellipsoid CLARKE1866
          Clarke 1866.
static Ellipsoid CLARKE1880ARC
          Clarke 1880 (Arc).
static Ellipsoid CLARKE1880IGN
          Clarke 1880 (IGN).
static Ellipsoid CLARKE1880RGS
          Clarke 1880 (RGS) or Clarke 1880 modified.
static Map<String,Ellipsoid> ellipsoidFromName
          ellipsoidFromName associates each ellipsoid to a short string used to recognize it in CTS.
static Ellipsoid EVERESTSS
          Everest 1830 (1967 definition).
static Ellipsoid GRS67
          GRS 1967 ellipsoid, used in Australian Geodetic Datum and in South American Datum 1969.
static Ellipsoid GRS80
          GRS 1980 ellipsoid, used in most recent spatial geodetic system (1990 and after).
static Ellipsoid HELMERT
          Helmert 1906.
static Ellipsoid INTERNATIONAL1924
          International 1924.
static Ellipsoid KRASSOWSKI
          Krassowski 1940.
static Ellipsoid SPHERE
          Perfect SPHERE.
static Ellipsoid WGS66
          WGS 66.
static Ellipsoid WGS72
          WGS 72.
static Ellipsoid WGS84
          WGS84 ellipsoid, used with the WGS84 spatial geodetic datum.
 
Fields inherited from interface org.cts.Identifiable
DEFAULT, LOCAL, UNKNOWN
 
Method Summary
 double arcFromLat(double phi)
          Computes the meridian arc from equator to point with ellipsoidal latitude phi.
static Ellipsoid createEllipsoidFromEccentricity(double semiMajorAxis, double eccentricity)
          Creates a new Ellipsoid whose definition is based on semi-major axis and eccentricity and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.
static Ellipsoid createEllipsoidFromEccentricity(Identifier identifier, double semiMajorAxis, double eccentricity)
          Creates a new Ellipsoid whose definition is based on semi-major axis and eccentricity and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.
static Ellipsoid createEllipsoidFromInverseFlattening(double semiMajorAxis, double invFlattening)
          Creates a new Ellipsoid whose definition is based on semi-major axis and inverse flattening and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.
static Ellipsoid createEllipsoidFromInverseFlattening(Identifier identifier, double semiMajorAxis, double invFlattening)
          Creates a new Ellipsoid whose definition is based on semi-major axis and inverse flattening and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.
static Ellipsoid createEllipsoidFromSemiMinorAxis(double semiMajorAxis, double semiMinorAxis)
          Creates a new Ellipsoid whose definition is based on semi-major axis and semi-minor axis and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.
static Ellipsoid createEllipsoidFromSemiMinorAxis(Identifier identifier, double semiMajorAxis, double semiMinorAxis)
          Creates a new Ellipsoid whose definition is based on semi-major axis and semi-minor axis and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.
 double curvilinearAbscissa(double latitude)
          Returns the curvilinear abscissa of the meridian arc for this latitude on an ellipsoid with eccentricity = this.e and semi-major axis = 1.0.
 boolean equals(Object other)
          Returns true if this Ellipsoid can be considered as equals to another one.
 double[] getArcCoeff()
          Get coefficients for the meridian arc length.
 double getEccentricity()
          Return the eccentricity of this ellipsoid (fr : excentricit�).
 double getFlattening()
          Return the flattening of this ellipsoid (fr : aplatissement).
 double getInverseFlattening()
          Return the inverse flattening of this ellipsoid (fr : aplatissement inverse).
 double[] getKCoeff(int max)
          Get k coefficients computed with an iterative method.
 double getSecondEccentricitySquared()
          Return the second eccentricity ((a-b)/b) of this ellipsoid (fr : seconde excentricité).
 double getSemiMajorAxis()
          Return the semi-major axis of this ellipsoid (fr : demi grand axe).
 double getSemiMinorAxis()
          Return the semi-minor axis of this ellipsoid (fr : demi petit axe).
 double getSquareEccentricity()
          Return the square eccentricity of this ellipsoid (fr : carré de l'excentricité).
 double grandeNormale(double latitude)
           
 int hashCode()
          Returns the hash code for this Ellipsoid.
 void initKCoeff(int max)
          This second method to compute the meridian arc length is taken from .
 double isometricLatitude(double latitude)
          Computes isometric latitude from geographic (or geodetic) latitude.
 double latFromArc(double s)
          Computes the ellipsoidal latitude from meridian arc length.
 double latitude(double isoLatitude)
          Computes geographic latitude from isometric latitude.
 double latitude(double isoLatitude, double epsilon)
          Computes the geographic latitude from the isometric latitude (fr : calcul de la latitude géographique à partir de la latitude isometrique).
 double meridionalRadiusOfCurvature(double latitude)
          The Meridional Radius of Curvature is the radius of curvature, at a specific latitude, of the ellipse used to generate the ellipsoid.
 String toString()
          Return a string representtaion of this ellipsoid.
 String toWKT()
          Returns a WKT representation of the ellipsoid.
 double transverseRadiusOfCurvature(double latitude)
          The Transverse Radius of Curvature or radius of the first vertical section or prime vertical radius of curvature (fr : Grande Normale).
 
Methods inherited from class org.cts.IdentifiableComponent
addAlias, addRemark, getAliases, getAuthorityKey, getAuthorityName, getCode, getComponent, getIdentifier, getName, getRemarks, getShortName, setIdentifier, setRemarks, setShortName
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

SPHERE

public static final Ellipsoid SPHERE
Perfect SPHERE.


GRS80

public static final Ellipsoid GRS80
GRS 1980 ellipsoid, used in most recent spatial geodetic system (1990 and after).


WGS84

public static final Ellipsoid WGS84
WGS84 ellipsoid, used with the WGS84 spatial geodetic datum. This ellipsoid (and datum) is coherent with GRS80 and the ITRS.


INTERNATIONAL1924

public static final Ellipsoid INTERNATIONAL1924
International 1924.


BESSEL1841

public static final Ellipsoid BESSEL1841
Bessel 1841.


CLARKE1866

public static final Ellipsoid CLARKE1866
Clarke 1866.


CLARKE1880IGN

public static final Ellipsoid CLARKE1880IGN
Clarke 1880 (IGN).


CLARKE1880RGS

public static final Ellipsoid CLARKE1880RGS
Clarke 1880 (RGS) or Clarke 1880 modified.


CLARKE1880ARC

public static final Ellipsoid CLARKE1880ARC
Clarke 1880 (Arc). Note that the ellipsoid called clrk80 in the proj library is defined as the Clarke 1880 mod. (modified) which is refered as the Clarke 1880 (RGS) in the epsg database, with an inverse flattening parameter of 293.465 instead of 293.466


KRASSOWSKI

public static final Ellipsoid KRASSOWSKI
Krassowski 1940.


EVERESTSS

public static final Ellipsoid EVERESTSS
Everest 1830 (1967 definition).


GRS67

public static final Ellipsoid GRS67
GRS 1967 ellipsoid, used in Australian Geodetic Datum and in South American Datum 1969.


AustSA

public static final Ellipsoid AustSA
GRS 1967 (SAD 1969) ellipsoid, used in Australian Geodetic Datum and in South American Datum 1969.


AIRY

public static final Ellipsoid AIRY
Airy 1830.


BESSNAM

public static final Ellipsoid BESSNAM
Bessel Namibia (GLM).


HELMERT

public static final Ellipsoid HELMERT
Helmert 1906.


AIRYMOD

public static final Ellipsoid AIRYMOD
Airy Modified 1849.


WGS66

public static final Ellipsoid WGS66
WGS 66.


WGS72

public static final Ellipsoid WGS72
WGS 72.


ellipsoidFromName

public static final Map<String,Ellipsoid> ellipsoidFromName
ellipsoidFromName associates each ellipsoid to a short string used to recognize it in CTS.

Method Detail

getSemiMajorAxis

public double getSemiMajorAxis()
Return the semi-major axis of this ellipsoid (fr : demi grand axe).


getInverseFlattening

public double getInverseFlattening()
Return the inverse flattening of this ellipsoid (fr : aplatissement inverse).


getSemiMinorAxis

public double getSemiMinorAxis()
Return the semi-minor axis of this ellipsoid (fr : demi petit axe).


getFlattening

public double getFlattening()
Return the flattening of this ellipsoid (fr : aplatissement).


getEccentricity

public double getEccentricity()
Return the eccentricity of this ellipsoid (fr : excentricit�).


getSquareEccentricity

public double getSquareEccentricity()
Return the square eccentricity of this ellipsoid (fr : carré de l'excentricité).


getSecondEccentricitySquared

public double getSecondEccentricitySquared()
Return the second eccentricity ((a-b)/b) of this ellipsoid (fr : seconde excentricité).


getArcCoeff

public double[] getArcCoeff()
Get coefficients for the meridian arc length.


getKCoeff

public double[] getKCoeff(int max)
Get k coefficients computed with an iterative method.


createEllipsoidFromInverseFlattening

public static Ellipsoid createEllipsoidFromInverseFlattening(double semiMajorAxis,
                                                             double invFlattening)
                                                      throws IllegalArgumentException
Creates a new Ellipsoid whose definition is based on semi-major axis and inverse flattening and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.

Parameters:
semiMajorAxis - length of the semi-major axis in meters
invFlattening - inverse flattening of the ellipsoid
Throws:
IllegalArgumentException

createEllipsoidFromInverseFlattening

public static Ellipsoid createEllipsoidFromInverseFlattening(Identifier identifier,
                                                             double semiMajorAxis,
                                                             double invFlattening)
                                                      throws IllegalArgumentException
Creates a new Ellipsoid whose definition is based on semi-major axis and inverse flattening and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.

Parameters:
identifier - ellipsoid identifier
semiMajorAxis - length of the semi-major axis in meters
invFlattening - inverse flattening of the ellipsoid
Throws:
IllegalArgumentException

createEllipsoidFromSemiMinorAxis

public static Ellipsoid createEllipsoidFromSemiMinorAxis(double semiMajorAxis,
                                                         double semiMinorAxis)
                                                  throws IllegalArgumentException
Creates a new Ellipsoid whose definition is based on semi-major axis and semi-minor axis and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.

Parameters:
semiMajorAxis - length of the semi-major axis in meters
semiMinorAxis - semi-minor-axis of the ellipsoid
Throws:
IllegalArgumentException

createEllipsoidFromSemiMinorAxis

public static Ellipsoid createEllipsoidFromSemiMinorAxis(Identifier identifier,
                                                         double semiMajorAxis,
                                                         double semiMinorAxis)
                                                  throws IllegalArgumentException
Creates a new Ellipsoid whose definition is based on semi-major axis and semi-minor axis and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.

Parameters:
identifier - ellipsoid identifier
semiMajorAxis - length of the semi-major axis in meters
semiMinorAxis - semi-minor-axis of the ellipsoid
Throws:
IllegalArgumentException

createEllipsoidFromEccentricity

public static Ellipsoid createEllipsoidFromEccentricity(double semiMajorAxis,
                                                        double eccentricity)
                                                 throws IllegalArgumentException
Creates a new Ellipsoid whose definition is based on semi-major axis and eccentricity and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.

Parameters:
semiMajorAxis - length of the semi-major axis in meters
eccentricity - semi-minor-axis of the ellipsoid
Throws:
IllegalArgumentException

createEllipsoidFromEccentricity

public static Ellipsoid createEllipsoidFromEccentricity(Identifier identifier,
                                                        double semiMajorAxis,
                                                        double eccentricity)
                                                 throws IllegalArgumentException
Creates a new Ellipsoid whose definition is based on semi-major axis and eccentricity and initializes common parameters such as a, b, e, e2, f, 1/f, e'2 and coefficients for the meridian arc.

Parameters:
identifier - ellipsoid identifier
semiMajorAxis - length of the semi-major axis in meters
eccentricity - semi-minor-axis of the ellipsoid
Throws:
IllegalArgumentException

initKCoeff

public void initKCoeff(int max)
This second method to compute the meridian arc length is taken from . It is based upon an iterative method and the precision of the result will depend on the number of iterations. It is to be used with arcFromLat or from latFromArc.


arcFromLat

public double arcFromLat(double phi)
Computes the meridian arc from equator to point with ellipsoidal latitude phi.

Parameters:
phi - the ellipsoidal latitude
Returns:
the meridian arc in meters

latFromArc

public double latFromArc(double s)
                  throws ArithmeticException
Computes the ellipsoidal latitude from meridian arc length.

Parameters:
s - the meridian arc length in meters
Returns:
the ellipsoidal latitude
Throws:
ArithmeticException

meridionalRadiusOfCurvature

public final double meridionalRadiusOfCurvature(double latitude)
The Meridional Radius of Curvature is the radius of curvature, at a specific latitude, of the ellipse used to generate the ellipsoid.

Parameters:
latitude - the geographic latitude
Returns:
the radius of curvature in meters

transverseRadiusOfCurvature

public final double transverseRadiusOfCurvature(double latitude)
The Transverse Radius of Curvature or radius of the first vertical section or prime vertical radius of curvature (fr : Grande Normale).

This is the radius of curvature in the plane which is normal to (i.e. perpendicular to) both the surface of the ellipsoid at, and the meridian passing through, the specific point of interest.

Parameters:
latitude - geographic latitude in radians
Returns:
a double value representing a length in meters

grandeNormale

public final double grandeNormale(double latitude)

isometricLatitude

public final double isometricLatitude(double latitude)
Computes isometric latitude from geographic (or geodetic) latitude.

Geographic latitude of a point P located on the surface of the ellipsoid is the angle between the perpendicular to the ellipsoid surface at P and the equatorial plan.

Isometric latitude is a function of geographic latitude L(lat) such as (lambda, L) is a symmetric parametric form of the ellipsoid surface.

Ref. IGN ALG0001

Parameters:
latitude - geographic latitude
Returns:
isometric latitude in radians

latitude

public final double latitude(double isoLatitude,
                             double epsilon)
Computes the geographic latitude from the isometric latitude (fr : calcul de la latitude géographique à partir de la latitude isometrique).

Geographic latitude of a point P located on the surface of the ellipsoid is the angle between the perpendicular to the ellipsoid surface at P and the equatorial plan.

Isometric latitude is a function of geographic latitude L(lat) such as (lambda, L) is a symmetric parametric form of the ellipsoid surface.

Geographic latitude is computed as the limit of a convergent suite. The loop is stopped when two consecutive terms of the suite is less than epsilon.

Ref. IGN ALG0002

Parameters:
isoLatitude - latitude isometrique
epsilon - value controlling the stop condition of this convergent sequence. Use 1E-10 for a precision of about 0.6 mm, 1E-11 for a precision of about 0.06 mm and 1E-12 for a preciison of about 0.006 mm
Returns:
the geographic latitude as a double

latitude

public final double latitude(double isoLatitude)
Computes geographic latitude from isometric latitude. The process stops as soon as the result reaches a pecision of 1.0E-11.

fr : Calcul la latitude géographique d'un point P à partir de sa latitude isométrique.

La latitude géographique est définie comme étant la limite d'une suite convergente. Le calcul de cette suite est interrompu lorsque la différence entre deux termes consécutifs est plus petit que 1E-11 (soit environ 0.006 mm).

Parameters:
isoLatitude - isometric latitude
Returns:
the geographic latitude in radians

curvilinearAbscissa

public double curvilinearAbscissa(double latitude)
Returns the curvilinear abscissa of the meridian arc for this latitude on an ellipsoid with eccentricity = this.e and semi-major axis = 1.0.

Usually noted beta, the meridian arc length is obtained by multiplying this result by the semi-major axis.

Parameters:
latitude - latitude.
Returns:
the curvilinear abscissa of this latitude on the meridian arc

toWKT

public String toWKT()
Returns a WKT representation of the ellipsoid.


toString

public String toString()
Return a string representtaion of this ellipsoid.

Overrides:
toString in class IdentifiableComponent

equals

public boolean equals(Object other)
Returns true if this Ellipsoid can be considered as equals to another one. Ellipsoid equals method is based on a comparison of the object dimensions with a sensibility of 0.1 mm.

Overrides:
equals in class IdentifiableComponent
Parameters:
other - the object to compare this Ellipsoid against

hashCode

public int hashCode()
Returns the hash code for this Ellipsoid.

Overrides:
hashCode in class IdentifiableComponent


Copyright © 2014 IRSTV CNRS-FR-2488. All Rights Reserved.