# Large Weyl sums and Hausdorff dimension

Roger C. Baker  Department of Mathematics, Brigham Young University, Provo, UT
84602, USA<EMAIL_ADDRESS>,  Changhao Chen  Center for Pure Mathematics,
School of Mathematical Sciences, Anhui University, Hefei 230601, China
<EMAIL_ADDRESS>and  Igor E. Shparlinski  Department of Pure Mathematics,
University of New South Wales, Sydney, NSW 2052, Australia
<EMAIL_ADDRESS>
###### Abstract.

We obtain the exact value of the Hausdorff dimension of the set of
coefficients of Gauss sums which for a given $\alpha\in(1/2,1)$ achieve the
order at least $N^{\alpha}$ for infinitely many sum lengths $N$. For Weyl sums
with polynomials of degree $d\geqslant 3$ we obtain a new upper bound on the
Hausdorff dimension of the set of polynomial coefficients corresponding to
large values of Weyl sums. Our methods also work for monomial sums, match the
previously known lower bounds, just giving exact value for the corresponding
Hausdorff dimension when $\alpha$ is close to $1$. We also obtain a nearly
tight bound in a similar question with arbitrary integer sequences of
polynomial growth.

###### Key words and phrases:

Weyl sum, Hausdorff dimension

###### 2010 Mathematics Subject Classification:

11L15, 11K55

###### Contents

  1. 1 Introduction
    1. 1.1 Set-up and motivation
    2. 1.2 New results and methods
    3. 1.3 Notation
  2. 2 Results for sets of very large sums
    1. 2.1 Multiparametric families of Gauss sums and Weyl sums
    2. 2.2 One parametric families of Weyl sums with real polynomials
    3. 2.3 Comparison
    4. 2.4 Ideas behind the proofs
  3. 3 Results for sets of exponential sums of arbitrary size
    1. 3.1 One parametric families of Weyl sums with integer polynomials
    2. 3.2 One parametric families of exponential sums with arbitrary sequences
    3. 3.3 Comparison
    4. 3.4 Ideas behind the proofs
  4. 4 Frostman Lemma and Gál–Koksma Theorem
    1. 4.1 Frostman Lemma
    2. 4.2 Gál–Koksma Theorem
  5. 5 Bounds of Gauss sums and Weyl sums
    1. 5.1 Structure of large Gauss sums
    2. 5.2 Frequency of large Gauss sums
    3. 5.3 Bounds of Weyl sums
  6. 6 Proof of the upper bound of Theorem 2.1
    1. 6.1 Mean values of Gauss sums
    2. 6.2 Concluding the proof
  7. 7 Proof of the lower bound of Theorem 2.1
    1. 7.1 Large values of Gauss sums
    2. 7.2 Simultaneous Diophantine approximations
  8. 8 Proof of Theorem 2.2
    1. 8.1 Mean values of Weyl sums
    2. 8.2 Concluding the proof
  9. 9 Proof of Theorem 2.3
    1. 9.1 One-dimensional mean values of Weyl sums
    2. 9.2 Concluding the proof
  10. 10 Proofs of Theorems 3.1, 3.3, 3.4, 3.5 and 3.6
    1. 10.1 Mean values of exponential polynomials
    2. 10.2 Continuity of exponential polynomials
    3. 10.3 Mean values and Hausdorff dimension for polynomially growing sequences
    4. 10.4 Concluding the proofs
  11. 11 Proofs of Theorems 3.7 and 3.8
    1. 11.1 Proof of Theorem 3.7
    2. 11.2 Proof of Theorem 3.8
  12. 12 Proof of Theorem 3.9
    1. 12.1 Preliminaries
    2. 12.2 Concluding the proof

##  1\. Introduction

###  1.1. Set-up and motivation

For $\mathbf{x}=(x_{1},\ldots,x_{d})\in\mathsf{T}_{d}$ where

$\mathsf{T}_{d}=[0,1]^{d}$

is the $d$-dimensional unit cube, we define the Weyl sums of length $N$ as

$S_{d}(\mathbf{x};N)=\sum_{n=1}^{N}{\mathbf{\,e}}\left(x_{1}n+\ldots+x_{d}n^{d}\right)$

where ${\mathbf{\,e}}(z)=\exp(2\pi iz)$. These sums were originally introduced
by Weyl to study equidistribution of fractional parts of polynomials and later
find their applications to the circle method and Riemann zeta function.

For many applications of Weyl sums, the key problem is to estimate the size of
the sum $S_{d}(\mathbf{x};N)$. There are often three kinds of estimates of
Weyl sums, namely individual bounds, mean value bounds and almost all bounds.
Despite more than a century since these sums were introduced, their behaviour
for individual values of $\mathbf{x}$ is not well understood, see [10, 11,
32].

Much more is known about the average behaviour of $S_{d}(\mathbf{x};N)$. The
recent advances of Bourgain, Demeter and Guth [9] (for $d\geqslant 4$) and
Wooley [39] (for $d=3$) (see also [40]) towards the optimal form Vinogradov
mean value theorem imply the estimate

$N^{s(d)}\leqslant\int_{\mathsf{T}_{d}}|S_{d}(\mathbf{x};N)|^{2s(d)}d\mathbf{x}\leqslant
N^{s(d)+o(1)},$

where

$s(d)=d(d+1)/2$

and is best possible up to $o(1)$ in the exponent of $N$.

We study exceptional sets of $\mathbf{x}\in\mathsf{T}_{d}$, which generate
abnormally large Weyl sums $S_{d}(\mathbf{x};N)$.

The first results concerning the almost all behaviour of Weyl sums are due to
Hardy and Littlewood [27] who have estimated the following special sums

$\mathsf{G}(x,N)=\sum_{n=1}^{N}{\mathbf{\,e}}\left(xn^{2}\right),$

in terms of the continued fraction expansion of $x$. Among other things Hardy
and Littlewood [27] proved that for almost all $x\in\mathsf{T}$,

$\left|\mathsf{G}(x,N)\right|\leqslant N^{1/2+o(1)},\quad\text{as}\quad
N\rightarrow\infty.$

Their idea has been expanded upon by Fiedler, Jurkat and Körner [25, Theorem
2] who give the following optimal lower and upper bounds. Suppose that
$\\{f(n)\\}_{n=1}^{\infty}$ is a non-decreasing sequence of positive numbers.
Then for almost all $x\in\mathsf{T}$ one has

(1.1)
$\operatorname*{\overline{lim}}_{N\rightarrow\infty}\frac{|\mathsf{G}(x,N)|}{\sqrt{N}f(N)}<\infty\quad\Longleftrightarrow\quad\sum_{n=1}^{\infty}\frac{1}{nf(n)^{4}}<\infty.$

For the sums $S_{2}(\mathbf{x};N)$, $\mathbf{x}\in\mathsf{T}_{2}$, Fedotov and
Klopp [24] have given a similar result, however adding the term
${\mathbf{\,e}}(x_{1}n)$ leads to more cancellations in the sums
$S_{2}(\mathbf{x};N)$. Suppose that $\\{g(n)\\}_{n=1}^{\infty}$ is a non-
decreasing sequence of positive numbers. Then for almost all
$\mathbf{x}\in\mathsf{T}_{2}$ one has

(1.2)
$\operatorname*{\overline{lim}}_{N\rightarrow\infty}\frac{\left|S_{2}(\mathbf{x};N)\right|}{\sqrt{N}g(\ln
N)}<\infty\quad\Longleftrightarrow\quad\sum_{n=1}^{\infty}\frac{1}{g(n)^{6}}<\infty.$

It is natural to expect that analogues of (1.1), (1.2) hold for Weyl sums
$S_{d}(\mathbf{x};N)$ with any $d\geqslant 3$, however this question seems to
be still open. However, we have the following nearly sharp bounds. For
$d\geqslant 3$, Chen and Shparlinski [14, 16] have shown in two different ways
in [14, Appendix A], and [16, Theorem 2.1] that for almost all
$\mathbf{x}\in\mathsf{T}_{d}$ one has

(1.3) $\left|S_{d}(\mathbf{x};N)\right|\leqslant
N^{1/2+o(1)}\quad\text{as}\quad N\rightarrow\infty.$

Recently, Chen, Kerr, Maynard and Shparlinski [13, Theorem 2.3] have shown
that the exponent $1/2$ is optimal, that is, there exists a constant $c>0$
such that for almost all $\mathbf{x}\in\mathsf{T}_{d}$, the inequality

(1.4) $|S_{d}(\mathbf{x};N)|\geqslant cN^{1/2}$

holds for infinitely many $N$.

This motivates our study of the “the exceptional sets” of Weyl sums.
Precisely, for $1/2<\alpha<1$ define

${\mathcal{E}}_{d,\alpha}=\\{\mathbf{x}\in\mathsf{T}_{d}:\leavevmode\nobreak\
|S_{d}(\mathbf{x};N)|\geqslant N^{\alpha}\text{ for infinitely many
}N\in{\mathbb{N}}\\}.$

Chen and Shparlinski [14, Theorem 1.3] show that for any $d\geqslant 2$ and
$1/2<\alpha<1$ the set ${\mathcal{E}}_{d,\alpha}$ is of second category in the
sense of Baire, and the proof of [14, Theorem 1.3] implies that the set
${\mathcal{E}}_{d,\alpha}$ is a dense subset of $\mathsf{T}_{d}$. Therefore,
the Minkowski dimension (or box dimension) of ${\mathcal{E}}_{d,\alpha}$ is
$d$. See [23] for more details on the Minkowski dimension.

The above results (1.2) and (1.3) imply that ${\mathcal{E}}_{d,\alpha}$ is of
zero Lebesgue measure for all $d\geqslant 2$ and any $\alpha\in(1/2,1)$. For
sets of Lebesgue measure zero, it is common to use the Hausdorff dimension to
describe their size and structure, and we are going to estimate the Hausdorff
dimension of the set ${\mathcal{E}}_{d,\alpha}$ for any $d\geqslant 2$ and any
$\alpha\in(1/2,1)$. We first recall the formal definition of Hausdorff
dimension, and we refer to [23, 33] for more details.

######  Definition 1.1.

The Hausdorff dimension of a set ${\mathcal{F}}\subseteq{\mathbb{R}}^{d}$ is
defined as

$\displaystyle\dim{\mathcal{F}}=\inf\Bigl{\\{}s>0:\leavevmode\nobreak\
\forall\,$ $\displaystyle\varepsilon>0,\leavevmode\nobreak\
\exists\,\\{{\mathcal{U}}_{i}\\}_{i=1}^{\infty},\
{\mathcal{U}}_{i}\subseteq{\mathbb{R}}^{d},$ $\displaystyle\text{such that
}{\mathcal{F}}\subseteq\bigcup_{i=1}^{\infty}{\mathcal{U}}_{i}\text{ and
}\sum_{i=1}^{\infty}\left(\operatorname{diam}{\mathcal{U}}_{i}\right)^{s}<\varepsilon\Bigr{\\}},$

where

$\operatorname{diam}{\mathcal{U}}=\sup\\{\|u-v\|:\leavevmode\nobreak\
u,v\in{\mathcal{U}}\\}$

and $\|w\|$ is the Euclidean norm in ${\mathbb{R}}^{d}$.

We remark that we could also define the set ${\mathcal{E}}_{d,\alpha}$ for
$\alpha\in(0,1/2]$. However, by (1.4) the set ${\mathcal{E}}_{d,\alpha}$ is of
full Lebesgue measure. This, by [17, Theorem 2.5] and the definition of the
Hausdorff dimension, is enough to conclude that

$\dim{\mathcal{E}}_{d,\alpha}=d.$

For an integer $d\geqslant 3$ and real $\alpha\in(1/2,1)$ some explicit upper
and lower bounds on $\dim{\mathcal{E}}_{d,\alpha}$ have been given in [14, 15,
16]. In particular, for any $\alpha\in(1/2,1)$, there are explicit functions
$\mathfrak{l}(d,\alpha),\mathfrak{u}(d,\alpha)$ such that

$0<\mathfrak{l}(d,\alpha)\leqslant\dim{\mathcal{E}}_{d,\alpha}\leqslant\mathfrak{u}(d,\alpha)<d.$

We show more details in the following. For $d\geqslant 2$, let

$\kappa_{d}=\max_{\nu=1,\ldots,d}\min\left\\{\frac{1}{2\nu},\frac{1}{2d-\nu}\right\\}.$

For each $1/2<\alpha<1$ and any cube ${\mathfrak{Q}}\subseteq\mathsf{T}_{d}$
we have the following lower bounds of $\dim{\mathcal{E}}_{d,\alpha}$:

  * (i)

for $d=2$,

$\dim{\mathcal{E}}_{2,\alpha}\cap{\mathfrak{Q}}\geqslant 3(1-\alpha)/2;$

  * (ii)

for $d\geqslant 3$,

$\dim{\mathcal{E}}_{d,\alpha}\cap{\mathfrak{Q}}\geqslant
2\kappa_{d}(1-\alpha).$

For the upper bound of $\dim{\mathcal{E}}_{d,\alpha}$ with $d\geqslant 2$ and
$1/2<\alpha<1$, we have

$\dim{\mathcal{E}}_{d,\alpha}\leqslant\mathfrak{u}(d,\alpha),$

where

$\mathfrak{u}(d,\alpha)=\min_{k=0,\ldots,d-1}\frac{(2d^{2}+4d)(1-\alpha)+k(k+1)}{4-2\alpha+2k}.$

It is not hard to show $\mathfrak{u}(d,\alpha)<d$ for any $\alpha\in(1/2,1)$.

In fact for $\alpha\rightarrow 1$ the behaviour of
$\dim{\mathcal{E}}_{d,\alpha}$ is understood reasonably well as a combination
of the above mentioned lower and upper bounds, implies that there are positive
constants $c_{1}(d),c_{2}(d)$ such that

$c_{1}(d)\leqslant\liminf_{\alpha\rightarrow
1}\,(1-\alpha)^{-1}\dim{\mathcal{E}}_{d,\alpha}\leqslant\limsup_{\alpha\rightarrow
1}\,(1-\alpha)^{-1}\dim{\mathcal{E}}_{d,\alpha}\leqslant c_{2}(d).$

For $\alpha\in(1/2,1)$, some heuristic arguments have been given in [13]
towards the following:

######  Conjecture 1.2.

For any $\alpha\in(1/2,1)$, the set ${\mathcal{E}}_{d,\alpha}$ is of Hausdorff
dimension

$\dim{\mathcal{E}}_{d,\alpha}=\min_{j=1,\ldots,d}\frac{d+1+j\vartheta_{j}-\sum_{i=1}^{j}\vartheta_{i}}{1+\vartheta_{j}},$

where

$\vartheta_{i}=\frac{i}{2(1-\alpha)}-1,\qquad i=1,\ldots,d.$

###  1.2. New results and methods

In this paper, we confirm the Conjecture 1.2 for $d=2$, and we obtain new
upper bounds of $\dim{\mathcal{E}}_{d,\alpha}$ when $d\geqslant 3$ and
$\alpha$ is close to $1$. Moreover, we also consider the following one
parametric family of exponential sums. Namely, for a real sequence $f(n)$,
$n\in{\mathbb{N}}$, $x\in\mathsf{T}$ and $N\in{\mathbb{N}}$ we denote

(1.5) $V_{f}(x;N)=\sum_{n=1}^{N}{\mathbf{\,e}}\left(xf(n)\right).$

Chen and Shparlinski [16, Corollary 2.2] shows that for any polynomial
$f\in{\mathbb{Z}}[X]$ with $\deg f\geqslant 2$ we have for almost all
$x\in\mathsf{T}$,

$\left|V_{f}(x;N)\right|\leqslant N^{1/2+o(1)}\qquad\text{as}\
N\rightarrow\infty.$

Similarly to the definition of ${\mathcal{E}}_{d,\alpha}$, for
$\alpha\in(1/2,1)$ we define the set

${\mathcal{F}}_{f,\alpha}=\\{x\in\mathsf{T}:\leavevmode\nobreak\
|V_{f}(x;N)|\geqslant N^{\alpha}\text{ for infinitely many $N\in{\mathbb{N}}$
}\\}.$

Perhaps the most interesting sums of this type are sums with monomials
$xn^{d}$, in which case we denote this special quantity by
$\mathscr{F}_{d,\alpha}$, that is,

$\mathscr{F}_{d,\alpha}=\left\\{x\in\mathsf{T}:\leavevmode\nobreak\
\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(xn^{d}\right)\right|\geqslant
N^{\alpha}\text{ for infinitely many $N\in{\mathbb{N}}$ }\right\\}.$

Some lower bounds of $\dim\mathscr{F}_{d,\alpha}$ have been obtained in [14,
Theorem 1.7]. In particular, [14, Theorem 1.7] implies that for
$\alpha\in(1/2,1)$

(1.6) $\dim\mathscr{F}_{2,\alpha}\geqslant 2(1-\alpha),$

and for $d\geqslant 3$ and $\alpha\in[d/(d+2),1)$,

(1.7)
$\dim\mathscr{F}_{d,\alpha}\geqslant\left(1+\frac{1}{d}\right)(1-\alpha).$

Some heuristic arguments have been given in [13, Section 8], suggesting that
in a certain range of $\alpha$ we may have

$\dim\mathscr{F}_{d,\alpha}=4(1-\alpha)/d,$

which is consistent with (1.6) and (1.7) for $d=2$ and $d=3$.

Moreover, for $\alpha\in(0,1/2)$ the set $\mathscr{F}_{d,\alpha}$ is of
positive Lebesgue measure (see [13] for more details), and hence,

$\dim\mathscr{F}_{d,\alpha}=1.$

It is very likely that for $f\in{\mathbb{Z}}[X]$ the bounds (1.6) and (1.7)
can be extended to the sets ${\mathcal{F}}_{f,\alpha}$.

To obtain these results we develop two different approaches:

  * •

For $\alpha$ close to $1$, we employ the classification of Baker [4, 5] in the
form given in [6].

  * •

