Random Number Generator
Generate random numbers using three statistical distributions — Integer (discrete uniform), Float (continuous uniform), and Normal (Gaussian bell curve). Supports seeded output for reproducibility, no-duplicates mode, sort order, and instant statistics including mean, median, standard deviation, and mode.
What Is a Random Number Generator?
A random number generator (RNG) produces sequences of numbers that lack any predictable pattern. This tool uses a seeded Linear Congruential Generator (LCG) — a fast, deterministic pseudo-random algorithm used in programming languages and simulation software worldwide. It supports three distinct statistical distributions for different use cases.
How to Use This Generator
- 1Choose a DistributionInteger for whole numbers, Float for decimals spread uniformly across a range, Normal for bell-curve distributed values.
- 2Set Count & RangeEnter how many numbers to generate (up to 10,000) and the minimum/maximum bounds. For Normal mode, set the mean and standard deviation instead.
- 3Configure OptionsChoose decimal places (float mode), a sort order, and whether duplicates are allowed (integer mode). Toggle a fixed seed for reproducible output.
- 4Generate & CopyClick Generate Numbers. Results appear instantly with all values displayed as chips. Click Copy All to grab the full list as a comma-separated string.
- 5Review StatisticsA statistics panel shows count, min, max, sum, mean, median, standard deviation, and mode — instantly useful for data analysis.
How the Distributions Work
Integer (Uniform Discrete)
Each integer in the range [min, max] has an equal probability of being selected. Formula: value = min + floor(rng() × (max − min + 1))
Example: Rolling a standard die — 6 integers [1, 6], each with exactly 1/6 probability.
Uniform Float (Continuous)
Every value in [min, max) is equally likely. Used in probability simulations and Monte Carlo integration. Formula: value = min + rng() × (max − min)
Normal / Gaussian Distribution
Uses the Box-Muller transform to convert two uniform random numbers into normally-distributed values. The result clusters around the mean (μ) with spread controlled by standard deviation (σ).
68% of values fall within μ ± 1σ | 95% within μ ± 2σ | 99.7% within μ ± 3σ
Worked Examples
① Lottery Quick Pick — 6 unique integers from 1 to 49
Settings: Distribution = Integer, Count = 6, Min = 1, Max = 49, No duplicates = ✓, Sort = Ascending
② Monte Carlo π Estimation
Generate pairs of uniform floats in [0, 1] and check if x² + y² ≤ 1 (inside the unit circle). The ratio of interior points × 4 approximates π. With 10,000 pairs this typically gives π ≈ 3.14 ± 0.01.
③ Simulate Test Scores — Normal distribution μ=70, σ=12
Settings: Distribution = Normal, Count = 100, Mean = 70, Std Dev = 12. Expected result: ~68 scores between 58–82, ~95 between 46–94, mean ≈ 70.
Frequently Asked Questions
Related Tools
Related Tools
Mean Calculator
Calculate all six types of mean simultaneously — Arithmetic, Geometric, Harmonic, Quadratic (RMS), Weighted, and Trimmed. Paste any dataset and instantly get the right average for your context, plus median, mode, standard deviation, variance, and coefficient of variation.
Median Calculator
Find the median of any dataset instantly, with quartiles (Q1, Q3), IQR, five-number summary, interactive box plot, outlier detection using Tukey fences, percentile table, MAD, and Pearson skewness. Robust central tendency analysis for statistics, data science, and research.
Mode Calculator
Find the mode(s) of any dataset with a complete frequency distribution table, visual bar chart, and automatic distribution type classification — unimodal, bimodal, multimodal, or amodal. Ideal for statistics, data science, surveys, and educational analysis.