jm.audio.math

## Class RealFloatFFT

- java.lang.Object
- - jm.audio.math.RealFloatFFT

- Direct Known Subclasses:
    RealFloatFFT_Radix2

      public abstract class RealFloatFFT
      extends java.lang.Object

  Abstract Class representing FFT's of real, single precision data. Concrete classes are typically named RealFloatFFT_method, implement the FFT using some particular method.

  The physical layout of the mathematical data d[i] in the array data is as follows:

          d[i] = data[i0 + stride*i]

  The FFT (D[i]) of real data (d[i]) is complex, but restricted by symmetry:

          D[n-i] = conj(D[i])

  It turns out that there are still n `independent' values, so the transformation can still be carried out in-place. However, each Real FFT method tends to leave the real and imaginary parts distributed in the data array in its own unique arrangment.

  You must consult the documentation for the specific classes implementing RealFloatFFT for the details. Note, however, that each class's backtransform and inverse methods understand thier own unique ordering of the transformed result and can invert it correctly.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `RealFloatFFT(int n)` Create an FFT for transforming n points of real, single precision data.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `backtransform(float[] data)` Compute the (unnomalized) inverse FFT of data, leaving it in place.
    `abstract void` | `backtransform(float[] data, int i0, int stride)` Compute the (unnomalized) inverse FFT of data, leaving it in place.
    `protected void` | `checkData(float[] data, int i0, int stride)`
    `void` | `inverse(float[] data)` Compute the (nomalized) inverse FFT of data, leaving it in place.
    `void` | `inverse(float[] data, int i0, int stride)` Compute the (nomalized) inverse FFT of data, leaving it in place.
    `float` | `normalization()` Return the normalization factor.
    `float[]` | `toWraparoundOrder(float[] data)` Return data in wraparound order.
    `abstract float[]` | `toWraparoundOrder(float[] data, int i0, int stride)` Return data in wraparound order.
    `void` | `transform(float[] data)` Compute the Fast Fourier Transform of data leaving the result in data.
    `abstract void` | `transform(float[] data, int i0, int stride)` Compute the Fast Fourier Transform of data leaving the result in data.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### RealFloatFFT

          public RealFloatFFT(int n)

      Create an FFT for transforming n points of real, single precision data.

  - ### Method Detail

    - #### checkData

          protected void checkData(float[] data,
                       int i0,
                       int stride)

    - #### transform

          public void transform(float[] data)

      Compute the Fast Fourier Transform of data leaving the result in data.

    - #### transform

          public abstract void transform(float[] data,
                       int i0,
                       int stride)

      Compute the Fast Fourier Transform of data leaving the result in data.

    - #### toWraparoundOrder

          public float[] toWraparoundOrder(float[] data)

      Return data in wraparound order.
      See Also:
        wraparound format

    - #### toWraparoundOrder

          public abstract float[] toWraparoundOrder(float[] data,
                                  int i0,
                                  int stride)

      Return data in wraparound order. i0 and stride are used to traverse data; the new array is in packed (i0=0, stride=1) format.
      See Also:
        wraparound format

    - #### backtransform

          public void backtransform(float[] data)

      Compute the (unnomalized) inverse FFT of data, leaving it in place.

    - #### backtransform

          public abstract void backtransform(float[] data,
                           int i0,
                           int stride)

      Compute the (unnomalized) inverse FFT of data, leaving it in place.

    - #### normalization

          public float normalization()

      Return the normalization factor. Multiply the elements of the backtransform'ed data to get the normalized inverse.

    - #### inverse

          public void inverse(float[] data)

      Compute the (nomalized) inverse FFT of data, leaving it in place.

    - #### inverse

          public void inverse(float[] data,
                     int i0,
                     int stride)

      Compute the (nomalized) inverse FFT of data, leaving it in place.