public class Bearing extends Object
Constructor and Description |
---|
Bearing(double azimuth,
double backazimuth,
double distance) |
Modifier and Type | Method and Description |
---|---|
static Bearing |
calculateBearing(double lat1,
double lon1,
double lat2,
double lon2)
Computes distance (in km), azimuth (degrees clockwise positive
from North, 0 to 360), and back azimuth (degrees clockwise positive
from North, 0 to 360), from latitude-longituide point pt1 to
latitude-longituide pt2.
|
static Bearing |
calculateBearing(double lat1,
double lon1,
double lat2,
double lon2,
Bearing result)
Deprecated.
do not use
|
static Bearing |
calculateBearing(Earth e,
double lat1,
double lon1,
double lat2,
double lon2)
Computes distance (in km), azimuth (degrees clockwise positive
from North, 0 to 360), and back azimuth (degrees clockwise positive
from North, 0 to 360), from latitude-longituide point pt1 to
latitude-longituide pt2.
|
static Bearing |
calculateBearing(Earth e,
double lat1,
double lon1,
double lat2,
double lon2,
Bearing result)
Deprecated.
do not use
|
static Bearing |
calculateBearing(Earth e,
LatLonPoint pt1,
LatLonPoint pt2)
Calculate the bearing between the 2 points.
|
static Bearing |
calculateBearing(Earth e,
LatLonPoint pt1,
LatLonPoint pt2,
Bearing result)
Deprecated.
do not use
|
static Bearing |
calculateBearing(LatLonPoint pt1,
LatLonPoint pt2)
Calculate the bearing between the 2 points.
|
static Bearing |
calculateBearing(LatLonPoint pt1,
LatLonPoint pt2,
Bearing result)
Deprecated.
do not use
|
static LatLonPointImpl |
findPoint(double lat1,
double lon1,
double az,
double dist,
LatLonPointImpl result)
Deprecated.
will return LatLonPoint in 6.
|
static LatLonPointImpl |
findPoint(Earth e,
double lat1,
double lon1,
double az,
double dist,
LatLonPointImpl result)
Deprecated.
will return LatLonPoint in 6.
|
static LatLonPointImpl |
findPoint(Earth e,
LatLonPoint pt1,
double az,
double dist,
LatLonPointImpl result)
Deprecated.
will return LatLonPoint in 6.
|
static LatLonPointImpl |
findPoint(LatLonPoint pt1,
double az,
double dist,
LatLonPointImpl result)
Deprecated.
will return LatLonPoint in 6.
|
double |
getAngle()
Get the azimuth in degrees, 0 = north, clockwise positive
|
double |
getBackAzimuth()
Get the back azimuth in degrees, 0 = north, clockwise positive
|
double |
getDistance()
Get the distance in kilometers
|
String |
toString() |
@Deprecated public static Bearing calculateBearing(Earth e, LatLonPoint pt1, LatLonPoint pt2, Bearing result)
public static Bearing calculateBearing(Earth e, LatLonPoint pt1, LatLonPoint pt2)
e
- Earth object (defines radius & flattening)pt1
- Point 1pt2
- Point 2@Deprecated public static Bearing calculateBearing(LatLonPoint pt1, LatLonPoint pt2, Bearing result)
public static Bearing calculateBearing(LatLonPoint pt1, LatLonPoint pt2)
pt1
- Point 1pt2
- Point 2@Deprecated public static Bearing calculateBearing(double lat1, double lon1, double lat2, double lon2, Bearing result)
public static Bearing calculateBearing(double lat1, double lon1, double lat2, double lon2)
lat1
- Lat of point 1lon1
- Lon of point 1lat2
- Lat of point 2lon2
- Lon of point 2@Deprecated public static Bearing calculateBearing(Earth e, double lat1, double lon1, double lat2, double lon2, Bearing result)
public static LatLonPointImpl findPoint(Earth e, LatLonPoint pt1, double az, double dist, LatLonPointImpl result)
e
- Earth object (defines radius and flattening)pt1
- Point 1az
- azimuth (degrees)dist
- distance from the point (km)result
- Object to use if non-nullfindPoint(double,double,double,double,LatLonPointImpl)
public static LatLonPointImpl findPoint(LatLonPoint pt1, double az, double dist, LatLonPointImpl result)
pt1
- Point 1az
- azimuth (degrees)dist
- distance from the point (km)result
- Object to use if non-nullfindPoint(double,double,double,double,LatLonPointImpl)
public static LatLonPointImpl findPoint(double lat1, double lon1, double az, double dist, LatLonPointImpl result)
lat1
- latitude of starting pointlon1
- longitude of starting pointaz
- forward azimuth (degrees)dist
- distance from the point (km)result
- Object to use if non-nullpublic static LatLonPointImpl findPoint(Earth e, double lat1, double lon1, double az, double dist, LatLonPointImpl result)
Original documentation:
SOLUTION OF THE GEODETIC DIRECT PROBLEM AFTER T.VINCENTY MODIFIED RAINSFORD'S METHOD WITH HELMERT'S ELLIPTICAL TERMS EFFECTIVE IN ANY AZIMUTH AND AT ANY DISTANCE SHORT OF ANTIPODAL
e
- Earth object (defines radius and flattening)lat1
- latitude of starting pointlon1
- longitude of starting pointaz
- forward azimuth (degrees)dist
- distance from the point (km)result
- Object to use if non-nullpublic static Bearing calculateBearing(Earth e, double lat1, double lon1, double lat2, double lon2)
Algorithm from U.S. National Geodetic Survey, FORTRAN program "inverse," subroutine "INVER1," by L. PFEIFER and JOHN G. GERGEN. See http://www.ngs.noaa.gov/TOOLS/Inv_Fwd/Inv_Fwd.html
Original documentation:
SOLUTION OF THE GEODETIC INVERSE PROBLEM AFTER T.VINCENTY
MODIFIED RAINSFORD'S METHOD WITH HELMERT'S ELLIPTICAL TERMS
EFFECTIVE IN ANY AZIMUTH AND AT ANY DISTANCE SHORT OF ANTIPODAL
STANDPOINT/FOREPOINT MUST NOT BE THE GEOGRAPHIC POLE
e
- Earth object (defines radius and flattening)lat1
- Lat of point 1lon1
- Lon of point 1lat2
- Lat of point 2lon2
- Lon of point 2public double getAngle()
public double getBackAzimuth()
public double getDistance()