Package com.opttek.optquest.heatmap
Class COptQuestKrigSphericalDistance
java.lang.Object
com.opttek.optquest.heatmap.COptQuestKrigSphericalDistance
- All Implemented Interfaces:
com.opttek.optquest.IKrigDistance
public class COptQuestKrigSphericalDistance
extends Object
implements com.opttek.optquest.IKrigDistance
An implementation of KrigDistance that returns the "map distance" between two
vectors on the surface of a sphere. The vectors are assumed to be two
dimensions, in the order of (lat, lon), and in degrees. Typical earth-based
stuff. The constructor takes "rin" which is the radius of the sphere.
-
Constructor Summary
ConstructorsConstructorDescriptionInitialize the spherical distance calculator with the radius of the sphere -
Method Summary
Modifier and TypeMethodDescriptiondouble[][]
getCurvature
(double[] v1, double[] v2, Double distance) double
getDistance
(double[] v1, double[] v2) return the distance between two multi dimensional vectors in any arbitrary space.double[]
getGradient
(double[] v1, double[] v2, Double distance) com.opttek.optquest.IKrigDistance
getProjection
(int[] dims) void
updateState
(double[][] space)
-
Constructor Details
-
COptQuestKrigSphericalDistance
public COptQuestKrigSphericalDistance()Initialize the spherical distance calculator with the radius of the sphere
-
-
Method Details
-
getDistance
public double getDistance(double[] v1, double[] v2) return the distance between two multi dimensional vectors in any arbitrary space.- Specified by:
getDistance
in interfacecom.opttek.optquest.IKrigDistance
- Parameters:
v1
- - the one of the two vectors we're computing the distance betweenv2
- - the other of the two vectors we're computing the distance between
-
getGradient
- Specified by:
getGradient
in interfacecom.opttek.optquest.IKrigDistance
-
getCurvature
- Specified by:
getCurvature
in interfacecom.opttek.optquest.IKrigDistance
-
getProjection
public com.opttek.optquest.IKrigDistance getProjection(int[] dims) - Specified by:
getProjection
in interfacecom.opttek.optquest.IKrigDistance
-
updateState
public void updateState(double[][] space) - Specified by:
updateState
in interfacecom.opttek.optquest.IKrigDistance
-