Is your feature request related to a problem? Please describe.
Hi, everyone, DifferentialEquations.jl is awesome and efficient. I am trying to implement an affect! function to set values u[i] on a time interval instead of a single time point so that the delay differential equation module can work when I introduce, during integration, new particles whose history can be set by the callback function. Thanks a lot if you can consider making it possible to allow an affect! function to influence the state values of an integrator on a time interval, or if you have any other elegant workarounds to solving this.
Describe the solution you’d like
Instead of setting values only at one time point by a usual affect! function,
function affect!(integrator)
integrator.u[2] = -integrator.u[2]
end
set its values for a whole time interval:
function affect!(integrator)
# here integrator is a DDE one (delay differential equation integrator) or others
for integrator.t in a custom time span, e.g. [the timepoint of callback - 1.0, the timepoint of callback]:
integrator.u .= (some custom function)
end
end
Describe alternatives you’ve considered
Repeatedly invoke a one-time affect! in the time interval, but this probably has too much overhead.
Is your feature request related to a problem? Please describe.
Hi, everyone, DifferentialEquations.jl is awesome and efficient. I am trying to implement an
affect!function to set valuesu[i]on a time interval instead of a single time point so that the delay differential equation module can work when I introduce, during integration, new particles whose history can be set by the callback function. Thanks a lot if you can consider making it possible to allow anaffect!function to influence the state values of an integrator on a time interval, or if you have any other elegant workarounds to solving this.Describe the solution you’d like
Instead of setting values only at one time point by a usual
affect!function,set its values for a whole time interval:
Describe alternatives you’ve considered
Repeatedly invoke a one-time
affect!in the time interval, but this probably has too much overhead.