public interface LaterationAlgorithm extends Configurable
Modifier and Type | Method and Description |
---|---|
String |
getName()
Returns the name of the algorithm.
|
Point2d |
localize(Point2d[] anchors,
double[] ranges,
Point2d actualPosition,
ErrorModel errorModel,
int width,
int height)
Runs the localization algorithm and returns the estimated position.
|
configure, isConfigurable
String getName()
The name should not be too long, e.g. less than 20 chars.
Point2d localize(Point2d[] anchors, double[] ranges, Point2d actualPosition, ErrorModel errorModel, int width, int height)
The size of the anchor and measured ranges array must be at least 3.
The actual position of the mobile node is passed to this method to allow the development of some sort of "cheating algorithm" which does some sort of optimum selection along a set of different algorithms.
The error model can be used by algorithms to determine the current average and maximum distance measurement error.
anchors
- The anchor/reference nodes.ranges
- The measured distances to the anchor/reference nodes.actualPosition
- The actual location of the mobile node to be located.errorModel
- The current error model used for simulation or
null
if running with real data (no error
model available).width
- The width of the playing field used for simulation or
-1
if running with real data.height
- The height of the playing field used for simulation or
-1
if running with real data.null
if no position could be calculated, e.g.
localization failed.Copyright © 2012 Thomas Hillebrandt. All Rights Reserved.