I was talking to a friend and the following set $S$ came up.


Let $f$ be some real valued function tending to infinity.
Let $S$ be a subset of natural numbers such that $|S \cap [1,N]| = N^{\delta}+ O(N^{\delta}/f(N))$ and further for any $r,m \in \mathbb{N}$ we have 
$$
| \{ x \in S \cap [1,N] : x \equiv r (\text{mod }m) \}| = \frac1m N^{\delta}+ O(N^{\delta}/f(N)),
$$
where the implicit constant does not depend on $r,m$.


I was curious are there any examples of such set $S$
other than the set of all natural numbers, which would satisfy
this condition when $\delta=1$? I am also wondering is it 
reasonable to assume such a set exist for $\delta<1$ with some choice of $f$? Thanks! 



Existence of a certain subset of natural numbers equidistributed modulo $m$ for every $m$
As mentioned by [Aaron Meyerowitz](https://mathoverflow.net/users/8008/aaron-meyerowitz), a set of the form $$S=\left\{\left[k^{1/\gamma}\right]:\ k\in\mathbb{N}\right\}$$ should work for any $1/2<\gamma<1$. Notice that for such a value of $\gamma$, $$\left[(k+1)^{\gamma}\right]-\left[k^{\gamma}\right]=\begin{cases}
1 & \text{ if }k+1=\left[n^{1/\gamma}\right]\\
0 & \text{ otherwise}
\end{cases}. $$


Let $s(x)=\left\{ x\right\} -\frac{1}{2}.$ Then the counting function for $S$ inside an arithmetic progression is $$\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}\left[(k+1)^{\gamma}\right]-\left[k^{\gamma}\right]=\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}(k+1)^{\gamma}-k^{\gamma}+\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}s(k^{\gamma})-s((k+1)^{\gamma}).$$ Above we have split up the sum into a main term and an error term.


**Main Term:** By the generalized binomial theorem $$(k+1)^{\gamma}-k^{\gamma}=\gamma k^{\gamma-1}+O\left(k^{\gamma-2}\right),$$ and so $$\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}(k+1)^{\gamma}-k^{\gamma}=\gamma\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}k^{\gamma-1}+O\left(1\right).$$ As $\gamma<1$, the main term equals $$\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}(k+1)^{\gamma}-k^{\gamma}=\frac{x^{\gamma}}{q}+O(1),$$ which satisfies the desired condition as $\sum\_{n\leq x} 1\_S(n)\sim x^\gamma$.


**Error Term:** The error term is more difficult to deal with, and in what follows we will give a sketch. The notation is the same as that used in [Balog and Friedlander's paper on Piatetski-Shapiro primes.](http://msp.org/pjm/1992/156-1/pjm-v156-n1-p03-p.pdf) 


Recall the Fourier expansion for $s(x).$ We have $$s(x)=-\sum\_{0<|h|<T}\frac{1}{2\pi ih}e(hx)+O\left(\min\left(1,\frac{1}{T\|x\|}\right)\right),$$ and $$\min\left(1,\frac{1}{T\|x\|}\right)=\sum\_{h=-\infty}^{\infty}b\_{h}e(hx)$$ where $$|b\_{h}|\ll\min\left(\frac{\log2T}{T},\ \frac{T}{h^{2}}\right).$$ Thus our error term can be written as $\Sigma\_{1}+\Sigma\_{2}$ where $\Sigma\_{1}$ arises from $\sum\_{0<|h|<T}\frac{1}{2\pi ih}e(hx),$ and $\Sigma\_{2}$ arises from the term $\sum\_{h=-\infty}^{\infty}b\_{h}e(hx).$ To deal with $\Sigma\_{2},$ notice that 


$$\left|\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}\sum\_{h=-\infty}^{\infty}b\_{h}e(hk^{\gamma})\right|\leq\left|\sum\_{h=-\infty}^{\infty}\left|b\_{h}\right|\left|\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}e(hk^{\gamma})\right|\right|.$$ An estimate of Van Der Corput yields $$\left|\sum\_{k\leq\frac{x}{q}}e(h(qk+a)^{\gamma})\right|\ll h^{1/2}x^{\gamma/2}+h^{-1/2}x^{1-\gamma/2},$$ and so $$\Sigma\_{2}\ll\frac{x}{T}+\sum\_{h=1}^{\infty}\left|b\_{h}\right|\left(h^{1/2}x^{\gamma/2}+h^{-1/2}x^{1-\gamma/2}\right)$$ 


$$\ll xT^{-1}+T^{1/2}x^{\gamma/2}+T^{-1/2}x^{1-\gamma/2}.$$ It remains to bound $\Sigma\_{1}.$ By using the identity $$e(hk^{\gamma})-e(h(k+1)^{\gamma})=2\pi i\gamma h\int\_{0}^{1}\left(k+u\right)^{\gamma-1}e\left(h(k+u)^{\gamma}\right)du,$$ $\Sigma\_{1}$ is at most $$\Sigma\_{1}\ll\sum\_{0<|h|<T}\int\_{0}^{1}\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}\left(k+u\right)^{\gamma-1}e\left(h(k+u)^{\gamma}\right)du.$$ Partial summation along with other classical bounds on exponential sums should be able to handle the problem from here. In the end we will take $T=x^{1-\gamma+\delta}$ for some small $\delta>0$. I *believe* that we may take $\delta=\frac{1}{4}\left(\gamma-\frac{1}{2}\right)$ to obtain $$\sum\_{\begin{array}{c}
k\leq x-1\\
k\equiv a\text{ mod }q
\end{array}}\left[(k+1)^{\gamma}\right]-\left[k^{\gamma}\right]=\frac{x^\gamma}{q}+O\left(x^{\frac{3}{4}\gamma+\frac{1}{8} }\right).$$ 


**Remark:** In the above method the error term grows out of control if $\gamma\leq \frac{1}{2}$.


