Hello,
I would like to know if it is possible to stop the simulation runtime based on condition testing.
I searched in Vensim's documentation and the forum but couldn't find any clue.
The model I am working on has as one of its goals the elapsed time to reach a predefined goal.
In some platform (e.g., AnyLogic), it is possible to programmatically interrupt the runtime:
getEngine().getExperiment().stop(); or by using events.
Is it possible to do something similar in Vensim?
Thank you very much, Eduardo.
Programatically interrupt simulation runtime based on condition testing
-
- Super Administrator
- Posts: 4573
- Joined: Wed Mar 05, 2003 3:10 am
Re: Programatically interrupt simulation runtime based on condition testing
I've attached a model showing how to do this. All you do is modify FINAL TIME.
- Attachments
-
- StopSimAt50.mdl
- (1.81 KiB) Downloaded 142 times
Advice to posters seeking help (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Units are important!
http://www.bbc.co.uk/news/magazine-27509559
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Units are important!
http://www.bbc.co.uk/news/magazine-27509559
Re: Programatically interrupt simulation runtime based on condition testing
Thank you very much! It worked perfectly.