Class TriadStaticIntervalDetector<U extends Enum<?>,M extends com.irurueta.units.Measurement<U>,T extends Triad<U,M>,D extends TriadStaticIntervalDetector<U,M,T,D,L>,L extends TriadStaticIntervalDetectorListener<U,M,T,D>>

java.lang.Object
com.irurueta.navigation.inertial.calibration.intervals.TriadStaticIntervalDetector<U,M,T,D,L>
Type Parameters:
U - type of unit.
M - a type of measurement.
T - a triad type.
D - a detector type.
L - a listener type.
Direct Known Subclasses:
AccelerationTriadStaticIntervalDetector, AngularSpeedTriadStaticIntervalDetector, MagneticFluxDensityTriadStaticIntervalDetector

public abstract class TriadStaticIntervalDetector<U extends Enum<?>,M extends com.irurueta.units.Measurement<U>,T extends Triad<U,M>,D extends TriadStaticIntervalDetector<U,M,T,D,L>,L extends TriadStaticIntervalDetectorListener<U,M,T,D>> extends Object
Abstract base class for detectors in charge of determining when a static period of measurements starts and finishes. Static periods are periods of time where the device is considered to remain static (no movement applied to it).
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static enum 
    Reason why this detector has failed during initialization.
    static enum 
    Possible detector status values.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private double
    Average x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Average y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Average z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private final AccumulatedTriadNoiseEstimator<U,M,T,?,?>
    Estimator to find accumulated accelerometer noise level.
    private double
    Standard deviation of x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Standard deviation of y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Standard deviation of z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Measurement base noise level that has been detected during initialization expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase.
    static final double
    Default overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase.
    static final int
    Number of samples to process during the initial static period to determine the sensor (accelerometer, gyroscope or magnetometer) noise level.
    static final double
    Default factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount.
    static final double
    Default factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes.
    static final int
    Number of samples to keep within the window by default.
    private int
    Number of samples to be processed initially while keeping the sensor static in order to find the base noise level when device is static.
    private double
    Windowed average x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Windowed average y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Windowed average z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount.
    private double
    Windowed standard deviation of x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Windowed standard deviation of y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Windowed standard deviation of z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private L
    Listener to handle events generated by this detector.
    static final int
    Minimum allowed number of samples to be processed during the initial static period.
    private int
    Number of samples that have been processed so far.
    private boolean
    Indicates whether this detector is busy processing last provided sample.
    Current status of this detector.
    private double
    Threshold to determine static/dynamic period changes expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    private double
    Factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes.
    private final WindowedTriadNoiseEstimator<U,M,T,?,?>
    Estimator to find instantaneous measurement noise level averaged for a certain window of samples.
    private int
    Number of samples to keep in window to find instantaneous noise level averaged within the window of samples.
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    TriadStaticIntervalDetector(WindowedTriadNoiseEstimator<U,M,T,?,?> windowedNoiseEstimator, AccumulatedTriadNoiseEstimator<U,M,T,?,?> accumulatedNoiseEstimator)
    Constructor.
    protected
    TriadStaticIntervalDetector(WindowedTriadNoiseEstimator<U,M,T,?,?> windowedNoiseEstimator, AccumulatedTriadNoiseEstimator<U,M,T,?,?> accumulatedNoiseEstimator, L listener)
    Constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    protected abstract double
    convertMeasurement(double value, U unit)
    Converts provided measurement value expressed in provided unit to the default measurement value, which is meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (t) for magnetic flux density.
    protected double
    convertMeasurement(M measurement)
    Converts provided measurement instance to its default unit, which is meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    protected abstract M
    createMeasurement(double value, U unit)
    Creates a measurement instance using provided value and unit.
    protected abstract T
    createTriad(double valueX, double valueY, double valueZ, U unit)
    Creates a triad.
    Gets average measurements triad accumulated during last static period.
    void
    Gets average measurements triad accumulated during last static period.
    double
    Gets average x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets average x-coordinate of measurements accumulated during last static period.
    void
    Gets average x-coordinate of measurements accumulated during last static period.
    double
    Gets average y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets average y-coordinate of measurements accumulated during last static period.
    void
    Gets average y-coordinate of measurements accumulated during last static period.
    double
    Gets average z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets average z-coordinate of measurements accumulated during last static period.
    void
    Gets average z-coordinate of measurements accumulated during last static period.
    Gets standard deviation of measurements accumulated during last static period.
    void
    Gets standard deviation of measurements accumulated during last static period.
    double
    Gets standard deviation of x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets standard deviation of x-coordinate of measurements accumulated during last static period.
    void
    Gets standard deviation of x-coordinate of measurements accumulated during last static period.
    double
    Gets standard deviation of y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets standard deviation of y-coordinate of measurements accumulated during last static period.
    void
    Gets standard deviation of y-coordinate of measurements accumulated during last static period.
    double
    Gets standard deviation of z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets standard deviation of z-coordinate of measurements accumulated during last static period.
    void
    Gets standard deviation of z-coordinate of measurements accumulated during last static period.
    double
    Gets measurement base noise level that has been detected during initialization expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    double
    Gets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase.
    Gets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase.
    void
    Gets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase.
    Gets measurement base noise level that has been detected during initialization.
    void
    Gets measurement base noise level that has been detected during initialization.
    double
    Gets measurement base noise level PSD (Power Spectral Density) expressed in (m^2 * s^-3) for accelerometer, (rad^2/s) for gyroscope or (T^2 * s) for magnetometer.
    double
    Gets measurement base noise level root PSD (Power SpectralDensity) expressed in (m * s^-1.5) for accelerometer, (rad * s^-0.5) for gyroscope or (T * s^0.5) for magnetometer.
    protected abstract U
    Gets default unit for measurements this implementation works with.
    int
    Gets number of samples to be processed initially while keeping the sensor static in order to find the base noise level when device is static.
    Gets windowed average of measurements for each processed triad.
    void
    Gets windowed average of measurements for each processed triad.
    double
    Gets windowed average x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets windowed average x-coordinate of measurements for each processed triad.
    void
    Gets windowed average x-coordinate of measurements for each processed triad.
    double
    Gets windowed average y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets windowed average y-coordinate of measurements for each processed triad.
    void
    Gets windowed average y-coordinate of measurements for each processed triad.
    double
    Gets windowed average z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets windowed average z-coordinate of measurements for each processed triad.
    void
    Gets windowed average z-coordinate of measurements for each processed triad.
    double
    Gets factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount.
    Gets windowed standard deviation of measurements for each processed triad.
    void
    Gets windowed standard deviation of measurements for each processed triad.
    double
    Gets windowed standard deviation of x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets windowed standard deviation of x-coordinate of measurements for each processed triad.
    void
    Gets windowed standard deviation of x-coordinate of measurements for each processed triad.
    double
    Gets windowed standard deviation of y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets windowed standard deviation of y-coordinate of measurements for each processed triad.
    void
    Gets windowed standard deviation of y-coordinate of measurements for each processed triad.
    double
    Gets windowed standard deviation of z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets windowed standard deviation of z-coordinate of measurements for each processed triad.
    void
    Gets windowed standard deviation of z-coordinate of measurements for each processed triad.
    Gets listener to handle events generated by this detector.
    int
    Gets number of samples that have been processed so far.
    Gets current status of this detector.
    double
    Gets threshold to determine static/dynamic period changes expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    Gets threshold to determine static/dynamic period changes.
    void
    Gets threshold to determine static/dynamic period changes.
    double
    Gets factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes.
    double
    Gets time interval between triad samples expressed in seconds (s).
    com.irurueta.units.Time
    Gets time interval between triad samples.
    void
    getTimeIntervalAsTime(com.irurueta.units.Time result)
    Gets time interval between triad samples.
    int
    Gets length of number of samples to keep within the window being processed to determine instantaneous accelerometer noise level.
    boolean
    Indicates whether this detector is busy processing last provided sample.
    boolean
    process(double valueX, double valueY, double valueZ)
    Processes a new measurement triad sample.
    boolean
    process(M valueX, M valueY, M valueZ)
    Processes a new measurement triad sample.
    boolean
    process(T triad)
    Processes a new measurement triad sample.
    void
    Resets this detector so that it is initialized again when new samples are added.
    void
    setBaseNoiseLevelAbsoluteThreshold(double baseNoiseLevelAbsoluteThreshold)
    Sets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase.
    void
    setBaseNoiseLevelAbsoluteThreshold(M baseNoiseLevelAbsoluteThreshold)
    Sets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase.
    void
    setInitialStaticSamples(int initialStaticSamples)
    Sets number of samples to be processed initially while keeping the sensor static in order to find the base noise level when device is static.
    void
    setInstantaneousNoiseLevelFactor(double instantaneousNoiseLevelFactor)
    Sets factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount.
    void
    setListener(L listener)
    Sets listener to handle events generated by this detector.
    void
    setThresholdFactor(double thresholdFactor)
    Sets factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes.
    void
    setTimeInterval(double timeInterval)
    Sets time interval between triad samples expressed in seconds (s).
    void
    setTimeInterval(com.irurueta.units.Time timeInterval)
    Sets time interval between triad samples.
    void
    setWindowSize(int windowSize)
    Sets length of number of samples to keep within the window being processed to determine instantaneous accelerometer noise level.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • DEFAULT_WINDOW_SIZE

      public static final int DEFAULT_WINDOW_SIZE
      Number of samples to keep within the window by default. For a sensor generating 100 samples/second, this is equivalent to 1 second. For a sensor generating 50 samples/second, this is equivalent to 2 seconds.
      See Also:
    • DEFAULT_INITIAL_STATIC_SAMPLES

      public static final int DEFAULT_INITIAL_STATIC_SAMPLES
      Number of samples to process during the initial static period to determine the sensor (accelerometer, gyroscope or magnetometer) noise level. For a sensor generating 100 samples/second, this is equivalent to 50 seconds. For a sensor generating 50 samples/second, this is equivalent to 100 seconds.
      See Also:
    • MINIMUM_INITIAL_STATIC_SAMPLES

      public static final int MINIMUM_INITIAL_STATIC_SAMPLES
      Minimum allowed number of samples to be processed during the initial static period.
      See Also:
    • DEFAULT_THRESHOLD_FACTOR

      public static final double DEFAULT_THRESHOLD_FACTOR
      Default factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes. This factor is unit-less.
      See Also:
    • DEFAULT_INSTANTANEOUS_NOISE_LEVEL_FACTOR

      public static final double DEFAULT_INSTANTANEOUS_NOISE_LEVEL_FACTOR
      Default factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount. This factor is unit-less.
      See Also:
    • DEFAULT_BASE_NOISE_LEVEL_ABSOLUTE_THRESHOLD

      public static final double DEFAULT_BASE_NOISE_LEVEL_ABSOLUTE_THRESHOLD
      Default overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. This threshold is expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density, and by default it is set to the maximum allowed value, thus effectively disabling this error condition check during initialization.
      See Also:
    • windowSize

      private int windowSize
      Number of samples to keep in window to find instantaneous noise level averaged within the window of samples. Window size should contain about 1 or 2 seconds of data to be averaged to obtain a more reliable instantaneous noise level.
    • initialStaticSamples

      private int initialStaticSamples
      Number of samples to be processed initially while keeping the sensor static in order to find the base noise level when device is static.
    • thresholdFactor

      private double thresholdFactor
      Factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes. This factor is unit-less.
    • instantaneousNoiseLevelFactor

      private double instantaneousNoiseLevelFactor
      Factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount. This factor is unit-less.
    • baseNoiseLevelAbsoluteThreshold

      private double baseNoiseLevelAbsoluteThreshold
      Overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes. This threshold is expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    • listener

      private L extends TriadStaticIntervalDetectorListener<U,M,T,D> listener
      Listener to handle events generated by this detector.
    • status

      Current status of this detector.
    • baseNoiseLevel

      private double baseNoiseLevel
      Measurement base noise level that has been detected during initialization expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    • threshold

      private double threshold
      Threshold to determine static/dynamic period changes expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
    • running

      private boolean running
      Indicates whether this detector is busy processing last provided sample.
    • processedSamples

      private int processedSamples
      Number of samples that have been processed so far.
    • accumulatedAvgX

      private double accumulatedAvgX
      Average x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
    • accumulatedAvgY

      private double accumulatedAvgY
      Average y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
    • accumulatedAvgZ

      private double accumulatedAvgZ
      Average z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
    • accumulatedStdX

      private double accumulatedStdX
      Standard deviation of x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
    • accumulatedStdY

      private double accumulatedStdY
      Standard deviation of y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
    • accumulatedStdZ

      private double accumulatedStdZ
      Standard deviation of z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
    • instantaneousAvgX

      private double instantaneousAvgX
      Windowed average x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing an average value for the samples within the window.
    • instantaneousAvgY

      private double instantaneousAvgY
      Windowed average y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing an average value for the samples within the window.
    • instantaneousAvgZ

      private double instantaneousAvgZ
      Windowed average z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing an average value for the samples within the window.
    • instantaneousStdX

      private double instantaneousStdX
      Windowed standard deviation of x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
    • instantaneousStdY

      private double instantaneousStdY
      Windowed standard deviation of y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
    • instantaneousStdZ

      private double instantaneousStdZ
      Windowed standard deviation of z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
    • windowedNoiseEstimator

      private final WindowedTriadNoiseEstimator<U extends Enum<?>,M extends com.irurueta.units.Measurement<U>,T extends Triad<U,M>,?,?> windowedNoiseEstimator
      Estimator to find instantaneous measurement noise level averaged for a certain window of samples.
    • accumulatedNoiseEstimator

      private final AccumulatedTriadNoiseEstimator<U extends Enum<?>,M extends com.irurueta.units.Measurement<U>,T extends Triad<U,M>,?,?> accumulatedNoiseEstimator
      Estimator to find accumulated accelerometer noise level.
  • Constructor Details

    • TriadStaticIntervalDetector

      protected TriadStaticIntervalDetector(WindowedTriadNoiseEstimator<U,M,T,?,?> windowedNoiseEstimator, AccumulatedTriadNoiseEstimator<U,M,T,?,?> accumulatedNoiseEstimator)
      Constructor.
      Parameters:
      windowedNoiseEstimator - windowed noise estimator to estimate noise within a window of measures.
      accumulatedNoiseEstimator - accumulated noise estimator to estimate accumulated noise and average.
    • TriadStaticIntervalDetector

      protected TriadStaticIntervalDetector(WindowedTriadNoiseEstimator<U,M,T,?,?> windowedNoiseEstimator, AccumulatedTriadNoiseEstimator<U,M,T,?,?> accumulatedNoiseEstimator, L listener)
      Constructor.
      Parameters:
      windowedNoiseEstimator - windowed noise estimator to estimate noise within a window of measures.
      accumulatedNoiseEstimator - accumulated noise estimator to estimate accumulated noise and average.
      listener - listener to handle events generated by this detector.
  • Method Details

    • getWindowSize

      public int getWindowSize()
      Gets length of number of samples to keep within the window being processed to determine instantaneous accelerometer noise level.
      Returns:
      length of number of samples to keep within the window.
    • setWindowSize

      public void setWindowSize(int windowSize) throws com.irurueta.navigation.LockedException
      Sets length of number of samples to keep within the window being processed to determine instantaneous accelerometer noise level. Window size must always be larger than allowed minimum value, which is 2 and must have and odd value.
      Parameters:
      windowSize - length of number of samples to keep within the window.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy processing a previous sample.
      IllegalArgumentException - if provided value is not valid.
    • getInitialStaticSamples

      public int getInitialStaticSamples()
      Gets number of samples to be processed initially while keeping the sensor static in order to find the base noise level when device is static.
      Returns:
      number of samples to be processed initially.
    • setInitialStaticSamples

      public void setInitialStaticSamples(int initialStaticSamples) throws com.irurueta.navigation.LockedException
      Sets number of samples to be processed initially while keeping the sensor static in order to find the base noise level when device is static.
      Parameters:
      initialStaticSamples - number of samples to be processed initially.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy.
      IllegalArgumentException - if provided value is less than MINIMUM_INITIAL_STATIC_SAMPLES
    • getThresholdFactor

      public double getThresholdFactor()
      Gets factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes. This factor is unit-less.
      Returns:
      factor to be applied to detected base noise level.
    • setThresholdFactor

      public void setThresholdFactor(double thresholdFactor) throws com.irurueta.navigation.LockedException
      Sets factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes. This factor is unit-less.
      Parameters:
      thresholdFactor - factor to be applied to detected base noise level.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy.
      IllegalArgumentException - if provided value is zero or negative.
    • getInstantaneousNoiseLevelFactor

      public double getInstantaneousNoiseLevelFactor()
      Gets factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount. This factor is unit-less.
      Returns:
      factor to determine that a sudden movement has occurred.
    • setInstantaneousNoiseLevelFactor

      public void setInstantaneousNoiseLevelFactor(double instantaneousNoiseLevelFactor) throws com.irurueta.navigation.LockedException
      Sets factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount. This factor is unit-less.
      Parameters:
      instantaneousNoiseLevelFactor - factor to determine that a sudden movement has occurred during initialization.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy.
      IllegalArgumentException - if provided value is zero or negative.
    • getBaseNoiseLevelAbsoluteThreshold

      public double getBaseNoiseLevelAbsoluteThreshold()
      Gets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes. This threshold is expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
      Returns:
      overall absolute threshold to determine whether there has been excessive motion.
    • setBaseNoiseLevelAbsoluteThreshold

      public void setBaseNoiseLevelAbsoluteThreshold(double baseNoiseLevelAbsoluteThreshold) throws com.irurueta.navigation.LockedException
      Sets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes. This threshold is expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
      Parameters:
      baseNoiseLevelAbsoluteThreshold - overall absolute threshold to determine whether there has been excessive motion.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy.
      IllegalArgumentException - if provided value is zero or negative.
    • getBaseNoiseLevelAbsoluteThresholdAsMeasurement

      public M getBaseNoiseLevelAbsoluteThresholdAsMeasurement()
      Gets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes.
      Returns:
      overall absolute threshold to determine whether there has been excessive motion.
    • getBaseNoiseLevelAbsoluteThresholdAsMeasurement

      public void getBaseNoiseLevelAbsoluteThresholdAsMeasurement(M result)
      Gets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes.
      Parameters:
      result - instance where result will be stored.
    • setBaseNoiseLevelAbsoluteThreshold

      public void setBaseNoiseLevelAbsoluteThreshold(M baseNoiseLevelAbsoluteThreshold) throws com.irurueta.navigation.LockedException
      Sets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes.
      Parameters:
      baseNoiseLevelAbsoluteThreshold - overall absolute threshold to determine whether there has been excessive motion.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy.
      IllegalArgumentException - if provided value is zero or negative.
    • getListener

      public L getListener()
      Gets listener to handle events generated by this detector.
      Returns:
      listener to handle events.
    • setListener

      public void setListener(L listener) throws com.irurueta.navigation.LockedException
      Sets listener to handle events generated by this detector.
      Parameters:
      listener - listener to handle events.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy.
    • getTimeInterval

      public double getTimeInterval()
      Gets time interval between triad samples expressed in seconds (s).
      Returns:
      time interval between triad samples.
    • setTimeInterval

      public void setTimeInterval(double timeInterval) throws com.irurueta.navigation.LockedException
      Sets time interval between triad samples expressed in seconds (s).
      Parameters:
      timeInterval - time interval between triad samples.
      Throws:
      IllegalArgumentException - if provided value is negative.
      com.irurueta.navigation.LockedException - if estimator is currently running.
    • getTimeIntervalAsTime

      public com.irurueta.units.Time getTimeIntervalAsTime()
      Gets time interval between triad samples.
      Returns:
      time interval between triad samples.
    • getTimeIntervalAsTime

      public void getTimeIntervalAsTime(com.irurueta.units.Time result)
      Gets time interval between triad samples.
      Parameters:
      result - instance where time interval will be stored.
    • setTimeInterval

      public void setTimeInterval(com.irurueta.units.Time timeInterval) throws com.irurueta.navigation.LockedException
      Sets time interval between triad samples.
      Parameters:
      timeInterval - time interval between triad samples.
      Throws:
      IllegalArgumentException - if provided value is negative.
      com.irurueta.navigation.LockedException - if estimator is currently running.
    • getStatus

      Gets current status of this detector.
      Returns:
      current status of this detector.
    • getBaseNoiseLevel

      public double getBaseNoiseLevel()
      Gets measurement base noise level that has been detected during initialization expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
      Returns:
      base noise level.
    • getBaseNoiseLevelAsMeasurement

      public M getBaseNoiseLevelAsMeasurement()
      Gets measurement base noise level that has been detected during initialization.
      Returns:
      measurement base noise level.
    • getBaseNoiseLevelAsMeasurement

      public void getBaseNoiseLevelAsMeasurement(M result)
      Gets measurement base noise level that has been detected during initialization.
      Parameters:
      result - instance where result will be stored.
    • getBaseNoiseLevelPsd

      public double getBaseNoiseLevelPsd()
      Gets measurement base noise level PSD (Power Spectral Density) expressed in (m^2 * s^-3) for accelerometer, (rad^2/s) for gyroscope or (T^2 * s) for magnetometer.
      Returns:
      measurement base noise level PSD.
    • getBaseNoiseLevelRootPsd

      public double getBaseNoiseLevelRootPsd()
      Gets measurement base noise level root PSD (Power SpectralDensity) expressed in (m * s^-1.5) for accelerometer, (rad * s^-0.5) for gyroscope or (T * s^0.5) for magnetometer.
      Returns:
      measurement base noise level root PSD.
    • getThreshold

      public double getThreshold()
      Gets threshold to determine static/dynamic period changes expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
      Returns:
      threshold to determine static/dynamic period changes.
    • getThresholdAsMeasurement

      public M getThresholdAsMeasurement()
      Gets threshold to determine static/dynamic period changes.
      Returns:
      threshold to determine static/dynamic period changes.
    • getThresholdAsMeasurement

      public void getThresholdAsMeasurement(M result)
      Gets threshold to determine static/dynamic period changes.
      Parameters:
      result - instance where result will be stored.
    • isRunning

      public boolean isRunning()
      Indicates whether this detector is busy processing last provided sample.
      Returns:
      true if this detector is busy, false otherwise.
    • getProcessedSamples

      public int getProcessedSamples()
      Gets number of samples that have been processed so far.
      Returns:
      number of samples that have been processed so far.
    • getAccumulatedAvgX

      public double getAccumulatedAvgX()
      Gets average x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      accumulated average x-coordinate of measurement during last static period.
    • getAccumulatedAvgXAsMeasurement

      public M getAccumulatedAvgXAsMeasurement()
      Gets average x-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      accumulated average x-coordinate of measurement during last static period.
    • getAccumulatedAvgXAsMeasurement

      public void getAccumulatedAvgXAsMeasurement(M result)
      Gets average x-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getAccumulatedAvgY

      public double getAccumulatedAvgY()
      Gets average y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      accumulated average y-coordinate of measurement during last static period.
    • getAccumulatedAvgYAsMeasurement

      public M getAccumulatedAvgYAsMeasurement()
      Gets average y-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      accumulated average y-coordinate of measurement during last static period.
    • getAccumulatedAvgYAsMeasurement

      public void getAccumulatedAvgYAsMeasurement(M result)
      Gets average y-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getAccumulatedAvgZ

      public double getAccumulatedAvgZ()
      Gets average z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      accumulated average y-coordinate of measurement during last static period.
    • getAccumulatedAvgZAsMeasurement

      public M getAccumulatedAvgZAsMeasurement()
      Gets average z-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      accumulated average z-coordinate of measurement during last static period.
    • getAccumulatedAvgZAsMeasurement

      public void getAccumulatedAvgZAsMeasurement(M result)
      Gets average z-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getAccumulatedAvgTriad

      public T getAccumulatedAvgTriad()
      Gets average measurements triad accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      accumulated average measurements triad during last static period.
    • getAccumulatedAvgTriad

      public void getAccumulatedAvgTriad(T result)
      Gets average measurements triad accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getAccumulatedStdX

      public double getAccumulatedStdX()
      Gets standard deviation of x-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      standard deviation of x-coordinate of measurements accumulated during last static period.
    • getAccumulatedStdXAsMeasurement

      public M getAccumulatedStdXAsMeasurement()
      Gets standard deviation of x-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      standard deviation of x-coordinate of measurements accumulated during last static period.
    • getAccumulatedStdXAsMeasurement

      public void getAccumulatedStdXAsMeasurement(M result)
      Gets standard deviation of x-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getAccumulatedStdY

      public double getAccumulatedStdY()
      Gets standard deviation of y-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      standard deviation of y-coordinate of measurements accumulated during last static period.
    • getAccumulatedStdYAsMeasurement

      public M getAccumulatedStdYAsMeasurement()
      Gets standard deviation of y-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      standard deviation of y-coordinate of measurements accumulated during last static period.
    • getAccumulatedStdYAsMeasurement

      public void getAccumulatedStdYAsMeasurement(M result)
      Gets standard deviation of y-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getAccumulatedStdZ

      public double getAccumulatedStdZ()
      Gets standard deviation of z-coordinate of measurements accumulated during last static period expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      standard deviation of z-coordinate of measurements accumulated during last static period.
    • getAccumulatedStdZAsMeasurement

      public M getAccumulatedStdZAsMeasurement()
      Gets standard deviation of z-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      standard deviation of z-coordinate of measurements accumulated during last static period.
    • getAccumulatedStdZAsMeasurement

      public void getAccumulatedStdZAsMeasurement(M result)
      Gets standard deviation of z-coordinate of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getAccumulatedStdTriad

      public T getAccumulatedStdTriad()
      Gets standard deviation of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Returns:
      standard deviation of measurements accumulated during last static period.
    • getAccumulatedStdTriad

      public void getAccumulatedStdTriad(T result)
      Gets standard deviation of measurements accumulated during last static period. This value is updated when switching from a static period to a dynamic one or after completing initialization.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousAvgX

      public double getInstantaneousAvgX()
      Gets windowed average x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing an average value for the samples within the window.
      Returns:
      windowed average x-coordinate of measurements for each processed triad.
    • getInstantaneousAvgXAsMeasurement

      public M getInstantaneousAvgXAsMeasurement()
      Gets windowed average x-coordinate of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Returns:
      windowed average x-coordinate of measurements for each processed triad.
    • getInstantaneousAvgXAsMeasurement

      public void getInstantaneousAvgXAsMeasurement(M result)
      Gets windowed average x-coordinate of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousAvgY

      public double getInstantaneousAvgY()
      Gets windowed average y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing an average value for the samples within the window.
      Returns:
      windowed average y-coordinate of measurements for each processed triad.
    • getInstantaneousAvgYAsMeasurement

      public M getInstantaneousAvgYAsMeasurement()
      Gets windowed average y-coordinate of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Returns:
      windowed average y-coordinate of measurements for each processed triad.
    • getInstantaneousAvgYAsMeasurement

      public void getInstantaneousAvgYAsMeasurement(M result)
      Gets windowed average y-coordinate of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousAvgZ

      public double getInstantaneousAvgZ()
      Gets windowed average z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing an average value for the samples within the window.
      Returns:
      windowed average z-coordinate of measurements for each processed triad.
    • getInstantaneousAvgZAsMeasurement

      public M getInstantaneousAvgZAsMeasurement()
      Gets windowed average z-coordinate of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Returns:
      windowed average z-coordinate of measurements for each processed triad.
    • getInstantaneousAvgZAsMeasurement

      public void getInstantaneousAvgZAsMeasurement(M result)
      Gets windowed average z-coordinate of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousAvgTriad

      public T getInstantaneousAvgTriad()
      Gets windowed average of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Returns:
      windowed average of measurements for each processed triad.
    • getInstantaneousAvgTriad

      public void getInstantaneousAvgTriad(T result)
      Gets windowed average of measurements for each processed triad. This value is updated for each processed sample containing an average value for the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousStdX

      public double getInstantaneousStdX()
      Gets windowed standard deviation of x-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Returns:
      windowed standard deviation of x-coordinate of measurements for each processed triad.
    • getInstantaneousStdXAsMeasurement

      public M getInstantaneousStdXAsMeasurement()
      Gets windowed standard deviation of x-coordinate of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Returns:
      windowed standard deviation of x-coordinate of measurements for each processed triad.
    • getInstantaneousStdXAsMeasurement

      public void getInstantaneousStdXAsMeasurement(M result)
      Gets windowed standard deviation of x-coordinate of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousStdY

      public double getInstantaneousStdY()
      Gets windowed standard deviation of y-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Returns:
      windowed standard deviation of y-coordinate of measurements for each processed triad.
    • getInstantaneousStdYAsMeasurement

      public M getInstantaneousStdYAsMeasurement()
      Gets windowed standard deviation of y-coordinate of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation of the samples within the window.
      Returns:
      windowed standard deviation of y-coordinate of measurements for each processed triad.
    • getInstantaneousStdYAsMeasurement

      public void getInstantaneousStdYAsMeasurement(M result)
      Gets windowed standard deviation of y-coordinate of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation of the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousStdZ

      public double getInstantaneousStdZ()
      Gets windowed standard deviation of z-coordinate of measurements for each processed triad expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Returns:
      windowed standard deviation of z-coordinate of measurements for each processed triad.
    • getInstantaneousStdZAsMeasurement

      public M getInstantaneousStdZAsMeasurement()
      Gets windowed standard deviation of z-coordinate of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Returns:
      windowed standard deviation of z-coordinate of measurements for each processed triad.
    • getInstantaneousStdZAsMeasurement

      public void getInstantaneousStdZAsMeasurement(M result)
      Gets windowed standard deviation of z-coordinate of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • getInstantaneousStdTriad

      public T getInstantaneousStdTriad()
      Gets windowed standard deviation of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Returns:
      windowed standard deviation of measurements for each processed triad.
    • getInstantaneousStdTriad

      public void getInstantaneousStdTriad(T result)
      Gets windowed standard deviation of measurements for each processed triad. This value is updated for each processed sample containing measured standard deviation for the samples within the window.
      Parameters:
      result - instance where result will be stored.
    • process

      public boolean process(T triad) throws com.irurueta.navigation.LockedException
      Processes a new measurement triad sample.
      Parameters:
      triad - a new measurement triad to be processed.
      Returns:
      true if provided triad has been processed, false if provided triad has been skipped because detector previously failed. If detector previously failed, it will need to be reset before processing additional samples.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy processing a previous sample.
    • process

      public boolean process(M valueX, M valueY, M valueZ) throws com.irurueta.navigation.LockedException
      Processes a new measurement triad sample.
      Parameters:
      valueX - x-coordinate of sensed measurement.
      valueY - y-coordinate of sensed measurement.
      valueZ - z-coordinate of sensed measurement.
      Returns:
      true if provided triad has been processed, false if provided triad has been skipped because detector previously failed. If detector previously failed, it will need to be reset before processing additional samples.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy processing a previous sample.
    • process

      public boolean process(double valueX, double valueY, double valueZ) throws com.irurueta.navigation.LockedException
      Processes a new measurement triad sample. Provided measurement coordinates are expressed in meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
      Parameters:
      valueX - x-coordinate of sensed measurement.
      valueY - y-coordinate of sensed measurement.
      valueZ - z-coordinate of sensed measurement.
      Returns:
      true if provided triad has been processed, false if provided triad has been skipped because detector previously failed. If detector previously failed, it will need to be reset before processing additional samples.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy processing a previous sample.
    • reset

      public void reset() throws com.irurueta.navigation.LockedException
      Resets this detector so that it is initialized again when new samples are added.
      Throws:
      com.irurueta.navigation.LockedException - if detector is busy.
    • convertMeasurement

      protected double convertMeasurement(M measurement)
      Converts provided measurement instance to its default unit, which is meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (T) for magnetic flux density.
      Parameters:
      measurement - measurement to be converted.
      Returns:
      converted value.
    • convertMeasurement

      protected abstract double convertMeasurement(double value, U unit)
      Converts provided measurement value expressed in provided unit to the default measurement value, which is meters per squared second (m/s^2) for acceleration, radians per second (rad/s) for angular speed or Teslas (t) for magnetic flux density.
      Parameters:
      value - value to be converted.
      unit - unit of value to be converted.
      Returns:
      converted value.
    • createMeasurement

      protected abstract M createMeasurement(double value, U unit)
      Creates a measurement instance using provided value and unit.
      Parameters:
      value - value of measurement.
      unit - unit of value.
      Returns:
      created measurement
    • getDefaultUnit

      protected abstract U getDefaultUnit()
      Gets default unit for measurements this implementation works with.
      Returns:
      default measurement unit.
    • createTriad

      protected abstract T createTriad(double valueX, double valueY, double valueZ, U unit)
      Creates a triad.
      Parameters:
      valueX - x-coordinate value.
      valueY - y-coordinate value.
      valueZ - z-coordinate value.
      unit - unit of values.
      Returns:
      created triad.