13
13
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="en" xml:id="freq">
15
<refname>freq</refname>
16
<refpurpose> frequency response</refpurpose>
19
<title>Calling Sequence</title>
20
<synopsis>[x]=freq(A,B,C [,D],f)
25
<title>Arguments</title>
28
<term>A, B, C, D</term>
31
real matrices of respective dimensions <literal>nxn, nxp, mxn, mxp</literal>.
39
polynomial matrices of dimension <literal>mxp</literal>
46
<para>real or complex matrix</para>
52
<title>Description</title>
54
<literal>x=freq(A,B,C [,D],f)</literal> returns a real or complex <literal>mxp*t</literal> matrix
58
<literal>x(:,k*p:(k+1)*p)= C*inv(f(k)*eye()-A)*B + D</literal>.
61
Thus, for <literal>f</literal> taking values along the imaginary axis or
62
on the unit circle <literal>x</literal> is the continuous or discrete time
63
frequency response of <literal>(A,B,C,D)</literal>.
66
<literal>x=freq(NUM,DEN,f)</literal> returns a real or complex matrix <literal>x</literal> such
67
that columns <literal>k*(p-1)+1</literal> to <literal>k*p</literal> of <literal>x</literal> contain the matrix
68
<literal>NUM(f(k))./DEN(f(k))</literal>
72
<title>Examples</title>
73
<programlisting role="example"><![CDATA[
15
<refname>freq</refname>
16
<refpurpose> frequency response</refpurpose>
19
<title>Calling Sequence</title>
20
<synopsis>[x]=freq(A,B,C [,D],f)
25
<title>Arguments</title>
28
<term>A, B, C, D</term>
31
real matrices of respective dimensions <literal>nxn, nxp, mxn, mxp</literal>.
39
polynomial matrices of dimension <literal>mxp</literal>
46
<para>real or complex matrix</para>
52
<title>Description</title>
54
<literal>x=freq(A,B,C [,D],f)</literal> returns a real or complex <literal>mxp*t</literal> matrix
58
<literal>x(:,k*p:(k+1)*p)= C*inv(f(k)*eye()-A)*B + D</literal>.
61
Thus, for <literal>f</literal> taking values along the imaginary axis or
62
on the unit circle <literal>x</literal> is the continuous or discrete time
63
frequency response of <literal>(A,B,C,D)</literal>.
66
<literal>x=freq(NUM,DEN,f)</literal> returns a real or complex matrix <literal>x</literal> such
67
that columns <literal>k*(p-1)+1</literal> to <literal>k*p</literal> of <literal>x</literal> contain the matrix
68
<literal>NUM(f(k))./DEN(f(k))</literal>
72
<title>Examples</title>
73
<programlisting role="example"><![CDATA[
75
75
sys=(s+1)/(s^3-5*s+4)
76
76
rep=freq(sys("num"),sys("den"),[0,0.9,1.1,2,3,10,20])
80
80
[A,B,C,D]=abcd(Sys);
81
81
freq(A,B,C,[0,0.9,1.1,2,3,10,20])
82
82
]]></programlisting>
84
<refsection role="see also">
85
<title>See Also</title>
86
<simplelist type="inline">
88
<link linkend="repfreq">repfreq</link>
91
<link linkend="horner">horner</link>
84
<refsection role="see also">
85
<title>See Also</title>
86
<simplelist type="inline">
88
<link linkend="repfreq">repfreq</link>
91
<link linkend="horner">horner</link>