For smaller values of $\alpha$ (which means that $\alpha$ is close to $1/2$),
and also for sums $V_{f}(x;N)$ with non-polynomial functions when the above
classification is not available, we link Hausdorff dimension of the sets
${\mathcal{E}}_{d,\alpha}$ and ${\mathcal{F}}_{f,\alpha}$ to various mean
value theorems.

The above arguments are complemented by the use of the Frostman Lemma (see
[23, Corollary 4.12]) and the Gál–Koksma Theorem [26, Theorem 4].

###  1.3. Notation

Throughout the paper, the notations $U=O(V)$, $U\ll V$ and $V\gg U$ are
equivalent to $|U|\leqslant cV$ for some positive constant $c$, which
throughout the paper may depend on the degree $d$, the growth rate $\tau$ and
occasionally on the small real positive parameter $\varepsilon$ and the real
parameter $t$.

For any quantity $V>1$ we write $U=V^{o(1)}$ (as $V\rightarrow\infty$) to
indicate a function of $V$ which satisfies
$V^{-\varepsilon}\leqslant|U|\leqslant V^{\varepsilon}$ for any
$\varepsilon>0$, provided that $V$ is large enough. One additional advantage
of using $V^{o(1)}$ is that it absorbs $\log V$ and other similar quantities
without changing the whole expression.

For $m\in{\mathbb{N}}$, we write $[m]$ to denote the set
$\\{0,1,\ldots,m-1\\}$.

##  2\. Results for sets of very large sums

###  2.1. Multiparametric families of Gauss sums and Weyl sums

Here we confirm the Conjecture 1.2 for $d=2$, that is, for the Gauss sums

$G(\mathbf{x};N)=\sum_{n=1}^{N}{\mathbf{\,e}}\left(x_{1}n+x_{2}n^{2}\right),$

we improve the previous upper and lower bounds of [14, 15, 16], and obtain the
exact value of the Hausdorff dimension of ${\mathcal{E}}_{2,\alpha}$.

######  Theorem 2.1.

For any $\alpha\in(1/2,1)$ we have

$\dim{\mathcal{E}}_{2,\alpha}=\begin{cases}7/2-3\alpha&\text{if}\
5/6\geqslant\alpha>1/2,\\\ 6(1-\alpha)&\text{if}\ 1>\alpha>5/6.\end{cases}$

For $d\geqslant 3$, by applying the same idea as in the proof of Theorem 2.1
and combining some other new ideas, we obtain the following upper bound, which
improves the previous bound of [15, Theorem 1.1] when $\alpha$ is close to
$1$. For $d\geqslant 3$ we always write

(2.1) $D=\min\\{2^{d-1},2d(d-1)\\}.$

######  Theorem 2.2.

For $d\geqslant 3$ and any $\alpha\in(1-1/D,1)$, where $D$ is given by (2.1),
we have

$\dim{\mathcal{E}}_{d,\alpha}\leqslant\min_{h=1,\ldots,d}\frac{(d^{2}+1)(1-\alpha)}{h}+\frac{h-1}{2}.$

###  2.2. One parametric families of Weyl sums with real polynomials

We now obtain upper bounds on $\dim{\mathcal{F}}_{f,\alpha}$, which in the
case of monomial sums and large values of $\alpha$ matches the lower bounds
(1.6) and (1.7). Depending on using different methods, we divide the results
on $\dim{\mathcal{F}}_{f,\alpha}$ into two subsections.

######  Theorem 2.3.

Let $f\in{\mathbb{R}}[X]$ be a polynomial of degree $d$. For any
$\alpha\in(1-1/D,1)$, where $D$ is given by (2.1), we have

$\dim{\mathcal{F}}_{f,\alpha}\leqslant\begin{cases}2(1-\alpha)&\text{if}\
d=2,\\\ \left(1+1/d\right)(1-\alpha)&\text{if}\ d\geqslant 3.\end{cases}$

Combining Theorem 2.3 with (1.6) and (1.7) and noticing that for $d\geqslant
2$,

$\frac{d}{d+2}\leqslant 1-\frac{1}{D},$

we obtain the following exact values in the case of monomial sums.

######  Corollary 2.4.

For any $\alpha\in(1-1/D,1)$, where $D$ is given by (2.1), we have

$\dim\mathscr{F}_{d,\alpha}=\begin{cases}2(1-\alpha)&\text{if}\ d=2,\\\
\left(1+1/d\right)(1-\alpha)&\text{if}\ d\geqslant 3.\end{cases}$

As we have mentioned, we believe that in the case $f\in{\mathbb{Z}}[X]$ the
lower bounds (1.6) and (1.7) and thus Corollary 2.4, can be extended to
$\dim{\mathcal{F}}_{f,\alpha}$.

We observe that Theorem 2.3 can be applied to estimate
$\dim{\mathcal{E}}_{d,\alpha}\cap{\mathcal{L}}$ where ${\mathcal{L}}$ is a
straight line in${\mathbb{R}}^{d}$ passing through the origin. Precisely, let
$\mathbf{v}=(v_{1},\ldots,v_{d})\in{\mathbb{R}}^{d}$,
$\mathbf{v}\neq{\mathbf{0}}$, and

${\mathcal{L}}_{\mathbf{v}}=\\{\lambda\mathbf{v}:\leavevmode\nobreak\
\lambda\in\mathsf{T}\\}.$

For $\mathbf{x}\in{\mathcal{L}}_{\mathbf{v}}$ for some $\lambda\in\mathsf{T}$
we have

$S_{d}(\mathbf{x};N)=\sum_{n=1}^{N}{\mathbf{\,e}}\left(\lambda f(n)\right),$

where $f(n)=v_{1}n+\ldots+v_{d}n^{d}$. It follows that
$\dim\left({\mathcal{E}}_{d,\alpha}\cap{\mathcal{L}}_{\mathbf{v}}\right)\leqslant\dim{\mathcal{F}}_{f,\alpha},$
and by Theorem 2.3 we derive the following explicit bound.

######  Corollary 2.5.

Let $\mathbf{v}=(v_{1},\ldots,v_{k},0,\ldots,0)\in{\mathbb{R}}^{d}$ with
$v_{k}\neq 0$ and $v_{j}=0$ when $k<j\leqslant d$. Let

$D_{k}=\min\\{2^{k-1},2k(k-1)\\}.$

Then for any $\alpha\in(1-1/D_{k},1)$ we have

$\dim{\mathcal{E}}_{d,\alpha}\cap{\mathcal{L}}_{v}\leqslant\begin{cases}2(1-\alpha)&\text{if}\
k=2,\\\ \left(1+1/k\right)(1-\alpha)&\text{if}\ k\geqslant 3.\end{cases}$

We remark that Corollary 2.4 implies that the bounds of Corollary 2.5 is sharp
in general when $\alpha$ is close to $1$. This follows by choosing
$\mathbf{v}=(v_{1},\ldots,v_{d})$ such that $v_{k}=1$ and $v_{j}=0$ when
$j\neq k$. Moreover, motivated from the research on Diophantine approximation
on manifolds (see, for instance [28, Chapter 9]), we pose the following
general question.

######  Question 2.6.

Given an “interesting” surface $\Gamma\subseteq{\mathbb{R}}^{d}$, for example,
an algebraic hypersurface or a smooth analytic surface of given curvature,
determine the Hausdorff dimension of the intersection
${\mathcal{E}}_{d,\alpha}\cap\Gamma$.

We note that upper bounds on the means values of Weyl sums along various
surfaces have been given in [17, 19].

###  2.3. Comparison

We observe that Theorem 2.2 improves the upper bound

(2.2)
$\dim{\mathcal{E}}_{d,\alpha}\leqslant\min_{k=0,\ldots,d-1}\frac{(2d^{2}+4d)(1-\alpha)+k(k+1)}{4-2\alpha+2k}$

of [15, Theorem 1.1] for the range $\alpha\in(1-1/D,1)$. Indeed, consider the
functions

$F(h,\beta)=\frac{(d^{2}+1)\beta}{h}+\frac{h-1}{2},\qquad
G(k,\beta)=\frac{(2d^{2}+4d)\beta+k(k+1)}{2+2\beta+2k}$

and note that it is enough to verify that for $\beta\in(0,1/D)$ and
$h=1,\ldots,d$ we have

(2.3) $F(h,\beta)<G(h-1,\beta).$

Clearly, the inequality (2.3) is equivalent to

$\frac{(d^{2}+1)\beta}{h}+\frac{h-1}{2}<\frac{(2d^{2}+4d)\beta+h(h-1)}{2\beta+2h}$

or

$\left(2(d^{2}+1)\beta+h(h-1)\right)\left(\beta+h\right)<\left((2d^{2}+4d)\beta+h(h-1)\right)h.$

Simplifying we obtain an equivalent inequality

$2(d^{2}+1)\beta^{2}<\beta\left(4dh-h(h+1)\right)$

and finally

$2(d^{2}+1)\beta<4dh-h(h+1).$

Since $\beta<1/D$ and the right hand side of above inequality is increasing
with $h\in[1,d]$ it is only enough to check that

$2(d^{2}+1)/D<4d-2,$

which can be numerically verified for $3\leqslant d\leqslant 7$ and
established via elementary calculus for $d\geqslant 8$. This shows that (2.3)
holds and thus Theorem 2.2 is stronger than (2.2) for any $d\geqslant 3$ and
all admissible values of $\alpha$.

