# Questions tagged [event-detection]

Questions on events in differential equations, which may arise from WhenEvent or discontinuous coefficients in the commands NDSolve and DSolve.

81 questions
Filter by
Sorted by
Tagged with
65 views

### Strange behavior of WhenEvent, a bug?

I really feel sorry that I have asked too many questions on this forum about DAE. But I'm indeed facing a lot of problems on this topic and NDSolve. Once again I ...
59 views

### Problem with DSolve, NDSolve with WhenEvent, Boundary Value Problem

I got the same problem as in question: DSolve, NDSolve with WhenEvent Give Incorrect ...
57 views

### WhenEvent with a function

I have the the function kill[x_]:=Map[#->0&,x] which is supposed to set a list of functions to zero. That seems to be working, because ...
41 views

### NDSolve with Events that reevaluate with different Discrete Variables

I have the following problem: I have a set of ODEs and some discrete variables which I can solve successfully. Now I want mathematica to check at every $0.1 \,t$ time step, wether it would increase ...
46 views

### WhenEvent action won't be applied (+ strange problem?)

I'm building a project about the dynamics of a 9-conf robotic industrial arm. I've come to the point where I have to integrate the solution of differential equations for a couple of movements, but can'...
192 views

### WhenEvent fails in NDSolve

The code with one condition Mod[t, 2 π] == 0 ...
31 views

### How can I use WhenEvent to stop the integration? [duplicate]

I have a questions about stopping the integration. I calculate the function as the following. It gives the message: "At NN=58.7035438......, the step size is effectively zero; singularity or stiff ...
139 views

### WhenEvent in ParametricNDSolve with parameterized trigger fails?

Edited to add: New information at bottom. Consider the following system of differential equations: ...
55 views

### Hybrid Systemn Anomalous results while using ParametricNDSolveValue

The hybrid system that I am solving ...
47 views

### Sensitivity analysis of a hybrid system (using WhenEvent) using ParametricNDSolve [closed]

I am trying to do a sensitivity analysis using ParametricNDSolve for a hybrid system. with the following event: ...
88 views

### WhenEvent error in NDSolve ODEs

I wish to change the term, T'[t] to 0 when S[t]<=0 when I solve ODEs. I have used WhenEvent in my NDSolve part, but it seems not work. The code is ...
124 views

### WhenEvent&NDSolve: How to detect saddle point?

I'm considering a simple ode. With the help of WhenEvent and Discrete Variable it is possible to detect the sign of the ...
75 views

### WhenEvent ignores some actions

I've got a problem where WhenEvent successfully detects an event, but then performs only some of the actions. In this minimal example, ...
80 views

### WhenEvent not setting discrete variables in If clause

The following example shows two functionally identical versions of the same WhenEvent. The two versions rely on two conditions Condition A and Condition B being satisfied and differ only in the order ...
111 views

### Having trouble using WhenEvent with NDSolve

First of all, this is my first time on this forum. Please be patient with me because if I make some mistakes in this post. I'm not used to doing this! I'm trying to modify a parameter during ...
36 views

### Changing the integration equation in NDSolve upon an event

I'm trying to implement the solution to the following ODE dx/dt = -x for x < 0 dx/dt = x for x > 0 Using NDSolve and ...
160 views

### Using WhenEvent to limit the derivative

In the system below, would like to keep z[t] between 0 and 1. The intent of the code below is to use WhenEvent to detect when z[t] reaches the limit of 1, and then only allow negative values of the ...
277 views

345 views

### Spurious Error Messages from NDSolve when Using WhenEvent with Time Delays

Bug introduced between versions 10.1 and 10.4, and resolved in 11.3. Using either 11.2 or 10.4 on Windows 10 (64 bit), I am unable to reproduce the answer by March to question 99576. Specifically, ...
110 views

### speed of WhenEvent in NDSolve with many events

Is there a way to speed up NDSolve with WhenEvent in this example (many state variables and many events)? ...
32 views

### Modifying this GoL implementation to make it sensible to clicks on the corner of the array

I'm interested in modifying this interactive implementation of the Game of Life http://demonstrations.wolfram.com/RealTimeSimulationOfTheGameOfLife/ to make it sensible to click events on the ...
97 views

### Issue with WhenEvent with dependence in a parameter

Here I define the equations: ...
303 views

### Options of WhenEvent

I'm using NDSolve and WhenEvent to simulate building heating systems and their discontinuous operation. Here is a simplified example. The idea is quite simple. I have the following WhenEvents: <...