Return degraded state to a certain value
Return degraded state to a certain value
Hi
I need help on how to make my "Bearing condition" return to value 10 (100% condition) after it has been replaced (maintenance)
Right now I just put the equation as IF THEN ELSE(Bearings Condition EL 1<=2, 10, 0), so that every time the condition drops to 20% it is replaced.
However, as you see here the value given when statement is true us 10. I have 2 remaining = 12. Setting true statement to 8 will not solve my problem, as I need in several places in my simulation values set to its original ( starting) value after a maintenance event.
Is there a function to set a level to its original value when it has reached a certain value.
+Is there a way to count these events? (Number of times a level has been set to original value)
Thanks
I need help on how to make my "Bearing condition" return to value 10 (100% condition) after it has been replaced (maintenance)
Right now I just put the equation as IF THEN ELSE(Bearings Condition EL 1<=2, 10, 0), so that every time the condition drops to 20% it is replaced.
However, as you see here the value given when statement is true us 10. I have 2 remaining = 12. Setting true statement to 8 will not solve my problem, as I need in several places in my simulation values set to its original ( starting) value after a maintenance event.
Is there a function to set a level to its original value when it has reached a certain value.
+Is there a way to count these events? (Number of times a level has been set to original value)
Thanks
- Attachments
-
- screenshot
- Capture7.PNG (45.73 KiB) Viewed 5313 times
-
- Super Administrator
- Posts: 4592
- Joined: Wed Mar 05, 2003 3:10 am
Re: Return degraded state to a certain value
Can you upload the model?
It's straightforward to do, and much easier if we can look at your model and show you how to do it.
It's straightforward to do, and much easier if we can look at your model and show you how to do it.
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
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Units are important!
http://www.bbc.co.uk/news/magazine-27509559
Re: Return degraded state to a certain value
I uploaded the model
- Attachments
-
- System Design V1,4.mdl
- (5.41 KiB) Downloaded 192 times
Re: Return degraded state to a certain value
The generic approach is as follows.
You have:
stock = INTEG( flow, init val )
you can reset the stock with:
stock = INTEG( flow + reset, init val )
reset = (desired stock - stock)/TIME STEP - flow
In other words, the reset has to (a) adjust the stock toward the desired value (which might be init val) instantly, and (b) cancel out any net flows that would otherwise disturb it.
You have:
stock = INTEG( flow, init val )
you can reset the stock with:
stock = INTEG( flow + reset, init val )
reset = (desired stock - stock)/TIME STEP - flow
In other words, the reset has to (a) adjust the stock toward the desired value (which might be init val) instantly, and (b) cancel out any net flows that would otherwise disturb it.
/*
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
*/
Re: Return degraded state to a certain value
I still can't figure this out.
Is "reset" a function? I can not find it in the functions list. I tried both in the stock and flow boxes.
I am using Vensim PLE 7.2a
Typing in reset does not work either.
Is "reset" a function? I can not find it in the functions list. I tried both in the stock and flow boxes.
I am using Vensim PLE 7.2a
Typing in reset does not work either.
Re: Return degraded state to a certain value
"reset" is an additional variable.
/*
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
*/
Re: Return degraded state to a certain value
I got it to work. What a great forum.
Thanks for the quick reply!
Thanks for the quick reply!
Re: Return degraded state to a certain value
Great!
/*
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
*/
-
- Junior Member
- Posts: 4
- Joined: Thu May 24, 2018 12:02 pm
- Vensim version: PLE
Re: Return degraded state to a certain value
I kind of have the same problem, except I have a negative rate reducing the value in a Level. I use the same kind of "reset", however, the value does not Return to the initial value, but "initial value-rate"
How can I stop the rate from affecting the stock when need it reset?
Lets say the initial value is 100, and rate -20. When value reaches 20, I want it reset to 100. But it resets to 80, most likely because the rate made it 100-20=80
How do I make the rate = 0 when I need the stock level reset?
Thanks
How can I stop the rate from affecting the stock when need it reset?
Lets say the initial value is 100, and rate -20. When value reaches 20, I want it reset to 100. But it resets to 80, most likely because the rate made it 100-20=80
How do I make the rate = 0 when I need the stock level reset?
Thanks
-
- Super Administrator
- Posts: 4592
- Joined: Wed Mar 05, 2003 3:10 am
Re: Return degraded state to a certain value
Can you upload the model? It's much easier to give you an answer if we can see what you are doing.krissCraft wrote:I kind of have the same problem, except I have a negative rate reducing the value in a Level. I use the same kind of "reset", however, the value does not Return to the initial value, but "initial value-rate"
How can I stop the rate from affecting the stock when need it reset?
Lets say the initial value is 100, and rate -20. When value reaches 20, I want it reset to 100. But it resets to 80, most likely because the rate made it 100-20=80
How do I make the rate = 0 when I need the stock level reset?
Thanks
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
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Units are important!
http://www.bbc.co.uk/news/magazine-27509559
Re: Return degraded state to a certain value
Your case should just be the negative of the solution above:
stock = INTEG( - flow + reset, init val )
reset = (desired stock - stock)/TIME STEP + flow
stock = INTEG( - flow + reset, init val )
reset = (desired stock - stock)/TIME STEP + flow
/*
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
*/
-
- Junior Member
- Posts: 4
- Joined: Thu May 24, 2018 12:02 pm
- Vensim version: PLE
Re: Return degraded state to a certain value
Now it resets just how I want it to. Thank you. I should have seen that myself.