Hi at all. I´m new to this forum because I have a little question regarding to my seminar work for university.
The Topic is to find a modell that show the victims in traffic accidents related to driver assistance systems. I want to show that the research on the systems should be higher if the death rate rises. So like if there are more then 1000 death people per year set research to one and start a new "research loop"
I tried with the if then else funkction but this will work just for the first 1000 accident victims, I want after acitvate the new loop to sart again with zero deaths.
its like:
if deaths > 1000, set research to one "one assistence system is on research"
set counter to zero
if deats > 1000, set reseacht to one "second assistece is on research"
and so on ....
furthermore I have to say that the traffic victims function has a goal seeking behaviour, so the time to reach 1000 victims is different
Hope this description is reasonable enough for some help
count number of people and set variable from 0 to 1
-
- Super Administrator
- Posts: 4596
- Joined: Wed Mar 05, 2003 3:10 am
Re: count number of people and set variable from 0 to 1
Could you use a lookup table?
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: count number of people and set variable from 0 to 1
thanks for the quick answer! But is it posible to use a method which works continously. If I use lookup i have to use a lot of lines because I don´t know the max. rate of accident victims yet. Furthermore this soltion don´t look that nice to me, hope I can find some more elegant solution.
-
- Super Administrator
- Posts: 4596
- Joined: Wed Mar 05, 2003 3:10 am
Re: count number of people and set variable from 0 to 1
How about using something like MODULO?
deaths per assistance system = 1000
if then else ( MODULO(deaths,deaths per assistance system) > 1000, add one assistance system , 0 )
If you post the model maybe we can suggest something better (it's much easier for us to help if we have something to look at).
deaths per assistance system = 1000
if then else ( MODULO(deaths,deaths per assistance system) > 1000, add one assistance system , 0 )
If you post the model maybe we can suggest something better (it's much easier for us to help if we have something to look at).
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: count number of people and set variable from 0 to 1
It sounds like you need a stock that serves as a counter. Whenever the research loop is triggered, you flush out the contents (outflow = stock/TIME STEP) and start counting again.
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/