Clearly, when $\alpha$ is close to $1$ then the choice of $h=1$ in Theorem 2.2
is optimal. However sometimes other choices of $h$ give better result. For
example, if $\alpha\in(1-1/D,1-1/(d^{2}+1)$ than then choice of $h=2$ is
better than $h=1$. The above range is non-empty provided that
$d^{2}+1\geqslant D$, and this happens when $3\leqslant d\leqslant 6$ only.
Moreover, for larger $d$ (say $d\geqslant 7$) and $\alpha\in(1-1/D,1)$ the
value $\alpha$ is quite near the value $1$, thus we may take $h=1$ only in
Theorem 2.2 when $d\geqslant 7$. Although for our applications here the values
$h\geqslant 3$ are never used, we present the argument in full generality as
we believe it can be used to study Weyl sums with other polynomials.

###  2.4. Ideas behind the proofs

We concentrate on the ideas in the proof of Theorem 2.1. Before doing this, we
remark that a similar argument to the proof of the upper bound on
$\dim{\mathcal{E}}_{2,\alpha}$ also implies an upper bound on
$\dim{\mathcal{E}}_{d,\alpha}$ and $\dim{\mathcal{F}}_{f,\alpha}$ in Theorems
2.2 and 2.3. However, the idea for obtaining the lower bound on
$\dim{\mathcal{E}}_{2,\alpha}$ does not work for $d\geqslant 3$. The main
reason is that we do not have a version of Lemma 7.1 when $d\geqslant 3$ and
in fact for a prime $p\equiv 2\pmod{3}$ there are many vectors
$(a,b,c)\in[p]^{3}$ such that

$\sum_{n=1}^{p}{\mathbf{\,e}}_{p}(an+bn^{2}+cn^{3})=0,$

see [14, Remark 2.8] for more details.

#### Upper bound:

Our argument is based on a combination of the Frostman Lemma (see [23,
Corollary 4.12]) and the Gál–Koksma Theorem [26, Theorem 4], which are
presented in Section 4.

For any $t<\dim{\mathcal{E}}_{2,\alpha}$, by the Frostman Lemma (see [23,
Corollary 4.12] or Lemma 4.1 below), there exists a Radon measure $\mu$ on
${\mathcal{E}}_{2,\alpha}$ with

$\mu({\mathcal{E}}_{2,\alpha})>0\quad\text{ and }\quad\mu(B(\mathbf{x},r))\ll
r^{t}$

for all $\mathbf{x}$ and $r>0$. Applying the description of Baker [4, Theorem
3] of the structure of large Gauss sums, we obtain the following type
$L^{\rho}$ bound: for any $M,N\in{\mathbb{N}}$ we have

$\int_{\mathsf{T}_{2}}\left|\sum_{n=M+1}^{M+N}{\mathbf{\,e}}(x_{1}n+x_{2}n^{2})\right|^{\rho}d\mu(\mathbf{x})\leqslant
N^{s_{1}+o(1)}(N+M)^{s_{2}},$

where the exponents $s_{1}$ and $s_{2}$ depend on $\rho$ and $t$. By a result
of Gál and Koksma [26, Theorem 4], we obtain that for almost all
$\mathbf{x}=(x_{1},x_{2})$ with respect to $\mu$

$\sum_{n=1}^{N}{\mathbf{\,e}}(x_{1}n+x_{2}n^{2})=o\left(N^{(s_{1}+s_{2})/\rho}\right),\quad
N\rightarrow\infty.$

Since $\mu({\mathcal{E}}_{2,\alpha})>0$, there is a set of $(x_{1},x_{2})$ of
positive $\mu$-measure such that

$\left|\sum_{n=1}^{N}{\mathbf{\,e}}(x_{1}n+x_{2}n^{2})\right|\geqslant
N^{\alpha}$

for infinitely many $N\in{\mathbb{N}}$. It follows that

$\alpha\leqslant(s_{1}+s_{2})/\rho.$

By taking the concrete parameters we obtain

$t<\min\\{1/2+3(1-\alpha),6(1-\alpha)\\}.$

Note that this inequality holds for any $t<\dim{\mathcal{E}}_{2,\alpha}$. Thus
we obtain

$\dim{\mathcal{E}}_{2,\alpha}\leqslant\min\\{1/2+3(1-\alpha),6(1-\alpha)\\},$

which yields the desired upper bound.

Proofs of Theorems 2.2 and 2.3 follow a similar idea, albeit in a more
technically involved way.

#### Lower bound:

we make the heuristic argument of [13, Section 8] rigorous for the case $d=2$.
In brief, Gauss sums are large at rational points and their small
neighbourhood, and we know the size of them from Diophantine analysis. Indeed,
first note that the Gauss sums are large at rational points, for instance for
any $a,b,p$ where $p$ is a prime number, $(p,b)=1$ we have

$\left|\sum_{n=1}^{p}{\mathbf{\,e}}_{p}(an+bn^{2})\right|=\sqrt{p},$

where ${\mathbf{\,e}}_{p}(z)=\exp(2\pi iz/p)$, and hence, by periodicity, for
suitably large $N$ we have

$\left|\sum_{n=1}^{N}{\mathbf{\,e}}_{p}(an+bn^{2})\right|\approx\frac{N}{\sqrt{p}}\approx
N^{\alpha}.$

Here $z\approx Z$ means that $Z/C\leqslant z\leqslant CZ$ for some absolute
positive constant $C$. By the continuity of the Gauss sums, we have

$\left|\sum_{n=1}^{N}{\mathbf{\,e}}(xn+yn^{2})\right|\approx N^{\alpha},$

provided that

(2.4)
$\left|x-\frac{a}{p}\right|<p^{-\frac{1}{2(1-\alpha)}},\quad\left|y-\frac{b}{p}\right|<p^{-\frac{1}{1-\alpha}}.$

It follows that if $(x,y)$ satisfies (2.4) for infinitely many $a,b,p$ then
$(x,y)\in{\mathcal{E}}_{2,\alpha}$, and we denote the collection of these
$(x,y)$ by $W_{\alpha}$. Thus $W_{\alpha}\subseteq{\mathcal{E}}_{2,\alpha}$.
By Rynne [36, Theorem 1], for $\alpha\in(1/2,1)$ we have

$\dim W_{\alpha}=\min\left\\{1/2+3(1-\alpha),6(1-\alpha)\right\\},$

and thus yields the desired lower bound.

##  3\. Results for sets of exponential sums of arbitrary size

###  3.1. One parametric families of Weyl sums with integer polynomials

Theorem 2.3 says nothing for $\dim\mathscr{F}_{f,\alpha}$ when
$\alpha\in(1/2,1-1/D)$. Our next result fills that gap, and in particular for
any polynomial $f\in{\mathbb{Z}}[X]$ with degree $d\geqslant 2$ and any
$\alpha\in(1/2,1)$ we have

(3.1) $\dim{\mathcal{F}}_{f,\alpha}<1.$

In fact, Theorem 3.5 below implies that for any real polynomial
$f\in{\mathbb{R}}[X]$ with degree $d\geqslant 2$ the nontrivial bound (3.1)
still holds.

######  Theorem 3.1.

Let $f\in{\mathbb{Z}}[x]$ be a polynomial with degree $d\geqslant 2$. For any
real $\alpha\in(1/2,1)$, we have

$\dim{\mathcal{F}}_{f,\alpha}\leqslant\min\\{U_{1}(d,\alpha),U_{2}(d,\alpha)\\},$

where

$\displaystyle
U_{1}(d,\alpha)=\min_{r=1,\ldots,d}\frac{d+1-\alpha+2^{r}(1-\alpha)-r}{d+1-\alpha},$
$\displaystyle
U_{2}(d,\alpha)=\min_{r=1,\ldots,d}\frac{d+1-\alpha+r(r+1)(1-\alpha)-r}{d+1-\alpha}.$

Now we extract some easier upper bounds for $\dim{\mathcal{F}}_{f,\alpha}$.
Taking $r=2$ and $r=d$ in the definition of $U_{1}(d,\alpha)$, we obtain

$U_{1}(d,\alpha)\leqslant\min\left\\{\frac{d+3-5\alpha}{d+1-\alpha},\frac{(2^{d}+1)(1-\alpha)}{d+1-\alpha}\right\\}.$

Furthermore, taking $r=d$ in the definition of $U_{2}(d,\alpha)$ we obtain

$U_{2}(d,\alpha)\leqslant\frac{(d^{2}+d+1)(1-\alpha)}{d+1-\alpha}.$

We formulate the following corollary.

######  Corollary 3.2.

Let $f\in{\mathbb{Z}}[x]$ be a polynomial with degree $d\geqslant 2$. For any
real $\alpha\in(1/2,1)$, we have

$\dim{\mathcal{F}}_{f,\alpha}\leqslant\min\left\\{\frac{d+3-5\alpha}{d+1-\alpha},\frac{(2^{d}+1)(1-\alpha)}{d+1-\alpha},\frac{(d^{2}+d+1)(1-\alpha)}{d+1-\alpha}\right\\}.$

Corollary 3.2 implies that for any $f\in{\mathbb{Z}}[x]$ be a polynomial with
degree $d\geqslant 2$ and any $\alpha\in(1/2,1)$ we have

$\dim{\mathcal{F}}_{f,\alpha}<1.$

Furthermore, for monomials we have yet abother bound.

######  Theorem 3.3.

Let $d\geqslant 2$. For any real $\alpha\in(1/2,1)$, we have

$\dim\mathscr{F}_{d,\alpha}\leqslant\frac{(1+s_{0})(1-\alpha)}{d+1-\alpha},$

where

$s_{0}=d(d-1)+\min_{r=1,\ldots,d}\frac{2d+(r-1)(r-2)}{r}.$

Furthermore, for “polynomial-like” sequences, such in the special case of
Piatetski-Shapiro sequences $f(n)=\left\lfloor n^{\tau}\right\rfloor$ we have
the following result.

######  Theorem 3.4.

Let $f(n)=\left\lfloor n^{\tau}\right\rfloor$ for some $\tau\geqslant 1$. For
any $\alpha\in(1/2,1)$, we have

$\dim{\mathcal{F}}_{f,\alpha}\leqslant\begin{cases}1-\frac{4\alpha+\tau-4}{\tau+1-\alpha}&\text{if}\
\tau<2,\\\ 1-\frac{4\alpha-2}{\tau+1-\alpha}&\text{if}\ \tau\geqslant
2.\end{cases}$

Note that for any $\alpha\in(1/2,1)$ Theorem 3.4 provides nontrivial upper
bound, that is, $\dim{\mathcal{F}}_{f,\alpha}<1$, in a wide range of
parameters $\alpha$ and $\tau$, for instance, when $2>\tau>4-4\alpha$.

###  3.2. One parametric families of exponential sums with arbitrary sequences

Let $f(n)$ be a real sequence. We extend the definition of exponential sums
$V_{f}(x;N)$ in (1.5) and of the sets ${\mathcal{F}}_{f,\alpha}$ to
exponential sums with an arbitrary real sequence $f(n)$, $n=1,2,\ldots$.

First we consider sequences with a given rate of their growth on average.
Namely, we assume that there exists a real number $\tau>0$ such that for all
large enough $N$ we have

(3.2) $\frac{1}{N}\sum_{n=1}^{N}|f(n)|\ll N^{\tau}.$

######  Theorem 3.5.

Let $f(n)$ be a real sequence such that $|f(n)-f(m)|\gg 1$ for all $n\neq m$
and the sequence $f(n)$ satisfies (3.2) for some $\tau>0$. For any real
$\alpha\in(1/2,1)$, we have

$\dim{\mathcal{F}}_{f,\alpha}\leqslant 1-\frac{2\alpha-1}{\tau+1-\alpha}.$

Clearly for any $\alpha\in(1/2,1)$ and $\tau>0$ we have

$1-\frac{2\alpha-1}{\tau+1-\alpha}<1.$

######  Theorem 3.6.

Let $f(n)\in{\mathbb{Z}}$ be a strictly convex integer sequence that satisfies
(3.2) for some $\tau>0$. Then we have

$\dim{\mathcal{F}}_{f,\alpha}\leqslant\min\\{U_{1}(\tau,\alpha),U_{2}(\tau,\alpha)\\},$

where

$\displaystyle U_{1}(\tau,\alpha)=\frac{\tau+45/13-5\alpha}{\tau-\alpha},$
$\displaystyle U_{2}(\tau,\alpha)=\inf_{k\geqslant
3,\,k\in{\mathbb{N}}}\frac{\tau-\alpha+2k-1+2^{-k+1}-2k\alpha}{\tau+1-\alpha}.$

Next we consider sequences with a restriction on the growth of individual
terms rather than on average as in (3.2).

######  Theorem 3.7.

Let $f(n)$ be a sequence of strictly increasing sequence of natural numbers
with $f(n)=O(n^{\tau})$ for some $\tau\geqslant 1$. For any
$\alpha\in(1/2,1)$, we have

$\dim{\mathcal{F}}_{f,\alpha}\leqslant 1-\frac{2\alpha-1}{\tau}.$

We note that that the upper bound of Theorem 3.7 is nearly sharp when
$\alpha\rightarrow 1$. In fact we consider the following set of exponential
sums with an even more stringent condition. Namely, for $c>0$, we define the
set

(3.3) ${\mathcal{G}}_{f,c}=\\{x\in T:\leavevmode\nobreak\
|V_{f}(x;N)|\geqslant cN\text{ for infinitely many $N\in{\mathbb{N}}$ }\\}.$

Here we mention some related work on ${\mathcal{G}}_{f,c}$. Suppose further
that $f(n)\in{\mathbb{N}}$ for all $n$ with $f(n)=O(n^{\tau})$ for some
$\tau\geqslant 1$. First Salem [37] and then Erdős and Taylor [22] have shown
that the set of $x\in\mathsf{T}$ such that the sequence

$xf(n),\ n=1,2,\ldots,\ \text{is not uniformly distributed}\ \pmod{1}$

has Hausdorff dimension at most $1-1/\tau$. The result has been extended to
arbitrary real sequences $f(n)=O(n^{\tau})$ by Baker [1]. Moreover, for each
$p\geqslant 1$, Ruzsa [35] exhibits an integer sequence $f(n)=O(n^{\tau})$ to
show that the above upper bound $1-1/\tau$ is attained. The above results are
related to the set ${\mathcal{G}}_{f,c}$ by using the _Weyl criterion_ (see
[20, Section 1.2.1]) and _the countable stability_ of Hausdorff dimension (see
[23, Section 2.2]). More precisely, we recall that the countable stability of
Hausdorff dimension asserts that for any sequence of sets ${\mathcal{F}}_{i}$
we have

$\dim\bigcup_{i\in{\mathbb{N}}}{\mathcal{F}}_{i}=\sup_{i\in{\mathbb{N}}}\dim{\mathcal{F}}_{i}.$

It follows from the above result of Baker [1], Erdős and Taylor [22] and Salem
[37] that for a sequence $f(n)=O(n^{\tau})$ with $\tau\geqslant 1$ and any
$c>0$ we have

(3.4) $\dim{\mathcal{G}}_{f,c}\leqslant 1-1/\tau.$

Moreover, the result of Ruzsa [35] implies that for any $\tau\geqslant 1$ and
any $\varepsilon>0$ there exists a sequence $f(n)=O(n^{\tau})$ such that

(3.5) $\dim{\mathcal{G}}_{f,c}\geqslant 1-1/\tau-\varepsilon.$

By combining with other ideas, we could remove the $\varepsilon$ of (3.5), and
obtain the following.

######  Theorem 3.8.

For any $\tau\geqslant 1$ there exits a strictly increasing sequence of
natural numbers $f(n)$ with $f(n)=O(n^{\tau})$ such that for some $c>0$, we
have

$\dim{\mathcal{G}}_{f,c}=1-1/\tau.$

Let $f(n)=O(n^{\tau}),\tau\geqslant 1$ be a monotone increasing real sequence
such that $f(n+1)-f(n)\gg 1$. Baker, Coatney and Harman [7, Theorem 1] show
that the set of $\mathbf{x}\in\mathsf{T}_{d}$ such that the sequence

$f(n)\mathbf{x},\ n=1,2,\ldots,\ \text{is not uniformly distributed}\
\pmod{1}$

is of Hausdorff dimension at most $d-1/\tau$. Moreover, [7, Theorem 2] shows
that the bound $d-1/\tau$ is sharp. By adapting the method of the proof of
Theorem 3.1 (which is same as in the proofs of Theorems 3.3, 3.4, 3.5 and
3.6), we obtain the following result where $f(n)$ is a sequence of matrices.

For a $d\times d$ matrix $A$ we use $\|A\|$ to denote its opetator norm, that
is,

$\|A\|=\sup\left\\{\|\mathbf{x}A\|:\leavevmode\nobreak\
\mathbf{x}\in{\mathbb{R}}^{d},\ \|\mathbf{x}\|=1\right\\}$

where, as before, $\|w\|$ denotes the Euclidean norm in ${\mathbb{R}}^{d}$.

######  Theorem 3.9.

Let ${\mathcal{S}}=(A_{n})_{n\in{\mathbb{N}}}$ be a sequence of $d\times d$
integer matrices such that for some $\tau\geqslant 1/d$ and for all
$N\in{\mathbb{N}}$ we have

(3.6) $\frac{1}{N}\sum_{n=1}^{N}\|A_{n}\|\ll N^{\tau}.$

Moreover for any $n\neq m$ the matrix $A_{n}-A_{m}$ is invertible. Let
${\mathcal{E}}_{{\mathcal{S}}}$ be the collection of point
$\mathbf{x}\in\mathsf{T}_{d}$ such that the sequence

$\mathbf{x}A_{n},\ n=1,2,\ldots,\ \text{is not uniformly distributed}\
\pmod{1}.$

Then we have

$\dim{\mathcal{E}}_{{\mathcal{S}}}\leqslant d-1/\tau.$

We remark that the reason of taking $\tau\geqslant 1/d$ is making the estimate
(12.1) meaningful. Moreover, we claim that the bound of Theorem 3.9 is sharp
in general, and this follows by using the aforementioned [7, Theorem 2]. More
precisely, [7, Theorem 2] shows that for any $\tau\geqslant 1$, there exists
an integer sequence $f(n)=O(n^{\tau})$ such that the set of
$\mathbf{x}\in\mathsf{T}_{d}$ for which

$\mathbf{x}f(n),\ n=1,2,\ldots,\ \text{is not uniformly distributed}\
\pmod{1}$

is of Hausdorff dimension $d-1/\tau$. For example, for each $n\in{\mathbb{N}}$
let $A_{n}$ be a diagonal matrix with the same diagonal elements $f(n)$, then
this sequence $A_{n}$ attains the above upper bound $d-1/\tau$ which implies
the claim above.

###  3.3. Comparison

Clearly Theorem 3.7 applies to polynomials $f\in{\mathbb{R}}[X]$ with $\tau=d$
and thus complements Theorem 2.3. In particular, as we have mentioned we see
that for any real polynomial $f\in{\mathbb{R}}[X]$ with degree $d\geqslant 2$
the nontrivial bound (3.1) still holds.

We remark that Theorem 3.5 still hold under a relaxed condition, that is
$|f(n)-f(m)|\gg 1$ for all $n\neq m\geqslant N_{0}$ for any constant $N_{0}$,
and thus also applies to polynomials $f\in{\mathbb{R}}[X]$ with $\tau=d$,
however the corresponding upper bounds implied by Theorems 3.7 and 3.5 satisfy

$1-\frac{2\alpha-1}{d}<1-\frac{2\alpha-1}{d+1-\alpha}.$

Finally the lower bound in Theorem 3.8 is based on an idea of Ruzsa [35].

###  3.4. Ideas behind the proofs

Results of Section 3 are all based on various mean values theorems, continuity
of exponential sums and on the completion technique in the style used in [16,
15, 18]. We roughly show that how their arguments imply the upper bounds of
$\dim{\mathcal{F}}_{f,\alpha}$. For obtaining the upper bound of
$\dim{\mathcal{F}}_{f,\alpha}$, we find some intervals to cover the set
${\mathcal{F}}_{f,\alpha}$. We collect these intervals by using the continuity
of the sums

$V_{f}(x;N)=\sum_{n=1}^{N}{\mathbf{\,e}}(xf(n)),$

that is if $|V_{f}(x;N)|\geqslant N^{\alpha}$ then $|V_{f}(y;N)|\geqslant
N^{\alpha}/2$ when $y$ belongs to some small neighbourhood of $x$. Moreover,
the mean value bounds of $V_{f}(x;N)$ control the cardinality of above chosen
intervals, which yields the desired upper bounds. Thus for obtaining better
bounds, we have to know how small neighbourhood of above $x$ explicitly, and
we need various mean values theorems as well. For technical reasons
(completion technique), we in fact use an auxiliary exponential sums
$W_{f}(x;N)$, which is given by (10.1) to ‘control’ the size of $V_{f}(x;N)$.

More precisely, to establish Theorem 3.1, 3.5 and 3.6, we combine Lemma 10.10
with mean values theorems collected in Section 10.1. To prove Theorem 3.7 we
use the mean value bound from Lemma 11.1, which comes from [2], and, as for
results in Section 2, on the Frostman Lemma and Gál–Koksma Theorem, see Lemmas
4.1 and 4.3, respectively.

##  4\. Frostman Lemma and Gál–Koksma Theorem

###  4.1. Frostman Lemma

For a real $s\geqslant 0$ and a set ${\mathcal{F}}\subseteq{\mathbb{R}}^{d}$
denote

$\displaystyle{\mathcal{H}}^{s}_{\delta}({\mathcal{F}})=\inf\biggl{\\{}\sum_{i=1}^{\infty}\left(\operatorname{diam}{\mathcal{U}}_{i}\right)^{s}:\leavevmode\nobreak\
$
$\displaystyle{\mathcal{F}}\subseteq\bigcup_{i=1}^{\infty}{\mathcal{U}}_{i},$
$\displaystyle{\mathcal{U}}_{i}\subseteq{\mathbb{R}}^{d}\text{ and
}\operatorname{diam}({\mathcal{U}}_{i})\leqslant\delta,i\in{\mathbb{N}}\biggr{\\}},$

and the $s$-dimensional Hausdorff measure of the set ${\mathcal{F}}$ is
defined as

${\mathcal{H}}^{s}({\mathcal{F}})=\lim_{\delta\rightarrow
0}{\mathcal{H}}^{s}_{\delta}({\mathcal{F}}).$

Moreover, alternatively the Hausdorff dimension of ${\mathcal{F}}$ can also be
defined as

$\dim{\mathcal{F}}=\inf\\{s\geqslant 0:\leavevmode\nobreak\
{\mathcal{H}}^{s}({\mathcal{F}})=0\\}=\sup\\{s\geqslant 0:\leavevmode\nobreak\
{\mathcal{H}}^{s}({\mathcal{F}})=\infty\\}.$

We also need the following result, which is known as the Frostman Lemma, see,
for instance, [23, Corollary 4.12].

######  Lemma 4.1.

Let ${\mathcal{F}}\subseteq{\mathbb{R}}^{d}$ be a Borel set with
$0<{\mathcal{H}}^{s}({\mathcal{F}})\leqslant\infty$. Then there exists a
compact set ${\mathcal{E}}\subseteq{\mathcal{F}}$ such that
$0<{\mathcal{H}}^{s}({\mathcal{E}})<\infty$ and

${\mathcal{H}}^{s}({\mathcal{E}}\cap B(\mathbf{x},r))\ll r^{s}$

for all $\mathbf{x}$ and $r>0$.

We remark that for our application of Lemma 4.1 we take $\mu$ to be the
restriction of the $s$-Hausdorff measure ${\mathcal{H}}^{s}$ on
${\mathcal{E}}$, that is for any ${\mathcal{A}}\subseteq{\mathbb{R}}^{d}$,

$\mu({\mathcal{A}})={\mathcal{H}}^{s}({\mathcal{E}}\cap{\mathcal{A}}).$

It follows that $\mu$ is a Radon measure such that $\mu({\mathcal{E}})>0$ and

$\mu(B(\mathbf{x},r))\ll r^{s}$

for all $\mathbf{x}$ and $r>0$.

###  4.2. Gál–Koksma Theorem

We first recall the following result of Gál and Koksma [26, Theorem 4], which
shows that mean value bounds imply almost all bounds with respect to the same
measure. Note that [26] treats the case of the Lebesgue measure on a set
${\mathcal{S}}$ rather than an arbitrary Radon measure $\mu$, however the
proof goes through without change.

######  Lemma 4.2.

Let $\mu$ be a Radon measure on $\mathsf{T}_{d}$ and let
$f_{1}(\mathbf{x}),f_{2}(\mathbf{x}),\ldots$ be a sequence of Borel measurable
function on ${\mathbb{R}}^{d}$. Suppose that we have the bound, for some
$\rho>0$ and for all $M\geqslant 0,N\geqslant 1$,

$\int_{{\mathbb{R}}^{d}}\left|\sum_{n=M+1}^{M+N}f_{n}(\mathbf{x})\right|^{\rho}d\mu(\mathbf{x})\leqslant
C\Psi(N)\Phi(M,N),\quad\Phi(M,N)\geqslant 1,$

where $C$ is an absolutely constant, $\Psi(N)$ and $\Phi(M,N)$ are some
positive functions, and $\Psi(N)/N^{1+\gamma}$ is nondecreasing for some
positive $\gamma$. Let $\psi(N)>0$ be nondecreasing and

(4.1)
$\psi(2^{n})\geqslant\Phi(0,2^{n})+\sum_{\lambda=1}^{n}2^{(\lambda-n)(1+\beta)}\sum_{k=0}^{2^{n-\lambda}-1}\Phi(2^{n}+k2^{\lambda},2^{\lambda-1}),$

where $0<\beta<\gamma$ is a constant. Let $\chi(N)$ be a positive
nondecreasing function with

(4.2) $\sum_{n=1}^{\infty}(N\chi(N))^{-1}<\infty.$

Then for almost all $\mathbf{x}$ with respect to $\mu$, we have

$\sum_{n=1}^{N}f_{n}(\mathbf{x})=o(\Psi(N)\psi(N)\chi(N))^{1/p},\quad
N\rightarrow\infty.$

For convenience of our application, we formulate the following particular case
of Lemma 4.2.

######  Lemma 4.3.

Let $\mu$ be a Radon measure on $\mathsf{T}_{d}$ and let
$f_{1}(\mathbf{x}),f_{2}(\mathbf{x}),\ldots$ be a sequence of Borel measurable
function on ${\mathbb{R}}^{d}$. Suppose that we have the bound, for some
$\rho>0$ and for all $M\geqslant 0,N\geqslant 1$,

$\int_{{\mathbb{R}}^{d}}\left|\sum_{n=M+1}^{M+N}f_{n}(\mathbf{x})\right|^{\rho}d\mu(\mathbf{x})\leqslant
N^{s_{1}+o(1)}(M+N)^{s_{2}}$

for some constants $s_{1}>1$ and $s_{2}>0$. Then for almost all
$\mathbf{x}\in{\mathbb{R}}^{d}$ with respect to $\mu$ we have

$\left|\sum_{n=1}^{N}f_{n}(\mathbf{x})\right|\leqslant
N^{(s_{1}+s_{2})/\rho+o(1)},\qquad N\rightarrow\infty.$

###### Proof.

We show that $\psi(N)=CN^{s_{2}}$ satisfies (4.1) when $C$ is some large
constant. To see this, we note that for $1\leqslant\lambda\leqslant n$, we
have

$\sum_{k=0}^{2^{n-\lambda}-1}(2^{n}+k2^{\lambda}+2^{\lambda-1})^{s_{2}}\ll
2^{n-\lambda}2^{ns_{2}},$

and for some small $\beta>0$,

$\sum_{\lambda=1}^{n}2^{(\lambda-n)(1+\beta)}2^{n-\lambda}2^{ns_{2}}=\sum_{\lambda=1}^{n}2^{-(n-\lambda)\beta}2^{ns_{2}}\ll
2^{ns_{2}}.$

Moreover, for any $\varepsilon>0$ the function $\chi(N)=N^{\varepsilon}$
satisfies (4.2). By Lemma 4.2 we obtain that for almost all
$\mathbf{x}\in{\mathbb{R}}^{d}$ with respect to $\mu$ we have

$\left|\sum_{n=1}^{N}f_{n}(\mathbf{x})\right|\leqslant
N^{(s_{1}+s_{2}+\varepsilon)/\rho+o(1)},\quad N\rightarrow\infty.$

By the arbitrary choice of $\varepsilon>0$ we obtain the desired bound.
$\sqcap$$\sqcup$

##  5\. Bounds of Gauss sums and Weyl sums

###  5.1. Structure of large Gauss sums

The following result of Baker [4, Theorem 3] and [5, Theorem 4] describes the
structure of large Gauss sums.

For each $m\in{\mathbb{N}}$ recalling that $[m]=\\{0,1,\ldots,m-1\\}$.

######  Lemma 5.1.

We fix some $\varepsilon>0$, and suppose that for a real

$A>N^{1/2+\varepsilon},$

we have $|G(x_{1},x_{2};N)|\geqslant A$ for some
$(x_{1},x_{2})\in{\mathbb{R}}^{2}$. Then there exist integers $q,a_{1},a_{2}$
such that

$1\leqslant q\leqslant\left(NA^{-1}\right)^{2}N^{o(1)},$

and for $i=1,2$ we have

$\left|x_{i}-\frac{a_{i}}{q}\right|\leqslant(NA^{-1})^{2}q^{-1}N^{-i+o(1)}.$

We now use Lemma 5.1 to descrbite the structure of large sums
$G(x_{1},x_{2};M,N)$.

######  Lemma 5.2.

We fix some $\varepsilon>0$, and suppose that for a real

$A>N^{1/2+\varepsilon},$

we have $|G(x_{1},x_{2};M,N)|\geqslant A$ for some
$(x_{1},x_{2})\in\mathsf{T}_{2}$. Then there exist integers $q,b_{1},b_{2}$
such that

$1\leqslant q\leqslant\left(NA^{-1}\right)^{2}N^{o(1)},\quad 0\leqslant
b_{1},b_{2}\leqslant q,$

and

$\displaystyle\left|x_{1}-\frac{b_{1}}{q}\right|\leqslant(M+N)q^{-1}A^{-2}N^{o(1)},$
$\displaystyle\left|x_{2}-\frac{b_{2}}{q}\right|\leqslant
q^{-1}A^{-2}N^{o(1)}.$

###### Proof.

Elementary arithmetic shows that

$|G(x_{1},x_{2};M,N)|=|G(x_{1}+2Mx_{2},x_{2};N)|.$

By Lemma 5.1 there exist $q,a_{1},a_{2}$ such that

(5.1) $\begin{split}&\left|x_{1}+2Mx_{2}-\frac{a_{1}}{q}\right|\leqslant
q^{-1}A^{-2}N^{1+o(1)},\\\ &\left|x_{2}-\frac{a_{2}}{q}\right|\leqslant
q^{-1}A^{-2}N^{o(1)}.\end{split}$

Clearly $A^{-2}N^{o(1)}<1$, we conclude that $0\leqslant a_{2}\leqslant q$,
and we take $b_{2}=a_{2}$.

We now search for an integer $b_{1}$ with the desired property. From (5.1) we
obtain

(5.2)
$\left|x_{1}-\frac{a_{1}-2Ma_{2}}{q}\right|\leqslant(M+N)q^{-1}A^{-2}N^{o(1)}.$

Suppose that $(M+N)A^{-2}N^{o(1)}\leqslant 1$, then by (5.2) we conclude that

$0\leqslant a_{1}-2Ma_{2}\leqslant q,$

and we take $b_{1}=a_{1}-2Ma_{2}$. Suppose to the contrary that

$(M+N)A^{-2}N^{o(1)}>1,$

then trivially there exists $b_{1}$ with $0\leqslant b_{1}\leqslant q$ and
such that

$\left|x_{1}-\frac{b_{1}}{q}\right|\leqslant
q^{-1}\leqslant(M+N)q^{-1}A^{-2}N^{o(1)},$

which finishes the proof. $\sqcap$$\sqcup$

######  Remark 5.3.

For large enough $M$ the bound

$\left|x_{1}-\frac{b_{1}}{q}\right|\leqslant(M+N)q^{-1}A^{-2}N^{o(1)}$

of Lemma 5.1 would be trivial. Thus we may add $1/q$ term, that is

$\left|x_{1}-\frac{b_{1}}{q}\right|\leqslant\min\\{(M+N)q^{-1}A^{-2}N^{o(1)},1/q\\}.$

However, the bound $(M+N)q^{-1}A^{-2}N^{o(1)}$ is sufficient for our
applications, and hence we use this bound only.

###  5.2. Frequency of large Gauss sums

Let $\mu$ be a Radon measure on $\mathsf{T}_{2}$ such that

(5.3) $\mu(B(\mathbf{x},r))\ll r^{t}$

holds for some $t>0$ and for all $\mathbf{x}\in\mathsf{T}_{2}$ and $r>0$. Let
$\mathfrak{R}$ be a rectangle with side length $a<b$, then we have

$\mu(\mathfrak{R})\ll\min\\{ba^{t-1},b^{t}\\}.$

Indeed, we can either include $\mathfrak{R}$ in a ball of radius $O(b)$ or
cover it by $O(b/a)$ balls of radius $a$.

######  Lemma 5.4.

Let $\mu$ be a Radon measure satisfying (5.3) and $A$ be a real number with
$1\leqslant A\leqslant N$. For fixed $M,N\in{\mathbb{N}}$ denote

${\mathcal{E}}_{B}=\\{\mathbf{x}\in\mathsf{T}_{2}:\leavevmode\nobreak\
|G(\mathbf{x};M,N)|\geqslant B\\}.$

Then we have

$\mu({\mathcal{E}}_{B})\leqslant N^{6-2t+o(1)}B^{-6}\min\\{M+N,(M+N)^{t}\\}.$

###### Proof.

Denote

$Q=(NB^{-1})^{2}N^{o(1)}.$

From Lemma 5.1 we conclude that

$\\{\mathbf{x}\in\mathsf{T}_{2}:\leavevmode\nobreak\
|G(\mathbf{x};M,N)|\geqslant B\\}\subseteq\bigcup_{q\leqslant
Q}\bigcup_{(a_{1},a_{2})\in[q]^{2}}\mathfrak{R}_{q,b_{1},b_{2}},$

where $\mathfrak{R}_{q,b_{1},b_{2}}$ is a rectangle with side lengths

$(M+N)B^{-2}q^{-1}N^{o(1)}\qquad\mbox{and}\qquad B^{-2}q^{-1}N^{o(1)}.$

For $Z\geqslant 1$, we write $z\sim Z$ to denote that $Z/2<z\leqslant Z$.
Denote

$\delta_{z}=B^{-2}z^{-1}.$

Taking a dyadic partition of the interval $[1,Q]$, we see that there is a
number $1\leqslant Z\leqslant Q$ such that

$\displaystyle\mu({\mathcal{E}}_{B})$ $\displaystyle\leqslant
N^{o(1)}\sum_{q\sim
Z}\sum_{(a_{1},a_{2})\in[q]^{2}}\mu(\mathfrak{R}_{q,a_{1},a_{2}})$
$\displaystyle\leqslant
N^{o(1)}Z^{3}\min\\{(M+N)\delta_{Z}^{t},(M+N)^{t}\delta_{Z}^{t}\\}$
$\displaystyle\leqslant N^{o(1)}\min\\{I,J\\},$

where

$I=Z^{3}(M+N)\delta_{Z}^{t}\leqslant Z^{3-t}B^{-2t}(M+N)\leqslant
N^{6-2t}B^{-6}(M+N),$

and

$J=Z^{3}(M+N)^{t}\delta_{Z}^{t}\leqslant N^{6-2t}B^{-6}(M+N)^{t},$

which finishes the proof. $\sqcap$$\sqcup$

###  5.3. Bounds of Weyl sums

Corresponding to the bounds of Gauss sums, we have the following estimation
for Weyl sums which is needed for the proof of Theorem 2.2.

An integer number $n$ is called

  * •

$r$-th power free if any prime number $p\mid n$ satisfies $p^{r}\nmid n$;

  * •

$r$-th power full if any prime number $p\mid n$ satisfies $p^{r}\mid n$.

We note that $1$ is both cube free and cube full.

For any integer $i\geqslant 2$ it is convenient to denote

$\mathscr{Q}_{i}=\\{n\in{\mathbb{N}}:\leavevmode\nobreak\ \text{$n$ is $i$-th
power
full}\\}\quad\text{and}\quad\mathscr{Q}_{i}(x)=\mathscr{Q}_{i}\cap[1,x].$

The classical result of Erdős and Szekeres [21] gives an asymptotic formula
for the cardinality of $\mathscr{Q}_{i}(x)$ which we present here in a very
relaxed form as the upper bound

(5.4) $\\#\mathscr{Q}_{i}(x)\ll x^{1/i}.$

The following Lemma 5.5 comes from [6, Lemma 2.7].

######  Lemma 5.5.

We fix $d\geqslant 3$, some $\varepsilon>0$, and suppose that for a real

$A>N^{1-1/D+\varepsilon},$

where $D$ is given by (2.1), we have $|S_{d}(\mathbf{x};N)|\geqslant A$ for
some $\mathbf{x}\in{\mathbb{R}}^{d}$. Then there exist positive integers
$q_{2},\ldots,q_{d}$ with $\gcd(q_{i},q_{j})=1$, $2\leqslant i<j\leqslant d$,
and such that

  * (i)

$q_{2}$ is cube free,

  * (ii)

$q_{i}$ is $i$-th power full but $(i+1)$-th power free when $3\leqslant
i\leqslant d-1$,

  * (iii)

$q_{d}$ is $d$-th power full,

and

$\prod_{i=2}^{d}q_{i}^{1/i}\leqslant N^{1+o(1)}A^{-1}$

and integers $b_{1},\ldots,b_{d}$ such that

$\left|x_{j}-\frac{b_{j}}{q_{2}\ldots
q_{d}}\right|\leqslant(NA^{-1})^{d}N^{-j+o(1)}\prod_{i=2}^{d}q_{i}^{-d/i},\qquad
j=1,\ldots,d.$

We now need a version of Lemma 5.5 for the sums

$S_{d}(\mathbf{x};M,N)=\sum_{n=1}^{N}{\mathbf{\,e}}\left(x_{1}(M+n)+\ldots+x_{d}(M+n)^{d}\right)$

over arbitrary intervals.

######  Lemma 5.6.

We fix $d\geqslant 3$ and some $\varepsilon>0$. Let $M\geqslant 0$ and
$N\geqslant 1$. Suppose $\mathbf{x}\in\mathsf{T}_{d}$ and

$|S_{d}(\mathbf{x};M,N)|\geqslant B\geqslant N^{1-1/D+\varepsilon},$

where $D$ is given by (2.1). Then there exists $q=q_{2}q_{3}\ldots q_{d}$ with
$\gcd(q_{i},q_{j})=1$, $2\leqslant i<j\leqslant d$, and such that

  * (i)

$q_{2}$ is cube free,

  * (ii)

$q_{i}$ is $i$-th power full but $(i+1)$-th power free when $3\leqslant
i\leqslant d-1$,

  * (iii)

$q_{d}$ is $d$-th power full,

and

$q_{2}^{1/2}q_{3}^{1/3}\ldots q_{d}^{1/d}\leqslant N^{1+o(1)}B^{-1},$

and there are $a_{1},\ldots,a_{d}\in[q]$ such that

(5.5) $x_{k}=\frac{a_{k}}{q}+O\left(\left(M+N\right)^{d-k}r\right),\qquad
k=1,\ldots,d,$

where

(5.6) $r=N^{o(1)}B^{-d}\prod_{i=2}^{d}q_{i}^{-d/i}.$

###### Proof.

The coefficient of $n^{k}$ in $(M+n)x_{1}+\ldots+(M+n)^{d}x_{d}$ is

(5.7) $y_{k}=\sum_{j=k}^{d}\binom{j}{k}M^{j-k}x_{j}.$

Note that $y_{d}=x_{d}$. It follows that

$\displaystyle\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left((M+n)x_{1}+\ldots+(M+n)^{d}x_{d}\right)\right|$
$\displaystyle\quad\quad\quad\quad\quad\quad=\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(y_{1}n+\ldots+y_{d}n^{d}\right)\right|.$

Then we have the following equivalence

$|S_{d}\left(\mathbf{x};M,N\right)|\geqslant
B\quad\Longleftrightarrow\quad|S_{d}(\mathbf{y};N)|\geqslant B.$

By Lemma 5.5 there exist positive integers $q_{2}\ldots q_{d}$ with the above
mentioned properties $(i),(ii),(iii)$ and

$\prod_{i=2}^{d}q_{i}^{1/i}\leqslant N^{1+o(1)}A^{-1},$

and integers $b_{1},\ldots,b_{d}$ such that

(5.8) $\left|y_{j}-\frac{b_{j}}{q_{2}\ldots q_{d}}\right|\leqslant
N^{d-j}r,\qquad j=1,\ldots,d,$

where $r$ is given by (5.6).

We now going to show (5.5) holds by induction. First note that since
$x_{d}=y_{d}$, we have the bound

$x_{d}=\frac{b_{d}}{q_{2}\ldots q_{d}}+O(r).$

Suppose that (5.5) hold for any $k+1\leqslant j\leqslant d$, that is, there
exist $a_{j}$, $k+1\leqslant j\leqslant d$, such that

(5.9) $x_{j}=\frac{a_{j}}{q}+O\left(\left(M+N\right)^{d-j}r\right),\quad
j=k+1,\ldots,d.$

Applying (5.7), (5.8), we derive that

$\left|x_{k}+\sum_{j=k+1}^{d}{j\choose k}M^{j-k}x_{j}-\frac{b_{k}}{q_{2}\ldots
q_{d}}\right|\leqslant N^{d-k}r.$

Combining with (5.9) we conclude that there exists $a_{k}$ such that

$\displaystyle\left|x_{k}-\frac{a_{k}}{q_{2}\ldots q_{d}}\right|$
$\displaystyle\leqslant
N^{d-k}r+O\left(\sum_{j=k+1}^{d}M^{j-k}(M+N)^{d-j}r\right)$
$\displaystyle\ll(M+N)^{d-k}r,$

from which we obtain (5.5) by induction.

Applying similar argument as in the proof of Lemma 5.2, we can always find
$a_{1},a_{2},\ldots a_{d}\in[q_{2}\ldots q_{d}]$ such that the desired
property hold. $\sqcap$$\sqcup$

Suppose that ${\mathcal{R}}$ is a rectangle with side lengths

$K^{d-1}\delta\geqslant K^{d-2}\delta\geqslant\ldots\geqslant
K\delta\geqslant\delta$

for some constants $K\geqslant 1,\delta>0$. Then, by elementary geometric
argument, for any integer $1\leqslant h\leqslant d$ we can cover
${\mathcal{R}}$ by $O(K^{h(h-1)/2})$ cubes with side length $K^{d-h}\delta$.
Furthermore, suppose that $\mu$ is a Radon measure satisfying (5.3), then we
conclude that

(5.10) $\mu({\mathcal{R}})\ll K^{h(h-1)/2}\left(K^{d-h}\delta\right)^{t}.$

######  Lemma 5.7.

We fix $d\geqslant 3$ and some $\varepsilon>0$. Let $\mu$ be a Radon measure
satisfying (5.3) and let $B$ be a real number with
$N^{1-1/D+\varepsilon}\leqslant B\leqslant N$, where $D$ is given by (2.1).
For fixed $M,N\in{\mathbb{N}}$ denote

${\mathcal{E}}_{B}=\\{\mathbf{x}\in\mathsf{T}_{d}:\leavevmode\nobreak\
|S_{d}(\mathbf{x};M,N)|\geqslant B\\}.$

Then for any integer $h$ with $1\leqslant h\leqslant d$ we have

$\mu\left({\mathcal{E}}_{B}\right)\leqslant
B^{-d^{2}-1}N^{d^{2}+1-dt+o(1)}(M+N)^{(d-h)t+h(h-1)/2}.$

###### Proof.

Denote

(5.11) $Q=(NB^{-1})^{d},$

and fix some $\eta>0$. By Lemma 5.6, we conclude that

(5.12)
${\mathcal{E}}_{B}\subseteq\bigcup_{(q_{2},\ldots,q_{d})\in\Omega}\bigcup_{\mathbf{a}\in[q_{2}\ldots
q_{d}]^{d}}{\mathcal{R}}_{q_{2},\ldots,q_{d},\mathbf{a}},$

where, slightly relaxing the conditions of Lemma 5.6, we can take

(5.13)
$\begin{split}\Omega=\biggl{\\{}\left(q_{2},\ldots,q_{d}\right)\in{\mathbb{N}}^{d-1}:\leavevmode\nobreak\
q_{j}\in\mathscr{Q}_{j},&\ 3\leqslant j\leqslant d,\\\
&\prod_{j=2}^{d}q_{j}^{1/j}\leqslant CQ^{1/d}N^{\eta}\biggr{\\}}\end{split}$

and ${\mathcal{R}}_{q_{2},\ldots,q_{d},\mathbf{a}}$ is a rectangle with side
lengths

$(M+N)^{d-1}r_{q_{2},\ldots,q_{d}}\geqslant\ldots\geqslant(M+N)r_{q_{2},\ldots,q_{d}}\geqslant
r_{q_{2},\ldots,q_{d}},$

with some

$r_{q_{2},\ldots,q_{d}}=N^{o(1)}B^{-d}\prod_{j=2}^{d}q_{j}^{-d/j}.$

Let $1\leqslant h\leqslant d$ be an integer. Combining (5.12) with the bound
(5.10), we obtain

$\mu\left({\mathcal{E}}_{B}\right)\ll\sum_{(q_{2},\ldots,q_{d})\in\Omega}(q_{2}\ldots
q_{d})^{d}r_{q_{2},\ldots,q_{d}}^{t}(M+N)^{(d-h)t+h(h-1)/2}.$

Covering $\Omega$ by $O\left(\left(\log N\right)^{d-1}\right)$ dyadic boxes,
we see that that there are some integers $Q_{2},\ldots,Q_{d}\geqslant 1$ with

(5.14) $\prod_{j=2}^{d}Q_{j}^{1/j}\ll Q^{1/d}N^{\eta}$

such that

$\displaystyle\mu\left({\mathcal{E}}_{B}\right)$ $\displaystyle\ll\left(\log
N\right)^{d-1}(M+N)^{(d-h)t+h(h-1)/2}$
$\displaystyle\qquad\qquad\qquad\qquad\times\sum_{\begin{subarray}{c}q_{2}\sim
Q_{2},\ldots,q_{d}\sim Q_{d}\\\
q_{3}\in\mathscr{Q}_{3}\left(Q_{3}\right),\ldots,q_{d}\in\mathscr{Q}_{d}\left(Q_{d}\right)\end{subarray}}(q_{2}\ldots
q_{d})^{d}r_{q_{2},\ldots,q_{d}}^{t}$
$\displaystyle=N^{o(1)}B^{-dt}(M+N)^{(d-h)t+h(h-1)/2}$
$\displaystyle\qquad\qquad\qquad\qquad\qquad\times\sum_{\begin{subarray}{c}q_{2}\sim
Q_{2},\ldots,q_{d}\sim Q_{d}\\\
q_{3}\in\mathscr{Q}_{3}\left(Q_{3}\right),\ldots,q_{d}\in\mathscr{Q}_{d}\left(Q_{d}\right)\end{subarray}}\prod_{j=2}^{d}q_{j}^{d-dt/j}$
$\displaystyle=N^{o(1)}B^{-dt}(M+N)^{(d-h)t+h(h-1)/2}$
$\displaystyle\qquad\qquad\qquad\qquad\qquad\times
Q_{2}^{d-dt/2}\prod_{j=3}^{d}\left(Q_{j}^{d-dt/j}\\#\mathscr{Q}_{j}\left(Q_{j}\right)\right).$

Recalling (5.4) we derive

(5.15) $\mu\left({\mathcal{E}}_{B}\right)\leqslant
N^{o(1)}B^{-dt}(M+N)^{(d-h)t+h(h-1)/2}\prod_{j=2}^{d}Q_{j}^{\alpha_{j}},$

where

$\alpha_{2}=d+1-dt/2,\qquad\mbox{and}\qquad\alpha_{j}=d+1/j-dt/j,\quad
3\leqslant j\leqslant d.$

Observe that for $j=2,\ldots,d$, we have

(5.16) $\alpha_{j}\leqslant d\alpha_{d}/j,$

which for $j\geqslant 3$ is obvious from

$j\alpha_{j}=dj+1-dt\leqslant d^{2}+1-dt=d\alpha_{d}$

and for $j=2$ from

$2\alpha_{2}=2d+2-dt\leqslant d^{2}+1-dt$

since $d\geqslant 3$.

Therefore, in view of (5.16), recalling (5.14), we obtain

$\prod_{j=2}^{d}Q_{j}^{\alpha_{j}}\leqslant\left(\prod_{j=2}^{d}Q_{j}^{1/j}\right)^{d\alpha_{d}}\ll
Q^{\alpha_{d}}N^{d\alpha_{d}\eta}$

Then combining this with (5.15) we obtain

$\mu\left({\mathcal{E}}_{B}\right)\leqslant
N^{o(1)}B^{-dt}(M+N)^{(d-h)t+h(h-1)/2}Q^{\alpha_{d}}N^{d\eta}.$

Recalling the choice of $Q$ in (5.11), since $\eta>0$ is arbitrary we obtain
the desired bound. $\sqcap$$\sqcup$

We need the following analogue of Lemma 5.7.

######  Lemma 5.8.

We fix some $\varepsilon>0$. Let $f\in{\mathbb{R}}[X]$ be a polynomial of
degree $d$. Let $\mu$ be a Radon measure satisfying (5.3) and let $B$ be a
real number with $N^{1-1/D+\varepsilon}\leqslant B\leqslant N$, where $D$ is
given by (2.1). For fixed $M,N\in{\mathbb{N}}$ denote

$\mathscr{E}_{B}=\\{\mathbf{x}\in\mathsf{T}:\leavevmode\nobreak\
|V_{f}(x;M,N)|\geqslant B\\}.$

Then

$\mu\left(\mathscr{E}_{B}\right)\leqslant
N^{o(1)}\begin{cases}N^{4-2t}B^{-4}&\text{if}\ d=2,\\\
N^{d+1-dt}B^{-d-1}&\text{if}\ d\geqslant 3.\end{cases}$

###### Proof.

We proceed as in the proof of Lemma 5.7. In particular, we fix some $\eta>0$
and define $Q$ by (5.11).

Suppose that

$f(n)=\beta_{0}+\beta_{1}n+\ldots+\beta_{d}n^{d},$

where $\beta_{i}\in{\mathbb{R}},0\leqslant i\leqslant d$ and $\beta_{d}\neq
0$. Since the leading coefficient of $f(n+M)$ coincides with that of $f(n)$,
that is $\beta_{d}$, we see that

$\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(xf(n+M)\right)\right|=\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(y_{1}n+\ldots+y_{d}n^{d}\right)\right|,$

where $y_{i}$, $0\leqslant i\leqslant d$ depend on $M,x$ and in particular
$y_{d}=x\beta_{d}$. It follows that if $|V_{f}(x;M,N)|\geqslant B$ for some
$x\in\mathsf{T}$ then

$\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(y_{1}n+\ldots+y_{d}n^{d}\right)\right|\geqslant
B,$

where $y_{d}=\beta_{d}x$. By Lemma 5.5 there are $q_{2},q_{3},\ldots,q_{d}$,
which satisfy the conditions of Lemma 5.5 and some integer $b$ such that

$\left|\beta_{d}x-\frac{b}{q_{2}\ldots q_{d}}\right|\leqslant
N^{o(1)}B^{-d}\prod_{i=2}^{d}q_{i}^{-d/i},$

which is equivalent to

(5.17) $|x-\frac{b}{q_{2}\ldots q_{d}\beta_{d}}|\leqslant
N^{o(1)}B^{-d}\prod_{i=2}^{d}q_{i}^{-d/i}.$

Since $|\beta_{d}x|\leqslant|\beta_{d}|$, we derive that

$\frac{|b|}{q_{2}\ldots
q_{d}}\leqslant|\beta_{d}|+N^{o(1)}B^{-d}\prod_{i=2}^{d}q_{i}^{-d/i},$

and thus

(5.18) $|b|\leqslant 2|\beta_{d}|q_{2}\ldots q_{d}$

provided that $N$ is large enough. It follows that for large enough $N$ we
have

(5.19)
$\mathscr{E}_{B}\subseteq\bigcup_{(q_{2},\ldots,q_{d})\in\Omega}\bigcup_{\begin{subarray}{c}b\in{\mathbb{Z}}\\\
|b|\leqslant 2|\beta_{d}|q_{2}\ldots
q_{d}\end{subarray}}{\mathcal{I}}_{q_{2},\ldots,q_{d},b},$

where, as in the proof of Lemma 5.7, the set $\Omega$ is given by (5.13) and
${\mathcal{I}}_{q_{2},\ldots,q_{d},b}$ is an interval of length

$|{\mathcal{I}}_{q_{2},\ldots,q_{d},b}|\leqslant
N^{o(1)}B^{-d}\prod_{j=2}^{d}q_{j}^{-d/j}.$

Hence we derive from (5.3), (5.17), (5.18) and (5.19), that

$\displaystyle\mu\left(\mathscr{E}_{B}\right)$ $\displaystyle\leqslant
N^{o(1)}B^{-dt}\sum_{(q_{2},\ldots,q_{d})\in\Omega}\prod_{j=2}^{d}q_{j}\left(\prod_{j=2}^{d}q_{j}^{-d/j}\right)^{t}$
$\displaystyle\leqslant
N^{o(1)}B^{-dt}\sum_{(q_{2},\ldots,q_{d})\in\Omega}\prod_{j=2}^{d}q_{j}^{1-dt/j}.$

Again as in the proof of Lemma 5.7, covering $\Omega$ by $O\left(\left(\log
N\right)^{d-1}\right)$ dyadic boxes, we see that that there are some integers
$Q_{2},\ldots,Q_{d}\geqslant 1$ with (5.14) such that

$\displaystyle\mu\left(\mathscr{E}_{B}\right)$ $\displaystyle\leqslant
N^{o(1)}B^{-dt}\sum_{\begin{subarray}{c}q_{2}\sim Q_{2},\ldots,q_{d}\sim
Q_{d}\\\
q_{3}\in\mathscr{Q}_{3}\left(Q_{3}\right),\ldots,q_{d}\in\mathscr{Q}_{d}\left(Q_{d}\right)\end{subarray}}\prod_{j=2}^{d}q_{j}^{1-dt/j}$
$\displaystyle\leqslant
N^{o(1)}B^{-dt}\prod_{j=2}^{d}Q_{j}^{1-dt/j}\sum_{\begin{subarray}{c}q_{2}\sim
Q_{2},\ldots,q_{d}\sim Q_{d}\\\
q_{3}\in\mathscr{Q}_{3}\left(Q_{3}\right),\ldots,q_{d}\in\mathscr{Q}_{d}\left(Q_{d}\right)\end{subarray}}1$
$\displaystyle\leqslant
N^{o(1)}B^{-dt}Q_{2}^{2-dt/2}\prod_{j=3}^{d}\left(Q_{j}^{1-dt/j}\\#\mathscr{Q}_{j}\left(Q_{j}\right)\right).$

Thus, by (5.4), we have

(5.20) $\mu\left(\mathscr{E}_{B}\right)\leqslant
N^{o(1)}B^{-dt}Q_{2}^{2-dt/2}\prod_{j=3}^{d}Q_{j}^{1-(dt-1)/j}.$

Denote

$\prod_{j=2}^{d}Q_{j}^{1/j}=R.$

Then we can rewrite (5.20) as

(5.21) $\mu\left(\mathscr{E}_{B}\right)\leqslant
N^{o(1)}B^{-dt}R^{-dt+1}Q_{2}^{3/2}\prod_{j=3}^{d}Q_{j}.$

If $d=2$ then $Q_{2}=R^{2}$ and (5.21) becomes

$\mu\left(\mathscr{E}_{B}\right)\leqslant N^{o(1)}B^{-2t}R^{4-2t}.$

Using $R\ll Q^{1/2}N^{\eta}$ and recalling the definition of $Q$ in (5.11) we
obtain,

(5.22) $\mu\left(\mathscr{E}_{B}\right)\leqslant
N^{4-2t+\eta(4-2t)+o(1)}B^{-4}.$

Now let $d\geqslant 3$, then trivially

$\prod_{j=3}^{d}Q_{j}\leqslant\prod_{j=3}^{d}Q_{j}^{d/j}=\left(RQ_{2}^{-1/2}\right)^{d}.$

Hence we derive from (5.21) that

$\mu\left(\mathscr{E}_{B}\right)\leqslant
N^{o(1)}B^{-dt}R^{d-dt+1}Q_{2}^{3/2-d/2}\leqslant N^{o(1)}B^{-dt}R^{d-dt+1}.$

Since $t\leqslant 1$ we have $d-dt+1>0$. Therefore, using $R\ll
Q^{1/d}N^{\eta}$ we obtain

(5.23) $\begin{split}\mu\left(\mathscr{E}_{B}\right)&\leqslant
N^{\eta(2d-dt+1)}B^{-dt}\left(NB^{-1}\right)^{d-dt+1}\\\
&=N^{d-dt+1+\eta(d-dt+1)}B^{-d-1}.\end{split}$

Since $\eta$ is arbitrary, from (5.22) and (5.23) we derive the desired
result. $\sqcap$$\sqcup$

##  6\. Proof of the upper bound of Theorem 2.1

###  6.1. Mean values of Gauss sums

We need the following mean value estimate for Gauss sums with respect to an
arbitrary Radon measure, which is interesting in its own right.

######  Lemma 6.1.

Let $\mu$ be a Radon measure on $\mathsf{T}_{2}$ such that

$\mu(B(\mathbf{x},r))\ll r^{t}$

holds for some $t>0$ and for all $\mathbf{x}\in\mathsf{T}_{2}$ and $r>0$. Then
for all $M,N$ we have

$\int_{\mathsf{T}_{2}}\left|G(\mathbf{x};M,N)\right|^{6}d\mu(\mathbf{x})\leqslant
N^{6-2t+o(1)}(M+N)^{\min\\{1,t\\}}.$

###### Proof.

Let us fix some $\varepsilon>0$. Denote

$K=N^{1/2+\varepsilon}.$

By a dyadic partition argument, there exits $B\in[K,N]$ such that

(6.1)
$\int_{\mathsf{T}_{2}}\left|G(\mathbf{x};M,N)\right|^{6}d\mu(\mathbf{x})\leqslant
K^{6}\mu(\mathsf{T}_{2})+B^{6}\mu({\mathcal{E}}_{B})N^{o(1)}.$

By Lemma 5.4 we have

$\mu({\mathcal{E}}_{B})\leqslant N^{6-2t+o(1)}B^{-6}(M+N)^{\min\\{1,t\\}}.$

which after substitution in (6.1) implies

$\int_{\mathsf{T}_{2}}\left|G(\mathbf{x};M,N)\right|^{6}d\mu(\mathbf{x})\leqslant
N^{3+6\varepsilon}+N^{6-2t+o(1)}(M+N)^{\min\\{1,t\\}}.$

Since $t\leqslant 2$ and $\varepsilon$ is arbitrary, the result now follows.
$\sqcap$$\sqcup$

###  6.2. Concluding the proof

We now turn to the proof of the upper bound of Theorem 2.1. Let
$t\in(0,\dim{\mathcal{E}}_{2,\alpha})$. Then ${\mathcal{E}}_{2,\alpha}$ has
infinite ${\mathcal{H}}^{t}$-measure. By Lemma 4.1, there exists a Radon
measure $\mu$ on $\mathsf{T}_{2}$ with

$\mu({\mathcal{E}}_{2,\alpha})>0\quad\text{ and }\quad\mu(B(\mathbf{x},r))\ll
r^{t}$

for all $\mathbf{x}\in\mathsf{T}_{2}$ and $r>0$. Taking the function

$f_{n}(x_{1},x_{2})={\mathbf{\,e}}(x_{1}n+x_{2}n^{2})$

and applying Lemmas 4.3 and 6.1, we immediately derive that for almost all
$(x_{1},x_{2})\in\mathsf{T}_{2}$ with respect to $\mu$,

(6.2) $|G(x_{1},x_{2};N)|\leqslant N^{1-t/3+\min\\{1/6,t/6\\}+o(1)}.$

Since $\mu({\mathcal{E}}_{2,\alpha})>0$, there is a set of
$(x_{1},x_{2})\in\mathsf{T}_{2}$ of positive $\mu$-measure such that

$|G(x_{1},x_{2};N)|\geqslant N^{\alpha}$

for infinitely many $N\in{\mathbb{N}}$. Combining with (6.2) we derive

$\alpha\leqslant 1-t/3+\min\\{1/6,t/6\\},$

which implies

$t\leqslant\min\\{1/2+3(1-\alpha),6(1-\alpha)\\}.$

Since this holds for any $t<\dim{\mathcal{E}}_{2,\alpha}$, we conclude that

$\dim{\mathcal{E}}_{2,\alpha}\leqslant\min\\{1/2+3(1-\alpha),6(1-\alpha)\\},$

which yields the desired upper bound.

##  7\. Proof of the lower bound of Theorem 2.1

###  7.1. Large values of Gauss sums

The main purpose of this subsection is to show Lemma 7.4. We start from
recalling the following property of Gaussian sums, see [31, Equation (1.55)].

######  Lemma 7.1.

Let $p\geqslant 3$ and $a,b\in{\mathbb{Z}}_{p}$ with $b\neq 0$, then

$\left|\sum_{n=0}^{p-1}{\mathbf{\,e}}_{p}\left(an+bn^{2}\right)\right|=\sqrt{p}.$

Using the Gauss bound together with the standard completion technique, see
[31, Sections 11.11 and 12.2] we also immediately obtain:

######  Lemma 7.2.

For any prime $p$ and any $a\in{\mathbb{F}}_{p}\setminus\\{0\\}$ we have

$\max_{1\leqslant M,N\leqslant p}\left|\sum_{M+1\leqslant n\leqslant
M+N}{\mathbf{\,e}}_{p}\left(an^{2}\right)\right|\ll\sqrt{p}\log p.$

The continuity of Gauss sums yields the following result.

######  Lemma 7.3.

For $N\gg p\log p$ we have

$\displaystyle|G(x_{1},x_{2};N)$ $\displaystyle-G(a/p,b/p;N)|$
$\displaystyle\ll Np^{-1/2}(|x_{1}-a/p|N+|x_{2}-b/p|N^{2}).$

###### Proof.

We use the following version of summation by parts. Let $a_{n}$ be a sequence
and for each $t\geqslant 1$ denote

$A(t)=\sum_{1\leqslant n\leqslant t}a_{n}.$

Let $\psi:[1,N]\rightarrow{\mathbb{C}}$ be a continuously differentiable
function. Then

$\sum_{n=1}^{N}a_{n}\psi(n)=A(N)\psi(N)-\int_{1}^{N}A(t)\psi^{\prime}(t)dt.$

Let $\delta_{1}=x-a/p$, $\delta_{2}=x_{2}-b/p$. Then define

(7.1) $\begin{split}\Delta&=G(x_{1},x_{2};N)-G(a/p,b/p;N)\\\
&=\sum_{n=1}^{N}{\mathbf{\,e}}(na/p+n^{2}b/p)\left({\mathbf{\,e}}(\delta_{1}n+\delta_{2}n^{2})-1\right).\end{split}$

For an integer $M$ with $1\leqslant M\leqslant N$, we split the sum
$G(a/p,b/p;M)$ into $O(N/p)$ complete sums and at most one incomplete sum,
applying Lemmas 7.1 and 7.2, we derive

$\max_{1\leqslant M\leqslant N}|G(a/p,b/p;M)|\ll Np^{-1/2}+p^{1/2}\log p.$

Hence, applying to the sum in (7.1) summation by parts with
$a_{n}={\mathbf{\,e}}(na/p+n^{2}b/p)$ and
$\psi(t)={\mathbf{\,e}}(\delta_{1}t+\delta_{2}t^{2})-1$, we derive that

$\displaystyle\Delta$ $\displaystyle\ll\max_{1\leqslant M\leqslant
N}|G(a/p,b/p;M)|\left(|\delta_{1}|N+|\delta_{2}|N^{2}\right)$
$\displaystyle\ll\left(Np^{-1/2}+p^{1/2}\log
p\right)\left(|\delta_{1}|N+|\delta_{2}|N^{2}\right)$ $\displaystyle\ll
Np^{-1/2}\left(|\delta_{1}|N+|\delta_{2}|N^{2}\right),$

which finishes the proof. $\sqcap$$\sqcup$

From Lemma 7.1 and Lemma 7.3 we obtain the following, which is the main
purpose of this subsection.

######  Lemma 7.4.

We fix $\alpha\in(1/2,1)$. Let $p\geqslant 3$ and $a,b\in{\mathbb{Z}}_{p}$
with $b\neq 0$. Let $N$ be the smallest number such that $p|N$ and

$N\geqslant p^{\frac{1}{2(1-\alpha)}}.$

Then there exists a sufficiently small number $\eta>0$ such that for any
$(x_{1},x_{2})\in\mathsf{T}_{2}$ with

$\left|x_{1}-\frac{a}{p}\right|<\eta
p^{-\frac{1}{2(1-\alpha)}}\qquad\mbox{and}\qquad\left|x_{2}-\frac{b}{p}\right|<\eta
p^{-\frac{1}{1-\alpha}}$

we have

$G(x_{1},x_{2};N)\gg N^{\alpha}.$

###### Proof.

Recalling that $z\approx Z$ means $Z/C\leqslant z\leqslant CZ$ for some
absolute positive constant $C$. First note that the choice of $N$ implies

$N\approx p^{\frac{1}{2(1-\alpha)}}\qquad\mbox{and}\qquad Np^{-1/2}\approx
N^{\alpha}.$

By Lemma 7.3 we have

$|G(x_{1},x_{2};N)-G(a/p,b/p;N)|\ll\eta N^{\alpha}.$

Lemma 7.1 implies $G(a/p,b/p;N)\approx N^{\alpha}$. Therefore, we obtain the
desired bound by choosing a sufficiently small $\eta$. $\sqcap$$\sqcup$

###  7.2. Simultaneous Diophantine approximations

Let $\bm{\vartheta}=(\vartheta_{1},\ldots,\vartheta_{d})$ be a vector of
positive real numbers and let ${\mathfrak{Q}}$ an arbitrary set of positive
integers. Without losing generality, assuming that
$\vartheta_{1}\leqslant\ldots\leqslant\vartheta_{d}$. We denote by
$W_{{\mathfrak{Q}},\bm{\vartheta}}$ be the collection of points
$(x_{1},\ldots,x_{d})\in\mathsf{T}_{d}$ for which there are infinitely many
$q\in{\mathfrak{Q}}$ such that

$\left\|qx_{i}\right\|<q^{-\vartheta_{i}},\qquad i=1,\ldots,d,$

where $\left\|x\right\|=\min\\{|x-n|:\leavevmode\nobreak\
n\in{\mathbb{Z}}\\}$. Denote

$\nu({\mathfrak{Q}})=\inf\left\\{\nu\in{\mathbb{R}}:\leavevmode\nobreak\
\sum_{q\in{\mathfrak{Q}}}q^{-\nu}<\infty\right\\}.$

We need the following result of Rynne [36, Theorem 1].

######  Lemma 7.5.

Suppose that $\vartheta_{1}+\ldots+\vartheta_{d}\geqslant\nu({\mathfrak{Q}}),$
then we have

$\dim W_{{\mathfrak{Q}},\bm{\vartheta}}=\min_{1\leqslant j\leqslant
d}\frac{d+\nu({\mathfrak{Q}})+j\vartheta_{j}-\sum_{i=1}^{j}\vartheta_{i}}{1+\vartheta_{j}}.$

For $d=2$ and $\nu({\mathfrak{Q}})=1$ we have the following.

$\dim
W_{{\mathfrak{Q}},\bm{\vartheta}}=\min\left\\{\frac{3}{1+\vartheta_{1}},\frac{3+\vartheta_{2}-\vartheta_{1}}{1+\vartheta_{2}}\right\\}.$

We now turn to the proof of the lower bound of Theorem 2.1. Indeed this
follows by combining Lemma 7.4 and Lemma 7.5. Let ${\mathfrak{Q}}$ be the
collection of prime numbers. Clearly we have $\nu({\mathfrak{Q}})=1$. By Lemma
7.4, for any $\varepsilon>0$ we obtain

$W_{{\mathfrak{Q}},\vartheta}\subseteq{\mathcal{E}}_{2,\alpha-\varepsilon}$

with

$\vartheta_{1}=\frac{1}{2(1-\alpha)}-1\qquad\mbox{and}\qquad\vartheta_{2}=\frac{1}{1-\alpha}-1.$

Since $\alpha\in(1/2,1)$, we have $\vartheta_{1}+\vartheta_{2}\geqslant 1$.
Thus by Lemma 7.5 we obtain

$\dim W_{{\mathfrak{Q}},\vartheta}=\min\\{1/2+3(1-\alpha),6(1-\alpha)\\}.$

It follows that

$\dim{\mathcal{E}}_{2,\alpha-\varepsilon}\geqslant\min\\{1/2+3(1-\alpha),6(1-\alpha)\\}.$

Since $\varepsilon>0$ is arbitrary, we obtain the desired bound.

##  8\. Proof of Theorem 2.2

###  8.1. Mean values of Weyl sums

We need the following mean value estimate of Weyl sums with respect to a
general measure.

######  Lemma 8.1.

Let $\mu$ be a Radon measure on $\mathsf{T}_{d},d\geqslant 3$ such that

$\mu(B(\mathbf{x},r))\ll r^{t}$

holds for some $t>0$ and for all $\mathbf{x}\in\mathsf{T}_{d}$ and $r>0$. Then
for any integer $h$ with $1\leqslant h\leqslant d$ we have

$\displaystyle\int_{\mathsf{T}_{d}}|S_{d}(\mathbf{x};M,N)|^{d^{2}+1}$
$\displaystyle d\mu(\mathbf{x})\leqslant N^{(1-1/D)(d^{2}+1)+o(1)}$
$\displaystyle+N^{d^{2}+1-dt+o(1)}(M+N)^{(d-h)t+h(h-1)/2},$

where $D$ is given by (2.1).

###### Proof.

Let us fix some $\varepsilon>0$. Denote

$K=N^{1-1/D+\varepsilon}.$

Similar to the proof of Lemma 6.1, taking a dyadic partition of the interval
$[K,N]$, there exists a number $B\in[K,N]$ such that

$\displaystyle\int_{\mathsf{T}_{d}}|S_{d}(\mathbf{x};M,N)|^{d^{2}+1}d\mu(\mathbf{x})$
$\displaystyle\qquad\leqslant
K^{d^{2}+1}+N^{o(1)}B^{d^{2}+1}\mu(\\{\mathbf{x}\in\mathsf{T}_{d}:B\leqslant
S_{d}(\mathbf{x};M,N)|\leqslant 2B\\}).$

Combining with Lemma 5.7 we obtain

$\displaystyle\int_{\mathsf{T}_{d}}|S_{d}(\mathbf{x};M,N)|^{d^{2}+1}d\mu(\mathbf{x})$
$\displaystyle\qquad\leqslant
N^{(1-1/D)(d^{2}+1)+\varepsilon(d^{2}+1)}+N^{o(1)}N^{d^{2}+1-dt}(M+N)^{(d-h)t+h(h-1)/2}.$

By the arbitrary choice of $\varepsilon>0$ we obtain the desired bound.
$\sqcap$$\sqcup$

###  8.2. Concluding the proof

We now turn to the proof of Theorem 2.2. Let
$t\in(0,\dim{\mathcal{E}}_{d,\alpha})$. Then we see that
${\mathcal{E}}_{d,\alpha}$ has infinite ${\mathcal{H}}^{t}$-measure. By Lemma
4.1, there exists a Radon measure $\mu$ on $\mathsf{T}_{d}$ with

$\mu({\mathcal{E}}_{2,\alpha})>0\quad\text{ and }\quad\mu(B(\mathbf{x},r))\ll
r^{t}$

for all $\mathbf{x}\in\mathsf{T}_{d}$ and $r>0$.

Let $1\leqslant h\leqslant d$ be an integer. There are two cases to consider.

Case 1. Suppose that the ‘total exponent’

$d^{2}+1-dt+(d-h)t+h(h-1)/2=d^{2}+1-ht+h(h-1)/2$

in the second term in the bound of Lemma 8.1 is at least as large as the
exponent of the first term, that is,

$d^{2}+1-ht+h(h-1)/2\geqslant(1-1/D)(d^{2}+1).$

Since $t<\dim{\mathcal{E}}_{d,\alpha}\leqslant d$, we have $d^{2}+1-dt>1$, and
thus by Lemma 4.3 we derive that for almost all $\mathbf{x}\in\mathsf{T}_{d}$
with respect to $\mu$,

(8.1) $|S_{d}(\mathbf{x};N)|\leqslant
N^{\frac{d^{2}+1-ht+h(h-1)/2}{d^{2}+1}+o(1)}.$

Since $\mu({\mathcal{E}}_{d,\alpha})>0$, there is a set of
$\mathbf{x}\in\mathsf{T}_{d}$ of positive $\mu$-measure such that

$|S_{d}(\mathbf{x};N)|\geqslant N^{\alpha}$

for infinitely many $N\in{\mathbb{N}}$. Combining with (8.1) we derive

(8.2) $\alpha\leqslant\frac{d^{2}+1-ht+h(h-1)/2}{d^{2}+1},$

which implies

(8.3) $t\leqslant\frac{(d^{2}+1)(1-\alpha)}{h}+\frac{h-1}{2}.$

Case 2. Suppose that $d^{2}+1-th+h(h-1)/2<(1-1/D)(d^{2}+1)$. Then Lemma 8.1
implies that

$|S_{d}(\mathbf{x};N)|\leqslant
N^{d^{2}+1-dt+o(1)}(M+N)^{(1-1/D)(d^{2}+1)-(d^{2}+1-dt)}.$

By Lemma 4.3 we conclude that for almost all $\mathbf{x}\in\mathsf{T}$ with
respect to $\mu$,

$|S_{d}(\mathbf{x};N)|\leqslant N^{1-1/D+o(1)}.$

Then applying the similar argument to Case 1, we obtain

(8.4) $\alpha\leqslant 1-1/D,$

which contradicts our assumption that $\alpha\in(1-1/D,1)$. Thus we are in
Case 1 and we have (8.3) for any integer $1\leqslant h\leqslant d$. Since
(8.3) holds for any $t<\dim{\mathcal{E}}_{d,\alpha}$, we obtain the desired
upper bound.

##  9\. Proof of Theorem 2.3

###  9.1. One-dimensional mean values of Weyl sums

For the proof of Theorem 2.3, similarly to the proofs of the upper bounds of
Theorems 2.1 and 2.2, we see from Lemma 4.1 that it is sufficient to prove the
following mean value bounds.

We start with quadratic polynomials.

######  Lemma 9.1.

Let $f\in{\mathbb{R}}[X]$ be a polynomial of degree $d=2$. Let $\mu$ be a
Radon measure on $\mathsf{T}$ such that

$\mu(B(\mathbf{x},r))\ll r^{t}$

holds for some $t\in(0,1)$ and for all $x\in\mathsf{T}$ and $r>0$. Then for
all $M,N$ we have

$\int_{\mathsf{T}}|V_{f}(x;M,N)|^{4}d\mu(x)\leqslant N^{4(1-t/2)+o(1)}.$

###### Proof.

Let us fix some $\varepsilon>0$. Denote

$K=N^{1/2+\varepsilon}.$

Similar to the proofs of Lemmas 6.1 and 8.1, taking a dyadic partition of the
interval $[K,N]$, there exists a number $B\in[K,N]$ such that

$\int_{\mathsf{T}}|V_{f}(x;M,N)|^{4}d\mu(x)\leqslant
K^{4}+N^{o(1)}B^{4}\mu({\mathcal{E}}_{B}).$

Hence by Lemma 5.8 applied with $d=2$, we have

$\int_{\mathsf{T}}|V_{f}(x;M,N)|^{4}d\mu(x)\leqslant K^{4}+N^{4-2t+o(1)}.$

Since $t\leqslant 1$ and $\varepsilon$ is arbitrary, the result now follows.
$\sqcap$$\sqcup$

For polynomials of higher degree we have a similar bound.

######  Lemma 9.2.

Let $f\in{\mathbb{R}}[X]$ be a polynomial of degree $d\geqslant 3$. Let $\mu$
be a Radon measure on $\mathsf{T}$ such that

$\mu(B(\mathbf{x},r))\ll r^{t}$

holds for some $t\in(0,1)$ and for all $x\in\mathsf{T}$ and $r>0$. Then for
all $M,N$ we have

$\int_{\mathsf{T}}|V_{f}(x;M,N)|^{d+1}d\mu(x)\leqslant
N^{d+1-(d+1)/D+o(1)}+N^{d+1-dt+o(1)},$

where $D$ is given by (2.1).

###### Proof.

Let us fix some $\varepsilon>0$. Denote

$K=N^{1-1/D+\varepsilon}.$

Then, similarly to the above, by Lemma 5.8 with $d\geqslant 3$ there exists
$K\leqslant B\leqslant N$ such that

$\int_{\mathsf{T}}|V_{f}(x;M,N)|^{d+1}d\mu(x)\leqslant
K^{d+1}+N^{o(1)}B^{d+1}\mu({\mathcal{E}}_{B}).$

By Lemma 5.8, we have

$\int_{\mathsf{T}}|V_{f}(x;M,N)|^{d+1}d\mu(x)\leqslant
K^{d+1}+N^{d-dt+1+o(1)}.$

Since $\varepsilon$ is arbitrary, the result now follows. $\sqcap$$\sqcup$

###  9.2. Concluding the proof

Similarly to the proofs of the upper bounds of Theorems 2.1 and 2.2, Lemmas
9.1 and 9.2 combined with Lemma 4.3 imply the desired upper bound of Theorem
2.3.

In particular, for $d=2$ the proof is a full analogue of that of the upper
bound of Theorem 2.1 where we use Lemma 9.1 in an appropriate place instead of
Lemma 6.1.

For $d\geqslant 3$, as in the proofs of Theorem 2.2, we consider two cases

$t\leqslant\frac{d+1}{dD}\qquad\mbox{and}\qquad t>\frac{d+1}{dD}.$

Now, by Lemma 4.3, in the first case, similarly to (8.2), we derive

$\alpha\leqslant\frac{d-dt+1}{d+1}$

which gives the desired bound, while in the second case we obtain (8.4), which
contradicts the assumption $\alpha\in(1-1/D,1)$.

##  10\. Proofs of Theorems 3.1, 3.3, 3.4, 3.5 and 3.6

###  10.1. Mean values of exponential polynomials

For a real sequences $f(n)$ we define the sums

(10.1)
$W_{f}(\mathbf{x};N)=\sum_{h=-N}^{N}\frac{1}{|h|+1}\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(hn/N+xf(n)\right)\right|.$

Then a special form of [16, Lemma 3.2] implies for $\mathbf{x}\in\mathsf{T}$
and $1\leqslant M\leqslant N$ we have

(10.2) $V_{f}(\mathbf{x};M)\ll W_{f}(\mathbf{x};N),$

where $W_{f}(\mathbf{x};N)$ is given by (10.1).

Our method is based on mean value estimates on the sums $W_{f}(x;N)$. However
our next result shows that for integer-valued sequences the mean value of
$W_{f}(x;N)$ is controlled by the mean value of $V_{f}(x;N)$ provided that the
exponent is some even integer. It follows by using a similar argument to the
proof of [18, Lemma 2.4]. We give a proof here for completeness.

######  Lemma 10.1.

Let $f\in{\mathbb{Z}}[x]$ be an integer sequence such that for some even
number $s>0$ and some real $t>0$ one has

$\int_{\mathsf{T}}|V_{f}(x;N)|^{s}dx\ll N^{t},$

then we have

$\int_{\mathsf{T}}W_{f}(x;N)^{s}dx\ll N^{t}(\log N)^{s}.$

###### Proof.

Write

$\displaystyle
W_{f}(\mathbf{x};N)=\sum_{h=-N}^{N}\left(\frac{1}{|h|+1}\right)^{1-1/s}$
$\displaystyle\left(\frac{1}{|h|+1}\right)^{1/s}$
$\displaystyle\times\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(hn/N+xf(n)\right)\right|.$

Applying the Hölder inequality, we obtain

(10.3) $\begin{split}W_{f}(\mathbf{x};N)^{s}\ll\left(\log
N\right)^{s-1}&\sum_{h=-N}^{N}\frac{1}{1+|h|}\\\
&\quad\quad\quad\times\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(hn/N+xf(n)\right)\right|^{s}.\end{split}$

For any $h$ and $N$ and even number $s$, opening the integral and applying the
orthogonal property of ${\mathbf{\,e}}(x)$, we derive

$\displaystyle\int_{\mathsf{T}}$
$\displaystyle\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(hn/N+xf(n)\right)\right|^{s}dx$
$\displaystyle=\\#\left\\{(n_{1},\ldots,n_{s}):\leavevmode\nobreak\ 1\leqslant
n_{i}\leqslant N,\ \sum_{i=1}^{s/2}(f(n_{i})-f(n_{s/2+i})=0\right\\}$
$\displaystyle=\int_{\mathsf{T}}\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(xf(n)\right)\right|^{s}dx.$

Combining with (10.3) we obtain the desired bound. $\sqcap$$\sqcup$

Observe that Lemma 10.1 implies that for integer-values sequences, we only
need to estimate the moments of the sums $V_{f}(x;N)$ rather than of
$W_{f}(x;N)$.

We now recall some mean value estimates on the sums $V_{f}(x;N)$ in (1.5) when
$f\in{\mathbb{Z}}[x]$ is a polynomial. We first recall the following result of
Hua [29], see also [40, Section 14].

######  Lemma 10.2.

Let $f\in{\mathbb{Z}}[x]$ be a polynomial with degree $d\geqslant 2$, then for
each natural number $1\leqslant r\leqslant d$,

$\int_{T}|V_{f}(x;N)|^{2^{r}}dx\leqslant N^{2^{r}-r+o(1)}.$

Wooley [40, Corollary 14.2] (see also [8, Theorem 10]) obtains the following
better bound when $r$ is large.

######  Lemma 10.3.

Let $f\in{\mathbb{Z}}[x]$ be a polynomial with degree $d\geqslant 2$, then for
each natural number $1\leqslant r\leqslant d$,

$\int_{T}|V_{f}(x;N)|^{r(r+1)}dx\leqslant N^{r^{2}+o(1)}.$

Furthermore, for the case of monomials Wooley [40, Corollary 14.7] gives a
stronger result.

######  Lemma 10.4.

Let $d\geqslant 2$ and

$s_{0}=d(d-1)+\min_{r=1,\ldots,d}\frac{2d+(r-1)(r-2)}{r}.$

Then

$\int_{T}\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(xn^{d}\right)\right|^{s_{0}}dx\leqslant
N^{s_{0}-d+o(1)}.$

We now turn to mean value theorems for sums with arbitrary sequences.

In particular, we have the following simple bound on the second moment of the
sums $W_{f}(x;N)$, defined by (1.5) with well-spaced sequences.

######  Lemma 10.5.

Let $f(n)$ be a real sequence such that $f(n)-f(m)\gg 1$ for all $m\neq n$.
Then for any interval ${\mathcal{I}}$ we have

$\int_{{\mathcal{I}}}W_{f}(x;N)^{2}dx\ll N(\log N)^{3},$

where $W_{f}(\mathbf{x};N)$ is given by (10.1).

###### Proof.

By the Cauchy inequality, we obtain

$\displaystyle W_{f}(x;N)^{2}$ $\displaystyle\ll\log
N\sum_{h=-N}^{N}\frac{1}{|h|+1}\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(hn/N+xf(n)\right)\right|^{2}$
$\displaystyle\ll\log
N\sum_{h=-N}^{N}\frac{1}{|h|+1}\left(N+\Sigma(x)\right),$

where

$\Sigma(x)=\sum_{1\leqslant n\neq m\leqslant
N}{\mathbf{\,e}}(h(n-m)/N+x(f(n)-f(m)).$

The condition $|f(n)-f(m)|\gg 1$ implies that the values $f(1),\ldots,f(N)$
are separated from each by a unit interval, and thus so are the values
$f(1)-\zeta,\ldots,f(N)-\zeta$ for any real $\zeta$. In particular

$\sum_{\begin{subarray}{c}n=1\\\
f(n)\neq\zeta\end{subarray}}^{N}\frac{1}{|f(n)-\zeta|}\ll\log N.$

Therefore,

$\displaystyle\int_{{\mathcal{I}}}\left|\Sigma(x)\right|dx$
$\displaystyle\ll\sum_{1\leqslant n\neq m\leqslant
N}\left|\int_{{\mathcal{I}}}{\mathbf{\,e}}(x(f(n)-f(m))dx\right|$
$\displaystyle\ll\sum_{1\leqslant n\neq m\leqslant N}\frac{1}{|f(n)-f(m)|}\ll
N\log N.$

Combining with (10.1) we obtain the desired bound. $\sqcap$$\sqcup$

Suppose that $f(n)\in{\mathbb{N}}$ is a strictly convex sequence, Iosevich,
Konyagin, Rudnev, and Ten [30, Equation (1.13)] (general even number $s$) and
Shkredov [38, Theorem 1.1] ($s=4$) gives the following bounds.

######  Lemma 10.6.

Suppose that $f(n)\in{\mathbb{N}}$ is a strictly convex sequence, then

$\int_{\mathsf{T}}|V_{f}(x;N)|^{4}dx\ll N^{32/13+o(1)}$

and for any even number $s\geqslant 6$ we have

$\int_{\mathsf{T}}|V_{f}(x;N)|^{s}dx\ll N^{s-2+2^{1-s/2}}.$

We note that for sequences satisfying stronger conditions than convexity
stronger versions of Lemma 10.6 are known, see [12].

We now observe that the result of Robert and Sargos [34, Theorem 2] implies
the following bound.

######  Lemma 10.7.

Let $f(n)=\left\lfloor n^{\tau}\right\rfloor$ for some $\tau\geqslant 1$.

$\int_{\mathsf{T}}|V_{f}(x;N)|^{4}dx\ll N^{2+o(1)}+N^{4-\tau+o(1)}.$

###  10.2. Continuity of exponential polynomials

The following is a special form of [15, Lemma 2.4].

######  Lemma 10.8.

Let $f(n)$ be a real sequnce that satisfies (3.2) for some constant $\tau>0$.
Let $0<\alpha<1$ and let $\varepsilon>0$ be sufficiently small. If
$W_{f}(x;N)\geqslant N^{\alpha}$ for some $x\in\mathsf{T}$, then

$W_{f}(y;N)\geqslant N^{\alpha}/2$

holds for any $y\in(x-\zeta,x+\zeta)$ provided that $N$ is large enough and

$0<\zeta\leqslant N^{\alpha-\tau-1-\varepsilon}.$

###### Proof.

Note that for any $x,y\in{\mathbb{R}}$ and any $h,N$ we have

${\mathbf{\,e}}(hn/N+xf(n))-{\mathbf{\,e}}(hn/N+yf(n))\ll|x-y||f(n)|.$

Thus we obtain

$|W_{f}(x;N)-W_{f}(y;N)|\ll|x-y|\log N\sum_{n=1}^{N}|f(n)|,$

which yields the desired result. $\sqcap$$\sqcup$

######  Lemma 10.9.

Let $f(n)$ be a real sequnce that satisfies (3.2) for some constant $\tau>0$.
Suppose that

$\int_{\mathsf{T}}W_{f}(x;N)^{s}dx\leqslant N^{t+o(1)}.$

Then

$\left\\{x\in\mathsf{T}:\leavevmode\nobreak\ W_{f}(x;N)\geqslant
N^{\alpha}\right\\}\subseteq\bigcup_{I\in{\mathcal{I}}_{N}}I,$

where ${\mathcal{I}}_{N}$ is a collection of intervals with equal length such
that $|I|\leqslant N^{\alpha-\tau-1-\varepsilon}$ for each
$I\in{\mathcal{I}}_{N}$ and of cardinality

$\\#{\mathcal{I}}_{N}\leqslant N^{t-s\alpha+\tau+1-\alpha+2\varepsilon}$

provided that $N$ is sufficiently large.

###### Proof.

Let

$\zeta=1/\left\lceil N^{\tau+1+\varepsilon-\alpha}\right\rceil.$

We divide $\mathsf{T}$ into $\zeta^{-1}$ intervals of the type
$[k\zeta,(k+1)\zeta]$ with $k=0,1,\ldots,\zeta^{-1}-1$. Let
${\mathcal{D}}_{N}$ be the collection of these intervals and

${\mathcal{I}}_{N}=\\{I\in{\mathcal{D}}_{N}:\leavevmode\nobreak\ \exists\,x\in
I\text{ such that }W_{f}(x;N)\geqslant N^{\alpha}\\}.$

Lemma 10.8 implies that for each $I\in{\mathcal{I}}_{N}$,

$W_{f}(x;N)\geqslant N^{\alpha}/2,\qquad\forall x\in I.$

It follows that

$(\\#{\mathcal{I}}_{N})\zeta
N^{s\alpha}\ll\int_{\mathsf{T}}W_{f}(x;N)^{s}dx\leqslant N^{t+o(1)},$

which gives the desired result. $\sqcap$$\sqcup$

###  10.3. Mean values and Hausdorff dimension for polynomially growing
sequences

We have the following general result about the upper bound on
$\dim{\mathcal{F}}_{f,\alpha}$.

######  Lemma 10.10.

Let $f(n)$ be a real sequence that satisfies (3.2) for some constant $\tau>0$.
Suppose that there are positive constants $s,t$ such that

$\int_{\mathsf{T}}|W_{f}(x;N)|^{s}dx\leqslant N^{t+o(1)}.$

Then

$\dim{\mathcal{F}}_{f,\alpha}\leqslant\frac{\tau+1-\alpha+t-s\alpha}{\tau+1-\alpha}.$

###### Proof.

For each $N\in{\mathbb{N}}$ denote

$B_{N}=\\{x\in T:\leavevmode\nobreak\ W_{f}(x;N)\geqslant N^{\alpha}\\}.$

Let $N_{i}=2^{i}$, $i\in{\mathbb{N}}$ and $\eta>0$. Applying (10.2) we obtain

${\mathcal{F}}_{f,\alpha+\eta}\subseteq\bigcap_{q=1}^{\infty}\bigcup_{i=q}^{\infty}B_{N_{i}}.$

Indeed, let $x\in{\mathcal{F}}_{f,\alpha+\eta}$ and suppose to the contrary
that

$x\notin\bigcap_{q=1}^{\infty}\bigcup_{i=q}^{\infty}B_{N_{i}}.$

Then $W_{f}(x;N_{i})<N_{i}^{\alpha}$ holds for all large $N_{i}$. For any $N$
there exists a number $i\in{\mathbb{N}}$ such that $N_{i}\leqslant N<N_{i+1}$,
and for large enough $N$ by Lemma 10.9 we have

$V_{f}(x;N)\ll W_{f}(x;N_{i+1})\ll N_{i+1}^{\alpha}\ll N^{\alpha},$

which contradicts our assumption.

For each $N_{i}$ by Lemma 10.9 we obtain

$B_{N_{i}}\subseteq\bigcup_{I\in{\mathcal{I}}_{N_{i}}}{\mathcal{I}}_{N_{i}},$

where $|I|\leqslant N^{\alpha-\tau-1-\varepsilon}$ for each
$I\in{\mathcal{I}}_{N_{i}}$ and $\\#{\mathcal{I}}_{N_{i}}\leqslant
N_{i}^{t-s\alpha+\tau+1-\alpha+2\varepsilon}$.

From the definition of the Hausdorff dimension, using the above notation, we
have the following inequality

(10.4)
$\dim{\mathcal{F}}_{f,\alpha+\eta}\leqslant\inf\left\\{\nu>0:\leavevmode\nobreak\
\sum_{i=1}^{\infty}\sum_{I\in{\mathcal{I}}_{N_{i}}}|I|^{\nu}<\infty\right\\}.$

Note that

$\sum_{i=1}^{\infty}\sum_{I\in{\mathcal{I}}_{N_{i}}}|I|^{\nu}\ll\sum_{i=1}^{\infty}N_{i}^{t-s\alpha+\tau+1-\alpha+2\varepsilon}N_{i}^{(\alpha-\tau-1)\nu},$

thus to make the series convergent it is sufficient to have

$\nu>\frac{t-s\alpha+\tau+1-\alpha+2\varepsilon}{\tau+1-\alpha}.$

Combining with (10.4) and the arbitrary choice of $\varepsilon>0$ we obtain

$\dim{\mathcal{F}}_{f,\alpha+\eta}\leqslant\frac{\tau+1-\alpha+t-s\alpha}{\tau+1-\alpha}.$

Since this holds for any $\eta>0$, we obtain the desired bound.
$\sqcap$$\sqcup$

###  10.4. Concluding the proofs

Combining Lemma 10.10 (and taking $\tau=d$ for polynomial sequneces) with

  * •

Lemmas 10.1, 10.2 and 10.3, we obtain Theorem 3.1;

  * •

Lemmas 10.1 and 10.4, we obtain Theorem 3.3;

  * •

Lemmas 10.1 and 10.7, we obtain Theorem 3.4;

  * •

Lemma 10.5, we obtain Theorem 3.5;

  * •

Lemmas 10.1 and 10.6, we obtain Theorem 3.6.

##  11\. Proofs of Theorems 3.7 and 3.8

###  11.1. Proof of Theorem 3.7

The upper bound of Theorem 3.7 follows by applying Lemmas 4.1 and 4.3 and the
following mean value bound of Baker [2, Equation (18)].

######  Lemma 11.1.

Let $f(n)$ be a sequence of natural numbers with $f(n)=O(n^{\tau})$ for some
real number $\tau>0$. Let $\mu$ be a Radon measure on $\mathsf{T}$ such that

$\mu(B(\mathbf{x},r))\ll r^{t}$

holds for some $t\in(0,1)$ and for all $x\in\mathsf{T}$ and $r>0$. Then for
all $M,N$ we have

$\int_{\mathsf{T}}|V_{f}(x;M,N)|^{2}d\mu(x)\ll N(M+N)^{\tau(1-t)}.$

###  11.2. Proof of Theorem 3.8

By (3.4) the upper bound holds always, and hence we now prove the lower bound.
For any $\tau\geqslant 1$, Ruzsa [35] defines a strictly increasing sequence
of natural numbers $g(n)$ with $g(n)=O(n^{\tau})$, a constant $0<\ell_{0}<1$
(depending on $\tau$) and a set $\mathscr{G}\subseteq\mathsf{T}$ with
$\dim\mathscr{G}=1-1/\tau$, having the following property.

If $x\in\mathscr{G}$ then there are infinitely many $N$ and corresponding
intervals ${\mathcal{I}}(N,x)\subseteq T$ of length $\ell_{0}$ such that

(11.1) $\sum_{\begin{subarray}{c}n=1\\\
\\{xg(n)\\}\in{\mathcal{I}}(N,x)\end{subarray}}^{N}1\geqslant 2\ell_{0}N,$

where as usual $\\{u\\}$ denotes the fractional part of a real $u$.

Fix an integer

(11.2) $H>4/\ell_{0}.$

By [3, Lemma 2.7], there is a trigonometric polynomial

$\varPsi_{N,x}(y)=C_{0}+\sum_{0<|k|\leqslant H}C_{k}(N,x){\mathbf{\,e}}(ky),$

depending on $N$ and $x$ with

(11.3) $C_{0}=\ell_{0}+\frac{1}{H+1}$

and such that

(11.4) $\varPsi_{N,x}(y)\geqslant\begin{cases}1&\text{if}\
y\in{\mathcal{I}}(N,x),\\\ 0&\text{otherwise}.\end{cases}$

Note that since $\varPsi_{N,x}(y)\geqslant 0$, for any $k\neq 0$ we have

$|C_{k}(N,x)=\left|\int_{\mathsf{T}}\varPsi_{N,x}(y){\mathbf{\,e}}(-ky)dy\right|\leqslant\int_{\mathsf{T}}\varPsi_{N,x}(y)dy=C_{0},$

and hence

(11.5) $|C_{k}(N,x)|\leqslant C_{0},\qquad 0<|k|\leqslant H.$

Let $x\in\mathscr{G}$. Then by (11.1) and (11.4) we have

$\sum_{n=1}^{N}\varPsi_{N,x}\left(xg(n)\right)\geqslant 2\ell_{0}N.$

Thus

$C_{0}N+\sum_{0<|k|\leqslant
H}\left|C_{k}(N,x)\right|\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(kxg(n\right))\right|\geqslant
2\ell_{0}N.$

Recalling (11.2) and (11.3) we see that $2\ell_{0}-C_{0}\geqslant\ell_{0}/2$.
Hence

$\sum_{0<|k|\leqslant
H}\left|C_{k}(N,x)\right|\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(kxg(n)\right)\right|\geqslant\frac{\ell_{0}}{2}N,$

which together with (11.5) implies that there exists a number $k\in\\{\pm
1,\ldots,\pm H\\}$ such that

$\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(kxg(n)\right)\right|\geqslant\frac{\ell_{0}}{4HC_{0}}N.$

(we note that the number $k$ depends on $x$ and $N$).

Since for any $x\in\mathscr{G}$ and $N$ such that (11.1) holds there are
finite choices of $k$, we conclude that for any $x\in\mathscr{G}$ there exists
a number $k\in\\{\pm 1,\ldots,\pm H\\}$ such that for infinitely many $N$ we
have

$\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(kxg(n)\right)\right|\geqslant\frac{\ell_{0}}{4HC_{0}}N.$

That is, with $f_{k}(n)=|k|g(n)$ we have

$\mathscr{G}\subseteq\bigcup_{k=1}^{H}\mathscr{G}_{f_{k},c},$

where $c=\ell_{0}/(4HC_{0})$ and $\mathscr{G}_{f,c}$ is given by (3.3).
Therefore, for some $k\in\\{1,\ldots,H\\}$ we have.

$\dim\mathscr{G}_{f_{k},c}\geqslant\dim\mathscr{G}\geqslant 1-1/\tau.$

Together with the upper bound (3.4) this finishes the proof.

##  12\. Proof of Theorem 3.9

###  12.1. Preliminaries

Let ${\mathcal{S}}=(A_{n})_{n\in{\mathbb{N}}}$ be a sequence of $d\times d$
matrix. For any $\mathbf{h}\in{\mathbb{R}}^{d}$ (which treat as a column
vector) and $N\in{\mathbb{N}}$ let

$V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)=\sum_{n=1}^{N}{\mathbf{\,e}}\left(\left\langle\mathbf{x}A_{n},\mathbf{h}\right\rangle\right).$

where $\left\langle\mathbf{y},\mathbf{z}\right\rangle$ denotes the standard
scalar product.

######  Lemma 12.1.

Let ${\mathcal{S}}=(A_{n})_{n\in{\mathbb{N}}}$ be a sequence of $d\times d$
integer matrix such that $(A_{n}-A_{m})$ is invertible if $n\neq m$. Then for
any $\mathbf{h}\in{\mathbb{Z}}^{d}\setminus\\{{\bf 0}\\}$ and
$N\in{\mathbb{N}}$ we have

$\int_{\mathsf{T}_{d}}\left|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)\right|^{2}d\mathbf{x}=N.$

###### Proof.

Opening the square we have

$\displaystyle\int_{\mathsf{T}_{d}}$
$\displaystyle\left|\sum_{n=1}^{N}{\mathbf{\,e}}\left(\left\langle\mathbf{x}A_{n},\mathbf{h}\right\rangle\right)\right|^{2}d\mathbf{x}$
$\displaystyle=\sum_{1\leqslant n,m\leqslant
N}\int_{\mathsf{T}_{d}}{\mathbf{\,e}}\left(\left\langle\mathbf{x},(A_{n}-A_{m})\mathbf{h}\right\rangle\right)d\mathbf{x}$
$\displaystyle=N+\sum_{1\leqslant n\neq m\leqslant
N}\int_{\mathsf{T}_{d}}{\mathbf{\,e}}\left(\left\langle\mathbf{x},(A_{n}-A_{m})\mathbf{h}\right\rangle\right)d\mathbf{x}.$

By our condition that $A_{n}-A_{m}$ is invertible when $n\neq m$, we conclude
that $(A_{n}-A_{m})\mathbf{h}$ is a non-zero integer vector, and hence for
$n\neq m$ we have

$\int_{\mathsf{T}_{d}}{\mathbf{\,e}}\left(\left\langle\mathbf{x},(A_{n}-A_{m})\mathbf{h}\right\rangle\right)d\mathbf{x}=0,$

which yields the desired identity. $\sqcap$$\sqcup$

We have the following analogy of Lemma 10.8.

######  Lemma 12.2.

Let ${\mathcal{S}}=(A_{n})_{n\in{\mathbb{N}}}$ be a sequence of $d\times d$
matrices that satisfies (3.6) for some $\tau\geqslant 1/d$ and let
$\mathbf{h}\in{\mathbb{R}}^{d},c\in(0,1)$. Then there exists $\varepsilon>0$
such that if $|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|\geqslant cN$ for
some $\mathbf{x}\in\mathsf{T}_{d}$ then

$|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|\geqslant cN/2$

holds for any $\mathbf{y}\in B(\mathbf{x},\varepsilon N^{-\tau})$, where
$B(\mathbf{x},r)$ denotes the ball of $\mathsf{T}_{d}$ centered at
$\mathbf{x}$ and of radius $r$.

###### Proof.

For any $n\in{\mathbb{N}},\mathbf{h}\in{\mathbb{R}}^{d}$ and
$\mathbf{x},\mathbf{y}\in\mathsf{T}_{d}$ we have

$\displaystyle{\mathbf{\,e}}(\left\langle\mathbf{x}A_{n},\mathbf{h}\right\rangle)-{\mathbf{\,e}}(\left\langle\mathbf{y}A_{n},\mathbf{h}\right\rangle)$
$\displaystyle\ll\left\langle\mathbf{x}A_{n},\mathbf{h}\right\rangle-\left\langle\mathbf{y}A_{n},\mathbf{h}\right\rangle$
$\displaystyle=\left\langle(\mathbf{x}-\mathbf{y})A_{n},\mathbf{h}\right\rangle\ll\|A_{n}\|\|\mathbf{h}\|\|\mathbf{x}-\mathbf{y}\|.$

It follows that

$V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)-V_{{\mathcal{S}},\mathbf{h}}(\mathbf{y};N)\ll\|\mathbf{x}-\mathbf{y}\|N^{\tau+1}\|\mathbf{h}\|,$

which yields the desired bound. $\sqcap$$\sqcup$

######  Lemma 12.3.

Let ${\mathcal{S}}=(A_{n})_{n\in{\mathbb{N}}}$ be a sequence of $d\times d$
matrix that satisfies (3.6) for some $\tau\geqslant 1/d$ and let
$\mathbf{h}\in{\mathbb{R}}^{d},c\in(0,1)$. Then there exists $\varepsilon>0$
such that

$\\{\mathbf{x}\in\mathsf{T}_{d}:\leavevmode\nobreak\
|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|\geqslant
cN\\}\subseteq\bigcup_{Q\in{\mathcal{Q}}_{N}}Q,$

where ${\mathcal{Q}}_{N}$ is a certain collection of equal cubes with the side
lengths $1/\left\lfloor N^{\tau}\varepsilon^{-1}\right\rfloor$ and

(12.1) $\\#{\mathcal{Q}}_{N}\ll N^{d\tau-1},$

where the implied constant depends on $\varepsilon$.

###### Proof.

Divide $\mathsf{T}_{d}$ into $\zeta^{-d}$ interior disjoint equal cubes in a
natural way such that each cube has side length $\zeta=1/\left\lfloor
N^{\tau}\varepsilon^{-1}\right\rfloor$, and let ${\mathcal{D}}_{n}$ be a
collection of these cubes. Let

${\mathcal{Q}}_{N}=\\{Q\in{\mathcal{D}}_{n}:\leavevmode\nobreak\
\exists\,\mathbf{x}\in Q,\ \text{such that}\
|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|\geqslant cN\\}.$

It is sufficient to show that ${\mathcal{Q}}_{N}$ satisfies (12.1). For any
$Q\in{\mathcal{Q}}_{N}$ by Lemma 12.2 we have
$|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|\geqslant cN/2$ for all
$\mathbf{x}\in Q$. Hence

$N^{2}\\#{\mathcal{Q}}_{N}N^{-d\tau}\varepsilon^{d}\ll\int_{{\mathcal{Q}}_{N}}|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|^{2}d\mathbf{x}\leqslant\int_{\mathsf{T}^{d}}|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|^{2}d\mathbf{x}.$

Combining with the mean value bound Theorem 12.1 we derive

$N^{2}N^{-d\tau}\\#{\mathcal{Q}}_{N}\ll N,$

which implies the desired bound. $\sqcap$$\sqcup$

We remark that the condition $\tau\geqslant 1/d$ in Lemma 12.3 comes from the
inequality (12.1).

###  12.2. Concluding the proof

We now turn to the proof of Theorem 3.9. Let
${\mathcal{S}}=(A_{n})_{n\in{\mathbb{N}}}$ satisfy the condition of Theorem
3.9. For $c>0$ and $\mathbf{h}\in{\mathbb{R}}^{d}$ define

${\mathcal{G}}_{{\mathcal{S}},\mathbf{h},c}=\\{\mathbf{x}\in\mathsf{T}_{d}:|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|\geqslant
cN\text{ for infinitely many }N\in{\mathbb{N}}\\}.$

By using the _Weyl criterion_ (see [20, Section 1.2.1]) and _the countable
stability_ of Hausdorff dimension (see [23, Section 2.2]), it is sufficient to
prove that for any $c>0$ and any non-zero vector
$\mathbf{h}\in{\mathbb{Z}}^{d}$ one has

$\dim{\mathcal{G}}_{{\mathcal{S}},\mathbf{h},c}\leqslant d-1/\tau.$

For $N\in{\mathbb{N}}$ denote

$B_{N}=\\{\mathbf{x}\in\mathsf{T}_{d}:V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|\geqslant
cN/2\\}.$

Let $\beta>1$ and $N_{i}=i^{\beta}$. Then we have

$\displaystyle{\mathcal{G}}_{{\mathcal{S}},\mathbf{h},c}\subseteq\bigcap_{k=1}^{\infty}\bigcup_{i=k}^{\infty}B_{N_{i}}.$

Indeed let $\mathbf{x}\in{\mathcal{G}}_{{\mathcal{S}},\mathbf{h},c}$ and
suppose to the contrary that for all large enough $N_{i}$ we have

$|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N_{i})|<cN_{i}/2.$

For any large $N$ there is $i\in{\mathbb{N}}$ such that $N_{i}\leqslant
N<N_{i+1}$. Observe that $N_{i+1}-N_{i}=O(i^{\beta-1})$ for all
$i\in{\mathbb{N}}$, and

$\displaystyle|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N)|$
$\displaystyle\leqslant|V_{{\mathcal{S}},\mathbf{h}}(\mathbf{x};N_{i})|+N_{i+1}-N_{i}$
$\displaystyle\leqslant cN_{i}/2+O(i^{\beta-1})\leqslant 2cN/3$

provided that $N$ is large enough, which contradicts our assumption that
$\mathbf{x}\in{\mathcal{G}}_{{\mathcal{S}},\mathbf{h},c}$.

Let $\varepsilon>0$ be the same on as in Lemma 12.3. For each $N_{i}$ by Lemma
12.3 we obtain

$B_{N_{i}}\subseteq\bigcup_{Q\in{\mathcal{Q}}_{N_{i}}}Q,$

where each $Q\in{\mathcal{Q}}_{N_{i}}$ has side length $1/\left\lfloor
N^{\tau}\varepsilon^{-1}\right\rfloor$ and $\\#{\mathcal{Q}}_{N_{i}}\ll
N_{i}^{d\tau-1}$. From the definition of Hausdorff dimension we obtain

(12.2)
$\dim{\mathcal{G}}_{{\mathcal{S}},\mathbf{h},c}\leqslant\inf\left\\{\nu>0:\sum_{i=1}^{\infty}\sum_{Q\in{\mathcal{Q}}_{N_{i}}}N_{i}^{-\tau\nu}<\infty\right\\}.$

Note that

$\sum_{i=1}^{\infty}\sum_{Q\in{\mathcal{Q}}_{N_{i}}}N^{-\tau\nu}\leqslant\sum_{i=1}^{\infty}N_{i}^{d\tau-1}N_{i}^{-\tau\nu},$

thus the series is convergent provided

$\beta(d\tau-1-\tau\nu)<-1,$

which is equivalent to

$\nu>d-\frac{1}{\tau}+\frac{1}{\beta\tau}.$

Combining with (12.2) we obtain

$\dim{\mathcal{G}}_{{\mathcal{S}},\mathbf{h},c}\leqslant
d-\frac{1}{\tau}+\frac{1}{\beta\tau},$

and by the arbitrary choice of $\beta>1$ we obtain the desired bound.

## Acknowledgement

During preparation of this work, I.S. was supported by ARC Grant DP170100786.

## References

  * [1] R. C. Baker, ‘Slowly growing sequences and discrepancy modulo one’, Acta Arith., 23 (1973), 279–293.
  * [2] R. C. Baker, ‘Metric number theory and the large sieve’, J. London Math. Soc., 24 (1981), 34–40.
  * [3] R. C. Baker, Diophantine inequalities, Oxford Univ. Press, 1986.
  * [4] R. C. Baker, ‘Weyl sums and Diophantine approximation’, J. London Math. Soc. 25 (1982), 25–34; Correction, ibid. 46 (1992), 202–204.
  * [5] R. C. Baker, ‘Small fractional parts of polynomials’, Funct. et Approx. 55 (2016), 131–137.
  * [6] R. Baker, C. Chen and I. E. Shparlinski, ‘Bounds on the norms of maximal operators on Weyl sums’, Preprint, 2021 (available at https://arxiv.org/abs/2107.13674).
  * [7] R. C. Baker, R. Coatney, and G. Harman, ‘Weyl’s theorem in the measure theory of numbers’, Dependence in Probability, Analysis and Number Theory, Kendrick Press, 2010, 51–72.
  * [8] J. Bourgain, ‘On the Vinogradov mean value’, Proc. Steklov Math. Inst., 296 (2017), 30–40.
  * [9] J. Bourgain, C. Demeter and L. Guth, ‘Proof of the main conjecture in Vinogradov’s mean value theorem for degrees higher than three’, Ann. Math., 184 (2016), 633–682.
  * [10] J. Brüdern, ‘Approximations to Weyl sums’, Acta Arith., 184 (2018), 287–296.
  * [11] J. Brüdern and D. Daemen, ‘Imperfect mimesis of Weyl sums’, Internat. Math. Res. Notices, 2009 (2009), 3112–3126.
  * [12] P. J. Bradshaw, B. Hanson and M. Rudnev, ‘Higher convexity and iterated second moment estimates’, Preprint, 2021, (available at https://arxiv.org/abs/2104.11330).
  * [13] C. Chen, B. Kerr, J. Maynard and I. E. Shparlinski, ‘Metric theory of Weyl sums’, Preprint, 2020, (available at https://arxiv.org/abs/2011.09306).
  * [14] C. Chen and I. E. Shparlinski, ‘On large values of Weyl sums’, Adv. Math., 370 (2020). Article 107216.
  * [15] C. Chen and I. E. Shparlinski, ‘Hausdorff dimension of the large values of Weyl sums’, J. Number Theory,  214 (2020) 27–37.
  * [16] C. Chen and I. E. Shparlinski, ‘New bounds of Weyl sums’, Intern. Math. Res. Notices, 2021 (2021), 8451–8491.
  * [17] C. Chen and I. E. Shparlinski, ‘Restricted mean value theorems and metric theory of restricted Weyl sums’, Quart J. Math. (to appear).
  * [18] C. Chen and I. E. Shparlinski, ‘Hybrid bounds on two-parametric families of Weyl sums along smooth curves’, Michigan Math. J. (to appear).
  * [19] C. Demeter and B. Langowski, ‘Restriction of exponential sums to hypersurfaces’, Preprint, 2021, available at https://arxiv.org/abs/2104.11367.
  * [20] M. Drmota and R. F. Tichy, Sequences, discrepancies and applications, Springer-Verlag, Berlin, 1997.
  * [21] P. Erdős and G. Szekeres, ‘Über die Anzahl der Abelschen Gruppen gegebener Ordnung und über ein verwandtes zahlentheoretisches Problem’, Acta sei. Math. Szeged VII, 11 (1934), 95–102.
  * [22] P. Erdős and S. Taylor, ‘On the set of points of convergence of a lacunary trigonometric series and the equidistribution properties of related sequences’, Proc. London Math. Soc., 7 (1957), 598–615.
  * [23] K. J. Falconer, Fractal geometry: Mathematical foundations and applications, John Wiley, 2nd Ed., 2003.
  * [24] A. Fedotov and F. Klopp, ‘An exact renormalization formula for Gaussian exponential sums and applications’, Amer. J. Math., 134 (2012), 711–748.
  * [25] H. Fiedler, W. Jurkat and O. Körner, ‘Asymptotic expansions of finite theta series’, Acta Arith., 32 (1977), 129–146.
  * [26] I. Gál and J. Koksma, ‘Sur l’ordre de grandeur des fonctions sommables’, Proc. Kon. Ned. Akad. Wetench. 53 (1950), 638–653.
  * [27] G. H. Hardy and J. E. Littlewood, ‘The trigonometric series associated with the elliptic $\vartheta$-functions’, Acta Math., 37 (1914), 193–239.
  * [28] G. Harman, Metric number theory, London Math. Soc. Monographs. New Ser., vol. 18, The Clarendon Press, Oxford Univ. Press, New York, 1998.
  * [29] L.-K. Hua, ‘On Waring’s problem’, Quart. J. Math., 9 (1938) 199–202.
  * [30] A. Iosevich, S. V. Konyagin, M. Rudnev and V. Ten, ‘On combinatorial complexity of convex sequences’, Discrete Comput. Geom., 35 (2006), 143–158.
  * [31] H. Iwaniec and E. Kowalski, Analytic number theory, Amer. Math. Soc., Providence, RI, 2004.
  * [32] B. Kerr, ‘On the cubic Weyl sum’, Preprint, 2021, (available at https://arxiv.org/abs/2101.08058).
  * [33] P. Mattila, Geometry of sets and measures in Euclidean spaces: Fractals and rectifiability, Cambridge Univ. Press, 1995.
  * [34] O. Robert and P. Sargos, ‘Three-dimensional exponential sums with monomials’, J. Reine Angew. Math., 591 (2006), 1–20.
  * [35] I. Z. Ruzsa, ‘On the uniform and almost uniform distribution of $(a_{n}x)\mod 1$’, Séminaire Théorie des Nombres Bordeaux (1982-1983), exposé no. 20.
  * [36] B. P. Rynne, ‘Hausdorff dimension and generalized simultaneous Diophantine approximation’, Bull. London Math. Soc. 30 (1998), 365–376.
  * [37] R. Salem, ‘Uniform distribution and capacity of sets’, Comm. Sem. Math. Univ. Lund., suppl. (1952), 193–195.
  * [38] I. D. Shkredov, ‘Some new results on higher energies’, Trans. Mosc. Math. Soc., 74 (2013), 35–73.
  * [39] T. D. Wooley, ‘The cubic case of the main conjecture in Vinogradov’s mean value theorem’, Adv. in Math., 294 (2016), 532–561.
  * [40] T. D. Wooley, ‘Nested efficient congruencing and relatives of Vinogradov’s mean value theorem’, Proc. London Math. Soc., 118 (2019), 942–1016.