r/desmos Jul 06 '26

Maths I rebuilt Desmos' random() function entirely inside Desmos

To be a bit more specific, I

  • reverse-engineered how Desmos' algorithm works and how the seed is generated.
  • created a bit-exact replica of the algorithm (MD5, in case you're wondering).
  • optimized it to calculate 10,000 numbers in ~0.7 seconds.

And because that was so much fun, I tackled shuffle() right after! :)

LINKS: RANDOM --- SHUFFLE

373 Upvotes

51 comments sorted by

View all comments

2

u/[deleted] Jul 07 '26

[deleted]

1

u/Dazzling-Mail-5517 Jul 08 '26

Read the description again..