1
$\begingroup$

I have reached a chapter in the notes I am following where a program written in C++ is using a Monte Carlo method to estimate $\pi$. It mentions a 'seed', but does not say what this is. I have tried finding out what a seed is online, but I only seem to get results about 'why you should/shouldn't use a fixed seed', and unfortunately they have left me none the wiser as to what a seed actually is.

What is seed in this context?

$\endgroup$
2
$\begingroup$

The seed is an initial number of the pseudorandom number generator(PRNG) which is in fact fully deterministic. It returns a sequence of numbers that looks random enough for many purposes, but always generates the same sequence for given value.

In order to make simulation non-repeatable (returning always the same value) they advice different initial value for every simulation (this is what non-fixed seed means). Seed scheme

Image taken from here

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.