True random number generator (TRNG)
The outstanding feature of TRNG is that its output can not be copied. For example, if we toss a coin 100 times and record the results as a 100 digit sequence, few people on earth can produce the same sequence. True random number generators are all based on physical processes. The main examples include coin tossing, dice tossing, semiconductor sound, clock jitter and radioactive decay in digital circuits. In cryptography, TRNG is usually used to generate session key, which is then distributed between Alice and Bob or used for other purposes.
###Pseudo random number generator (PRNG)
The pseudo-random number generator starts from an initial seed and obtains the sequence through various calculations. Generally, the pseudo-random number sequence is obtained by recursively performing the following calculation:
s_0 = seed\\
s_{i +1} = f(s_i), i = 0, 1, …
Where a, B and m are all integer constants. Note: PRNG is not really random, because they can be calculated, so it can be said that they are determined by calculation.
A general requirement for PRNG is that it must have good statistical characteristics, which means that its output is almost the same as the true random number sequence.
This work adoptsCC agreementReprint must indicate the author and the link of this article