How to give the phase of the following delay differential equations by dde
1 view (last 30 days)
Show older comments

where



It is the system switching between ODE and DDE, how can I get the phase picture?
0 Comments
Answers (1)
Arnav
on 13 Mar 2025
You may model the system as the following function:
function dydt = ddesys(t, y, Z)
S = y(1);
I = y(2);
S_lag = Z(1);
I_lag = Z(2);
l1 = 0.8 * heaviside(I - I_lag);
l0 = 1 - l1;
dSdt = 6 - S - I * exp(-(l0 * I + l1 * (I - I_lag))) * S;
dIdt = I * exp(-(l0 * I + l1 * (I - I_lag))) * S - I;
dydt = [dSdt; dIdt];
end
The system can be be solved using dde23 function as follows:
sol = dde23(@ddesys, [1 1], [S0 I0], [0 10]);
The phase plane shown above can be plotted by plotting the solutions obtained by varying the initial position over a grid of values.
You may refer to the MATLAB documentation page of dde23 function to learn more:
0 Comments
See Also
Categories
Find more on Numerical Integration and Differential Equations in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!