set fundamental to 0dB using snr
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
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 commentaires
Réponse acceptée
Star Strider
le 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 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Fourier Analysis and Filtering dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!