MATLAB Answers

implement quasi zeroth order kinetic in Simbio

1 view (last 30 days)
Ziyuan Zhao
Ziyuan Zhao on 20 May 2020
Answered: Arthur Goldsipe on 20 May 2020
I want to let a chemical species have fixed concentration periodically from 0-1, 2-3, ... (arbitrary time unit) and then have first order decay during 1-2, 3-4,... (so these two behaviors alternate), how to implement that by code? I've tried repeated assignment and repeated doses but didn't get what I want. If you can help me figure how to set this in the graphical window for Simbio, I will be really grateful!

  0 Comments

Sign in to comment.

Answers (1)

Arthur Goldsipe
Arthur Goldsipe on 20 May 2020
Hi,
Whenever you have a discontinuous step change like this in your model, you should include either doses or events at the discotinuities to avoid numerical problems with integration. I put together a small example on this topic.
For the periodic change you want to model, I would add two events that can trigger repeatedly. One event to turn on the first-order decay (by setting your rate constant to an appropriate value), and another event to turn it off (by setting the rate constant to zero). Here are more details on how you could do that:
  • Configure the first-order kinetic rate parameter. (Let's assume it is named k1 and needs to have a value of 1 when the reaction is in effect.) Make sure it can be modified by an event by (1) ensuring it is scoped to the model and not to the reaction and (2) disabling the "Constant" setting for the parameter.
  • Add two additional non-constant parameters that specify when each of the events should fire. Let's assume you name them timeToTurnOffR1 and timeToTurnOnR1. Set their initial values apprpriately (for example, timeToTurnOffR1=1 and timeToTurnOnR1=2). Disable the "Constant" setting for both parameters.
  • Add events to turn the the reaction on and off periodically. To turn the reaction on every 2 time units, add an event with trigger time > timeToTurnOnR1 and two event functions, timeToTurnOnR1 = timeToTurnOnR1 + 2 and k1 = 1. To turn the reaction off every 2 time units, add an event with trigger time > timeToTurnOffR1 and two event functions, timeToTurnOffR1 = timeToTurnOffR1 + 2 and k1 = 0.
The key to turning the reaction on and off is changing the rate constant between 0 and 1 (or whatever value makes sense for you).
The key to making the events keep firing every 2 time uints is that each event modifies the parameter that control when it fires.
I hope that makes sense. It's a little complicated, but I think that's the best option for now.
-Arthur

  0 Comments

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!