What is the RNG algorithm for VBMath.Rnd

Ken Jutz 1 Reputation point

What is the random number generator algorithm used for VBMath.Rnd? Is it utilizing System.Random?

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,418 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Viorel 109.9K Reputation points

    If you search using https://www.bing.com/search?q=VBMath+Rnd+Clone, you will probably find a sample class which pretends to be an exact replacement. To check this, call Randomize with the same parameters in both cases, then check if the generated pseudo-random sequences are the same.

    1 person found this answer helpful.
    0 comments No comments

  2. Dylan Zhu-MSFT 6,396 Reputation points

    Hi KenJutz,

    Maybe you could refer to the files: VBMath.cs and System.Random in .NET framework. The types of parameters and return values are different. Although, their implementation may have some same points, it seems that VBMath.Rnd doesn't utilize System.Random.

    Best Regards,

    0 comments No comments