All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class edu.sc.seis.TauP.SphericalCoords

edu.sc.seis.TauP.SphericalCoords

public class SphericalCoords
Utility class for spherical coordinate (lat-lon) transformations. Given lat, lon, lat, lon you can find the distance or azimuth and given lat, lon, distance, azimuth you can find the lat lon of the resultant point. Just uses spherical relations, no ellpticity correction is applied. See Appendix A of "Seismology and Plate Tectonics" by David Gubbins Cambridge University Press, 1990 and Chapter 3 of "Plate Tectonics: How it Works" by Allan Cox and Robert Brian Hart Blackwell Scientific Publications, 1986


Constructor Index

 o SphericalCoords()

Method Index

 o azimuth(double, double, double, double)
Calculates azimuth between two lat lon pairs.
 o distance(double, double, double, double)
Calculates angular distance between two lat lon pairs.
 o latFor(double, double, double, double)
Calculates the latitude of a point a given distance along a given azimuth from a starting lat lon.
 o lonFor(double, double, double, double)
Calculates the longitude of a point a given distance along a given azimuth from a starting lat lon.
 o main(String[])
 o rotate(double, double, double[], double)
rotates a point about a pole by an angle.
 o rotationPole(double, double, double, double)
Find the rotation pole required to rotate the first lat lon pair to the second.

Constructors

 o SphericalCoords
 public SphericalCoords()

Methods

 o distance
 public static double distance(double latA,
                               double lonA,
                               double latB,
                               double lonB)
Calculates angular distance between two lat lon pairs.

 o azimuth
 public static double azimuth(double latA,
                              double lonA,
                              double latB,
                              double lonB)
Calculates azimuth between two lat lon pairs.

 o rotationPole
 public static double[] rotationPole(double latA,
                                     double lonA,
                                     double latB,
                                     double lonB)
Find the rotation pole required to rotate the first lat lon pair to the second. Just does a cross product.

Returns:
s a 3 element double array with the X, Y and Z components of the pole.
 o rotate
 public static double[] rotate(double latA,
                               double lonA,
                               double pole[],
                               double angleDeg)
rotates a point about a pole by an angle.

Parameters:
pole - is a 3 element double array with X, Y and Z components of the pole.
Returns:
s [lat, lon] in array.
 o latFor
 public static double latFor(double latA,
                             double lonA,
                             double distance,
                             double azimuth)
Calculates the latitude of a point a given distance along a given azimuth from a starting lat lon.

 o lonFor
 public static double lonFor(double latA,
                             double lonA,
                             double distance,
                             double azimuth)
Calculates the longitude of a point a given distance along a given azimuth from a starting lat lon.

 o main
 public static void main(String args[])

All Packages  Class Hierarchy  This Package  Previous  Next  Index