Information on calculator Random Number Generators from PPC Journal articles
|
11-29-2016, 05:09 AM
(This post was last modified: 12-26-2016 12:38 AM by Namir.)
Post: #49
|
|||
|
|||
RE: Information on calculator Random Number Generators from PPC Journal articles
In the previous messages in this thread, the following similar PRNGs were mentioned:
r=frac((pi+r)^3) r=frac((pi+r)^5) Their general form is: r=frac((a+r)^b) I chose a = pi + cos(k * c2 / pi) and b = 4 + sin(k * c1 / pi) Where c1=127, c2=113, and k is a counter that is incremented every time we invoke the PRNG function. I tested 5 runs of 10,000 random numbers. The maximum absolute auto-correlation was less than 0.03. The Chi-Square was in (4, 10.3) range. The mean and sdev of all 50,000 random numbers were 0.500016257 and 0.288179175, respectively. The above PRNG should be adequate for calculation apps, simulations, and games. Enjoy! Namir PS: You can also use a = pi + sin(k * c2 / pi) and b = 4 +cos(k * c1 / pi) and get similar results. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 4 Guest(s)