Home > classes > @pzmodel > getlowerFreq.m

getlowerFreq

PURPOSE ^

GETLOWERFREQ gets the frequency of the lowest pole or zero in the model.

SYNOPSIS ^

function f = getlowerFreq(pzm)

DESCRIPTION ^

 GETLOWERFREQ gets the frequency of the lowest pole or zero in the model.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

 DESCRIPTION: GETLOWERFREQ gets the frequency of the lowest pole or zero in the
              model.

 CALL:        f = getlowerFreq(pzm);

 VERSION:     $Id: getlowerFreq.m,v 1.2 2007/07/18 13:58:45 ingo Exp $

 HISTORY:     04-04-2007 M Hewitson
                 Creation

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function f = getlowerFreq(pzm)
0002 % GETLOWERFREQ gets the frequency of the lowest pole or zero in the model.
0003 %
0004 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0005 %
0006 % DESCRIPTION: GETLOWERFREQ gets the frequency of the lowest pole or zero in the
0007 %              model.
0008 %
0009 % CALL:        f = getlowerFreq(pzm);
0010 %
0011 % VERSION:     $Id: getlowerFreq.m,v 1.2 2007/07/18 13:58:45 ingo Exp $
0012 %
0013 % HISTORY:     04-04-2007 M Hewitson
0014 %                 Creation
0015 %
0016 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0017 
0018 poles = get(pzm, 'poles');
0019 zeros = get(pzm, 'zeros');
0020 np = length(poles);
0021 nz = length(zeros);
0022 f = 1e10;
0023 for j=1:np
0024   pole = poles(j);
0025   fc = get(pole, 'f');
0026   if fc < f
0027     f = fc;
0028   end
0029 end
0030 
0031 for j=1:nz
0032   zero = zeros(j);
0033   fc = get(zero, 'f');
0034   if fc < f
0035     f = fc;
0036   end
0037 end
0038 
0039 
0040 
0041 % END

Generated on Mon 03-Sep-2007 12:12:34 by m2html © 2003