set fundamental to 0dB using snr
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Joe Miller
am 2 Sep. 2017
Kommentiert: Star Strider
am 3 Sep. 2017
Dear Sir/Madam,
How do you adjust the snr plot so that the fundamental is at 0dB?
Fs = 10000;
f = 2100;
t = 0:1/Fs:1;
x = 5*sin(2*pi*f*t) + 0.001*randn(1,length(t));
snr(x, Fs, 5);
Regards Joe
0 Kommentare
Akzeptierte Antwort
Star Strider
am 2 Sep. 2017
Dividing ‘x’ by ‘max(x)’ is probably as close as you can get:
xs = x/max(x);
figure(1)
snr(xs, Fs, 5)
2 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Fourier Analysis and Filtering finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!