HP Forums
Casio Scientific Calculator and Ran# - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: Not HP Calculators (/forum-7.html)
+--- Forum: Not remotely HP Calculators (/forum-9.html)
+--- Thread: Casio Scientific Calculator and Ran# (/thread-20061.html)



Casio Scientific Calculator and Ran# - Gamo - 06-07-2023 07:07 AM

Just noticed that most of the Casio Scientific Calculator only give

3 decimal digits output from the Ran# function.

When I try to do the 6 digits Random number with this input

Ran# x 899999 + 10^5

Here is some of the random result with FIX 0 for 6 digits random number.

614799, 438400, 505900, 752499 and 435700

Notice that the last two digit will always have 99 and 00

----------------------------------------------------------------

To make this a rather better Random result I did this way.

Ran#^Ran# x 899999 +10^5

Here is the random result

611299, 621167, 304497, 997392, 395310 and 438358

Gamo


RE: Casio Scientific Calculator and Ran# - HKG - 06-07-2023 08:57 AM

if ran# x ran#, the result is ranged from 0.000 to 0.998001 which does not cover fully from 0 to 0.99999

How about using this : ran# x 1000 + ran# x 10^6 ? This will cover fully from 0 to 999999


RE: Casio Scientific Calculator and Ran# - Gamo - 06-07-2023 10:41 AM

Thanks HKG

That one is really good input as

Ran# x 10^3 + Ran# x 10^6

Here is some of the result

464598, 764627, 949309, 651623 and 502449


Gamo


RE: Casio Scientific Calculator and Ran# - Dave Britten - 06-07-2023 12:08 PM

Usually on these older models, I just do Ran#+Ran#/1E3. Six digits are enough for whatever I'm doing with that old calculator. Smile (And if not, throw in another Ran# to get 9 digits).


RE: Casio Scientific Calculator and Ran# - pier4r - 06-09-2023 03:42 PM

On a side note, unless I am mistaken random^random or random*random produce a different distribution than a uniform one.

The random*10^3 + random*^10^6 should be still a uniform distribution.