Delay Differential Equation SolverĀ
Delay Differential Equation Solver solves a delay differential equation of the form \\( \frac{dx}{dt} = f(t, x(t), x(t-\tau)) \\) with constant delay \\( \tau \\). Users input the DDE, delay, initial condition, history function, time span, and step size. The solution is computed using the Runge-Kutta 4th order method (RK4) adapted for DDEs, visualized with p5.js, and steps are displayed with MathJax.
Delay Differential Equation Solver
The Delay Differential Equation Solver computes the solution to a DDE of the form \\( \frac{dx}{dt} = f(t, x(t), x(t-\tau)) \\) with a constant delay \\( \tau \\). Input the DDE (using x for x(t), xd for x(t-Ļ)), delay, initial condition, history function (for \\( t \leq 0 \\)), time span, and step size. The solution is computed using the Runge-Kutta 4th order (RK4) method adapted for DDEs, visualized with p5.js, and computational steps are shown with MathJax. Results can be shared or embedded.
Example 1: Linear DDE
DDE: \\( \frac{dx}{dt} = -0.1x(t) + 0.05x(t-\tau) \\).
Parameters: \\( \tau = 1 \\), \\( x(0) = 1 \\), history \\( x(t) = 1 \\) for \\( t \leq 0 \\), \\( t = 20 \\), \\( h = 0.01 \\).
Result: Oscillatory behavior due to the delayed feedback.
Example 2: Damped DDE
DDE: \\( \frac{dx}{dt} = -0.2x(t) \\).
Parameters: \\( \tau = 1 \\), \\( x(0) = 1 \\), history \\( x(t) = 1 \\) for \\( t \leq 0 \\), \\( t = 20 \\), \\( h = 0.01 \\).
Result: Exponential decay, as the delay term is absent.
Example 3: Oscillatory DDE
DDE: \\( \frac{dx}{dt} = -0.5x(t-\tau) \\).
Parameters: \\( \tau = 2 \\), \\( x(0) = 1 \\), history \\( x(t) = cos(t) \\) for \\( t \leq 0 \\), \\( t = 20 \\), \\( h = 0.01 \\).
Result: Sustained oscillations due to the delayed term.
Example 4: Nonlinear DDE
DDE: \\( \frac{dx}{dt} = -0.1x(t) + 0.1x(t-\tau)^2 \\).
Parameters: \\( \tau = 1 \\), \\( x(0) = 0.5 \\), history \\( x(t) = 0.5 \\) for \\( t \leq 0 \\), \\( t = 20 \\), \\( h = 0.01 \\).
Result: Complex behavior due to nonlinear delayed feedback.
Example 5: Large Delay
DDE: \\( \frac{dx}{dt} = -0.1x(t) + 0.05x(t-\tau) \\).
Parameters: \\( \tau = 5 \\), \\( x(0) = 1 \\), history \\( x(t) = 1 \\) for \\( t \leq 0 \\), \\( t = 30 \\), \\( h = 0.01 \\).
Result: Slower oscillations due to the larger delay.