Let $e:\mathbb R\to\mathbb C$ be defined by $e(t):=\exp(2\pi i t)$. Let $\mathbb T:=\mathbb R/\mathbb Z$, let $\mu_{\mathbb T}$ be normalized Haar probability measure on $\mathbb T$, and let $\|\cdot\|_{\mathbb T}$ denote distance to $0$ in $\mathbb T$. Let $\mathcal L^1$ and $\mathcal L^2$ denote one-dimensional and two-dimensional [Lebesgue measure](/page/Lebesgue%20Measure). Let $\Lambda:\mathbb N\to\mathbb R$ be the von Mangoldt function, let $\mu:\mathbb N\to\{-1,0,1\}$ be the Mobius function, and let $\varphi:\mathbb N\to\mathbb N$ be Euler's totient function. For each $N\in\mathbb N$, define $S_N:\mathbb T\to\mathbb C$ by
\begin{align*}
S_N(\alpha):=\sum_{1\le n\le N}\Lambda(n)e(n\alpha).
\end{align*}
For $Q,L\ge 1$ and $N\in\mathbb N$, define
\begin{align*}
\mathfrak M_N(Q,L):=\bigcup_{1\le q\le Q}\bigcup_{\substack{1\le a\le q, \gcd(a, q)=1}}\left\{\alpha\in\mathbb T:\left\|\alpha-\frac{a}{q}\right\|_{\mathbb T}\le \frac{L}{qN}\right\}.
\end{align*}
For $q\in\mathbb N$ and $m\in\mathbb Z$, define
\begin{align*}
c_q(m):=\sum_{\substack{1\le a\le q, \gcd(a, q)=1}}e\left(\frac{am}{q}\right).
\end{align*}
For $N\in\mathbb N$, define the ternary Goldbach singular series by the absolutely convergent Euler product
\begin{align*}
\mathfrak S_3(N):=\prod_p\left(1-\frac{c_p(-N)}{(p-1)^3}\right),
\end{align*}
equivalently by the absolutely convergent Ramanujan series
\begin{align*}
\mathfrak S_3(N)=\sum_{q=1}^{\infty}\frac{\mu(q)^3}{\varphi(q)^3}c_q(-N).
\end{align*}
Then, for every $C>0$, there exist $B=B(C)>0$ and $N_0=N_0(C)\in\mathbb N$ such that, if $N\ge N_0$ is odd and $Q=L=(\log N)^B$, then
\begin{align*}
\int_{\mathfrak M_N(Q,L)}S_N(\alpha)^3e(-N\alpha)\,d\mu_{\mathbb T}(\alpha)=\frac{1}{2}\mathfrak S_3(N)N^2+O_C\left(\frac{N^2}{(\log N)^C}\right).
\end{align*}
Moreover, there exists an absolute constant $c>0$ such that
\begin{align*}
\mathfrak S_3(N)\ge c
\end{align*}
for every odd $N\in\mathbb N$.