Integrating with respect to √dx: a finite nonzero answer
Replacing dx with √dx in a Riemann sum multiplies the ordinary integral by √n. A finite answer therefore needs a zero integral and a precisely tuned singularity.

A question on Mathematics Stack Exchange starts from the left-endpoint Riemann sum as the definition of a definite integral on [0, 1]: the integral of f(x) dx is the limit as n goes to infinity of the sum, for i from 0 to n−1, of f(i/n) · n−1. Read that way, dx is just the n−1 factor. So what happens if you replace it with n−2, a squared differential, or with n−1/2, which you might write as √dx?
For (dx)2 the asker found a function that gives a finite, nonzero answer. For g(x) = 1/(x−1)2, the pole at x = 1 grows exactly as fast as n−2 shrinks, and the sum collapses to the sum of 1/m2, which is π2/6.
The open question is the √dx version. Is there any h for which the limit of (1/√n) · Σ h(i/n) is finite and not zero? The asker's own attempt, built around √(x/(x−1)), went to infinity. The short answer is yes. Seeing why it is possible also shows why most attempts fail.
What the squared differential is actually computing
Start with the case that works. With n−2 in place of n−1, a bounded function contributes at most n terms of size M · n−2, which is M/n in total, and that goes to zero. This is why the asker notes that polynomials and exponentials always give zero. In the asker's picture, each rectangle becomes a box whose depth equals its width. The total volume of those boxes vanishes as the boxes get thinner.
To get something nonzero, the function has to fight back. With g(x) = 1/(x−1)2, the term g(i/n) · n−2 simplifies to 1/(i−n)2, and n no longer appears separately. Re-index with m = n−i and the partial sums run over 1/m2 for m from 1 to n. That converges to π2/6. Almost all of the value comes from the few rectangles nearest the pole. The bounded part of the interval contributes nothing in the limit.
Why √dx blows up for ordinary functions
The √dx case has the opposite problem. Rewrite the sum as (1/√n) · Σ h(i/n) = √n · [(1/n) · Σ h(i/n)]. The bracket is an ordinary Riemann sum. For any reasonably behaved h, it converges to the ordinary integral of h over [0, 1]. Multiply that by √n and the result goes to infinity, unless the ordinary integral is exactly zero.
That gives the first hard constraint. A candidate h must have an ordinary integral of zero over [0, 1]. A function that is positive throughout the interval can never work. Its Riemann sums settle on a positive number, and the √n factor sends the product to infinity. This is consistent with the divergence the asker saw.
Zero integral is necessary but not sufficient. Once the integral is zero, what remains is √n times the error of the Riemann sum. For the product to settle on a finite nonzero value, that error has to shrink at exactly the rate 1/√n. If it shrinks faster, the answer is zero. If it shrinks slower, the answer diverges.
A function that works
The accepted answer proposes h(x) = 1/(2√(1−x)) − 1 on [0, 1). Both constraints are visible in it. The ordinary integral of 1/(2√(1−x)) over [0, 1] is 1, so subtracting 1 brings the total to zero. The square-root singularity at x = 1 is what produces an error term of order 1/√n.
Substitute into the sum. The term 1/(2√(1 − i/n)) becomes √n/(2√(n−i)). Summing the constant −1 over n terms and dividing by √n gives −√n. After re-indexing:
S_n = (1/2) · Σ_{m=1..n} 1/√m − √nThe answer then uses a standard asymptotic expansion: the sum of 1/√m up to n equals 2√n + ζ(1/2) + O(1/√n). Half of 2√n cancels the −√n exactly. What is left is Sn = ζ(1/2)/2 + O(1/√n). That converges to about −1.46035/2, or roughly −0.73017. The limit is finite, nonzero, and negative.
Checking it numerically
The derivation is short, but it is worth running, because the convergence is slow. The error term is O(1/√n), so each extra correct digit costs about a hundredfold increase in n. The subtraction of √n also means you are cancelling two large quantities, so summation accuracy matters.
import math
def S(n):
terms = (1 / (2 * math.sqrt(1 - i / n)) - 1 for i in range(n))
return math.fsum(terms) / math.sqrt(n)
for n in (10**3, 10**5, 10**7):
print(n, S(n))The sequence should drift toward −0.73017 at the rate the expansion predicts. math.fsum keeps the cancellation from being swamped by rounding error. A naive running float sum over ten million terms gives that error room to creep in.
Where this breaks, and what to watch for
This construction is a limit of one specific sum. It is not an integral in any robust sense, and several things that normally hold for integrals fail here:
- Constants are fatal. Adding any nonzero constant c to h adds c·√n to the sum, which diverges. The zero-integral condition leaves no slack.
- The sampling rule is part of the definition. The value comes from the rectangles nearest the singularity, so the result depends on taking left endpoints. Right endpoints would evaluate h at the pole itself. Midpoints or uneven partitions can change the constant, even though they all agree for ordinary integrals.
- The answer is not unique. Scaling h scales the limit, so any finite value can be reached once one example exists. Saying 'the √dx integral of h' only means something with the partition and sample points fixed.
- The exponent and the singularity must match. The n−2 case needs a pole like 1/(1−x)2. The n−1/2 case needs an integrable singularity like 1/√(1−x), plus a correction that brings the ordinary integral to zero. A different exponent needs a different balance.
So these sums work as a way to probe how a Riemann sum's error behaves near a singularity. They do not give a new calculus of fractional differentials. If you rely on one, fix the sampling scheme explicitly, check numerically with enough terms, and expect the convergence to be slow.
This article draws on Is there any function you can integrate with respect to $\sqrt{dx}$ (using my definition of what that would mean) and get a finite nonzero r and an answer to it, on the Stack Exchange network, licensed under CC BY-SA 4.0.
- #Riemann sums
- #asymptotic expansion
- #calculus
- #definite-integrals
- #fractional differentials
- #zeta(1/2)



Comments