Class GaussianWaveform

java.lang.Object
org.yamcs.studio.data.sim.SimFunction<VDoubleArray>
org.yamcs.studio.data.sim.GaussianWaveform

public class GaussianWaveform extends SimFunction<VDoubleArray>
Function to simulate a waveform containing a gaussian that moves to the left.
  • Constructor Details

    • GaussianWaveform

      public GaussianWaveform()
      Creates a gaussian wave of 100 samples, with period of 1 second, standard deviation of 100 samples, updating every 100ms (10Hz).
    • GaussianWaveform

      public GaussianWaveform(Double periodInSeconds, Double stdDev, Double nSamples, Double updateRateInSeconds)
      Creates a gaussian wave of given number of samples, with given period and standard, updating at the given rate
      Parameters:
      periodInSeconds - the period measured in seconds
      stdDev - standard deviation of the gaussian distribution
      nSamples - number of elements in the waveform
      updateRateInSeconds - time between samples in seconds
  • Method Details

    • gaussian

      public static double gaussian(double x, double centerX, double width)
      1D gaussian, centered on centerX and with the specified width.
      Parameters:
      x - coordinate x
      centerX - center of the gaussian on x
      width - width of the gaussian in all directions
      Returns:
      the value of the function at the given coordinates