⏱

Delay

Dynamics
Run the live example Free · no sign-up · runs in your browser

Introduces a continuous transport lag (dead time or propagation delay τ\tau) to an incoming signal. Implemented via an efficient circular ring buffer that delays signal transmission by a configurable duration in physical seconds. Essential for modeling material transport delays on conveyor belts, pipeline fluid travel times, acoustic wave propagation, communication network packet latency, and sensory feedback delays in biological and robotic systems.

Mathematical Model

In the continuous time domain, the output signal is a time-shifted replica of the input signal:

y(t)={y0,if t<τu(t−τ),if t≥τy(t) = \begin{cases} y_0, & \text{if } t < \tau \\ u(t - \tau), & \text{if } t \ge \tau \end{cases}

where τ\tau represents delayTime and y0y_0 represents initialOutput.

In the Laplace domain (ss), pure dead time is represented by an irrational non-minimum-phase exponential transfer function:

H(s)=Y(s)U(s)=e−sτH(s) = \frac{Y(s)}{U(s)} = e^{-s\tau}

Evaluating the frequency response along the imaginary axis (s=jωs = j\omega) reveals unity gain and a phase lag that grows linearly with frequency without bound:

∣H(jω)∣=1,∠H(jω)=−ωτ (rad)=−57.296⋅ωτ (deg)|H(j\omega)| = 1, \quad \angle H(j\omega) = -\omega \tau \text{ (rad)} = -57.296 \cdot \omega \tau \text{ (deg)}

In discrete numerical simulation with timestep Δt\Delta t, the circular buffer capacity is allocated as:

N=⌈τΔt⌉+1N = \left\lceil \frac{\tau}{\Delta t} \right\rceil + 1

Inputs & Outputs

Direction ID Label Type Status
→ In in Input number Required
→ In reset Reset number Optional
← Out out Output number Output

Parameters

Parameters Label Type Default Description
delayTime Delay Time number 0.1
initialOutput Initial Output number 0

Usage Examples

Example 1: Pipeline Thermal Fluid Transport Lag

In industrial heating networks, hot fluid pumped through an insulated pipeline requires transit time τ=L/v\tau = L / v (where LL is length and vv is flow speed) before reaching downstream heat exchangers. Placing a Delay block with delayTime = 5.0 s and initialOutput = 20.0 °C between boiler output and heat exchanger input simulates the physical transport lag, illustrating how dead time erodes phase margin and induces temperature oscillations.

Example 2: Satellite Teleoperation Communication Latency

In space robotics and long-range unmanned underwater vehicles (UUVs), telemetry and joystick commands traverse high-latency satellite communication links. Inserting a Delay block with delayTime = 0.75 s into the forward control path and another into the sensor feedback path creates a realistic 1.5 s1.5\text{ s} round-trip latency, enabling engineers to design and evaluate predictive Smith Predictor control algorithms.

Remarks & Best Practices

  • Phase Margin Degradation: Pure transport delay introduces frequency-proportional phase lag (−ωτ-\omega \tau) with zero amplitude attenuation, drastically constraining closed-loop gain and phase margins.
  • Physical Time vs. Sample Count: Unlike UnitDelay which shifts signals by exactly one simulation step, Delay parameterizes dead time in true physical seconds, maintaining fidelity even if simulation step size is altered.
  • Minimum One-Step Cushion: Enforces a minimum delay of 1 simulation timestep (Δt\Delta t) to prevent instantaneous algebraic loops on direct feedthrough paths.
  • Synchronous Buffer Reset: Driving the optional bottom reset terminal with a positive value (r>0r > 0) immediately overwrites all circular buffer history registers with initialOutput.

Related Components

  • UnitDelay: Single-sample discrete shift operator (z−1z^{-1}) based on sample index.
  • SmithPredictor: Model-predictive dead-time compensation structure for transport-lagged plants.
  • Integrator: Continuous dynamic accumulator with state reset capability.
  • LeadLag: First-order dynamic phase lead and lag compensator.