Class RobustLateration3DSolver

java.lang.Object
com.irurueta.navigation.lateration.RobustLaterationSolver<com.irurueta.geometry.Point3D>
com.irurueta.navigation.lateration.RobustLateration3DSolver
Direct Known Subclasses:
LMedSRobustLateration3DSolver, MSACRobustLateration3DSolver, PROMedSRobustLateration3DSolver, PROSACRobustLateration3DSolver, RANSACRobustLateration3DSolver

public abstract class RobustLateration3DSolver extends RobustLaterationSolver<com.irurueta.geometry.Point3D>
This is an abstract class to robustly solve the lateration problem by finding the best pairs of 3D positions and distances among the provided ones. Implementations of this class should be able to detect and discard outliers in order to find the best solution.
  • Field Details

    • inhomogeneousLinearSolver

      protected InhomogeneousLinearLeastSquaresLateration3DSolver inhomogeneousLinearSolver
      Inhomogeneous linear lateration solver internally used by a robust algorithm.
    • homogeneousLinearSolver

      protected HomogeneousLinearLeastSquaresLateration3DSolver homogeneousLinearSolver
      Homogeneous linear lateration solver internally used by a robust algorithm.
    • nonLinearSolver

      protected NonLinearLeastSquaresLateration3DSolver nonLinearSolver
      Non-linear lateration solver internally used to refine solution found by robust algorithm.
    • innerPositions

      protected com.irurueta.geometry.Point3D[] innerPositions
      Positions for linear inner solver used during robust estimation.
    • innerDistances

      protected double[] innerDistances
      Distances for linear inner solver used during robust estimation.
    • innerDistanceStandardDeviations

      protected double[] innerDistanceStandardDeviations
      Standard deviations for non-linear inner solver used during robust estimation.
  • Constructor Details

    • RobustLateration3DSolver

      protected RobustLateration3DSolver()
      Constructor.
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Constructor.
      Parameters:
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Point3D[] positions, double[] distances)
      Constructor.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations)
      Constructor.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      distanceStandardDeviations - standard deviations of provided measured distances.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Point3D[] positions, double[] distances, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Constructor.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Constructor.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Throws:
      IllegalArgumentException - if either positions, distances or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Sphere[] spheres)
      Constructor.
      Parameters:
      spheres - spheres defining positions and distances.
      Throws:
      IllegalArgumentException - if spheres is null or if length of spheres array is less than required (4 points).
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations)
      Constructor.
      Parameters:
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Sphere[] spheres, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Constructor.
      Parameters:
      spheres - spheres defining positions and distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Throws:
      IllegalArgumentException - if spheres is null or if length of spheres array is less than required (4 points).
    • RobustLateration3DSolver

      protected RobustLateration3DSolver(com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Constructor.
      Parameters:
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
  • Method Details

    • getNumberOfDimensions

      public int getNumberOfDimensions()
      Gets number of dimensions of provided points.
      Specified by:
      getNumberOfDimensions in class RobustLaterationSolver<com.irurueta.geometry.Point3D>
      Returns:
      always returns 2 dimensions.
    • getMinRequiredPositionsAndDistances

      public int getMinRequiredPositionsAndDistances()
      Minimum required number of positions and distances. At least 3 positions will be required.
      Specified by:
      getMinRequiredPositionsAndDistances in class RobustLaterationSolver<com.irurueta.geometry.Point3D>
      Returns:
      minimum required number of positions and distances.
    • setPreliminarySubsetSize

      public void setPreliminarySubsetSize(int preliminarySubsetSize) throws LockedException
      Sets size of subsets to be checked during robust estimation. This has to be at least getMinRequiredPositionsAndDistances().
      Overrides:
      setPreliminarySubsetSize in class RobustLaterationSolver<com.irurueta.geometry.Point3D>
      Parameters:
      preliminarySubsetSize - size of subsets to be checked during robust estimation.
      Throws:
      LockedException - if instance is busy solving the lateration problem.
      IllegalArgumentException - if provided value is less than getMinRequiredPositionsAndDistances().
    • getSpheres

      public com.irurueta.geometry.Sphere[] getSpheres()
      Gets spheres defined by provided positions and distances.
      Returns:
      spheres defined by provided positions and distances.
    • setSpheres

      public void setSpheres(com.irurueta.geometry.Sphere[] spheres) throws LockedException
      Sets spheres defining positions and Euclidean distances.
      Parameters:
      spheres - spheres defining positions and distances.
      Throws:
      IllegalArgumentException - if sphere is null or length of array of spheres is less than 4.
      LockedException - if instance is busy solving the lateration problem.
    • setSpheresAndStandardDeviations

      public void setSpheresAndStandardDeviations(com.irurueta.geometry.Sphere[] spheres, double[] radiusStandardDeviations) throws LockedException
      Sets spheres defining positions and Euclidean distances along with the standard deviations of provided spheres radii.
      Parameters:
      spheres - spheres defining positions and distances.
      radiusStandardDeviations - standard deviations of spheres radii.
      Throws:
      IllegalArgumentException - if spheres is null, length of arrays is less than 4 or don't have the same length.
      LockedException - if instance is busy solving the lateration problem.
    • create

      public static RobustLateration3DSolver create(com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
    • create

      public static RobustLateration3DSolver create(RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      distanceStandardDeviations - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      spheres - spheres defining positions and distances.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      spheres - spheres defining positions and distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null or if length of spheres array is less than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if quality scores is null, length of quality scores is less than required minimum (4 samples).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if quality scores is null, length of quality scores is less than required minimum (4 samples).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances or quality scores are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      distanceStandardDeviations - standard deviations of provided measured distances.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances, quality scores or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances, quality scores or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Sphere[] spheres, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      spheres - spheres defining positions and distances.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either spheres or quality scores are null don't have the same length or their length is less than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either spheres, quality scores or standard deviations are null, don't have the same length or their length is less than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener, com.irurueta.numerical.robust.RobustEstimatorMethod method)
      Creates a robust 3D lateration solver.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      method - robust estimator method.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either spheres, quality scores or standard deviations are null, don't have the same length or their length is less than required (4 points).
    • create

      public static RobustLateration3DSolver create()
      Creates a robust 3D lateration solver using default robust method.
      Returns:
      a new robust 3D lateration solver.
    • create

      public static RobustLateration3DSolver create(RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      distanceStandardDeviations - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions or distances are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      spheres - spheres defining positions and distances.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      spheres - spheres defining positions and distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null or if length of spheres array is less than required (4 points).
    • create

      public static RobustLateration3DSolver create(com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if spheres is null, length of spheres array is less than required (4 points) or don't have the same length.
    • create

      public static RobustLateration3DSolver create(double[] qualityScores)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if quality scores is null, length of quality scores is less than required minimum (4 samples).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      listener - listener to be notified of events such as when estimation starts, enda or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if quality scores is null, length of quality scores is less than required minimum (4 samples).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances or quality scores are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node to be estimated.
      distanceStandardDeviations - standard deviations of provided measured distances.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances, quality scores or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Point3D[] positions, double[] distances, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      positions - known positions of static nodes.
      distances - euclidean distances from static nodes to mobile node.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either positions, distances, quality scores or standard deviations are null, don't have the same length or their length is smaller than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Sphere[] spheres)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      spheres - spheres defining positions and distances.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either spheres or quality scores are null, don't have the same length or their length is less than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either spheres, quality scores or standard deviations are null, don't have the same length or their length is less than required (4 points).
    • create

      public static RobustLateration3DSolver create(double[] qualityScores, com.irurueta.geometry.Sphere[] spheres, double[] distanceStandardDeviations, RobustLaterationSolverListener<com.irurueta.geometry.Point3D> listener)
      Creates a robust 3D lateration solver using default robust method.
      Parameters:
      qualityScores - quality scores corresponding to each provided sample. The larger the score value the better the quality of the sample.
      spheres - spheres defining positions and distances.
      distanceStandardDeviations - standard deviations of provided measured distances.
      listener - listener to be notified of events such as when estimation starts, ends or its progress significantly changes.
      Returns:
      a new robust 3D lateration solver.
      Throws:
      IllegalArgumentException - if either spheres, quality scores or standard deviations are null, don't have the same length or their length is less than required (4 points).
    • attemptRefine

      protected com.irurueta.geometry.Point3D attemptRefine(com.irurueta.geometry.Point3D position)
      Attempts to refine estimated position if refinement is requested. This method returns a refined solution or provided input if refinement is not requested or has failed. If refinement is enabled, and it is requested to keep covariance, this method will also keep covariance of refined position.
      Parameters:
      position - position estimated by a robust estimator without refinement.
      Returns:
      solution after refinement (if requested) or provided non-refined estimated position if not requested or refinement failed.
    • solvePreliminarySolutions

      protected void solvePreliminarySolutions(int[] samplesIndices, List<com.irurueta.geometry.Point3D> solutions)
      Solves a preliminary solution for a subset of samples picked by a robust estimator.
      Parameters:
      samplesIndices - indices of samples picked by the robust estimator.
      solutions - list where estimated preliminary solution will be stored.
    • internalSetSpheres

      private void internalSetSpheres(com.irurueta.geometry.Sphere[] spheres)
      Internally sets spheres defining positions and Euclidean distances.
      Parameters:
      spheres - spheres defining positions and distances.
      Throws:
      IllegalArgumentException - if spheres is null or length of array of spheres is less than getMinRequiredPositionsAndDistances()
    • internalSetSpheresAndStandardDeviations

      private void internalSetSpheresAndStandardDeviations(com.irurueta.geometry.Sphere[] spheres, double[] radiusStandardDeviations)
      Internally sets spheres defining positions and Euclidean distances along with the standard deviations of provided spheres radii.
      Parameters:
      spheres - spheres defining positions and distances.
      radiusStandardDeviations - standard deviations of spheres radii.
      Throws:
      IllegalArgumentException - if spheres is null, length of arrays is less than 4 or don't have the same length.
    • init

      private void init()
      Setup inner positions and distances.