@ChrisRackauckas I just wanted to briefly follow up on the question posed in this thread, specifically about the idea of a VectorDiscreteCallback. Could you elaborate on how this would work?
I’m asking this question in the context of using DiscreteCallbacks when I have high dimensional state vectors, and I want to check a condition on each component. As a thought-example, suppose I have a 10-dimensional vector u where the first five entries u[1:5] represent velocities and the last five u[6:10] are the corresponding positions. Suppose, after each integration step, I want to kick the velocity if its corresponding position is below zero. E.g. if the condition u[6] <= 0, then I do the action u[1] += 10; if u[7] <= 0, then I do u[2] += 10, and so on for each component.
In this case, it seems like I would have to write five separate DiscreteCallbacks and affect functions for each of the components I am separately checking. Or is there a better solution that I’m not aware of for this to have just a single callback that affects all of the components in a single step?
If I do have to write separate discrete callbacks for each component of the state vector, is the best practice then to wrap all of those in a CallbackSet?