look back/forward one period

Use this forum to post Vensim related questions.
Post Reply
KCL
Junior Member
Posts: 5
Joined: Fri Jul 07, 2006 3:25 pm

look back/forward one period

Post by KCL »

Hello,

I have been working with Vensim for a couple weeks doing financial modeling and ran into a few roadblocks. Hope to tap into the knowledge on the board to resolve the issues.

Question 1 - look forward one period
Suppose I have an auxiliary variable called XYZ. I want to calculate auxiliary variable Inventory based on XYZ one period from now. In other words, Inventory in the current period is calculated by multiplying the value of XYZ in the next period by a fixed percentage. Is this possible n Vensim?

Question 2 - looking back one period
I have an auxiliary variable Working Capital. I need to calculated auxiliary variable Change In Working Capital based on the Working Capital from the previous period and the Working Capital from the current period (i.e. Change in Working Capital = Working Capital from previous period - Working Capital from current period). I was wondering if there is a build-in function in Vensim to handle this type of logic.

Thanks, Ken
bob@vensim.com
Senior Member
Posts: 1107
Joined: Wed Mar 12, 2003 2:46 pm

Post by bob@vensim.com »

Question 1: Vensim Models are Causal in time. This means that the value of all variables depend only on the current or past values of other variables. Normally, since reality is also causal in time except at the quantum level this does not constrain modeling. Sometimes we need an estimate of what something will be in the future to determine current actions. The SMOOTH function is often used for this - see also TREND and FORECAST. At a more granular level sometimes we might use

expected level next period = level value + TIME STEP * ( inlows - outflows)

Generally this is applicable only to difference equation formulations.

2 is easy if you are working with difference equation.

lagged x = INTEG((x-lagged x)/TIME STEP,x)
Post Reply