How to keep critical time

Use this forum to post Vensim related questions.
Post Reply
Skoooby
Junior Member
Posts: 2
Joined: Wed Mar 14, 2018 11:27 am
Vensim version: PLE

How to keep critical time

Post by Skoooby »

Hi there! I am trying to simulate the condition of a train door(open closed, opening,closing) on vensim. In order to do so i ve come across the problem of saving a critical Time in one variable. I want this variable to aquire the value Time when some conditions are met and change this only when the same conditions are met later on the simulation. In essence i am trying to save a critical time to one variable to use it in calculations, and i want this variable to change again when another critical time apears, so that it saws the most recent critical time. I ve thought about how to spot the critical time i am looking for i just dont know how to keep it the same as long as there is no other critical time. Anyone with some idea. Could the SHIFT IF TRUE function help me? and if so how does it work?
Administrator
Super Administrator
Posts: 4573
Joined: Wed Mar 05, 2003 3:10 am

Re: How to keep critical time

Post by Administrator »

The function SAMPLE IF TRUE will do this.
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
Skoooby
Junior Member
Posts: 2
Joined: Wed Mar 14, 2018 11:27 am
Vensim version: PLE

Re: How to keep critical time

Post by Skoooby »

Thank you very much!
Post Reply