Class Ellipsoid
- java.lang.Object
-
- org.openstreetmap.josm.data.projection.Ellipsoid
-
public final class Ellipsoid extends java.lang.Object
Reference ellipsoids.
-
-
Field Summary
Fields Modifier and Type Field Description doubleahalf long axisstatic EllipsoidAiryAiry 1830static EllipsoidAiryModModified Airy 1849static EllipsoidAustSAAustralian National Spheroid (Australian Natl & S.doublebhalf short axisstatic EllipsoidBessel1841Bessel 1841 ellipsoidstatic EllipsoidBesselNamibiaBessel 1841 (Namibia)static EllipsoidClarke1866Clarke 1866 ellipsoidstatic EllipsoidClarke1880Clarke 1880 (modified)static EllipsoidClarkeIGNClarke 1880 IGN (French national geographic institute)doubleefirst eccentricity: sqrt(a*a - b*b) / adoublee2first eccentricity squared: (a*a - b*b) / (a*a)doubleeb2square of the second eccentricity: (a*a - b*b) / (b*b)static EllipsoidEverestEverest 1830static EllipsoidEverest1948Everest 1948static EllipsoidEverest1956Everest 1956static EllipsoidEverest1969Everest 1969static EllipsoidEverestSabahSarawakEverest (Sabah & Sarawak)static EllipsoidFischerFischer (Mercury Datum) 1960static EllipsoidFischer1968Fischer 1968static EllipsoidFischerModModified Fischer 1960static EllipsoidGRS67GRS67 ellipsoidstatic EllipsoidGRS80GRS80 ellipsoidstatic EllipsoidHayfordHayford's ellipsoid 1909 (ED50 system) Also known as International 1924 Proj.4 code: intlstatic EllipsoidHelmertHelmert 1906static EllipsoidHoughHoughstatic EllipsoidKrassowskyKrassowsky 1940 ellipsoidstatic EllipsoidSphereSpherebooleansphericalif ellipsoid is spherical, i.e. the major and minor semiaxis are the samestatic EllipsoidWalbeckWalbeckstatic EllipsoidWGS66WGS66 ellipsoidstatic EllipsoidWGS72WGS72 ellipsoidstatic EllipsoidWGS84WGS84 ellipsoid
-
Constructor Summary
Constructors Modifier Constructor Description privateEllipsoid(double a, double b, double e, double e2, double eb2, boolean sperical)private constructur - use one of the create_* methods
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description LatLoncart2LatLon(double... xyz)convert cartesian coordinates to ellipsoidal coordinatesLatLoncart2LatLon(double[] xyz, double epsilon)static EllipsoidcreateAb(double a, double b)create a new ellipsoidstatic EllipsoidcreateAes(double a, double es)create a new ellipsoidstatic EllipsoidcreateAf(double a, double f)create a new ellipsoidstatic EllipsoidcreateArf(double a, double rf)create a new ellipsoiddoublelatitude(double latIso, double e, double epsilon)Returns geographic latitude of isometric latitude of first eccentricity (e) and epsilon precisiondoublelatitudeIsometric(double phi)Returns isometric latitude of phi on first eccentricity (e)doublelatitudeIsometric(double phi, double e)Returns isometric latitude of phi on given first eccentricity (e)double[]latLon2Cart(LatLon coord)convert ellipsoidal coordinates to cartesian coordinatesdoublemeridionalArc(double phi)Returns the meridional arc, the true meridional distance on the ellipsoid from the equator to the specified latitude, in meters.doublemeridionalRadiusOfCurvature(double phi)Returns the radius of curvature in the meridian for this reference ellipsoid at the specified latitude.private static doublesqr(double x)java.lang.StringtoString()doubleverticalRadiusOfCurvature(double phi)Returns the radius of curvature in the prime vertical for this reference ellipsoid at the specified latitude.
-
-
-
Field Detail
-
AustSA
public static final Ellipsoid AustSA
Australian National Spheroid (Australian Natl & S. Amer. 1969) same as GRS67 Modified
-
Bessel1841
public static final Ellipsoid Bessel1841
Bessel 1841 ellipsoid
-
BesselNamibia
public static final Ellipsoid BesselNamibia
Bessel 1841 (Namibia)
-
Clarke1866
public static final Ellipsoid Clarke1866
Clarke 1866 ellipsoid
-
Clarke1880
public static final Ellipsoid Clarke1880
Clarke 1880 (modified)
-
ClarkeIGN
public static final Ellipsoid ClarkeIGN
Clarke 1880 IGN (French national geographic institute)
-
Everest1948
public static final Ellipsoid Everest1948
Everest 1948
-
Everest1956
public static final Ellipsoid Everest1956
Everest 1956
-
Everest1969
public static final Ellipsoid Everest1969
Everest 1969
-
EverestSabahSarawak
public static final Ellipsoid EverestSabahSarawak
Everest (Sabah & Sarawak)
-
FischerMod
public static final Ellipsoid FischerMod
Modified Fischer 1960
-
Fischer1968
public static final Ellipsoid Fischer1968
Fischer 1968
-
Hayford
public static final Ellipsoid Hayford
Hayford's ellipsoid 1909 (ED50 system) Also known as International 1924 Proj.4 code: intl
-
Krassowsky
public static final Ellipsoid Krassowsky
Krassowsky 1940 ellipsoid
-
a
public final double a
half long axis
-
b
public final double b
half short axis
-
e
public final double e
first eccentricity: sqrt(a*a - b*b) / a
-
e2
public final double e2
first eccentricity squared: (a*a - b*b) / (a*a)
-
eb2
public final double eb2
square of the second eccentricity: (a*a - b*b) / (b*b)
-
spherical
public final boolean spherical
if ellipsoid is spherical, i.e. the major and minor semiaxis are the same
-
-
Constructor Detail
-
Ellipsoid
private Ellipsoid(double a, double b, double e, double e2, double eb2, boolean sperical)
private constructur - use one of the create_* methods- Parameters:
a- semimajor radius of the ellipsoid axisb- semiminor radius of the ellipsoid axise- first eccentricity of the ellipsoid ( = sqrt((a*a - b*b)/(a*a)))e2- first eccentricity squaredeb2- square of the second eccentricitysperical- if the ellipsoid is sphere
-
-
Method Detail
-
createAb
public static Ellipsoid createAb(double a, double b)
create a new ellipsoid- Parameters:
a- semimajor radius of the ellipsoid axis (in meters)b- semiminor radius of the ellipsoid axis (in meters)- Returns:
- the new ellipsoid
-
createAes
public static Ellipsoid createAes(double a, double es)
create a new ellipsoid- Parameters:
a- semimajor radius of the ellipsoid axis (in meters)es- first eccentricity squared- Returns:
- the new ellipsoid
-
createAf
public static Ellipsoid createAf(double a, double f)
create a new ellipsoid- Parameters:
a- semimajor radius of the ellipsoid axis (in meters)f- flattening ( = (a - b) / a)- Returns:
- the new ellipsoid
-
createArf
public static Ellipsoid createArf(double a, double rf)
create a new ellipsoid- Parameters:
a- semimajor radius of the ellipsoid axis (in meters)rf- inverse flattening- Returns:
- the new ellipsoid
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
verticalRadiusOfCurvature
public double verticalRadiusOfCurvature(double phi)
Returns the radius of curvature in the prime vertical for this reference ellipsoid at the specified latitude.- Parameters:
phi- The local latitude (radians).- Returns:
- The radius of curvature in the prime vertical (meters).
-
sqr
private static double sqr(double x)
-
meridionalArc
public double meridionalArc(double phi)
Returns the meridional arc, the true meridional distance on the ellipsoid from the equator to the specified latitude, in meters.- Parameters:
phi- The local latitude (in radians).- Returns:
- The meridional arc (in meters).
-
meridionalRadiusOfCurvature
public double meridionalRadiusOfCurvature(double phi)
Returns the radius of curvature in the meridian for this reference ellipsoid at the specified latitude.- Parameters:
phi- The local latitude (in radians).- Returns:
- The radius of curvature in the meridian (in meters).
-
latitudeIsometric
public double latitudeIsometric(double phi, double e)
Returns isometric latitude of phi on given first eccentricity (e)- Parameters:
phi- The local latitude (radians).e- first eccentricity- Returns:
- isometric latitude of phi on first eccentricity (e)
-
latitudeIsometric
public double latitudeIsometric(double phi)
Returns isometric latitude of phi on first eccentricity (e)- Parameters:
phi- The local latitude (radians).- Returns:
- isometric latitude of phi on first eccentricity (e)
-
latitude
public double latitude(double latIso, double e, double epsilon)
Returns geographic latitude of isometric latitude of first eccentricity (e) and epsilon precision- Parameters:
latIso- isometric latitudee- first eccentricityepsilon- epsilon precision- Returns:
- geographic latitude of isometric latitude of first eccentricity (e) and epsilon precision
-
cart2LatLon
public LatLon cart2LatLon(double... xyz)
convert cartesian coordinates to ellipsoidal coordinates- Parameters:
xyz- the coordinates in meters (X, Y, Z)- Returns:
- The corresponding latitude and longitude in degrees
-
cart2LatLon
public LatLon cart2LatLon(double[] xyz, double epsilon)
-
latLon2Cart
public double[] latLon2Cart(LatLon coord)
convert ellipsoidal coordinates to cartesian coordinates- Parameters:
coord- The Latitude and longitude in degrees- Returns:
- the corresponding (X, Y Z) cartesian coordinates in meters.
-
-