Issue in Simbiology Stochastic Simulations
2 次查看(过去 30 天)
显示 更早的评论
I am able to run stochastic simulations on very small and simple models and it works okay, but if I add more than 5-10 components, it takes much more time and often just freezes my computer. Have anyone ever run into similar issues? If so, do you have any insights that you could share with me?
0 个评论
采纳的回答
Arthur Goldsipe
2017-7-18
Which stochastic solver are you using? If you're using 'ssa', then you will probably see simulation times increase with the number of molecules in the system. This is more likely to be the issue than the total number of unique species in the model.
First, I recommend setting the MaximumWallClock option any time you have trouble with long running simulations. This allows you to stop the simulation after an approximate amount of "real world" (or "wall clock") time. You can then inspect the simulation results and see why the simulations are taking so long.
In this case, you might find that one reason the simulations are taking so long is that you are logging many results at very small time intervals (due to the large number of molecules in the system). If that's the case, you can see if reducing the amount of data logging can speed up your simulations sufficiently. For example, you can set LogDecimation to 10 to report every 10th time point.
If 'ssa' still takes too long after setting LogDecimation, then I recommend switching to one of the tau-leap solvers. The implicit solver ('impltau') is usually the fastest of the 3 options. You can read more about how to choose a stochastic solver here.
-Arthur
0 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Scan Parameter Ranges 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!