RunMat
  • Pricing
RunMat
GitHub
GitHub
Sign inTry in browser
DesktopRuntimePhysicsCADAdministrationAgent

Get RunMat updates

New releases, guides and examples.

Product+
  • Runtime
  • GPU
  • Parallel
  • Compile
  • Interop and MEX
  • Simulation
  • MCAD
  • ECAD
  • Enterprise
  • AI integrations
  • Pricing
  • Download
Math+
  • Signal processing
  • Linear algebra
  • Statistics
  • Curve fitting
  • Differential equations
  • Control systems
  • Optimization
  • Finance
  • Data and tables
  • Plotting
Physics+
  • Simulation overview
  • Structural
  • Thermal
  • Electromagnetic
  • Joule heating
  • Thermal stress
  • Acoustics
  • Fluid flow
  • Conjugate heat transfer
  • Fluid–structure
  • What is FEA
Industries+
  • Aerospace
  • Automotive and transportation
  • Defense
  • Electronics and semiconductors
  • Energy
  • Industrial machinery
  • Life sciences
  • Quantitative finance
Learn+
  • Guides
  • Docs
  • Function reference
  • Language reference
  • Migration guide
  • Changelog
  • MATLAB Online
  • MATLAB AI agent
  • For students
Compare+
  • RunMat vs MATLAB
  • RunMat vs Ansys
  • RunMat vs SOLIDWORKS
  • RunMat vs Altium
  • RunMat vs Cadence
  • RunMat vs COMSOL
  • RunMat vs Python
  • RunMat vs Julia
  • RunMat vs Physics AI
  • RunMat vs Octave
  • Benchmarks
  • MATLAB alternatives
  • All comparisons
Company+
  • About
  • Blog
  • Contact
  • Source code↗
  • License
  • Privacy
  • Terms

Product

  • Runtime
  • GPU
  • Parallel
  • Compile
  • Interop and MEX
  • Simulation
  • MCAD
  • ECAD
  • Enterprise
  • AI integrations
  • Pricing
  • Download

Math

  • Signal processing
  • Linear algebra
  • Statistics
  • Curve fitting
  • Differential equations
  • Control systems
  • Optimization
  • Finance
  • Data and tables
  • Plotting

Physics

  • Simulation overview
  • Structural
  • Thermal
  • Electromagnetic
  • Joule heating
  • Thermal stress
  • Acoustics
  • Fluid flow
  • Conjugate heat transfer
  • Fluid–structure
  • What is FEA

Industries

  • Aerospace
  • Automotive and transportation
  • Defense
  • Electronics and semiconductors
  • Energy
  • Industrial machinery
  • Life sciences
  • Quantitative finance

Learn

  • Guides
  • Docs
  • Function reference
  • Language reference
  • Migration guide
  • Changelog
  • MATLAB Online
  • MATLAB AI agent
  • For students

Compare

  • RunMat vs MATLAB
  • RunMat vs Ansys
  • RunMat vs SOLIDWORKS
  • RunMat vs Altium
  • RunMat vs Cadence
  • RunMat vs COMSOL
  • RunMat vs Python
  • RunMat vs Julia
  • RunMat vs Physics AI
  • RunMat vs Octave
  • Benchmarks
  • MATLAB alternatives
  • All comparisons

Company

  • About
  • Blog
  • Contact
  • Source code↗
  • License
  • Privacy
  • Terms
GitHubXLinkedIn

© Dystr, Inc. · RunMat v0.7.1, Nov 17, 2026

RunMat® is a registered trademark of Dystr, Inc. MATLAB® is a registered trademark of The MathWorks, Inc. RunMat is not affiliated with, endorsed by, or sponsored by The MathWorks, Inc.

/
See all docs
Builtin Reference
    • care
    • ctrb
    • damp
    • db
    • dcgain
    • dlqr
    • feedback
    • isstable
    • lqr
    • minreal
    • pade
    • pole
    • pzmap
    • rlocus
    • stepinfo
    • zero

damp — Return natural frequencies, damping ratios, and poles for control models.

damp(sys) derives natural frequencies and damping ratios from the poles of a local tf or ss model. It returns up to three host-resident column vectors: natural frequency wn, damping ratio zeta, and poles p.

Syntax

wn = damp(sys)
[wn, zeta] = damp(sys)
[wn, zeta, p] = damp(sys)

Inputs

sys
Type
Any
Required
Yes
Description
SISO tf model or ss state-space model.
NameTypeRequiredDefaultDescription
sysAnyYes—SISO tf model or ss state-space model.

Returns

wn
Type
NumericArray
Description
Natural frequencies as an N-by-1 real double column vector.
zeta
Type
NumericArray
Description
Damping ratios as an N-by-1 real double column vector.
p
Type
Any
Description
Model poles as an N-by-1 real or complex double column vector.
NameTypeDescription
wnNumericArrayNatural frequencies as an N-by-1 real double column vector.
zetaNumericArrayDamping ratios as an N-by-1 real double column vector.
pAnyModel poles as an N-by-1 real or complex double column vector.

Returned values from damp depend on how many outputs the caller requests.

Errors

RunMat:damp:InvalidModel
When
Input system is malformed or missing model metadata.
Message
damp: invalid model
RunMat:damp:UnsupportedModel
When
Model class is unsupported.
Message
damp: unsupported model
RunMat:damp:OutputCount
When
More than three outputs are requested.
Message
damp: too many output arguments
RunMat:damp:Internal
When
Pole extraction or output construction failed.
Message
damp: internal error
IdentifierWhenMessage
RunMat:damp:InvalidModelInput system is malformed or missing model metadata.damp: invalid model
RunMat:damp:UnsupportedModelModel class is unsupported.damp: unsupported model
RunMat:damp:OutputCountMore than three outputs are requested.damp: too many output arguments
RunMat:damp:InternalPole extraction or output construction failed.damp: internal error

