Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,86 @@

/* eslint-disable max-lines */

import rfftf = require( '@stdlib/fft/base/fftpack/ndarray/float32/rfftf' );
import rffti = require( '@stdlib/fft/base/fftpack/ndarray/float32/rffti' );

/**
* Interface describing the `float32` namespace.
*/
interface Namespace {
/**
* TODO
* Computes the forward discrete Fourier transform (DFT) of a real-valued one-dimensional single-precision floating-point ndarray.
*
* ## Notes
*
* - The function expects the following ndarrays:
*
* - a one-dimensional input ndarray.
* - a one-dimensional workspace ndarray containing pre-computed values.
*
* @param arrays - array-like object containing ndarrays
* @returns input ndarray
*
* @example
* var Float32Vector = require( '@stdlib/ndarray/vector/float32' );
* var scalar2ndarray = require( '@stdlib/ndarray/from-scalar' );
* var rffti = require( '@stdlib/fft/base/fftpack/ndarray/float32/rffti' );
*
* var N = 4;
* var len = scalar2ndarray( N, {
* 'dtype': 'int32'
* });
*
* var w = new Float32Vector( ( 2*N ) + 34 );
* rffti( [ w, len ] );
*
* var r = new Float32Vector( [ 1.0, 2.0, 3.0, 4.0 ] );
*
* var out = ns.rfftf( [ r, w ] );
* // returns <ndarray>[ 10.0, -2.0, 2.0, -2.0 ]
*
* var bool = ( out === r );
* // returns true
*/
rfftf: typeof rfftf;

/**
* Initializes a workspace array for performing a real-valued Fourier transform on a one-dimensional single-precision floating-point ndarray.
*
* ## Notes
*
* - The function expects the following ndarrays:
*
* - a one-dimensional input ndarray.
* - a zero-dimensional ndarray containing the length of the sequence to transform.
*
* @param arrays - array-like object containing ndarrays
* @returns input ndarray
*
* @example
* var Float32Vector = require( '@stdlib/ndarray/vector/float32' );
* var scalar2ndarray = require( '@stdlib/ndarray/from-scalar' );
* var Slice = require( '@stdlib/slice/ctor' );
* var slice = require( '@stdlib/ndarray/slice' );
*
* var N = 8;
* var len = scalar2ndarray( N, {
* 'dtype': 'int32'
* });
*
* var w = new Float32Vector( ( 2*N ) + 34 );
*
* var out = ns.rffti( [ w, len ] );
* // returns <ndarray>
*
* var bool = ( out === w );
* // returns true
*
* var twiddleFactors = slice( w, new Slice( N, 2*N ) );
* // returns <ndarray>[ ~0.707, ~0.707, 0, 0, 0, 0, 0, 0 ]
*
* var factors = slice( w, new Slice( 2*N, ( 2*N ) + 4 ) );
* // returns <ndarray>[ 8, 2, 2, 4 ]

Check failure on line 102 in lib/node_modules/@stdlib/fft/base/fftpack/ndarray/float32/docs/types/index.d.ts

View workflow job for this annotation

GitHub Actions / Lint Changed Files

Expected entries [ 8, 2, 2, 4 ], but observed [ ~0, ~0, ~0, ~0 ]
*/
rffti: typeof rffti;
}
Expand Down
Loading