www.gusucode.com > signal 案例源码程序 matlab代码 > signal/FilterNormsExample.m

    %% Filter Norms
% Compute the 2-norm of a Butterworth IIR filter with tolerance $10^{-10}$.
% Specify a normalized cutoff frequency of $0.5\pi$ rad/s and a filter
% order of 5.

% Copyright 2015 The MathWorks, Inc.


%%

[b,a] = butter(5,0.5);
L2 = filternorm(b,a,2,1e-10)

%%
% Compute the infinity-norm of an FIR Hilbert transformer of order 30 and
% normalized transition width $0.2\pi$ rad/s.

b = firpm(30,[.1 .9],[1 1],'Hilbert');
Linf = filternorm(b,1,inf)