Class LowPassFilter

java.lang.Object
com.stuypulse.stuylib.streams.numbers.filters.LowPassFilter
All Implemented Interfaces:
IFilter

public class LowPassFilter extends Object implements IFilter
Implementation of a real time IIR LowPassFilter
  • Constructor Details

    • LowPassFilter

      public LowPassFilter(Number rc)
      Parameters:
      rc - Time Constant. The time constant is the amount of time in seconds that it takes to get 63.2% of the way to the target value. 63.2% is (1 - (1 / e)).
  • Method Details

    • get

      public double get(double next)
      Description copied from interface: IFilter
      Get next value in Filter based on the next value given
      Specified by:
      get in interface IFilter
      Parameters:
      next - next input value in the stream
      Returns:
      the output value of the filter