[tab:rand.req.eng] (original) (raw)
Table 125 β Random number engine requirements [tab:rand.req.eng]
πExpression | Return type | Pre/post-condition | Complexity |
---|---|---|---|
πE() | Creates an engine with the same initial state as all other default-constructed engines of type E. | ||
πE(x) | Creates an engine that compares equal to x. | ||
πE(s) | Creates an engine with initial state determined by s. | ||
πE(q)241 | Creates an engine with an initial state that depends on a sequence produced by one call to q.generate. | same as complexity of q.generate called on a sequence whose length is size of state | |
πe.seed() | void | Postconditions: e == E(). | same as E() |
πe.seed(s) | void | Postconditions: e == E(s). | same as E(s) |
πe.seed(q) | void | Postconditions: e == E(q). | same as E(q) |
πe() | T | Advances e's state e toe e) and returnsGA(e). | per [rand.req.urng] |
πe.discard(z)242 | void | Advances e's state e to by any means equivalent to z consecutive calls e(). | no worse than the complexity of z consecutive calls e() |
πx == y | bool | This operator is an equivalence relation. With and as the infinite sequences of values that would be generated by repeated future calls to x() and y(), respectively, returns true if ; else returns false. | |
πx != y | bool | !(x == y). |