开发者

Steady state in a process oriented simulation

I'm currently writing a process-oriented simulator using JavaSim for an university exam. The simulator itself is working nicely, but I have one major d开发者_StackOverflow社区oubt: is there a correct/best way to find the steady state of the simulation in code?

The book I read vaguely describe the process of finding the "steady state" when the behavior of the simulation converges to a constant or repeating value:

Steady state http://img24.imageshack.us/img24/9782/steadystate.png

But how does this look in code? I think I could sample the statistics I need to gather at regular intervals and check whether they converge on a certain mean value or not. Or I could simply print out the values in time and arbitrarily decide when the simulation reaches a steady state?


The standard approach is to monitor the rate of fluctuation, and pick some threshold small enough to be considered 'steady state'. Using a provided mean value is fragile because it hard-codes the absolute value of the solution you're looking for.

I would just calculate the standard deviation for a window of points, say the last 50, and declare the steady state reached when that deviation falls below an acceptable minimum (you do have to pick the minimum deviation yourself, because this is your definition of 'steady state'). This is roughly equivalent to accepting the answer when the wiggles in your graph become small enough for some sustained time.


Don't see that you ever got a good answer to this...

Check out online resources or Law and Kelton, Simulation Modeling and Analysis, for the process of determining steady state. The key is that you want your simulation to be independent of the system starting conditions. More to the point, the distribution of your key measures (like delay) should be independent of the starting conditions. They have a set of procedures to construct confidence intervals around your key measure based on the mean, variance, and sample size then to determine whether your consecutive samples are statistically the same. It's important to have a sufficient sample size though to satisfy the normality assumption.

Also good stuff in the book Simulation with Arena include a discussion of WHY steady state may not be important.

Good luck !

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