Models and outputs

The supported inputs are SISO tf objects and ss state-space objects. For transfer functions, damp analyzes the stored denominator polynomial without canceling pole-zero pairs. For state-space models, it analyzes the state matrix eigenvalues. Static-gain transfer functions produce empty N-by-1 columns with N equal to zero.

wn and zeta are real double N-by-1 columns. Pole output p is a real double column when every pole's imaginary magnitude is at most the control-model tolerance (1e-12); otherwise it is a complex double column. One, two, or three requested outputs return the corresponding prefix; requesting more than three raises an output-count error before model analysis. A discarded-output call still analyzes the model, while a statement call does not yet render a diagnostic table.

Continuous and discrete damping

For a continuous-time pole p, wn = abs(p) and zeta = -real(p)/wn. For a discrete-time model with sample time Ts, the damping metrics use the equivalent continuous pole log(p)/Ts; the returned p remains in the discrete domain. Modes are sorted by natural frequency, then damping ratio and pole components.

Special poles use defined current behavior: a continuous zero or infinity has damping ratio -1; a discrete zero has infinite natural frequency and damping ratio +1; a discrete one or infinity has damping ratio -1. At a continuous zero and discrete one, natural frequency is zero. Numerical behavior for singular and nearly singular poles remains part of the current control-model implementation.

Placement and current limits

damp reads model metadata and runs pole analysis on the CPU. A direct numeric gpuArray input is not a model object and fails before provider access; if a valid tf or ss object has resident numeric properties used by the analysis, only those properties are gathered. Raw integer, logical, and complex arrays are likewise not model objects. Typed-integer tf coefficients or Ts, logical tf coefficients, and typed-integer consumed ss matrices or Ts assigned after construction are checked when damp admits the model; they do not turn a numeric array into a model.

This call can suspend while gathering consumed resident model properties. It does not invoke callbacks, access workspace or environment state, or require filesystem, network, time, randomness, or a user interface. It can throw for malformed models or failed pole extraction. Distributed model objects and transfer to remote workers are not supported.

Generalized, uncertain, zpk, sparss, and mechss models are not yet supported. Sparse-model Focus, MaxNumber, Shift, Tolerance, and Display options are not implemented. Statement-form damp(sys) does not yet show MATLAB's diagnostic table; request one to three outputs to use the result.

Examples

Damping of a second-order transfer function

G = tf(1, [100 50 400]); [wn, zeta, p] = damp(G); fprintf('%.3f %.3f\n', wn(1), zeta(1));

Expected output:

2.000 0.125

Discrete-time damping and original pole

D = tf(1, [1 -0.5], 0.1); [wn, zeta, p] = damp(D);

Analyze state-space modes

S = ss([0 1; -4 -0.5], [0; 1], [1 0], 0); [wn, zeta] = damp(S);

Static gain has no dynamic modes

[wn, zeta, p] = damp(tf(2, 1));

A numeric array is not a control model

damp(1)

Using damp with coding agents

Open a RunMat example with live inputs, then ask the agent to explain how damp changes the result.

Run a small damp example, explain the result, then change one input and compare the output.

FAQ

Does damp cancel pole-zero pairs?⌄

No. For tf objects it analyzes the stored denominator polynomial.

Does damp support discrete-time systems?⌄

Yes. Frequency and damping ratio use log(p)/Ts while the returned pole remains in the discrete domain.

Related Control functions

Analysis

care · ctrb · db · dcgain · dlqr · feedback · isstable · lqr · minreal · pade · pole · pzmap · rlocus · stepinfo · zero

Response

bode · evalfr · freqresp · impulse · nyquist · step

Models

series · ss2tf · tfdata

Control

ss · tf · tf.ldivide · tf.minus · tf.mldivide · tf.mpower · tf.mrdivide · tf.mtimes · tf.plus · tf.power · tf.rdivide · tf.times · tf.uminus · tf.uplus

Source you can read

Every RunMat function's source is public. Read exactly how damp is executed, line by line, in Rust.

  • View the source for damp in Rust on GitHub
  • Learn how the RunMat runtime works
  • Found a bug? Open an issue with a minimal reproduction.

About RunMat

RunMat is a runtime that executes MATLAB-syntax code fast on any GPU. The runtime is free for individuals, including freelancers; students and faculty at an academic institution, for teaching or research there; contributors to an open-source project, for work on that project; organizations with 250 or fewer people and US$10M or less in annual revenue; and anyone, for non-production use. See runmat.com/license.

  • RunMat automatically optimizes your math for GPU execution on Apple, Nvidia, and AMD hardware. No code changes needed. Simulations that took hours now take minutes.
  • Start running code in seconds. RunMat runs in the browser, on the desktop, or from the CLI. No license server, no IT ticket.

Getting started · Benchmarks · Pricing

Download RunMat

Download RunMat for full performance, or use RunMat in your browser for zero setup.

Download RunMatOpen Sandbox
On this page
  • Syntax
  • Inputs
  • Returns
  • Errors
  • Models and outputs
  • Continuous and discrete damping
  • Placement and current limits
  • Examples
  • Damping of a second-order transfer function
  • Discrete-time damping and original pole
  • Analyze state-space modes
  • Static gain has no dynamic modes
  • A numeric array is not a control model
  • Using damp with coding agents
  • FAQ
  • Related Control functions
  • Analysis
  • Response
  • Models
  • Control
  • Source you can read
  • About RunMat