|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object marf.math.Algorithms.FFT
public static final class Algorithms.FFT
A collection of FFT-related math.
Constructor Summary | |
---|---|
Algorithms.FFT()
|
Method Summary | |
---|---|
static void |
doFFT(double[] padInputReal,
double[] padInputImag,
double[] padOutputReal,
double[] padOutputImag,
int piDirection)
FFT algorithm, translated from "Numerical Recipes in C++" that implements the Fast Fourier Transform, which performs a discrete Fourier transform in O(n*log(n)). |
static void |
doFFT2(ComplexMatrix poInputMatrix,
ComplexMatrix poOutputMatrix,
int piDirection)
Performs 2D FFT; which is merely 1D FFT for every column, and then, 1D FFT of every row of the result. |
static void |
normalFFT(double[] padSample,
double[] padMagnitude)
Performs a normal FFT, taking a real input (supposedly an audio sample) and returns the frequency analysis in terms of "magnitude". |
static void |
normalFFT(double[] padSample,
double[] padMagnitude,
double[] padPhaseAngle)
Performs a normal FFT, taking a real input (supposedly an audio sample) and returns the frequency analysis in terms of "magnitude" and "phase angle". |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Algorithms.FFT()
Method Detail |
---|
public static final void doFFT(double[] padInputReal, double[] padInputImag, double[] padOutputReal, double[] padOutputImag, int piDirection) throws MathException
padInputReal
- InputReal is real part of input arraypadInputImag
- InputImag is imaginary part of input arraypadOutputReal
- OutputReal is real part of output arraypadOutputImag
- OutputImag is imaginary part of output arraypiDirection
- Direction is 1 for normal FFT, -1 for inverse FFT
MathException
- if the sizes or direction are wrongpublic static final void doFFT2(ComplexMatrix poInputMatrix, ComplexMatrix poOutputMatrix, int piDirection) throws MathException
poInputMatrix
- poOutputMatrix
- piDirection
-
MathException
public static final void normalFFT(double[] padSample, double[] padMagnitude, double[] padPhaseAngle) throws MathException
padSample
- must be an array of size (2^k)padMagnitude
- must be half the size of "sample"padPhaseAngle
- must be half the size of "sample"
MathException
public static final void normalFFT(double[] padSample, double[] padMagnitude) throws MathException
padSample
- must be an array of size (2^k)padMagnitude
- must be half the size of "sample"
MathException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |