Mechatronic System Modeling & Simulation

Chapter 4
Mechanical System Models

Bachelor Program in Mechatronics Engineering
Mechatronic System Modeling & Simulation   •   Bachelor

Mechanical System Models

Introduction and Context

Mechanical subsystems are the physical basis of many mechatronic products: robot joints, machine tools, vehicle actuators, conveyor systems, hard-disk drives, pumps, and vibration isolators. A mechanical model converts physical properties—mass, inertia, elasticity, damping, friction, geometry, and constraints—into equations that predict motion under applied forces and torques.

A useful model is neither the most detailed possible model nor the simplest possible model. It is the simplest model that retains the dynamics relevant to the design question. For example, a flexible transmission may be represented as a rigid gear ratio during position-control design, but as a torsional spring and damper when resonance, backlash, or vibration is being studied.

This chapter develops translational, rotational, and coupled mechanical models using Newton–Euler and Lagrangian methods. It also introduces nonlinear effects, including Coulomb friction, viscous friction, backlash, impacts, and constraints.

Learning Objectives

By the end of this chapter, you should be able to:

  • select coordinates, reference directions, and system boundaries for a mechanical model;
  • formulate translational and rotational equations using Newton–Euler laws;
  • derive equations of motion using generalized coordinates and Lagrange’s equation;
  • combine mass, inertia, stiffness, damping, and friction in coupled models;
  • explain the effects of backlash, impacts, and kinematic constraints;
  • linearize a nonlinear mechanical model about an operating point;
  • assess assumptions, parameter uncertainty, and model validity in a mechatronic application.

1. Modeling Decisions and Fundamental Quantities

A mechanical model begins with a system boundary. Forces and torques crossing the boundary are inputs; displacements, velocities, and accelerations are state variables or outputs. The following quantities are central:

QuantitySymbolSI unitMeaning
Positionx or qmTranslational or generalized displacement
Velocityv or q̇m·s⁻¹Time derivative of position
Accelerationa or q̈m·s⁻²Time derivative of velocity
ForceFNTranslational effort
Angleθ or qradRotational displacement
Angular velocityωrad·s⁻¹Time derivative of angle
TorqueτN·mRotational effort
MassmkgResistance to translation
Moment of inertiaJ or Ikg·m²Resistance to rotation
Stiffnessk or KN·m⁻¹ or N·m·rad⁻¹Elastic restoring coefficient
Damping coefficientc or BN·s·m⁻¹ or N·m·s·rad⁻¹Velocity-dependent resistance

Radians are dimensionless in SI, although writing rad clarifies rotational quantities. A model must preserve sign conventions. If positive displacement is defined to the right, a spring stretched in that direction exerts a force opposite to the displacement.

2. Translational Mechanical Models

2.1 Newton’s law

For a particle or rigid body translating along one axis, Newton’s second law is

ΣF = ma

where ΣF is the algebraic sum of external forces in N, m is mass in kg, and a is acceleration in m·s⁻². The equation assumes an inertial reference frame and a lumped mass whose motion can be described by one coordinate.

For a mass connected to a linear spring and viscous damper, with external force F(t), displacement x(t), spring stiffness k, and damping coefficient c,

mẍ + cẋ + kx = F(t)

The spring force is −kx and the viscous damping force is −cẋ. Here k has units N·m⁻¹ and c has units N·s·m⁻¹. The equation assumes small deformation, linear elasticity, viscous damping, and one-dimensional motion.

The natural frequency and damping ratio of the unforced system are

ωₙ = √(k/m)
ζ = c/(2√(km))

where ωₙ is in rad·s⁻¹ and ζ is dimensionless. The system is underdamped when 0 < ζ < 1, critically damped when ζ = 1, and overdamped when ζ > 1. These classifications apply to positive m, c, and k.

2.2 Force balance and free-body diagrams

A free-body diagram isolates a body and shows every external force. Internal forces between elements are not shown unless one element has been separated from another. This practice prevents omitted forces and sign errors. For multiple masses, each mass receives its own balance.

For two masses joined by a spring and damper, the relative interaction force is

F₁₂ = k(x₂ − x₁) + c(ẋ₂ − ẋ₁)

where x₁ and x₂ are positions measured in the same positive direction. The force on mass 1 is F₁₂, while the force on mass 2 is −F₁₂. Thus, for external forces F₁ and F₂,

m₁ẍ₁ = F₁ + k(x₂ − x₁) + c(ẋ₂ − ẋ₁)
m₂ẍ₂ = F₂ − k(x₂ − x₁) − c(ẋ₂ − ẋ₁)

The equal-and-opposite terms express Newton’s third law.

2.3 Gravity and equilibrium coordinates

For a vertical mass, choosing upward as positive gives

mẍ = F − cẋ − kx − mg

where g ≈ 9.81 m·s⁻². If x is measured from the static equilibrium position, gravity is absorbed into the equilibrium offset and the dynamic equation becomes mẍ + cẋ + kx = F. Choosing coordinates about equilibrium often simplifies control and simulation models.

3. Rotational Mechanical Models

3.1 Newton–Euler rotational law

The rotational equivalent of Newton’s law is

Στ = Jα

where Στ is the algebraic sum of torques in N·m, J is the mass moment of inertia in kg·m², and α = θ̈ is angular acceleration in rad·s⁻². The equation assumes rotation about a fixed axis or an axis for which the scalar inertia model is valid.

For a rotary inertia connected to torsional stiffness K and rotational damping B,

Jθ̈ + Bθ̇ + Kθ = τ(t)

Here K has units N·m·rad⁻¹ and B has units N·m·s·rad⁻¹. Since radians are dimensionless, these units are also commonly written N·m and N·m·s, respectively, but the angular interpretation should remain clear.

The mass moment of inertia depends on geometry and the selected axis. Important examples include

J = mr²

for a point mass at radius r, and

J = (1/2)mR²

for a uniform solid disk about its central axis. The parallel-axis theorem is

JO = JC + md²

where J_C is inertia about a parallel axis through the center of mass and d is the distance between axes.

3.2 Gear trains and reflected inertia

For ideal gears with angular displacements θ₁ and θ₂, the speed relationship is

θ₂ = −(N₁/N₂)θ₁

where N₁ and N₂ are tooth counts. The negative sign indicates opposite rotation for external gears. If an inertia J₂ is connected through an ideal gear ratio n = N₂/N₁, its input-side reflected inertia is

Jreflected = J₂n²

when θ₁ = nθ₂. The square occurs because both velocity and torque are transformed. Gear efficiency, compliance, backlash, and friction make practical transmissions depart from this ideal relation.

4. Lagrangian Modeling

Newton–Euler equations are direct and intuitive for simple free bodies. Lagrange’s method is often more efficient for systems with several coordinates, rotational joints, and constraints.

For generalized coordinates q₁, q₂, …, qₙ, define kinetic energy T and potential energy V. For conservative elastic and gravitational effects, Lagrange’s equation is

d/dt(∂L/∂q̇ᵢ) − ∂L/∂qᵢ = Qᵢ

where L = T − V is the Lagrangian, q̇ᵢ is generalized velocity, and Qᵢ is the nonconservative generalized force associated with qᵢ. The equation applies for i = 1, …, n and assumes suitable differentiability and correctly chosen independent coordinates.

For viscous damping represented by a Rayleigh dissipation function D,

D = (1/2)q̇ᵀCq̇

the equation becomes

d/dt(∂L/∂q̇ᵢ) − ∂L/∂qᵢ + ∂D/∂q̇ᵢ = Qᵢ

where C is a damping matrix. This representation is appropriate for linear viscous damping; dry friction generally requires a separate force law.

4.1 General multibody form

Many mechanical systems can be written as

M(q)q̈ + C(q,q̇)q̇ + G(q) + K(q) + Ff(q̇) = τ + Jc(q)ᵀλ

M(q) is the positive-definite inertia matrix, C(q,q̇)q̇ contains Coriolis and centrifugal terms, G(q) represents gravity, K(q) elastic forces, F_f friction, τ applied generalized forces, and J_cᵀλ constraint forces. This form is a modeling structure rather than a universal linear equation: individual terms depend on geometry and constitutive laws.

4.2 Worked example: a planar pendulum

Consider a point mass m at the end of a massless rigid rod of length l. Let θ be measured from the downward vertical. Its kinetic and potential energies, taking zero potential at the lowest position, are

T = (1/2)ml²θ̇²
V = mgl(1 − cosθ)

With no damping and an applied torque τ, Lagrange’s equation gives

ml²θ̈ + mgl sinθ = τ

For small angles, sinθ ≈ θ, so

ml²θ̈ + mglθ = τ

The linearization is valid when θ is sufficiently small for the approximation error to be acceptable. The nonlinear equation should be used for large-angle motion, energy analysis, or impact studies.

5. Stiffness, Damping, and Flexible Coupling

Real mechatronic mechanisms are rarely perfectly rigid. Shafts, belts, couplings, frames, and contact surfaces deform. A flexible coupling between motor angle θₘ and load angle θₗ can be modeled as

τs = Ks(θₘ − θₗ) + Bs(θ̇ₘ − θ̇ₗ)

where τ_s is the torque transmitted through the coupling, K_s is torsional stiffness, and B_s is torsional damping. The motor and load equations may then be written

Jₘθ̈ₘ = τₘ − τs − τₘf
Jₗθ̈ₗ = τs − τₗ − τₗf

where τₘ is motor torque, τₗ is external load torque, and τₘf and τₗf are friction torques.

Flexible coupling introduces resonant modes. Treating the transmission as rigid can therefore produce a controller that appears stable in a low-order simulation but excites oscillations in hardware. The modeling decision should reflect the bandwidth of interest: if control bandwidth approaches the first flexible resonance, flexibility must be included.

6. Friction Models

Friction is nonlinear, direction-dependent, and often uncertain. Common models include:

  • Viscous friction: τv = Bω, proportional to velocity.
  • Coulomb friction: τc = τ₀ sign(ω), approximately constant in magnitude during sliding.
  • Static friction: a resisting torque that can balance an applied torque while the body remains at rest, up to a breakaway value τ_s.
  • Stribeck friction: a smooth or empirical representation of decreasing friction near low speed.

A simple sliding model is

τf = Bω + τc sign(ω), ω ≠ 0

At ω = 0, the sign function is undefined and a sticking rule is required. A physically meaningful static condition is that sticking can occur if the net applied torque lies within the static-friction bound. Naively using sign(ω) in a numerical solver can cause chattering and convergence problems; regularized laws or complementarity methods are often preferable.

Friction affects positioning accuracy, energy consumption, limit cycles, and parameter identification. It should not be tuned merely to make a simulation match one experiment; its dependence on temperature, lubrication, load, and direction must be considered.

7. Backlash, Stops, and Impacts

7.1 Backlash

Backlash is a dead zone caused by clearance between mating elements, such as gears. If relative displacement δ lies within a clearance half-width b, no elastic contact torque is transmitted:

τb(δ) = 0, |δ| ≤ b

Outside the dead zone, an idealized piecewise-linear model is

τb(δ) = Kb(δ − b), δ > b
τb(δ) = Kb(δ + b), δ < −b

where K_b is contact stiffness. Real backlash also involves impact, damping, wear, and possible asymmetric clearances. It can cause lost motion, limit cycles, and repeated impacts under reversing motion.

7.2 Unilateral contact and hard stops

A hard stop imposes an inequality such as x ≤ x_max. The contact force is zero when the stop is not engaged and becomes active when penetration would occur. A compliant approximation uses a stiff spring and damper during penetration. Excessively high stiffness, however, creates a very fast time scale and may make explicit numerical integration unstable.

7.3 Impact and restitution

For a one-dimensional impact, the coefficient of restitution e is defined by

e = (v₂⁺ − v₁⁺)/(v₁⁻ − v₂⁻)

where superscripts − and + denote velocities immediately before and after impact, respectively. For 0 ≤ e ≤ 1, e = 1 is perfectly elastic and e = 0 is perfectly inelastic. Momentum conservation for an isolated two-body impact is

m₁v₁⁻ + m₂v₂⁻ = m₁v₁⁺ + m₂v₂⁺

Together, these equations determine post-impact velocities when masses and e are known. The model assumes a short impact interval, negligible external impulse during impact, and a one-dimensional collision.

8. Constraints and Coordinate Choice

A holonomic constraint has the form

φ(q,t) = 0

Its velocity and acceleration forms are obtained by differentiation:

Jc(q,t)q̇ + ∂φ/∂t = 0

where J_c = ∂φ/∂q is the constraint Jacobian. Constraint forces can be introduced through Lagrange multipliers λ. In the multibody equation, J_cᵀλ supplies forces that enforce the constraint without necessarily being assigned a displacement potential.

Independent generalized coordinates often produce compact equations, but finding them may be difficult for complex mechanisms. Redundant coordinates make geometry explicit but require constraint equations and can create numerical conditioning problems. A good model uses the fewest coordinates that preserve the required physical behavior, while retaining redundant coordinates when they improve implementation or contact handling.

9. Linearization and State-Space Representation

A nonlinear model can be expressed as

ẋ = f(x,u)

where x is the state vector and u is the input. Around an equilibrium (x₀,u₀), define small deviations Δx = x − x₀ and Δu = u − u₀. First-order Taylor expansion gives

Δẋ ≈ AΔx + BΔu

with

A = ∂f/∂x |_(x₀,u₀), B = ∂f/∂u |_(x₀,u₀)

The approximation is local and omits second- and higher-order terms. It is useful for modal analysis, controller design, and local stability assessment, but it does not accurately represent large-angle pendulum motion, impacts, or transitions across backlash boundaries.

For the mass–spring–damper system, choose x₁ = x and x₂ = ẋ. Then

[ẋ₁; ẋ₂] = [0 1; −k/m −c/m][x₁; x₂] + [0; 1/m]F

The matrix form is valid for constant m, c, and k and a linear force law.

10. Worked Numerical Example: Flexible Rotary Actuator

An actuator has load inertia J = 0.020 kg·m², torsional stiffness K = 10 N·m·rad⁻¹, and damping B = 0.10 N·m·s·rad⁻¹. Determine its undamped natural frequency and damping ratio.

The undamped natural frequency is

ωₙ = √(K/J) = √(10/0.020) = √500 ≈ 22.36 rad·s⁻¹

The damping ratio is

ζ = B/(2√(JK)) = 0.10/[2√(0.020×10)] ≈ 0.112

Thus the actuator is underdamped. Its natural frequency in hertz is fₙ = ωₙ/(2π) ≈ 3.56 Hz. The low damping indicates that a position controller or passive damper may need to address oscillatory behavior. Units are consistent: JK has units kg·m² × N·m, giving the required combination for rotational damping ratio evaluation.

11. Applied Case: Robotic Joint with Gear Backlash

Background

Consider an illustrative robotic elbow joint driven by a motor through a reduction gearbox. The motor has low inertia, while the arm has substantial reflected inertia. The gearbox has measurable backlash and the shaft has finite torsional stiffness.

Problem

A rigid single-inertia model predicts accurate motion during constant-direction travel but predicts a smooth reversal. Hardware tests show position error, audible impacts, and a short oscillation after every reversal.

Analysis

The discrepancy indicates that the rigid model omits at least two mechanisms: clearance in the gearbox and compliance between motor and load. During reversal, the motor shaft traverses the backlash region before contact is re-established. Contact then produces an impulsive or strongly damped torque. The load does not respond as if it were directly attached to the motor.

Modeling approach

Use motor angle θₘ and load angle θₗ as coordinates. Represent the shaft by K_s and B_s, and represent gear clearance with the piecewise torque law τ_b(θₘ/n − θₗ), where n is the ideal reduction ratio. Include motor and load friction separately. If impacts are short and pronounced, use an event-based impact law; if contact is gradual, use a compliant contact model.

The simulation should be validated in stages: first identify inertia and stiffness from free oscillation, then estimate damping, and finally characterize backlash by low-speed reversal tests. The controller should be tested both with and without compensation, because an algorithm that hides error under one load may fail under another.

Outcome and learning points

The enriched model explains reversal error and resonance, supports selection of a suitable sampling rate, and prevents over-optimistic stability claims. The principal lesson is that model structure matters: parameter adjustment cannot compensate for a missing physical mode or a missing discontinuity. Safety testing must also consider unexpected contact forces, pinch hazards, gearbox wear, and fail-safe behavior.

12. Simulation and Implementation Best Practices

  1. Define the purpose. Decide whether the model is for sizing, controller design, real-time estimation, trajectory planning, or fault analysis.
  2. Choose coordinates carefully. State positive directions, zero positions, and reference frames explicitly.
  3. Check dimensions. Every term in an equation must have compatible units.
  4. Start with an energy and force audit. Confirm that springs store energy, dampers dissipate energy, and ideal constraints do no unintended work.
  5. Use events for discontinuities. Detect contact, separation, and backlash-boundary crossings rather than relying only on a large-step solver.
  6. Verify limiting cases. Set damping, stiffness, or friction to zero and compare the result with known physical behavior.
  7. Validate experimentally. Compare displacement, velocity, acceleration, torque, resonance frequency, and reversal behavior.
  8. Document assumptions and parameters. Include tolerances, operating temperature, lubrication state, and measurement uncertainty.

Implicit or variable-step solvers are often appropriate for stiff systems containing high contact stiffness. Explicit solvers can be efficient for smooth, nonstiff models but may require very small steps near impacts. Numerical stability is not physical accuracy: a stable simulation can still be wrong because of an incorrect friction law or neglected flexibility.

13. Contemporary and Professional Considerations

Modern digital twins combine mechanical models with sensor data, parameter estimation, and health monitoring. AI-based methods can learn residual errors between a physics model and measurements, but they should not replace physical checks where safety is critical. A hybrid model can preserve conservation laws while using data-driven terms for uncertain friction or wear.

Engineers must distinguish measured data from inferred parameters and maintain traceability between model assumptions and design decisions. Safety-critical mechanisms require conservative analysis of worst-case inertia, friction, impact energy, and sensor failure. Models used for collaborative robots, medical devices, or autonomous machinery should support hazard analysis, verification, and explainable failure responses.

Chapter Summary

Mechanical system modeling represents motion through forces, torques, energy, constitutive laws, and constraints. Newton–Euler methods provide direct balances for translational and rotational bodies, while Lagrange’s method gives a systematic formulation for multivariable systems using kinetic and potential energy. Mass and inertia resist acceleration; springs store energy; dampers dissipate energy; friction introduces velocity- and contact-dependent resistance.

Flexible couplings produce additional modes, and ideal gear relations must be modified for efficiency, compliance, and backlash. Backlash and impacts are discontinuous phenomena requiring piecewise laws or event-based simulation. Constraints may be expressed with Jacobians and Lagrange multipliers. Linearized state-space models are valuable near an operating point but cannot represent all nonlinear behavior. Reliable engineering practice combines dimensional checks, limiting-case verification, numerical care, experimental validation, and explicit documentation of assumptions.

Key Terms

Mass: Measure of resistance to translational acceleration.

Moment of inertia: Measure of resistance to angular acceleration about a specified axis.

Newton–Euler method: Force and torque balance method for deriving mechanical equations.

Generalized coordinate: Independent coordinate describing a system configuration.

Lagrangian: Difference between kinetic and potential energy, L = T − V.

Kinetic energy: Energy associated with motion.

Potential energy: Stored energy associated with position or deformation.

Stiffness: Force or torque change per unit displacement or angle.

Damping: Energy-dissipating resistance associated commonly with velocity.

Viscous friction: Friction proportional to velocity.

Coulomb friction: Approximately constant-magnitude sliding friction.

Static friction: Friction that prevents motion up to a limiting value.

Backlash: Clearance or dead zone between mating mechanical elements.

Coefficient of restitution: Ratio describing relative separation and approach speeds during impact.

Holonomic constraint: Position-level constraint expressed as φ(q,t) = 0.

Constraint Jacobian: Matrix of derivatives of constraint equations with respect to coordinates.

Reflected inertia: Inertia represented at another shaft through a transmission ratio.

Natural frequency: Characteristic frequency of free oscillation.

Damping ratio: Dimensionless measure of damping relative to critical damping.

Linearization: Local first-order approximation of a nonlinear model.

Review Questions

Short Answer Questions

  1. State Newton’s second law for one-dimensional translation and identify its variables.
  2. Why is a free-body diagram useful when deriving mechanical equations?
  3. Distinguish viscous friction from Coulomb friction.
  4. What physical phenomenon does backlash represent?
  5. State one limitation of a linearized mechanical model.

Long Answer Questions

  1. Derive the mass–spring–damper equation from a free-body diagram and explain the assumptions behind each term.
  2. Explain how Lagrange’s equation is constructed from kinetic and potential energy, including the role of generalized forces.
  3. Compare rigid-transmission and flexible-transmission models for a motor-driven load.
  4. Explain how coefficient of restitution and momentum conservation determine post-impact velocities.
  5. Discuss coordinate selection, redundant coordinates, and constraint Jacobians in multibody modeling.

Analytical / Application Questions

  1. A rotary actuator has J = 0.05 kg·m², K = 20 N·m·rad⁻¹, and B = 0.20 N·m·s·rad⁻¹. Calculate its undamped natural frequency and damping ratio, then classify its damping.
  2. Develop a two-inertia model for a motor and load connected by a torsional spring and damper. Identify the states, inputs, and measurable outputs.
  3. A robot joint exhibits position error only during direction reversal. Propose experiments that distinguish backlash, Coulomb friction, and shaft flexibility, and explain what measurements would support each diagnosis.

Multiple Choice Questions with Answers

Question 1

For a one-dimensional mass–spring–damper system, which equation correctly represents the force balance?

A. mẍ + cẋ + kx = F(t)

B. mẋ + cx + kẍ = F(t)

C. mẍ + cẋ − kx = F(t) for a restoring spring

D. m + c + k = F(t)

Correct Answer: A. mẍ + cẋ + kx = F(t)

Question 2

The SI unit of a translational viscous damping coefficient c is:

A. kg

B. N·s·m⁻¹

C. N·m

D. kg·m²

Correct Answer: B. N·s·m⁻¹

Question 3

For a rotary inertia J connected to torsional stiffness K, the undamped natural frequency is:

A. √(J/K)

B. K/J

C. √(K/J)

D. J/K

Correct Answer: C. √(K/J)

Question 4

In Lagrange’s equation, the Lagrangian is defined as:

A. T + V

B. T − V

C. V − T

D. T/V

Correct Answer: B. T − V

Question 5

For ideal external gears, the negative sign in the angular displacement relationship indicates:

A. Energy loss

B. Zero torque

C. Opposite rotation directions

D. Backlash

Correct Answer: C. Opposite rotation directions

Question 6

In a simple backlash model, the transmitted torque is zero when:

A. The relative displacement is outside the clearance

B. The relative displacement lies within the dead zone

C. The relative velocity is maximum

D. The contact stiffness is infinite

Correct Answer: B. The relative displacement lies within the dead zone

Question 7

Which condition describes critical damping for a second-order mass–spring–damper system?

A. ζ = 0

B. ζ = 0.5

C. ζ = 1

D. ζ > 2 only

Correct Answer: C. ζ = 1

Question 8

During an isolated one-dimensional impact, which quantity is conserved under the stated impact assumptions?

A. Kinetic energy for every value of restitution

B. Momentum

C. Relative velocity

D. Mechanical energy including dissipation

Correct Answer: B. Momentum

Question 9

A holonomic mechanical constraint is commonly written as:

A. φ(q,t) = 0

B. φ(q,t) = 1 for all systems

C. q̈ = 0

D. M = 0

Correct Answer: A. φ(q,t) = 0

Question 10

Linearization of a nonlinear mechanical model is generally most valid:

A. Only during impacts

B. Near a selected operating point

C. For all possible angles and velocities

D. Only when friction is infinite

Correct Answer: B. Near a selected operating point

Mechatronic System Modeling & Simulation
Chapter 4 of 15