You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am modeling a chamber experiment with a time step of 5 seconds and rates output step size of 5 seconds.
The output in speciesConcentrations looks fine, concentrations change at every time step as expected. However, in productionRates and lossRates the rates appear to not be being calculated at each time step and so the output is in steps, it is identical for several time steps and then jumps to another value.
I have tried changing the lossRates output step size to 5, 20, 60 and 600 seconds. The same things happen with the steps occurring in the same place (see attached figure for loss rates for an example reaction with each output step size).
The changes in the steps are at the same time for all lossRates (see green points in figure).
I also tried running with a shorter timestep (2 seconds), with a lossRates output step size of 5 seconds, and the results were the same.
Also shown in the figure is the loss rate calculated by multiplying the values from speciesConcentrations (red line).
The text was updated successfully, but these errors were encountered:
Hi @Ekimmai, sorry for the slow response, and welcome to Atchem. The behaviour you're seeing is a result of the way the underlying CVODE library algorithms work - rather than timestepping to the next output time, and outputting then, instead it largely chooses its own timesteps and interpolates to give the output at the requested times.
When you say that you shortened the timesteps, could you clarify how you did that - was it by line 5 in solver.parameters?
I am modeling a chamber experiment with a time step of 5 seconds and rates output step size of 5 seconds.
The output in speciesConcentrations looks fine, concentrations change at every time step as expected. However, in productionRates and lossRates the rates appear to not be being calculated at each time step and so the output is in steps, it is identical for several time steps and then jumps to another value.
I have tried changing the lossRates output step size to 5, 20, 60 and 600 seconds. The same things happen with the steps occurring in the same place (see attached figure for loss rates for an example reaction with each output step size).
The changes in the steps are at the same time for all lossRates (see green points in figure).
I also tried running with a shorter timestep (2 seconds), with a lossRates output step size of 5 seconds, and the results were the same.
Also shown in the figure is the loss rate calculated by multiplying the values from speciesConcentrations (red line).
The text was updated successfully, but these errors were encountered: