Negative Stock

Use this forum to discuss any issues relating to Systems Dynamics and Systems Thinking.
Post Reply
nadia
Member
Posts: 28
Joined: Sun Oct 31, 2010 4:02 pm

Negative Stock

Post by nadia »

Hye everybody,

Why stock become negative? When I try extreme condition test my stock become negative.But, the others variables behave appropriately. Only the stock become negative.Anybody please help me. Is that possible if I attach my model and get comment for improvement in my model. Really need your help. Thank you in advance.


Regards,
Nadia.
Administrator
Super Administrator
Posts: 4590
Joined: Wed Mar 05, 2003 3:10 am

Re: Negative Stock

Post by Administrator »

See the following thread. It should help.

http://www.ventanasystems.co.uk/forum/v ... ock#p14605

Or post your model here so we can take a look.

Tony.
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
nadia
Member
Posts: 28
Joined: Sun Oct 31, 2010 4:02 pm

Re: Negative Stock

Post by nadia »

Hi,

My model as attached. Hope I can get comments and suggestions for improvement for my model. Thank you.


Nadia.
Attachments
extreme condition test zero fertilizer vensim.mdl
(10.47 KiB) Downloaded 425 times
Administrator
Super Administrator
Posts: 4590
Joined: Wed Mar 05, 2003 3:10 am

Re: Negative Stock

Post by Administrator »

Try the following modifications.

local supply = min ( Rice Stock / time step , FRACTION STOCK RELEASE * Rice Stock )

What this equation does is take "what you want" (FRACTION STOCK RELEASE * Rice Stock) out of the stock, but if there is not enough, it completely empties the stock (Rice Stock / time step)

rice stock release = min ( gap in import , Rice Stock / time step - local supply )

This equation is similar to the local supply equation, you take out what you want (gap in import) or what is available (Rice Stock / time step minus anything taken out by "local supply").

This will stop the stock going negative.

Hope this helps.

Tony.
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
nadia
Member
Posts: 28
Joined: Sun Oct 31, 2010 4:02 pm

Re: Negative Stock

Post by nadia »

Ok.Thank you very much. It really helps me a lot.But what about the farmers net income? Where I can get the info about how to use min function?Thank you in advance.


Nadia.
Administrator
Super Administrator
Posts: 4590
Joined: Wed Mar 05, 2003 3:10 am

Re: Negative Stock

Post by Administrator »

Where I can get the info about how to use min function?
It's just MINIMUM. STOCK / TIME STEP is the rate the empty the entire stock in one time step. So you take out the minimum of everything (stock/time step) or what you actually want to take out.

You can think of it as
IF THEN ELSE ( what you want to take out > STOCK , what you want to take out , STOCK / TIME STEP )

I hope this makes sense.
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
Post Reply