ucar.unidata.geoloc
Class Earth

java.lang.Object
  extended by ucar.unidata.geoloc.Earth
Direct Known Subclasses:
EarthEllipsoid

public class Earth
extends Object

Defines the shape of the earth ellipsoid.

Author:
Russ Rew

Constructor Summary
Earth()
          Spherical earth with canonical radius.
Earth(double radius)
          Create a spherical earth.
Earth(double equatorRadius, double poleRadius, double reciprocalFlattening)
          Create an ellipsoidal earth.
Earth(double equatorRadius, double poleRadius, double reciprocalFlattening, String name)
          _more_
 
Method Summary
 boolean equals(Object o)
          _more_
 double getEccentricity()
          Get the Eccentricity property.
 double getEccentricitySquared()
          Get the EccentricitySquared property.
 double getEquatorRadius()
          Get the EquatorRadius property.
 double getFlattening()
          Get the Flattening property.
 double getMajor()
          Get the equatorial radius (semimajor axis) of the earth, in meters.
 double getMinor()
          Get the polar radius (semiminor axis) of the earth, in meters.
 String getName()
          Get the Name property.
 double getPoleRadius()
          Get the PoleRadius property.
static double getRadius()
          Get radius of spherical earth, in meters
 void setEccentricity(double value)
          Set the Eccentricity property.
 void setEccentricitySquared(double value)
          Set the EccentricitySquared property.
 void setEquatorRadius(double value)
          Set the EquatorRadius property.
 void setFlattening(double value)
          Set the Flattening property.
 void setName(String value)
          Set the Name property.
 void setPoleRadius(double value)
          Set the PoleRadius property.
 String toString()
          _more_
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Earth

public Earth()
Spherical earth with canonical radius.


Earth

public Earth(double radius)
Create a spherical earth.

Parameters:
radius - radius of spherical earth.

Earth

public Earth(double equatorRadius,
             double poleRadius,
             double reciprocalFlattening)
Create an ellipsoidal earth. The reciprocalFlattening is used if not zero, else the poleRadius is used.

Parameters:
equatorRadius - equatorial radius (semimajor axis) in meters, must be specified
poleRadius - polar radius (semiminor axis) in meters
reciprocalFlattening - inverse flattening = 1/flattening = a / (a-b)

Earth

public Earth(double equatorRadius,
             double poleRadius,
             double reciprocalFlattening,
             String name)
_more_

Parameters:
equatorRadius - _more_
poleRadius - _more_
reciprocalFlattening - _more_
name - _more_
Method Detail

getRadius

public static double getRadius()
Get radius of spherical earth, in meters

Returns:
radius of spherical earth in meters

getMajor

public double getMajor()
Get the equatorial radius (semimajor axis) of the earth, in meters.

Returns:
equatorial radius (semimajor axis) in meters

getMinor

public double getMinor()
Get the polar radius (semiminor axis) of the earth, in meters.

Returns:
polar radius (semiminor axis) in meters

setName

public void setName(String value)
Set the Name property.

Parameters:
value - The new value for Name

getName

public String getName()
Get the Name property.

Returns:
The Name

setEccentricity

public void setEccentricity(double value)
Set the Eccentricity property.

Parameters:
value - The new value for Eccentricity

getEccentricity

public double getEccentricity()
Get the Eccentricity property.

Returns:
The Eccentricity

setEccentricitySquared

public void setEccentricitySquared(double value)
Set the EccentricitySquared property.

Parameters:
value - The new value for EccentricitySquared

getEccentricitySquared

public double getEccentricitySquared()
Get the EccentricitySquared property.

Returns:
The EccentricitySquared

setEquatorRadius

public void setEquatorRadius(double value)
Set the EquatorRadius property.

Parameters:
value - The new value for EquatorRadius

getEquatorRadius

public double getEquatorRadius()
Get the EquatorRadius property.

Returns:
The EquatorRadius

setPoleRadius

public void setPoleRadius(double value)
Set the PoleRadius property.

Parameters:
value - The new value for PoleRadius

getPoleRadius

public double getPoleRadius()
Get the PoleRadius property.

Returns:
The PoleRadius

setFlattening

public void setFlattening(double value)
Set the Flattening property.

Parameters:
value - The new value for Flattening

getFlattening

public double getFlattening()
Get the Flattening property.

Returns:
The Flattening

equals

public boolean equals(Object o)
_more_

Overrides:
equals in class Object
Parameters:
o - _more_
Returns:
_more_

toString

public String toString()
_more_

Overrides:
toString in class Object
Returns:
_more_


Copyright © 1999-2011 UCAR/Unidata. All Rights Reserved.