Hi,
For a stock with just one flow, how to set the flow to be "bidirectional", so that the flow can sometimes be an inflow and sometimes be an outflow of the stock, depending upon the stock level as compared with an exogenously changing target?
Many thanks.
How to set "bidirectional" flow for a stock
-
- Senior Member
- Posts: 105
- Joined: Wed Oct 25, 2017 3:52 pm
- Vensim version: PRO
Re: How to set "bidirectional" flow for a stock
Vensim flows are always bidirectional, unless you explicitly constrain the equation with a MAX(0,...) or similar.
For example,
expected price = INTEG( expectation adj rate, initial price ) ~ $/kg
expectation adj rate = ( actual price - expected price )/adj time ~ $/kg/week
On the diagram you'd show the expectation adj rate as an inflow (arrow into stock), but when actual price < expected price, it will be negative, and therefore serve as an outflow.
For example,
expected price = INTEG( expectation adj rate, initial price ) ~ $/kg
expectation adj rate = ( actual price - expected price )/adj time ~ $/kg/week
On the diagram you'd show the expectation adj rate as an inflow (arrow into stock), but when actual price < expected price, it will be negative, and therefore serve as an outflow.
/*
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
*/
-
- Senior Member
- Posts: 105
- Joined: Wed Oct 25, 2017 3:52 pm
- Vensim version: PRO
Re: How to set "bidirectional" flow for a stock
Thanks a lot, Tom.
So there is no need to explicitly showing two arrows for one flow, i.e. one arrow of the flow going into the stock and the other arrow going into the cloud? Or maybe this is simply not realisable graphically?
So there is no need to explicitly showing two arrows for one flow, i.e. one arrow of the flow going into the stock and the other arrow going into the cloud? Or maybe this is simply not realisable graphically?
Re: How to set "bidirectional" flow for a stock
You can turn on the second arrow by right-clicking the pipe, but I don't find it helpful.
/*
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
*/