lsimplot
Plot simulated time response of dynamic system to arbitrary inputs with additional plot customization options
Syntax
Description
lsimplot
lets you plot simulated time response of dynamic
system to arbitrary inputs with a broader range of plot customization options than
lsim
. You can use lsimplot
to obtain the plot handle
and use it to customize the plot, such as modify the axes labels, limits and units. You can
also use lsimplot
to draw a simulated time response plot on an existing set
of axes represented by an axes handle. To customize an existing simulated time response plot
using the plot handle:
Obtain the plot handle
Use
getoptions
to obtain the option setUpdate the plot using
setoptions
to modify the required options
For more information, see Customizing Response Plots from the Command Line. To create simulated time response plots with default
options or to extract simulated response data, use lsim
.
opens
the Linear Simulation Tool for the dynamic system model
h
= lsimplot(sys
)sys
, where you can interactively specify the driving input(s), the time
vector, and initial state. It also returns the plot handle h
. You can
use this handle h
to customize the plot with the getoptions
and setoptions
commands.
For more information about using the Linear Simulation Tool for linear analysis, see Working with the Linear Simulation Tool.
plots the simulated time response of the model h
= lsimplot(sys
,u
,t
)sys
to the input signal
u
and the corresponding time vector t
. For MIMO
systems, u
is a matrix with as many columns as the number of inputs and
whose i
th row specifies the input value at time t(i)
.
For SISO systems, the input u
can be specified either as a row or
column vector.
plots the simulated response with the options set specified in
h
= lsimplot(___,plotoptions
)plotoptions
. You can use these options to customize the plot
appearance using the command line. Settings you specify in plotoptions
overrides the preference settings in the MATLAB® session in which you run lsimplot
. Therefore, this syntax
is useful when you want to write a script to generate multiple plots that look the same
regardless of the local preferences.
Examples
Input Arguments
Output Arguments
Version History
Introduced before R2006a