I have a structure that is causing lots of active initial difference warnings. The structure uses a random number to select a subscript of an arrayed value. The vector function suggests that I do any mapping with the first subscript value, say Var[sub1]. But the random number may choose the fourth subscript, so Var[sub4]. That causes a warning.
What is a good way to make the warnings disappear, without turn off the preference? I like warnings in general.
Sample model attached.
TIA,
Travis
Active Initial question, Vector function
Active Initial question, Vector function
- Attachments
-
- randQuestion.mdl
- (3.59 KiB) Downloaded 252 times
Re: Active Initial question, Vector function
Hi Travis
There is first an unit error. It might be better to add a variable named time in month = time * month in a year.
It is difficult to give an advice. The structure is rather clumsy. Can you describe exactly the problem you are trying to model?
Regards.
JJ
There is first an unit error. It might be better to add a variable named time in month = time * month in a year.
It is difficult to give an advice. The structure is rather clumsy. Can you describe exactly the problem you are trying to model?
Regards.
JJ
-
- Super Administrator
- Posts: 4599
- Joined: Wed Mar 05, 2003 3:10 am
Re: Active Initial question, Vector function
I'm looking into this. It looks like the report is an error, I just need to track down where it is.
Tony.
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
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Units are important!
http://www.bbc.co.uk/news/magazine-27509559
Re: Active Initial question, Vector function
JJ,
Sorry for the units error. This is part of a much bigger model, and I missed units when I cut it out. The bigger model passes unit check.
But to illustrate the question better, I made an much simpler model that has the same problem. Two vars: Random number into a Lookup. I get the Active Initial warning with this model. If there is a way to avoid this warning with a formulation change, I would be interested in learning it.
Tony, any luck on this? Is there a way to leave warnings in settings but do something differently to get these to go away?
Thanks,
Travis
Sorry for the units error. This is part of a much bigger model, and I missed units when I cut it out. The bigger model passes unit check.
But to illustrate the question better, I made an much simpler model that has the same problem. Two vars: Random number into a Lookup. I get the Active Initial warning with this model. If there is a way to avoid this warning with a formulation change, I would be interested in learning it.
Tony, any luck on this? Is there a way to leave warnings in settings but do something differently to get these to go away?
Thanks,
Travis
- Attachments
-
- randQuestion v3.mdl
- (1.28 KiB) Downloaded 251 times
Re: Active Initial question, Vector function
Have you tried checking the initialization step results by using Diff integration?
/*
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: Active Initial question, Vector function
Tom,
I don't follow. The v3 model (most recent that I uploaded) doesn't have any integration. Just a random number between [0-1], then input into a lookup table. A warning pops up. To see, just open the model and run once.
t
btw, I've seen this warning for years on several models, but only now does it really start to bother me. I have a model that triggers this warning 50+ times each run, instead of once as in my v3 demo model.
I don't follow. The v3 model (most recent that I uploaded) doesn't have any integration. Just a random number between [0-1], then input into a lookup table. A warning pops up. To see, just open the model and run once.
t
btw, I've seen this warning for years on several models, but only now does it really start to bother me. I have a model that triggers this warning 50+ times each run, instead of once as in my v3 demo model.
-
- Super Administrator
- Posts: 4599
- Joined: Wed Mar 05, 2003 3:10 am
Re: Active Initial question, Vector function
I don't get any warnings with the v3 model.
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: Active Initial question, Vector function
Hmm. Have you tried the first model, with more variables? That definitely gets the warnings for me.
t
t
Re: Active Initial question, Vector function
Even if there's no integration, there's a step at time=initial time, which sets up stock initial values (if there were any). That may produce the warning, because the initialization step produces a different random # from the dynamic step. I'm looking into the RNG in general, so there may be a way to suppress this.
/*
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: Active Initial question, Vector function
Okay, so it sounds like there is nothing I can do right now. Let me know if/when there is a fix for me to try.
Thanks for your help,
Travis
Thanks for your help,
Travis