[READ-ONLY] Mirror of https://github.com/jmrplens/FFT2octave. Matlab. Filter FFT data to octave-band and fractional octave-band.
0

Configure Feed

Select the types of activity you want to include in your feed.

Output in RMS

authored by

Jose M. Requena Plens and committed by
GitHub
(Apr 28, 2021, 2:40 AM +0200) b41fcd6d a3a43849

+2 -2
+2 -2
FFT2octave.m
··· 69 69 % Acumulate 70 70 switch lower(type) 71 71 case 'db' % Logarithmic 72 - Oct(nOct) = 10*log10(sum(10.^(OctArr/10))); 72 + Oct(nOct) = 10*log10(sqrt(sum((10.^(OctArr/10)).^2))); % rms 73 73 if floor(BW(nOct)/deltaf) <= numel(OctArr) 74 74 % Correction factor. Product by frequency increment 75 75 Oct(nOct) = Oct(nOct) + 10*log10( BW(nOct)/(deltaf*numel(OctArr)) ); 76 76 end 77 77 78 78 otherwise % Linear 79 - Oct(nOct) = sum(OctArr); 79 + Oct(nOct) = sqrt(sum(OctArr.^2)); % rms 80 80 if floor(BW(nOct)/deltaf) <= numel(OctArr) 81 81 % Correction factor. Product by frequency increment 82 82 Oct(nOct) = Oct(nOct) * BW(nOct)/(deltaf*numel(OctArr));