The Riemann sum over an interval $[a,b]$ is usually defined as $$\lim\limits_{N\to\infty}\sum\limits_{k=0}^Nf\left(a+k\cdot\frac{b-a}{N}\right)\frac{b-a}{N}$$
Thus if we encounter a sum of the form $$\lim\limits_{N\to\infty}\sum\limits_{k=0}^Nf\left(k\cdot\frac{1}{N}\right)\frac{1}{N}$$ we can conclude that it is equal to an integral over the interval $[0,1]$. $$\lim\limits_{N\to\infty}\sum\limits_{k=0}^Nf\left(k\cdot\frac{1}{N}\right)\frac{1}{N}=\int_0^1f(x)dx\tag{1}\label{1}$$
What can we conclude about the following sum
$$\lim\limits_{N\to\infty}\lim\limits_{M\to\infty}\sum\limits_{k=0}^M f\left(k\cdot\frac{1}{N}\right)\frac{1}{N}\tag{2}\label{2}$$
To clarify, this is an infinite sum \eqref{2}, that differs from the Riemann sum \eqref{1}, in the upper limit of the sum. In the Riemann sum \eqref{1}, there is a relation between $M$ and $N$, namely $N=M$, while there is no such relation specified in \eqref{2}. If we can equate it to an integral, how are we to determine the limits of integration?
The equation \eqref{2} is to be taken, that the $M\to\infty$, we thus have an infinite sum (suppose it is convergent). Than we form a sequence of infinite sums, where $N$ increases for each element of the sequence. That is $$S_N=\lim\limits_{M\to\infty}\sum\limits_{k=0}^M f\left(k\cdot\frac{1}{N}\right)\frac{1}{N}$$ What does this sequence tend to?
Is it true that (or when is it true) $$\lim\limits_{N\to\infty}S_N=\int_0^\infty f(x)dx$$
Also the general term in \eqref{2} is $C_k=f\left(k\cdot\frac{1}{N}\right)$. How does it behave in the limit, namely $$\lim\limits_{N\to \infty}\lim\limits_{M\to \infty}f\left(M\cdot\frac{1}{N}\right)$$