How can I add a delay in a function of a function (DDE)?
16 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Sofia Tsangaridou
le 13 Juil 2021
Commenté : Steven Lord
le 13 Juil 2021
Hey guys,
I'm new to MATLAB and I'm having some trouble coding the model I need to code. So, I have two delayed differential equations (time delays) but the delays are implicit in my model. What I mean by that is, for exaple, my DDEs look like this:
dy/dt = y(x(t - 1)) + y(t)
instead of:
dy/dt = y(t - 1) + y(t).
I've managed to code the latter with dde23 but I can't figure out how to code the version of the DDE I actually have because I don't know how to delay t in x. With what I've tried I can only get a delay x in y (I'm assuming cause MATLAB didn't recognise x as a function of t as but I don't know how to do that either since I don't have an expression of x(t). I only have dx/dt which in turn depends on the soludion of the system of DDEs).
Any insight will be greatly appreciated. Thank you in advance.
0 commentaires
Réponse acceptée
Steven Lord
le 13 Juil 2021
The dde23 function is for solving delay differential equations with constant delays.
The ddesd function is for solving delay differential equations with general delays. There's also ddensd for DDEs of neutral type.
From the description of your problem I think it fits the model of ddesd rather than dde23.
5 commentaires
Steven Lord
le 13 Juil 2021
Your system of DDEs is where .
The dely function on that page accepts t and Q.
The delays in x will be Z(2, :) and the delays in T will be Z(5, :) in ddefun.
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Delay Differential Equations dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!