Fft<T>.ForwardTransform Method

Definition

Namespace: Extreme.Mathematics.SignalProcessing
Assembly: Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.23

Overload List

ForwardTransform(Vector<T>) Computes the discrete Fourier transform of a real signal and returns the result.
ForwardTransform(Vector<Complex<T>>) Computes the discrete Fourier transform of a complex signal and returns the result.
ForwardTransform(ArraySlice<T>, ArraySlice<Complex<T>>) Computes the discrete Fourier transform of a real signal.
ForwardTransform(ArraySlice<Complex<T>>, ArraySlice<Complex<T>>) Computes the discrete Fourier transform of a complex signal.
ForwardTransform(DenseVector<T>, ComplexConjugateSignalVector<T>) Computes the discrete Fourier transform of a real signal.
ForwardTransform(DenseVector<Complex<T>>, DenseVector<Complex<T>>) Computes the discrete Fourier transform of a complex signal.
ForwardTransform(Vector<T>, Vector<Complex<T>>) Computes the discrete Fourier transform of a real signal.
ForwardTransform(Vector<Complex<T>>, Vector<Complex<T>>) Computes the discrete Fourier transform of a complex signal.
ForwardTransform(Vector<T>, Vector<Complex<T>>, RealFftFormat) Computes the discrete Fourier transform of a real signal.

ForwardTransform(Vector<T>)

Computes the discrete Fourier transform of a real signal and returns the result.
C#
public ComplexConjugateSignalVector<T> ForwardTransform(
	Vector<T> input
)

Parameters

input  Vector<T>
A Double vector containing the input signal.

Return Value

ComplexConjugateSignalVector<T>
A ComplexConjugateSignalVector<T>.

Remarks

The output is stored in a compact format to take advantage of the symmetry properties of a real Fourier transform. Specifically, the return value stores only the first n/2+1 terms of the transformed signal.

Exceptions

ArgumentNullExceptioninput is null.

ForwardTransform(Vector<Complex<T>>)

Computes the discrete Fourier transform of a complex signal and returns the result.
C#
public DenseVector<Complex<T>> ForwardTransform(
	Vector<Complex<T>> input
)

Parameters

input  Vector<Complex<T>>
On input, a complex vector containing the input signal. On return, the forward transform of the input.

Return Value

DenseVector<Complex<T>>

Exceptions

ArgumentNullExceptioninput is null.

ForwardTransform(ArraySlice<T>, ArraySlice<Complex<T>>)

Computes the discrete Fourier transform of a real signal.
C#
public abstract void ForwardTransform(
	ArraySlice<T> input,
	ArraySlice<Complex<T>> output
)

Parameters

input  ArraySlice<T>
A real array slice containing the input signal.
output  ArraySlice<Complex<T>>
A complex array slice to hold the transformed signal.

Remarks

The output is stored in a compact format to take advantage of the symmetry properties of a real Fourier transform. Specifically, output contains only the first n/2+1 terms of the transformed signal. Use the complex ArraySlice<T> class to obtain a complex vector that represents the complete signal.

Exceptions

InvalidOperationExceptionThe Fourier transform implementation is not configured to accept real input.
ArgumentNullExceptioninput is null.

-or-

output is null.

DimensionMismatchException The length of input does not equal the length of output.

ForwardTransform(ArraySlice<Complex<T>>, ArraySlice<Complex<T>>)

Computes the discrete Fourier transform of a complex signal.
C#
public abstract void ForwardTransform(
	ArraySlice<Complex<T>> input,
	ArraySlice<Complex<T>> output
)

Parameters

input  ArraySlice<Complex<T>>
A complex ArraySlice<T> containing the input signal.
output  ArraySlice<Complex<T>>
A complex ArraySlice<T> to hold the transformed signal.

Exceptions

ArgumentNullExceptioninput is null.

-or-

output is null.

DimensionMismatchException The length of input does not equal the length of output.

