Class Chi2Bearings
java.lang.Object
Localiser.algorithms.genericLocaliser.Chi2Bearings
- All Implemented Interfaces:
MinimisationFunction
Minimisation functions which is based on bearings rather than time delay measurements. e.g. this could be used for
target motion localisation, DIFAR buoy or any system which uses bearings rather than time delay measurements.
- Author:
- Jamie Macaulay
-
Field Summary
Modifier and TypeFieldDescriptiondouble[]
Detection angles for simple cases of linear arrays these are angles relative to the heading vectors.Conveneince variable.The heading of the array at each loclaisation point. -
Constructor Summary
ConstructorDescriptionChi2Bearings
(PamVector[] wordlVectors, PamVector[] subDetectionAngleErrors, PamVector[] subDetectionOrigins, PamQuaternion[] rotationVector) Constructor to set up the minimisation function for bearing localisationChi2Bearings
(PamVector[] wordlVectors, PamVector[] subDetectionAngleErrors, PamVector[] subDetectionOrigins, PamQuaternion[] rotationVector, int nDim) Constructor to set up the minimisation function for bearing localisation -
Method Summary
Modifier and TypeMethodDescriptionint
getDim()
Get the simulation dimensions e.g.double[]
Get first search jump (often not needed)Get the rotation of the hydrophone array for each detection.double[]
getStart()
Get starting position for search algorithm.Get sub detection angle errors.Get sub detection origins.Get the angle of each sub detection.void
setStart
(double[] start) Set the start location for the algortihmdouble
value
(double[] location) Return the Chi2 value at a specified 'location'/ for a set of points which can be used to generated expected data that is then used to calculated a chi2 value with observed data.
-
Field Details
-
rotationVector
The heading of the array at each loclaisation point. Used if a localisation algortihm to transform stuff. -
headingVectors
Conveneince variable. Heading vectors. -
detectionAngles
public double[] detectionAnglesDetection angles for simple cases of linear arrays these are angles relative to the heading vectors.
-
-
Constructor Details
-
Chi2Bearings
public Chi2Bearings(PamVector[] wordlVectors, PamVector[] subDetectionAngleErrors, PamVector[] subDetectionOrigins, PamQuaternion[] rotationVector) Constructor to set up the minimisation function for bearing localisation- Parameters:
wordlVectors
- - the world vectors- relative to the x y of the arraysubDetectionAngleErrors
- - the errors in the bearingssubDetectionOrigins
- - the location of each bearing origin in x y z co-ordinate frame
-
Chi2Bearings
public Chi2Bearings(PamVector[] wordlVectors, PamVector[] subDetectionAngleErrors, PamVector[] subDetectionOrigins, PamQuaternion[] rotationVector, int nDim) Constructor to set up the minimisation function for bearing localisation- Parameters:
wordlVectors
- - the world vectors- relative to the x y of the arraysubDetectionAngleErrors
- - the errors in the bearingssubDetectionOrigins
- - the location of each bearing origin in x y z co-ordinate framenDim
- - the number of dimensions to solve for.
-
-
Method Details
-
value
public double value(double[] location) Description copied from interface:MinimisationFunction
Return the Chi2 value at a specified 'location'/ for a set of points which can be used to generated expected data that is then used to calculated a chi2 value with observed data. Example location might be [x y z] location to generate time delays which are then compared to expected time delays.- Specified by:
value
in interfaceMinimisationFunction
- Parameters:
location
- - the point at which chi2 value is to be calculated;- Returns:
- the chi2 value.
-
getDim
public int getDim()Description copied from interface:MinimisationFunction
Get the simulation dimensions e.g. if solving for [x y z] location getDim()=3;- Specified by:
getDim
in interfaceMinimisationFunction
-
getStart
public double[] getStart()Description copied from interface:MinimisationFunction
Get starting position for search algorithm.- Specified by:
getStart
in interfaceMinimisationFunction
- Returns:
- starting location with getDim() dimensions.
-
setStart
public void setStart(double[] start) Set the start location for the algortihm- Parameters:
start
- location. Must be the same length as number of dimensions
-
getFirstStep
public double[] getFirstStep()Description copied from interface:MinimisationFunction
Get first search jump (often not needed)- Specified by:
getFirstStep
in interfaceMinimisationFunction
- Returns:
- first jump location with getDim() dimensions.
-
getSubDetectionOrigins
Get sub detection origins. This is the origin of the subdection in Cartesian space.- Returns:
- a list of sub detection co-ordinates.
-
getSubDetectionAngleErrors
Get sub detection angle errors.- Returns:
- the angular errors
-
getUsedWorldVectors
Get the angle of each sub detection. Note that the this is a non-ambiguous angle.- Returns:
- the angle of each sub detection.
-
getRotationVectors
Get the rotation of the hydrophone array for each detection. Used to transofmr co-oridnatres,- Returns:
- the rotation of the hydrophone for each subdetection.
-