Class ShrinkParameterspaceIterator

All Implemented Interfaces:
FWSimFieldContainer

public class ShrinkParameterspaceIterator extends DefaultSimulationIterator
Iterator that shrinks the parameter space, i. e. reduces the range where a parameter can vary. WIKI_START == Documentation == In each iteration step, the range of a parameter is shrunk by `cShrinkFactor` and centered around the the actual value of the parameter. === Initial step === Values for each cal variable's `min` and `max` or `sigma` and `mean` are taken from initial configuration. === Subsequent steps === If the cal variable has a value, calculated by a simulation and selected by a selector in the previous iteration, then the new range will be centered around this value. Otherwise the new range will be centered around the midpoint of the previous range. If `cDrift` is set to `true` then the new range can exceed the initial `min` and `max` values. Otherwise the new range will be cut to fit inside the original range. If it is false, then `min` and `max` properties have to be give, even if you wan to use only `mean` and `sigma`. WIKI_END Calculation for iteration step \(i \gt 1\): \[ \begin{eqnarray} mean_i & = & \begin{cases} parametervalue & \text{if parametervalue is set} \\ \frac{max_{i-1} + min_{i-1}}{2} & \text{else} \end{cases} \\ radius_i & = & \frac{max_{i-1} - min_{i-1}}{2} \cdot cShrinkFactor \\ min_i & = & \begin{cases} mean_i - radius_i & \text{if } cDrift \text{ is true} \\ \max(mean_i - radius_i,min_1) & \text{else} \end{cases} \\ max_i & = & \begin{cases} mean_i + radius_i & \text{if } cDrift \text{ is true} \\ \min(mean_i + radius_i,max_1) & \text{else} \end{cases} \\ sigma_i & = & sigma_{i-1} \cdot cShrinkFactor \end{eqnarray} \] WIKI_START === Stop condition === The iterator runs maximum `maxCount` times. Iteration will stop earlier, if the constraint rule becomes false. == Example == === Defining and configuring an iterator === {{{ | | .5 | false | 5 | | | 0.01 | 0.1 | 0.0025 | 0.02 | | | 1 | 5 | 0.21 | 3.0 | | }}} Iterator calculates min/max/mean/sigma for two parameters `vSLA` and `vLUE`. Initial interval for `vLUE` is from 1.0 to 5.0. In each interation step, the size of the interval will be half of the previous size. E.g. if after iteration step 1 the selected LUE will be 3.7, then the new intervall will range from 2.7 to 4.7. If the selected LUE after iteration step 2 will be 3.8, then the new intervall will range from 3.3 to 4.3 etc... If the selected LUE after iteration step 2 will be 4.6, then the new interval will range from 4.1 to 5.0, as the designed upper bound 5.1 is bigger than initial max value 5.0. === Using the iterator by a generator === {{{ | | 100 | | | | | | Normal | | | | | Uniform | | }}} The generator will generate 100 simulations in each, chosing `vLUE` from a normal distribution centered around the mean and sigma values provided by the iterator. As sigma becomes smaller, the range of the values will be smaller. Notice that for `vSLA` min and max are independent from the iterator, so in each step the values will be randomly chosen from the same range. WIKI_END
Author:
G. Krauss