Class AbsMin

java.lang.Object
me.wobblyyyy.pathfinder.math.AbsMin

public class AbsMin
extends java.lang.Object
Additional math utilities for getting the absolute minimum of a set of data. This is mostly useful in speed and state normalization.
Since:
0.5.0
Author:
Colin Robertson
  • Constructor Summary

    Constructors
    Constructor Description
    AbsMin()  
  • Method Summary

    Modifier and Type Method Description
    static double getAbsoluteMax​(double... values)
    Get the minimum absolute value of the provided numbers.
    static double of​(double... values)
    Get the minimum absolute value of the provided numbers.

    Methods inherited from class java.lang.Object

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

    • AbsMin

      public AbsMin()
  • Method Details

    • getAbsoluteMax

      public static double getAbsoluteMax​(double... values)
      Get the minimum absolute value of the provided numbers.

      Example A:

      • Inputs: 10, -15, 20, 30
      • Output: 10

      Example B:

      • Inputs: -130, 20, 10, 30
      • Output: 10

      Parameters:
      values - the values to find the absolute minimum of.
      Returns:
      the absolute minimum of the provided values.
    • of

      public static double of​(double... values)
      Get the minimum absolute value of the provided numbers. This method calls getAbsoluteMax(double...).

      Example A:

      • Inputs: 10, -15, 20, 30
      • Output: 10

      Example B:

      • Inputs: -130, 20, 10, 30
      • Output: 10

      Parameters:
      values - the values to find the absolute minimum of.
      Returns:
      the absolute minimum of the provided values.