Home > freetb4matlab > control > fir2sys.m

fir2sys

PURPOSE ^

% construct a system data structure from @acronym{FIR} description

SYNOPSIS ^

function sys = fir2sys (num, tsam, inname, outname)

DESCRIPTION ^

% -*- texinfo -*-
% @deftypefn {Function File} {} fir2sys (@var{num}, @var{tsam}, @var{inname}, @var{outname})
% construct a system data structure from @acronym{FIR} description
%
% @strong{Inputs}
% @table @var
% @item num
% vector of coefficients 
% @ifinfo
% [c0, c1, @dots{}, cn]
% @end ifinfo
% @iftex
% @tex
% $ [c_0, c_1, \ldots, c_n ]$
% @end tex
% @end iftex
% of the @acronym{SISO} @acronym{FIR} transfer function
% @ifinfo
% C(z) = c0 + c1*z^(-1) + c2*z^(-2) + @dots{} + cn*z^(-n)
% @end ifinfo
% @iftex
% @tex
% $$ C(z) = c_0 + c_1z^{-1} + c_2z^{-2} + \ldots + c_nz^{-n} $$
% @end tex
% @end iftex
%
% @item tsam
% sampling time (default: 1)
%
% @item inname
% name of input signal;  may be a string or a list with a single entry.
%
% @item outname
% name of output signal; may be a string or a list with a single entry.
% @end table
%
% @strong{Output}
% @table @var
% @item sys
% system data structure
% @end table
%
% @strong{Example}
% @example
% octave:1> sys = fir2sys([1 -1 2 4],0.342,...
% > 'A/D input','filter output');
% octave:2> sysout(sys)
% Input(s)
%         1: A/D input
%
% Output(s):
%         1: filter output (discrete)
%
% Sampling interval: 0.342
% transfer function form:
% 1*z^3 - 1*z^2 + 2*z^1 + 4
% -------------------------
% 1*z^3 + 0*z^2 + 0*z^1 + 0
% @end example
% @end deftypefn

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:
Generated on Fri 22-May-2009 15:13:00 by m2html © 2003