Chapter 2 Linear System Representation
Xmath Control Design Module 2-10 ni.com
numden( )
[num,den] = numden(Sys)
The numden( ) function returns the numerator and denominator
polynomials comprising a single-input, single-output system in transfer
function form. If the system is in state-space form, an internal conversion
is performed to find the transfer function equivalent, but the format of the
system variable itself remains unchanged. State-space systems used in
conjunction with numden( ) must be single-input, single-output.
As noted in the Transfer Function System Models section, common roots in
the numerator and denominator polynomials are not canceled.
Example 2-5 uses the state-space system from Example 2-2 to illustrate the
use of numden( ).
Example 2-5 Using numden( ) to Extract the Transfer Function Polynomials
sys4=system([0,1;-0.75,0],[1,0]',[0,1],0,
{dt=0.5});
[num,den] = numden(sys4)?
num (a polynomial) =
-0.75
den (a polynomial) =
(z2 + 0.75)
Because num and den are polynomial objects and not a complete system,
the discrete sampling time is not explicitly saved. You can use check( )
with the convert keyword to map the two internal representations to each
other, as described in the Using check() with System Objects section.
However, notice that z was used as the polynomial variable, indicating that
these numerator and denominator polynomials were obtained from a
discrete-time system. Had the system been continuous, s would have been
used instead of z.
period( )
dt = period(Sys)
The period( ) function extracts the sample period (in seconds) of a
system. If the system is continuous, period( ) will return zero.
In Example 2-5, you found the numerator and denominator polynomials
corresponding to the discrete state-space system. Example 2-6 combines