You can explicitly convert a model from one representation to
another using the model-creation command for the target model type.
For example, convert to state-space representation using
ss, and convert to parallel-form PID
pid. For information
about converting to a particular model type, see the reference page
for that model type.
In general, you can convert from any model type to any other. However, there are a few limitations. For example, you cannot convert:
frd models to analytic model
types such as
you perform system identification with System
Identification Toolbox™ software).
ss models with internal delays
You can convert between Numeric LTI models and Generalized LTI models.
Converting a Generalized LTI model to a Numeric LTI model evaluates any Control Design Blocks at their current (nominal) value.
Converting a Numeric LTI model to a Generalized LTI
model creates a Generalized LTI model with an empty
Some algorithms operate only on one type of model object. For
example, the algorithm for zero-order-hold discretization with
c2d can only be performed on state-space
models. Similarly, commands such as
a particular type of model (
respectively). For convenience, such commands automatically
convert input models to the appropriate or required model type. For
sys = ss(0,1,1,0) [num,den] = tfdata(sys)
tfdata automatically converts the state-space
sys to transfer function form to return numerator
and denominator data.
Conversions to state-space form are not uniquely defined. For
this reason, automatic conversions to state space do not occur when
the result depends on the choice of state coordinates. For example,
require state-space models.
You can represent numeric system components using any model
type. However, Numeric LTI model types are not equally well-suited
for numerical computations. In general, it is recommended that you
work with state-space (
ss) or frequency response
frd) models, for the following reasons:
The accuracy of computations using high-order transfer
is sometimes poor, particularly for MIMO or high-order systems. Conversions
to a transfer function representation can incur a loss of accuracy.
When you convert
to state space using
ss, the software automatically
performs balancing and scaling operations. Balancing and scaling improves
the numeric accuracy of computations involving the model. For more
information about balancing and scaling state-space models, see Scaling State-Space Models.
In addition, converting back and forth between
model types can introduce additional states or orders, or introduce
numeric inaccuracies. For example, conversions to state space are
not uniquely defined, and are not guaranteed to produce a minimal
realization for MIMO models. For a given state-space model
can return a model with different state-space matrices, or even a different number of states in the MIMO case.