Casino Tools
RNG Fairness Checker
Inputs
Results
Fairness
Pass
Z-Score
-1.26
How to use RNG Fairness Checker
The RNG Fairness Checker is a one-proportion z-test in gambling clothes. Three inputs: Samples n (default 1000), Expected Hits (default 500), Actual Hits (default 480). It sets p = expected/n, variance = n p (1−p), z = (actual − expected) / √variance, and declares Fairness Pass if |z| < 1.96 and Review otherwise. That 1.96 is the two-sided 5% normal critical value, the 95% interval everyone memorizes. On the defaults, p = 500/1000 = 0.5, √(1000×0.5×0.5) = √250 ≈ 15.8114, z = (480−500)/15.8114 ≈ −1.26, printed −1.26, |z| < 1.96, Pass.
Twenty fewer hits than a fair 50/50 in a thousand trials is ordinary noise. Move Actual to 450: z = −50/15.8114 ≈ −3.16, Review. Move Actual to 500: z = 0, Pass. If Expected is 100 in 1000 (a 10% event), p = 0.1, √(1000×0.1×0.9) = √90 ≈ 9.487, actual 80 → z ≈ −2.11, Review. The same 20-hit deficit that passed at p = 0.5 fails at p = 0.1 because the null variance is smaller.
The label is Fairness, not Proof of RNG quality. A Pass means this one binomial count is compatible with the stated p at 5%. It is not a cryptographic audit, not a DIEHARD/TestU01 battery, not a lab certification, and not a test of independence between trials. A bent wheel can pass a one-cell z-test on a quiet number. A broken generator that repeats a cycle of length 1000 might still hit 480.
Expected Hits is the null mean, not a wish. If you do not have a theoretical p, do not invent 500. For a European roulette number in 1000 spins, expected is 1000/37 ≈ 27.03; type that, not 500. The default 500/1000 is a fair coin, the same model as the coin-toss calculator, now in z-score form.
Read z with the Pass/Review word. z = −1.26 is “about one and a quarter standard deviations low,” which happens. z = −4 is a red flag or a wrong null, not a licence to allege fraud without a protocol.
About this calculator
Testing whether a count of hits matches a claimed probability is older than electronic RNGs. Pearson’s chi-square (1900) and the later Neyman–Pearson lemma framed hypothesis tests for frequencies. The one-proportion z-test is the normal approximation to a single binomial cell, the same approximation de Moivre used on coins. Gambling regulators certify RNGs with far heavier batteries (NIST, TestU01, Dieharder) plus source-code review and sealing of hardware. This page is the classroom z, useful for a single advertised p and a single count.
Why ship it? Because players collect “480 reds in 1000 spins” and want a number. The honest number is z ≈ −1.26, Pass at 5%. The dishonest number is a forum post that 480 “proves” a bent wheel. SorteCalc prints z and a Pass/Review threshold so the 1.96 line is visible. Review is not Fail-the-casino; it is “this sample is in the 5% tails under the null you typed.” Type the wrong expected hits and you test the wrong null.
Electronic gambling RNGs are typically cryptographic or at least hardware-seeded PRNGs under lab test. A z-test on 1000 rounds does not touch period length, modular bias, or seed control. Live wheels and cards are physical; their “RNG” is chaotic dynamics plus a lab inspection. Poincaré’s roulette mixing argument is the physical cousin of a statistical test: you need many spins and a model. 1000 samples at p = 0.5 is a decent z-test and a pathetic crypto audit.
Limits: one cell, two-sided 5%, normal approximation, independent Bernoulli trials under the null, no multiple-testing across 37 numbers or across nights. If you test 20 tables, one Review is expected at 5%. Bonferroni or a chi-square on the full vector is the fix; not implemented. Continuity correction (Yates) is not applied; at n = 1000 it barely moves z.
Use it as a sanity filter on a single proportion. Pair with the coin-toss exact binomial if n is small and p = 0.5. Do not file a regulator complaint on z = −1.26. Pearson and Neyman gave you a language for surprise. They did not give you a verdict from 480 versus 500.
Math under the hood
A lecture on how to test a single count against a claimed mean is a one-proportion normal test, not a cryptographic audit. Samples n = 1000, expected hits 500, actual hits 480. The implied success chance is 500/1000 = 0.5. Variance is n p (1 − p) = 250, so the standard deviation is the square root of 250 ≈ 15.8114. The standardized residual is z = (480 − 500) / √250 ≈ −1.26. Fairness is Pass if the absolute value of z is less than 1.96, the two-sided 5 percent normal critical value, and Review otherwise. Absolute 1.26 is less than 1.96, so Pass. Twenty fewer hits than a fair half in a thousand trials is ordinary noise.
Move actual to 450 and z ≈ −3.16, Review. Move actual to 500 and z = 0, Pass. The same 20-hit deficit that passed at p = 0.5 fails at p = 0.1: expected 100 in 1000, variance 90, square root about 9.49, actual 80 gives z ≈ −2.11. The null variance is smaller, so the same gap is more surprising. Pearson’s chi-square for one cell versus its complement is z squared: about 1.60 on one degree of freedom, the same test. A full roulette chi-square would sum 37 cells; this page never does that. Continuity correction is not applied; at n = 1000 it barely moves z.
Abraham de Moivre and Laplace supplied the normal approximation to a binomial count, the de Moivre–Laplace theorem. Pearson in 1900 framed chi-square tests of frequencies. Neyman and Pearson later gave the language of Type I error that 1.96 marks as a threshold. Gambling laboratories certify generators with far heavier batteries — NIST suites, TestU01, Dieharder — plus source review. This page is not DIEHARD. A Pass means this one count is compatible with the stated mean at 5 percent. It is not a proof of quality, not a test of independence, not a period-length audit. A bent wheel can pass a one-cell test on a quiet number. A broken generator that repeats a cycle of length 1000 might still hit 480.
Assumptions: independent trials, correct p, two-sided 5 percent, no look-elsewhere. If you test 20 tables, one Review is expected at 5 percent. For a European roulette number in 1000 spins, expected is 1000/37 ≈ 27.03; type that, not 500. The default 500/1000 is a fair coin, the same model as the coin-toss lecture, now in z-score form. Exact two-sided chance of a 20-hit gap under 1000 trials at one half is about 0.21, far from 0.05 — consistent with Pass. Normal approximation quality wants n p and n (1 − p) of several tens; 500 and 500 are excellent. Do not file a complaint on z = −1.26. Pearson and Neyman gave you a language for surprise, not a verdict from 480 versus 500.