https://github.com/albinzayedrawan/random-number-generator
Lab exercises to understand the concepts of True Random Number Generators (TRNG) and Pseudo-Random Number Generators (PRNG).
https://github.com/albinzayedrawan/random-number-generator
cryptography lcg prng trng
Last synced: 6 months ago
JSON representation
Lab exercises to understand the concepts of True Random Number Generators (TRNG) and Pseudo-Random Number Generators (PRNG).
- Host: GitHub
- URL: https://github.com/albinzayedrawan/random-number-generator
- Owner: albinzayedrawan
- Created: 2024-11-09T18:07:38.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-11-09T18:16:06.000Z (11 months ago)
- Last Synced: 2025-02-10T01:30:03.525Z (8 months ago)
- Topics: cryptography, lcg, prng, trng
- Language: Python
- Homepage:
- Size: 6.84 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Random Number Generator
## True Random Number Generator (TRNG):
- Use an online TRNG service (e.g., random.org) or system-based entropy source (e.g., /dev/random) to collect 100 random numbers.
- Record these numbers in a text file for analysis.
- Plot the collected TRNG numbers on a histogram to visualize their distribution.
- Comment on whether the numbers appear evenly distributed or show any discernible patterns.## Linear Congruential Generator (LCG):
- Implement an LCG, a common PRNG algorithm, in Python using any parameters of your choice.
- Generate a sequence of 100 numbers using the LCG, and record the results.
- Use a fixed seed to ensure repeatability, and plot the distribution of the generated numbers.## Pseudo-Random Number Generator (PRNG):
- Use Python’s built-in PRNG (random module) to generate another sequence of 100 numbers.
- Set a fixed seed to make the results reproducible.
- Record and plot the distribution of these numbers alongside the LCG-generated numbers.