Skip to content

signal.AdaptiveStft.Function.getSingle

Christian d'Heureuse edited this page Jun 7, 2026 · 2 revisions

dsp-collection / signal/AdaptiveStft / getSingle

Function: getSingle()

function getSingle(
   samples, 
   roughFrequency, 
   windowFunction): Complex;

Defined in: signal/AdaptiveStft.ts:110

A simplified version of getSingle_maxWindow().

The maximum window width covers the entire input signal.

Parameters

samples

Float32Array<ArrayBufferLike> | Float64Array<ArrayBufferLike>

The input signal.

roughFrequency

number

The rough frequency of the sine wave component to be computed. The specified value is adjusted to the nearest value that allows a computation without subsampling. The unit of the specified frequency value is 1/samples (normalized frequency).

windowFunction

| WindowFunction | undefined

A window function or undefined for no windowing (i.e. for using a rectangular window).

Returns

Complex

A complex value that represents the amplitude and phase of the sine wave component, or Complex.NaN.

Clone this wiki locally