dicklyon@517: % Copyright 2012, Google, Inc. dicklyon@517: % Author: Richard F. Lyon dicklyon@517: % dicklyon@517: % This Matlab file is part of an implementation of Lyon's cochlear model: dicklyon@517: % "Cascade of Asymmetric Resonators with Fast-Acting Compression" dicklyon@517: % to supplement Lyon's upcoming book "Human and Machine Hearing" dicklyon@517: % dicklyon@517: % Licensed under the Apache License, Version 2.0 (the "License"); dicklyon@517: % you may not use this file except in compliance with the License. dicklyon@517: % You may obtain a copy of the License at dicklyon@517: % dicklyon@517: % http://www.apache.org/licenses/LICENSE-2.0 dicklyon@517: % dicklyon@517: % Unless required by applicable law or agreed to in writing, software dicklyon@517: % distributed under the License is distributed on an "AS IS" BASIS, dicklyon@517: % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. dicklyon@517: % See the License for the specific language governing permissions and dicklyon@517: % limitations under the License. dicklyon@517: tom@516: function ERB = ERB_Hz(CF_Hz, ERB_break_freq, ERB_Q) tom@516: % function ERB = ERB_Hz(CF_Hz, ERB_break_freq, ERB_Q) tom@516: % tom@516: % Auditory filter nominal Equivalent Rectangular Bandwidth tom@516: % Ref: Glasberg and Moore: Hearing Research, 47 (1990), 103-138 tom@516: % ERB = 24.7 * (1 + 4.37 * CF_Hz / 1000); tom@516: tom@516: if nargin < 3 tom@516: ERB_Q = 1000/(24.7*4.37); % 9.2645 tom@516: if nargin < 2 tom@516: ERB_break_freq = 1000/4.37; % 228.833 tom@516: end tom@516: end tom@516: tom@516: ERB = (ERB_break_freq + CF_Hz) / ERB_Q;