Use of the TREND and DELAY functions in Vensim

Use this forum to post Vensim related questions.
Post Reply
mbosin
Junior Member
Posts: 2
Joined: Thu Jan 16, 2020 10:04 pm
Vensim version: PLE

Use of the TREND and DELAY functions in Vensim

Post by mbosin »

I am new to Vensim and I am trying to use the TREND and DELAY functions in Vensim in building a model for workforce movements. I read the definition for each of the functions, but it is still difficult for me to discern what specific information I need to write the equations. Is there a youtube that can take me through the process of how to use my data to write the equations for these functions? Thank you.
Administrator
Super Administrator
Posts: 4573
Joined: Wed Mar 05, 2003 3:10 am

Re: Use of the TREND and DELAY functions in Vensim

Post by Administrator »

I don't think there are videos on how to use these functions.

What part of the documentation are you struggling with?
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
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Use of the TREND and DELAY functions in Vensim

Post by tomfid »

There's a sample model for each, attached to the function's topic in the Help system.
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Use of the TREND and DELAY functions in Vensim

Post by tomfid »

See also:

Sterman, John D. 1987. Expectation Formation in Behavioral Simulation Models. Behavioral Science, 32:190-211.

Sterman, John D. 2000, Business Dynamics, Boston, MA: McGraw-Hill. Chapter 16.

And:

https://metasd.com/2011/04/delay-sandbox/
mbosin
Junior Member
Posts: 2
Joined: Thu Jan 16, 2020 10:04 pm
Vensim version: PLE

Re: Use of the TREND and DELAY functions in Vensim

Post by mbosin »

I see these examples in the definition of the TREND function, but I don't know how to translate the information I have into the equation. For example, I have a 'workforce level' variable that has historically increased on an average of 6% per year, which translates to .05% per month. How do I incorporate this trend information into the TREND equation provided, if I want to simulate workforce growth over the next 10 years, one month at a time?


Returns the average fractional growth rate (negative for decline) in the input. Equivalent to the equations:

TREND=ZIDZ(input-avval,average time*ABS(avval))

avval=INTEG((input-avval)/average time,input/(1+ini*averate time))

The TREND function provides a very simple trend estimate for a variable. It really only makes sense for numbers that are always positive and don’t get very close to zero. If you want to trend a number that may be positive or negative the TREND function is not very useful. Instead, you should use the fractional trend relative to a quantity that is always positive (for example change in profit as a fraction of gross income).



Units: TREND(units,time,1/time) --> 1/time

Units for the average time must match those of TIME STEP.

Example

R = 10 + RAMP(1,30,70)

TR = TREND(R,5,.08)
tomfid
Administrator
Posts: 3804
Joined: Wed May 24, 2006 4:54 am

Re: Use of the TREND and DELAY functions in Vensim

Post by tomfid »

In that case, you don't want the TREND function at all. You want something like a stock of Workforce, with an inflow of hiring or workforce growth or similar, where the inflow (people/month) equals the stock (people) multiplied by a growth rate (fraction per month, e.g. .005).
Post Reply