Skip to contents

Pitch period at the quefrency of the dominant rahmonic of \(c(q) = \mathrm{IDFT}\{\log|X(f)|\}\). The logarithm turns the product of excitation and envelope spectra into a sum, separating them in quefrency. Mirrors morie.fn.rgcepsp.

Usage

morie_cepstrum_pitch(x, fs, f0_range = c(50, 500))

Arguments

x

numeric signal.

fs

sampling frequency.

f0_range

plausible pitch range in Hz.

Value

list: f0, period_s, peak_value.

References

Rangayyan (2015), Ch. 3.

Examples

set.seed(1)
morie_cepstrum_pitch(rnorm(1024), 8000)$f0
#> [1] 70.17544