Experiments Gallery¶
A compact, image-first overview of the experiments in py-mathx-lab.
E001: Taylor error landscapes
Truncation error, convergence behavior, and error landscapes for Taylor approximations.
E002: Perfect numbers
Explore perfect numbers via the sum-of-divisors function and the Euclid–Euler characterization.
E003: Abundancy index
Study the abundancy index $\sigma(n)/n$ and how it separates number classes.
E004: Sum-of-divisors (sigma)
Compute $\sigma(n)$, test multiplicativity, and explore divisor-sum structure.
E005: Odd perfect numbers
Constraints, known results, and computational checks related to odd perfect numbers.
E006: Near-perfect numbers
Definitions, examples, and experiments around near-perfect (and related) integers.
E007: Mersenne growth
Bits and digits of Mn = 2n − 1: fast size estimates for planning feasible bounds.
E008: Lucas–Lehmer scan
Scan prime exponents with the Lucas–Lehmer test and visualize scaling and outcomes.
E009: Small-factor scan
Pre-sieve Mp candidates by finding small structured factors before expensive primality tests.
E010: Perfect numbers from Mersenne primes
Generate even perfect numbers via Euclid–Euler and visualize growth and validation checks.
E011: Heuristic rarity
Compare observed Mersenne-prime counts to a simple heuristic expectation curve.
E012: Fermat pseudoprimes and Carmichael numbers (counterexamples)
Counterexamples to naive Fermat primality testing: base-a pseudoprimes and Carmichael numbers.
E013: Prime-polynomial counterexamples (Euler's n^2 + n + 41)
Turn “prime-generating polynomials” folklore into a crisp counterexample (Euler’s n²+n+41).
E014: Primorial ± 1 counterexamples
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E015: Wilson test infeasibility
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E016: Trial division vs. Miller–Rabin scaling
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E017: Sieve memory blow-up vs. segmented sieve
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E018: Miller–Rabin base choice counterexamples
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E019: Prime density and pnt visualization
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E020: Compare pi(x) to li-x numerically
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E021: Explicit bounds sanity checks
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E022: Prime race modulo 4
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E023: Residue class distribution mod q
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E024: Ulam spiral structure
Render an Ulam spiral and highlight primes on the spiral grid to make diagonal structure (prime-rich diagonals) visible, then compare how that structure changes as the spiral size increases.
E025: Prime gaps are not monotone
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E026: Normalized prime gaps
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E027: Record prime gaps vs. log^2 heuristic
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E028: Jumping champions (most frequent gaps)
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E029: Twin primes: observed vs. heuristic
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E030: Cousin and sexy prime pairs
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E031: Admissibility and modular obstructions
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E032: Prime triplets and quadruplets
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E033: Bounded gaps vs. twin primes (not the same)
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E034: Twin primes in sliding windows
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E035: Primes in arithmetic progressions mod q
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E036: Prime arithmetic progressions (small search)
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E037: Prime-free intervals via factorial construction
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E038: Bertrand's postulate (computational verification)
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E039: Sophie Germain and safe primes
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E040: Palindromic primes and the '11 trap'
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E041: Fermat numbers: not all prime
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E042: Repunit primes (small k scan)
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E043: Pollard rho runtime variability
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E044: Solovay–Strassen vs. Miller–Rabin (liars)
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E045: Deterministic 64-bit MR base sets
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E046: Prime-testing pipeline and tuning pitfalls
This is a thin wrapper that follows the standard experiment template and delegates the actual computation to…
E047: Fermat numbers: Pépin test + factor witnesses
Pépin test classification and bounded factor search, showing the classic counterexample at F₅.
E048: Carmichael numbers: Korselt scan
Enumerate 3-prime-factor Carmichael numbers via Korselt’s criterion and verify Fermat-test failure modes.
E049: Wieferich primes: scan up to a bound
Search for base-2 Wieferich primes and visualize the quotient-like distribution; recovers 1093 and 3511 under default bounds.
E050: Primorials: Euclid numbers p# ± 1
Compute primorial ± 1 and show they are usually composite; produce small factor witnesses for early k.
E051: Semiprimes: balanced vs. unbalanced factoring
Generate small semiprimes and compare Pollard-rho factorization timings for balanced vs. unbalanced cases.
E052: Totient ratio landscape
Visual structure in \varphi(n)/n and primorial effects
E053: Inverse totient multiplicities
How often does a value occur as \varphi(n)?
E054: Squarefree density via Möbius
Estimate the squarefree density using \mu(n)^2
E055: Mertens function walk
Summatory Möbius M(x)=\sum_{n\le x}\mu(n) as a random-walk-like object
E056: Liouville vs. Möbius walks
Compare summatory \lambda(n) and \mu(n)
E057: Erdős–Kac in practice
Histogram of \Omega(n) and normal approximation
E058: Divisor-count record highs
Record values of \tau(n) and highly composite behavior
E059: Abundancy index landscape
Plot \sigma(n)/n and connect to perfect / abundant numbers
E060: Jordan totients
Normalize J_k(n) by n^k for small k
E061: Chebyshev ψ(x) and prime powers
Compute \psi(x)=\sum_{n\le x}\Lambda(n) and compare to x
E062: Carmichael λ(n) vs. φ(n)
Compare λ(n) and φ(n) via ratios and distributions
E063: Dirichlet convolution playground
Validate classic identities like \mu*1=\varepsilon and \mu*\mathrm{id}=\varphi
E064: Dirichlet character tables (phase view)
Enumerate Dirichlet characters modulo a small q and visualize character values on residues a=0..q-1.
E065: Orthogonality matrix for Dirichlet characters
Compute the character inner-product matrix modulo q and visualize orthogonality errors.
E066: Character partial sums: cancellation profiles
Study partial sums S(N)=sum_{n<=N} chi(n) and measure maximum growth for small moduli.
E067: Gauss sums: magnitude vs. sqrt(q)
Compute Gauss sums for characters modulo q and compare magnitudes to sqrt(q).
E068: Dirichlet L(s,chi): series vs. Euler product
For Re(s)>1, compare partial Dirichlet series and partial Euler products for L(s,chi).
E069: L(1,chi): slow convergence and smoothing
Investigate slow convergence near s=1 and compare naive partial sums to smoothed/accelerated variants.
E070: Primes in residue classes: pi(x; q, a)
Count primes in selected reduced residue classes modulo q and compare class-to-class differences.
E071: PNT(AP) numerics: pi(x;q,a) minus Li(x)/phi(q)
Compare prime counts in arithmetic progressions to the PNT(AP) main term Li(x)/phi(q).
E072: Prime race mod 4: pi(x;4,3) vs. pi(x;4,1)
Track the classic mod-4 prime race and visualize the running lead and sign changes.
E073: Prime race mod 3: pi(x;3,2) vs. pi(x;3,1)
Compare the two reduced residue classes modulo 3 and study lead changes over x.
E074: Prime race mod 8: leaderboard among 1,3,5,7
Track four residue classes modulo 8 and visualize which class leads most often.
E075: Prime race statistic: distribution on a log-grid
Study a normalized race statistic on a log-grid and compare its empirical distribution to heuristics.
E076: Chebyshev theta(x;q,a): weighted prime counts
Compute theta(x;q,a) for residue classes and compare growth and fluctuations across classes.
E077: Indicator via character orthogonality (sanity check)
Use character orthogonality to express an indicator of a residue class and verify numerically.
E078: Max partial sums across characters
For each character modulo q, compute max_{1<=N<=Nmax} |S(N)| and compare across the character table.
E079: Primitive vs. imprimitive characters: conductors
Classify characters by conductor (smallest modulus they factor through) and visualize primitive vs. imprimitive structure.
E080: Chebyshev bias: leader fraction vs. x
For a prime race difference D(x), compute the fraction of x where D(x)>0 and visualize bias as x grows.
E081: Prime race sign changes: first crossings table
Track sign changes of a prime race difference D(x) and record early crossing points in a compact table.
E082: Zeta(s) series convergence
Compare partial sums of the Dirichlet series for ζ(s) across regions of the complex plane.
E083: Series vs. Euler product (ζ)
Numerically compare ζ(s) via truncated Dirichlet series versus truncated Euler product.
E084: |ζ(1/2+it)| growth snapshots
Sample magnitudes of ζ(1/2+it) to visualize typical size variations along the critical line.
E085: Dirichlet eta acceleration for ζ(s)
Use the alternating η(s) series to evaluate ζ(s) in Re(s)>0 and compare truncation errors.
E086: Hardy Z(t) near zeros
Plot Hardy’s Z-function around known zeros and inspect local sign changes and oscillations.
E087: Gram points and spacing
Compute Gram points and visualize the spacing and the Gram law heuristic numerically.
E088: Zero counting via Riemann–von Mangoldt
Compare numerical zero counts with the Riemann–von Mangoldt formula across heights.
E089: log|ζ(s)| heatmap
Render a heatmap of log|ζ(s)| over a rectangle to reveal poles, zeros, and ridges.
E090: Functional equation residual heatmap
Heatmap of the functional-equation residual R(s)=ζ(s)-χ(s)ζ(1−s) on a grid.
E091: Partial Euler products on the critical line
Compare ζ(1/2+it) to partial Euler products as the prime cutoff grows.
E092: 1/ζ(s) via the Möbius Dirichlet series
Compare 1/ζ(s) to partial sums Σ_{n≤N} μ(n)/n^s for Re(s)>1.
E093: −ζ′(s)/ζ(s) via the von Mangoldt series
Compare −ζ′(s)/ζ(s) to partial sums Σ_{n≤N} Λ(n)/n^s for Re(s)>1.
E094: ω(n) vs. Ω(n): Erdős–Kac normalization
Compare ω(n) and Ω(n) distributions and their Erdős–Kac normalizations.
E095: Squarefree filter: ω(n)=Ω(n) when μ(n)≠0
Use μ(n) as a squarefree indicator and verify ω(n)=Ω(n) on that subset.
E096: Record-holders for τ(n)
Track running maxima of τ(n) up to N and visualize growth of record values.
E097: σ(n)/n landscape: deficient, perfect, abundant
Visualize σ(n)/n and classify integers using σ(n) compared to 2n.
E098: Maximizers of σ(n)/n^α across α
For α on a grid, find n≤N maximizing σ(n)/n^α and show regime changes.
E099: Jordan totients J_k: identities and ratios
Compute J_k(n), verify J_1=φ, and visualize ratios J_k(n)/n^k.
E100: Carmichael λ(n) vs. Euler φ(n)
Compare λ(n) and φ(n) and visualize λ(n)/φ(n) over a finite range.
E101: Reduced residues modulo q: concrete structure
List reduced residues mod q, verify count=φ(q), and summarize simple structure checks.
E102: Dirichlet convolution identity zoo
Verify classic convolution identities numerically on 1..N (μ*1=ε, φ*1=id, 1*1=τ).
E103: Chebyshev ψ(x): prime powers drive jumps
Plot ψ(x) and highlight jump contributions coming from prime powers.
E104: von Mangoldt Λ(n): support and statistics
Visualize where Λ(n) is nonzero (prime powers) and summarize basic statistics.
E105: Mertens M(x): scaling views
Plot M(x)=∑_{n≤x} μ(n) and rescalings such as M(x)/√x.
E106: Character gallery: real vs. complex
Compare value-sets of Dirichlet characters and count real-valued characters.
E107: Conductor: primitive vs. induced characters
Compute conductors and separate primitive from imprimitive characters.
E108: Orthogonality heatmap for characters
Visualize orthogonality relations via inner-product matrices.
E109: Gauss sums: magnitude patterns
Compute Gauss sums τ(χ) and compare |τ(χ)| to √q.
E110: Dirichlet L-series partial sums at s=1 and s=1/2
Compare partial Dirichlet series behavior near s=1 and on the critical line.
E111: Euler product vs. Dirichlet series for L(s,χ)
Compare truncated Euler products and truncated series for L(s,χ).
E112: Prime race: π(x;q,a) − π(x;q,b)
Compute prime counts in residue classes and plot difference curves for representative pairs.
E113: First prime in each residue class
For each reduced residue a (mod q), find the smallest prime p≡a (mod q) and visualize results.
E114: ζ via η: stability map on the critical line
Study stability of ζ(1/2+it) via η-acceleration under truncation changes.
E115: Hardy Z: sign changes and zero bracketing
Scan Hardy Z(t), bracket sign changes, and visualize candidate zeros.
E116: Gram points and zero-counting heuristics
Compare Gram-point heuristics and simple zero-counting diagnostics over a finite range.
E117: Prime-counting approximations: li(x) and friends
Compare π(x) to li(x) and related approximations and visualize signed error.
E118: Chebyshev bias: lead-time statistics
Measure how often one residue class leads another and visualize lead-time statistics.
E119: Summatory totient Φ(x) scaling check
Plot Φ(x)=∑_{n≤x} φ(n) and compare to the main-term scaling 3x²/π².
E120: Liouville λ(n): partial sums and parity
Explore partial sums of the Liouville function and simple parity correlations.
E121: Möbius inversion as convolution undo
Recover a function from its Dirichlet convolution with 1 via Möbius inversion.
E122: Character averages over primes
Average χ(p) over primes in arithmetic progressions and compare to equidistribution heuristics.
E123: π(x;q,a) vs. a simple baseline
Compare π(x;q,a) to a baseline x/(φ(q) log x) and visualize deviations.
E124: Klauber triangle
Rows between consecutive squares; highlight primes to reveal vertical streaks.
E125: Sacks spiral
Polar spiral r=√n, θ=2π√n; primes plotted as points often form dense spiral fragments.
E126: Hexagonal number spiral
Centered hex-grid spiral; plot primes only to explore lattice-aligned structure.
E127: Quadratic prime-run atlas
Heatmap of initial prime-run lengths for f(n)=n^2+an+b over a small coefficient grid.
E128: Quadratic modular obstructions
Roots of f(n)≡0 (mod p) for small primes p; explains why prime streaks must fail.
E129: Euler lucky constants
Compare n^2+n+b for classical 'lucky' b; visualize prime indicators and streak lengths.