Download as pdf or txt
Download as pdf or txt
You are on page 1of 19

6T1: Harmonic Model

Xavier Serra
Universitat Pompeu Fabra, Barcelona
&
Stanford University
Index
● Harmonic model
● Sinusoids-partials-harmonics
● Polyphonic-monophonic signals
● Harmonic detection (after F0 detection)
● Harmonic model system
Harmonic model

R
yh[n]=∑ Ar [n]cos(2 π rf 0 [n]n)
r=1

R : number of harmonic components


Ar [n]: instantaneous amplitude
f 0 [n]: fundamental frequency (Hz)
Spectral view
Rl

Yhl [k ]= ∑ A(r , l) W [ k −r ^f (0,l ) ]


r=1

W :spectrum of analysis window


R : number of harmonics
A :amplitude of harmonic
f^ 0 : normalized fundamental frequency
l :frame number
r : harmonic number
Sinusoids-partials-harmonics
Sinusoids-partials-harmonics
Polyphonic-monophonic signals
Polyphonic-monophonic signals
Polyphonic-monophonic signals
Harmonic detection
Harmonic stable spectral peak whose frequency is close
to a multiple of the fundamental frequency.

Condition for a peak f p to be a harmonic f h :

f p [l ]= f h [l ] if (| f p [l ]−(h∗ f 0 [l ])| < threshold )


and exists f h [l −2] , f h [l −3] ,... , f h [l− L]
Harmonic model system
w[n]
|X[k]| Apfp pp f0
x[n] Peak F0 Harmonic
X FFT detection detection
xw[n] detection
<X[k]
Ah fh ph
Analysis

Synthesis
Sine spectral
synthesis

Yh[k]

IFFT

yhw[n]

Overlap-add

yh[n]
References and credits

● More information in:


– https://en.wikipedia.org/wiki/Harmonic_series_(music)
– https://en.wikipedia.org/wiki/Harmonic
● Sounds from:
http://www.freesound.org/people/xserra/packs/13038/
● Slides and code released using the CC Attribution-
Noncommercial-Share Alike license or the Affero GPL license
and available from https://github.com/MTG/sms-tools
6T1: Harmonic Model

Xavier Serra
Universitat Pompeu Fabra, Barcelona
&
Stanford University

You might also like