Page 1 of 1

change demand

Posted: Tue Dec 12, 2006 6:50 am
by Nurul
HI!

I need help in modelling travel demand.
If, for example, I have a demand at time t=7, t=15, and t=20. Every demand will travel for about 3 hours by car. So,demand will be 0 at time t=7, t=15, and t=20, and at time t=10, t=18, and t=23 demand will be 1.
My problem is I can't change the demand at t=7, t=15, and t=20 to be zero, while at time t=10, t=18, and t=23 the demand will be 1.

Thanks

Posted: Tue Dec 12, 2006 11:28 am
by bob@vensim.com
just use

active demand = INTEG(trip start - trip completions,0)
trip completions = DELAY FIXED(trip starts,trip duration,0)

Posted: Wed Dec 13, 2006 5:38 am
by Nurul
Thanks bob,
but it works only when I set trip duration to constant number. It doesnt work if I set trip duration as random number. Instead, I get a warning message "-customer-initial=3 Active=2 has changed in value", What does it mean? What should I do if I want to set trip duration as a random number?

Posted: Wed Dec 13, 2006 8:05 am
by Administrator
It would be a good idea if you read about the different delay functions in Vensim.

Go to
http://www.vensim.com/documentation/vensim.htm, wait for the help to load, select the "Index" tab and then type in "DELAY". Now take a closer look at
DELAY_FIXED, DELAY_MATERIAL and DELAY_INFORMATION.

Hope this helps.

Tony.

Posted: Wed Dec 13, 2006 10:11 am
by Nurul
Thanks Tony,
But I have one more problem. I have a randomly delay magnitude. for example, at time t=1, delay is 3 hour, at t=2 delay is 2 hour, and at t=3 delay is 6 hour. How do I convert the magnitude to time. I mean, for the first time, at time t=1, t=2, and t=3 the demand is 1,1,and 1. And because of the delay, now demand at t=1, t=2, and t=3 would be 0 while at t=4 demand would be 2 and at t=9 demand would be 1.

Thanks for any help for this problem

Posted: Wed Dec 13, 2006 9:41 pm
by bob@vensim.com
just use

active demand = INTEG(trip start - trip completions,0)
trip completions = DELAY MATERIAL(trip starts,trip duration,0,0)

if trip duration is variable.

Posted: Thu Dec 14, 2006 3:10 am
by Nurul
Thanks Bob

It works!!.

Thank you