Mercurial > hg > aimmat
view aim-mat/modules/nap/twodat2003/calcfreqslope.m @ 0:74dedb26614d
Initial checkin of AIM-MAT version 1.5 (6.4.2011).
author | tomwalters |
---|---|
date | Fri, 20 May 2011 12:32:31 +0100 |
parents | |
children | 20ada0af3d7d |
line wrap: on
line source
% % function adjacent_band_level=calcfreqslope(cf,af); % % INPUT VALUES: % % % RETURN VALUE: % % % (c) 2011, University of Southampton % Maintained and written by Stefan Bleeck (bleec@gmail.com) % http://www.soton.ac.uk/aim function adjacent_band_level=calcfreqslope(cf,af,b); % function used to calculate the relative amplitudes in adjacent GTFBs %e.g to calculate the level in 2000Hz critical band due to excitation %in 1000Hz critical band calcfreqslope(2000,1000); n=4; %ERB = 24.7+0.108.*cf; [dummy ERB]=Freq2ERB(cf); B=b.*ERB; h_cf=abs(3.*(B./(2.*pi.*i.*(cf-cf)+2.*pi.*B)).^n); h_af=abs(3.*(B./(2.*pi.*i.*(af-cf)+2.*pi.*B)).^n); adjacent_band_level=h_af./h_cf; adjacent_band_level=20.*log10(adjacent_band_level);