Mercurial > hg > ltpda
view m-toolbox/classes/@pzmodel/abcascade.m @ 3:960fe1aa1c10 database-connection-manager
Add LTPDADatabaseConnectionManager implementation. Java code
author | Daniele Nicolodi <nicolodi@science.unitn.it> |
---|---|
date | Mon, 05 Dec 2011 16:20:06 +0100 |
parents | f0afece42f48 |
children |
line wrap: on
line source
% ABCASCADE Cascade two filters together to get a new filter. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % DESCRIPTION: ABCASCADE Cascade two filters together to get a new filter. % % CALL: [a,b] = abcascade(a1,b1,a2,b2) % % VERSION: $Id: abcascade.m,v 1.3 2010/10/29 16:09:15 ingo Exp $ % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% function [ao,bo] = abcascade(a1,b1,a2,b2) n = length(a1); m = length(a2); N = m+n-1; alpha = zeros(1, N); beta = zeros(1, N); for i=0:n-1 for j=0:m-1 alpha(i+j+1) = alpha(i+j+1) + a1(i+1)*a2(j+1); beta(i+j+1) = beta(i+j+1) + b1(i+1)*b2(j+1); end end ao = alpha; bo = beta; end