Documentation Center

  • Trial Software
  • Product Updates

Functions in Control System Toolbox

  • By Category | Alphabetical List
  • Linear System Representation

    Basic Models

    tf Create transfer function model, convert to transfer function model
    zpk Create zero-pole-gain model; convert to zero-pole-gain model
    ss Create state-space model, convert to state-space model
    frd Create frequency-response data model, convert to frequency-response data model
    pid Create PID controller in parallel form, convert to parallel-form PID controller
    pidstd Create a PID controller in standard form, convert to standard-form PID controller
    dss Create descriptor state-space models
    drss Generate random discrete test model
    filt Specify discrete transfer functions in DSP format
    rss Generate random continuous test model

    Tunable Models

    genss Generalized state-space model
    genfrd Generalized frequency response data (FRD) model
    genmat Generalized matrix with tunable parameters
    ltiblock.gain Tunable static gain block
    ltiblock.pid Tunable PID controller
    ltiblock.pid2 Tunable two-degree-of-freedom PID controller
    ltiblock.ss Tunable fixed-order state-space model
    ltiblock.tf Tunable transfer function with fixed number of poles and zeros
    realp Real tunable parameter
    loopswitch Switch for opening and closing feedback loops
    getLoopTransfer Open-loop transfer function of control system
    getIOTransfer Closed-loop transfer function from generalized model of control system
    getSensitivity Sensitivity function from generalized model of control system
    getCompSensitivity Complementary sensitivity function from generalized model of control system
    getSwitches Get list of loop opening sites in generalized model of control system
    replaceBlock Replace or update Control Design Blocks in Generalized LTI model
    getValue Current value of Generalized Model
    setValue Modify current value of Control Design Block
    getBlockValue Current value of Control Design Block in Generalized Model
    setBlockValue Modify value of Control Design Block in Generalized Model
    showBlockValue Display current value of Control Design Blocks in Generalized Model
    showTunable Display current value of tunable Control Design Blocks in Generalized Model
    nblocks Number of blocks in Generalized matrix or Generalized LTI model
    getLFTModel Decompose generalized LTI model
    view (genmat) Visualize gain surface as a function of scheduling variables

    Models with Time Delays

    hasdelay True for linear model with time delays
    hasInternalDelay Determine if model has internal delays
    pade Padé approximation of model with time delays
    absorbDelay Replace time delays by poles at z = 0 or phase shift
    thiran Generate fractional delay filter based on Thiran approximation
    totaldelay Total combined I/O delays for LTI model
    delayss Create state-space models with delayed inputs, outputs, and states
    setDelayModel Construct state-space model with internal delays
    getDelayModel State-space representation of internal delays

    Model Attributes

    get Access model property values
    set Set or modify model properties
    tfdata Access transfer function data
    zpkdata Access zero-pole-gain data
    ssdata Access state-space model data
    frdata Access data for frequency response data (FRD) object
    piddata Access PID data
    pidstddata Access PIDSTD data
    dssdata Extract descriptor state-space data
    chgFreqUnit Change frequency units of frequency-response data model
    chgTimeUnit Change time units of dynamic system
    isct Determine if dynamic system model is in continuous time
    isdt Determine if dynamic system model is in discrete time
    isempty Determine whether dynamic system model is empty
    isfinite Determine if model has finite coefficients
    isParametric Determine if model has tunable parameters
    isproper Determine if dynamic system model is proper
    isreal Determine if model has real-valued coefficients
    issiso Determine if dynamic system model is single-input/single-output (SISO)
    isstable Determine whether system is stable
    isstatic Determine if model is static or dynamic
    order Query model order
    ndims Query number of dimensions of dynamic system model or model array
    size Query output/input/array dimensions of input–output model and number of frequencies of FRD model

    Model Arrays

    stack Build model array by stacking models or model arrays along array dimensions
    nmodels Number of models in model array
    permute Permute array dimensions in model arrays
    reshape Change shape of model array
    repsys Replicate and tile models

    Model Interconnection

    feedback Feedback connection of two models
    connect Block diagram interconnections of dynamic systems
    sumblk Summing junction for name-based interconnections
    series Series connection of two models
    parallel Parallel connection of two models
    append Group models by appending their inputs and outputs
    blkdiag Block-diagonal concatenation of models
    imp2exp Convert implicit linear relationship to explicit input-output relation
    inv Invert models
    lft Generalized feedback interconnection of two models (Redheffer star product)
    connectOptions Options for the connect command

    Model Transformation

    Model Type Conversion

    tf Create transfer function model, convert to transfer function model
    zpk Create zero-pole-gain model; convert to zero-pole-gain model
    ss Create state-space model, convert to state-space model
    frd Create frequency-response data model, convert to frequency-response data model
    pid Create PID controller in parallel form, convert to parallel-form PID controller
    pidstd Create a PID controller in standard form, convert to standard-form PID controller
    genfrd Generalized frequency response data (FRD) model
    genss Generalized state-space model
    genmat Generalized matrix with tunable parameters

    Continuous-Discrete Conversion

    c2d Convert model from continuous to discrete time
    d2c Convert model from discrete to continuous time
    d2d Resample discrete-time model
    upsample Upsample discrete-time models
    c2dOptions Create option set for continuous- to discrete-time conversions
    d2cOptions Create option set for discrete- to continuous-time conversions
    d2dOptions Create option set for discrete-time resampling

    Model Simplification

    hsvd Hankel singular values of dynamic system
    hsvplot Plot Hankel singular values and return plot handle
    sminreal Structural pole/zero cancellations
    balred Model order reduction
    minreal Minimal realization or pole-zero cancelation
    balreal Gramian-based input/output balancing of state-space realizations
    modred Model order reduction
    balredOptions Create option set for model order reduction
    hsvdOptions Create option set for computing Hankel singular values and input/output balancing

    State-Coordinate Transformation

    balreal Gramian-based input/output balancing of state-space realizations
    canon State-space canonical realization
    prescale Optimal scaling of state-space models
    ss2ss State coordinate transformation for state-space model
    xperm Reorder states in state-space models

    Modal Decomposition

    modsep Region-based modal decomposition
    stabsep Stable-unstable decomposition
    freqsep Slow-fast decomposition
    stabsepOptions Options for stable-unstable decomposition
    freqsepOptions Options for slow-fast decomposition

    Linear Analysis

    Time-Domain Analysis

    ltiview LTI Viewer for LTI system response analysis
    impulseplot Plot impulse response and return plot handle
    initialplot Plot initial condition response and return plot handle
    lsimplot Simulate response of dynamic system to arbitrary inputs and return plot handle
    stepplot Plot step response and return plot handle
    covar Output and state covariance of system driven by white noise
    impulse Impulse response plot of dynamic system; impulse response data
    initial Initial condition response of state-space model
    lsim Simulate time response of dynamic system to arbitrary inputs
    step Step response plot of dynamic system
    lsiminfo Compute linear response characteristics
    stepinfo Rise time, settling time, and other step response characteristics
    stepDataOptions Options set for step

    Frequency-Domain Analysis

    ltiview LTI Viewer for LTI system response analysis
    bodeplot Plot Bode frequency response with additional plot customization options
    nicholsplot Plot Nichols frequency responses and return plot handle
    nyquistplot Nyquist plot with additional plot customization options
    sigmaplot Plot singular values of frequency response and return plot handle
    bode Bode plot of frequency response, magnitude and phase of frequency response
    nichols Nichols chart of frequency response
    nyquist Nyquist plot of frequency response
    sigma Singular values plot of dynamic system
    evalfr Evaluate frequency response at given frequency
    freqresp Frequency response over grid
    bandwidth Frequency response bandwidth
    dcgain Low-frequency (DC) gain of LTI system
    getGainCrossover Crossover frequencies for specified gain
    getPeakGain Peak gain of dynamic system frequency response

    Stability Analysis

    pole Compute poles of dynamic system
    zero Zeros and gain of SISO dynamic system
    damp Natural frequency and damping ratio
    dsort Sort discrete-time poles by magnitude
    esort Sort continuous-time poles by real part
    tzero Invariant zeros of linear system
    pzplot Pole-zero map of dynamic system model with plot customization options
    iopzplot Plot pole-zero map for I/O pairs and return plot handle
    allmargin Gain margin, phase margin, delay margin and crossover frequencies
    margin Gain margin, phase margin, and crossover frequencies

    Plot Customization

    bodeoptions Create list of Bode plot options
    hsvoptions Create list of Hankel singular value plot options
    nicholsoptions Create list of Nichols plot options
    nyquistoptions List of Nyquist plot options
    pzoptions Create list of pole/zero plot options
    sigmaoptions Create list of singular-value plot options
    timeoptions Create list of time plot options
    setoptions Set plot options for response plot
    getoptions Return @PlotOptions handle or plot options property
    ctrlpref Set Control System Toolbox preferences
    updateSystem Update dynamic system data in a response plot

    Control Design

    PID Controller Tuning

    pidtool Open PID Tuner for PID tuning
    pidtune PID tuning algorithm for linear plant model
    pidtuneOptions Define options for the pidtune command

    SISO Feedback Loops

    rlocus Root locus plot of dynamic system
    rlocusplot Plot root locus and return plot handle
    sisotool Interactively design and tune SISO feedback loops
    sisoinit Configure SISO Design Tool at startup

    Linear-Quadratic-Gaussian Control

    lqr Linear-Quadratic Regulator (LQR) design
    lqry Form linear-quadratic (LQ) state-feedback regulator with output weighting
    lqi Linear-Quadratic-Integral control
    dlqr Linear-quadratic (LQ) state-feedback regulator for discrete-time state-space system
    lqrd Design discrete linear-quadratic (LQ) regulator for continuous plant
    kalman Kalman filter design, Kalman estimator
    kalmd Design discrete Kalman estimator for continuous plant
    lqg Linear-Quadratic-Gaussian (LQG) design
    lqgreg Form linear-quadratic-Gaussian (LQG) regulator
    lqgtrack Form Linear-Quadratic-Gaussian (LQG) servo controller
    augstate Append state vector to output vector
    norm Norm of linear model

    Pole Placement

    estim Form state estimator given estimator gain
    place Pole placement design
    reg Form regulator given state-feedback and estimator gains

    Matrix Computations

    lyap Continuous Lyapunov equation solution
    lyapchol Square-root solver for continuous-time Lyapunov equation
    dlyap Solve discrete-time Lyapunov equations
    dlyapchol Square-root solver for discrete-time Lyapunov equations
    care Continuous-time algebraic Riccati equation solution
    dare Solve discrete-time algebraic Riccati equations (DAREs)
    gcare Generalized solver for continuous-time algebraic Riccati equation
    gdare Generalized solver for discrete-time algebraic Riccati equation
    ctrb Controllability matrix
    obsv Observability matrix
    ctrbf Compute controllability staircase form
    obsvf Compute observability staircase form
    gram Controllability and observability gramians
    bdschur Block-diagonal Schur factorization
    norm Norm of linear model
    Was this topic helpful?