Files changed (3)
+// Before using, initialize the state by using init_genrand(seed) or init_by_array(init_key, key_length).
+// 3. The names of its contributors may not be used to endorse or promote products derived from this software
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
+// WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+// PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
+// TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+// if called with 2 args then 'seedArray,seed' is used for initialisation by the 'initByArray' method;
+// mt = new MersenneTwisterObject(1957,[11,18,03,06]) // create object using a seed array AND a specific seed
+// Example of generating random numbers (after creation of the object and optional re-initialisation of its state):
+// dmul0(m,n) performs double precision multiplication of two 32-bit integers and returns only the low order
+// - did not include the other variants returning real values - I think [0,1) is the only appropriate interval;
+// - included randomInt53() using the same method as was introduced 2002/01/09 by Isaku Wada in his genrand_res53;
+// - in the randomInt32 method I have changed the check "if (mti >= N)" to a 'while' loop decrementing mti by N
+// in each iteration, which allows skipping a range of randoms by simply adding a value to the mti property.
+// Since in this library the uninitialised state is not marked by mti==N+1 that's is a safe algorithm.
+// now define a function with the obsoleted name which simply tells the user about how to update the code.