Info

This question is closed. Reopen it to edit or answer.

How can I get the number of logs in SimBiology?

1 view (last 30 days)
Gaohua Lu
Gaohua Lu on 19 Sep 2017
Closed: MATLAB Answer Bot on 20 Aug 2021
Hi, I am using SimBiology to build PBPK model. I want to use the number of logs to modify some parameters of the model during the simulation. I found MaximumNumberOfLogs can stop simulation at specific step. Can I get the step number and use it during the simulation but not stop the simulation. If yes, please can you advise me how I can do this? Thanks,

Answers (1)

Arthur Goldsipe
Arthur Goldsipe on 19 Sep 2017
If I understand your question, this is not currently possible. In fact, I would avoid creating a model where parameter values change depending on the number of logs. The number of logs is very sensitive to your solver options, like your tolerances. This could make the model difficult to solve numerically. More importantly, I don't understand how that sort of parameter change would be appropriate for a PBPK model.
I recommend that you think about what you are really trying to model. Why is the parameter value changing? Is the change most directly related to the simulation time? Or maybe the parameter values changes when some species concentration cross a threshold value. Both of these seem more physically reasonable to me than changing the parameter based on the number of logs. And both of these can be modeled in SimBiology using events. You can read more about events in SimBiology here.
If you still have questions, I recommend creating a new question on MATLAB Answers that provides more details about what you want to model.
Good luck!
Arthur

Community Treasure Hunt

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

Start Hunting!