An Equidistribution Result for Differences Associated with Square Pyramidal Numbers
Anji Dong, Katerina Saettone, Kendra Song, Alexandru Zaharescu
TL;DR
The paper studies the sequence $a_n=|P_n-y_n^2|$ where $P_n$ is the $n$-th square pyramidal number and $y_n$ is the nearest square, aiming to quantify its average behavior and higher moments. By combining Weyl-type uniform distribution results for $\sqrt{P_n}$, exponential-sum bounds, and discrepancy estimates, the authors establish that $a_n$ is equidistributed in $[0,1/2]$ and derive precise asymptotics for the average $A(x)=\frac{1}{x}\sum_{n\le x} a_n$ and the $k$-th moments $M_k(x)=\sum_{n\le x} a_n^k$. The main contributions are the explicit asymptotics $A(x)=\frac{1}{5\sqrt{3}} x^{3/2}+O(x^{17/12})$ and, for fixed $k$, $M_k(x)=\frac{x^{\frac{3}{2}k+1}}{3^{k/2}(\frac{3}{2}k+1)(k+1)}+O_k\left(x^{\frac{3}{2}k+\frac{11}{12}}\right)$, obtained through a refined decomposition $a_n=|\sqrt{P_n}-y_n|\,|\sqrt{P_n}+y_n|$ and optimization of auxiliary parameters. These results advance quantitative understanding of the Cannonball problem related sequences and provide precise average-distance and moment information for the nearest-square distance to square pyramidal numbers.
Abstract
We provide an asymptotic formula for the average value of the sequence A351830: $a_{n} = |P_{n} - y^{2}_{n}|$ for $1 \leq n \leq x$, where $P_{n}$ is the $n$-th square pyramidal number and $y^{2}_{n}$ is the closest square to $P_{n}$. Moreover, we supply asymptotic formulas for the $k$-th moment of the same sequence, for any fixed natural number $k$.