ForwardTransform(DenseVector<T>, ComplexConjugateSignalVector<T>)

Computes the discrete Fourier transform of a real signal.
C#
public void ForwardTransform(
	DenseVector<T> input,
	ComplexConjugateSignalVector<T> output
)

Parameters

input  DenseVector<T>
A Double vector containing the input signal.
output  ComplexConjugateSignalVector<T>
A complex vector to hold the transformed signal.

Remarks

The output is stored in a compact format to take advantage of the symmetry properties of a real Fourier transform. Specifically, output contains only the first n/2+1 terms of the transformed signal. Use the ComplexConjugateSignalVector<T> class to obtain a complex vector that represents the complete signal.

Exceptions

InvalidOperationExceptionThe Fourier transform implementation is not configured to accept real input.
ArgumentNullExceptioninput is null.

-or-

output is null.

DimensionMismatchException The length of input does not equal the length of output.

ForwardTransform(DenseVector<Complex<T>>, DenseVector<Complex<T>>)

Computes the discrete Fourier transform of a complex signal.
C#
public void ForwardTransform(
	DenseVector<Complex<T>> input,
	DenseVector<Complex<T>> output
)

Parameters

input  DenseVector<Complex<T>>
A dense complex vector containing the input signal.
output  DenseVector<Complex<T>>
A dense complex vector to hold the transformed signal.

Exceptions

ArgumentNullExceptioninput is null.

-or-

output is null.

DimensionMismatchException The length of input does not equal the length of output.

ForwardTransform(Vector<T>, Vector<Complex<T>>)

Computes the discrete Fourier transform of a real signal.
C#
public void ForwardTransform(
	Vector<T> input,
	Vector<Complex<T>> output
)

Parameters

input  Vector<T>
A Double vector containing the input signal.
output  Vector<Complex<T>>
A complex vector to hold the transformed signal.

Remarks

The output is stored in a compact format to take advantage of the symmetry properties of a real Fourier transform. Specifically, output contains only the first n/2+1 terms of the transformed signal. Use the ComplexConjugateSignalVector<T> class to obtain a complex vector that represents the complete signal.

Exceptions

ArgumentNullExceptioninput is null.

-or-

output is null.

ForwardTransform(Vector<Complex<T>>, Vector<Complex<T>>)

Computes the discrete Fourier transform of a complex signal.
C#
public void ForwardTransform(
	Vector<Complex<T>> input,
	Vector<Complex<T>> output
)

Parameters

input  Vector<Complex<T>>
A complex vector containing the input signal.
output  Vector<Complex<T>>
A complex vector to hold the transformed signal.

Exceptions

ArgumentNullExceptioninput is null.

-or-

output is null.

ForwardTransform(Vector<T>, Vector<Complex<T>>, RealFftFormat)

Computes the discrete Fourier transform of a real signal.
C#
public void ForwardTransform(
	Vector<T> input,
	Vector<Complex<T>> output,
	RealFftFormat outputFormat
)

Parameters

input  Vector<T>
A Double vector containing the input signal.
output  Vector<Complex<T>>
A complex vector to hold the transformed signal.
outputFormat  RealFftFormat
A RealFftFormat value that specifies whether to return a one-sided or a two-sided transform.

Remarks

Use this method to compute the Fourier transform of a real signal. The outputFormat specifies whether the return value should contain the full complex transform (TwoSided), or only the first n/2+1 terms of the transformed signal (OneSided), where n is the length of the transform.

Exceptions

InvalidOperationExceptionThe Fourier transform implementation is not configured to accept real input.
ArgumentNullExceptioninput is null.

-or-

output is null.

ArgumentOutOfRangeExceptionoutputFormat is not a valid RealFftFormat value.
DimensionMismatchExceptionoutputFormat equals OneSided and the length of output does not equal half the length of input plus one.

-or-

outputFormat equals TwoSided and the length of input does not equal the length of output.

See Also