Mean values and variances of the digits of 1/p
Pith reviewed 2026-06-30 05:29 UTC · model grok-4.3
The pith
The variance of digits in the base-b expansion of 1/p admits closed-form expressions in Dedekind sums, class numbers, and generalized Bernoulli numbers when the period length equals (p-1)/2^m for m at least 1.
A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.
Core claim
For a prime p not dividing b, when the period length l equals (p-1)/2^m with m at least 1, both the mean value and the variance of the digits in one full period of the base-b expansion of 1/p are given by explicit formulas involving Dedekind sums, class numbers of imaginary quadratic fields, and generalized Bernoulli numbers.
What carries the argument
Closed-form expressions for the variance of the digit sum over a full period, obtained by reducing the sum via the order l = (p-1)/2^m to combinations of Dedekind sums and class-number terms.
If this is right
- The earlier results for full period l = p-1 and for l = (p-1)/2 become immediate special cases of the new theory.
- Exact variances become computable for any prime whose order is (p-1) divided by a power of two, without enumerating the digits.
- The same arithmetic invariants control both the mean and the variance across this family of periods.
- The approach supplies a uniform method that works uniformly for all m at least 1.
Where Pith is reading between the lines
- The method may extend to other proper divisors of p-1 that are not powers of two.
- Closed forms of this type could be used to test conjectures on the statistical uniformity of digits for primes with restricted orders.
- Links between digit variances and class numbers might produce new relations between quadratic fields and base-b expansions.
Load-bearing premise
The variance of the digits admits closed-form expressions in terms of Dedekind sums, class numbers of imaginary quadratic fields, and generalized Bernoulli numbers when the multiplicative order l equals (p-1)/2^m.
What would settle it
Pick a prime p such as 41 where (p-1)/4 = 10, fix base b=10, compute the exact variance of the ten digits in one period of 1/41 by direct addition, and compare the numerical value against the closed-form prediction from the Dedekind-sum expression.
read the original abstract
Let $p\ge 3$ be a prime and $b\ge 2$ an integer such that $p$ does not divide $b$. Then $1/p$ has a periodic digit expansion with respect to the basis $b$. The length $l$ of the period is the (multiplicative) order of $b$ mod $p$. In the cases $l=p-1$ and $l=(p-1)/2$, formulas for the variance of the digits of a period were given previously. These formulas involved Dedekind sums, class numbers of imaginary quadratic number fields, and generalized Bernoulli numbers. In the present paper we develop a theory of this kind for $l=(p-1)/2^m$, $m\ge 1$, which covers the special case $l=(p-1)/2$.
Editorial analysis
A structured set of objections, weighed in public.
Referee Report
Summary. The paper extends prior results on the mean and variance of digits in the base-b expansion of 1/p (p prime, b not divisible by p) to the case where the multiplicative order l of b modulo p equals (p-1)/2^m for integers m ≥ 1. It derives closed-form expressions for these quantities in terms of Dedekind sums, class numbers of imaginary quadratic fields, and generalized Bernoulli numbers, thereby covering and generalizing the previously treated cases l = p-1 and l = (p-1)/2.
Significance. If the derivations are correct, the work supplies a uniform number-theoretic framework for digit statistics over an infinite family of periods indexed by powers of 2. This strengthens the connection between periodic digit expansions and classical objects (Dedekind sums, class numbers, Bernoulli numbers) and may enable explicit computations or further arithmetic applications for these special periods.
minor comments (2)
- [Abstract] The abstract states that formulas 'were given previously' for l = p-1 and l = (p-1)/2 but does not cite the specific references; adding these citations would improve context.
- [Introduction] Notation for the generalized Bernoulli numbers and the precise range of m should be introduced explicitly in the introduction to avoid any ambiguity for readers unfamiliar with the prior literature.
Simulated Author's Rebuttal
We thank the referee for their positive report and recommendation to accept the manuscript. We are pleased that the work is viewed as providing a uniform framework connecting digit statistics to classical arithmetic objects.
Circularity Check
No significant circularity; derivation uses independent number-theoretic objects
full rationale
The abstract states that closed-form expressions for mean values and variances are developed in terms of Dedekind sums, class numbers of imaginary quadratic fields, and generalized Bernoulli numbers for the period length l=(p-1)/2^m. These are standard, externally defined objects in number theory. The paper extends prior formulas for l=p-1 and l=(p-1)/2 without any indication that the target quantities are fitted parameters, self-defined, or reduced by construction to the inputs. No load-bearing self-citation chain or ansatz smuggling is exhibited in the given text. The derivation chain is self-contained against external benchmarks.
Axiom & Free-Parameter Ledger
Reference graph
Works this paper leans on
-
[1]
M., Introduction to Analytic Number Theory
Apostol, T. M., Introduction to Analytic Number Theory. New York, 1976
1976
-
[2]
Chakraborty, K., Krishnamoorthy, K., On some symmetries of the basenexpansion of 1/m: the class number connection, Pacific J. Math. 319, 39–53 (2022)
2022
-
[3]
D., Kulisch, U., Liedl, R
Girstmair, K., Periodische Dezimalbr¨ uche – was nicht jeder dar¨ uber weiß, in: Beu- telspacher, A., Chatterji, S. D., Kulisch, U., Liedl, R. (eds.) Jahrbuch ¨Uberblicke Mathematik 1995, 163–179, Braunschweig, 1995. 9
1995
-
[4]
Number Th
Girstmair, K., Digit variance and Dedekind sums, J. Number Th. 65, 197–205 (1997)
1997
-
[5]
Girstmair, K., On the variance of the digits of 1/p, Ramanujan J. 70, Art. 27 (2026)
2026
-
[6]
Hirabayashi, M., Generalizations of Girstmair’s formula, Abh. Math. Sem. Univ. Hamburg 75, 83–95 (2005)
2005
-
[7]
208, 215–233 (2023)
Mizuno, Y., A certain character twisted average value of the digits of rational num- bers and the class numbers of imaginary quadratic fields, Acta Arith. 208, 215–233 (2023)
2023
-
[8]
Moree, P., Near-primitive roots, Funct. Approx. Comment. Math. 48, 133–145 (2013)
2013
-
[9]
R., Thangadurai, R., The class number ofQ( √−p) and digits of 1/p, Proc
Murty, M. R., Thangadurai, R., The class number ofQ( √−p) and digits of 1/p, Proc. Amer. Math. Soc. 139, 1277–1289 (2011)
2011
-
[10]
Pujahari, S., Saikia, N.,l-adic digits and class numbers of imaginary quadratic fields, Internat. J. Math. 35, Paper No. 2450041, 16 pp. (2024)
2024
-
[11]
Mathematical Association of America, 1972
Rademacher, H., Grosswald, E., Dedekind Sums. Mathematical Association of America, 1972
1972
-
[12]
71, 273–278 (1995)
Szmidt, J., Urbanowicz, J., Zagier, D., Congruences among generalized Bernoulli numbers, Acta Arith. 71, 273–278 (1995). Institut f¨ ur Mathematik Universit¨ at Innsbruck Technikerstr. 13/7 A-6020 Innsbruck, Austria Kurt.Girstmair@uibk.ac.at 10
1995
discussion (0)
Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.