1. If I want to find the mass of a rod of length l and density $\rho = kx$ where $x$ is the distance from one end.

  2. If I want to find the gravitational potential due to a hollow sphere at a distance x from the center

I want to know how to set up a Riemann sum for physics problems.

I know for a Riemann sum we need to sum up $\Sigma f(x_i)Δx$ from $i = 1$ to $∞$ where $Δx ->0$ turning this into an integral.

But I don't know how to set it up. For example, in the first part, I've tried $$M =\Sigma \Delta m =\Sigma (kx) \Delta x$$ where $\Delta x$ is a small(finite) length but I don't know how to set up the index and sum it from 0 to l

  • 2
    $\begingroup$ ...why would you want to "set up a Riemann sum" and not just integrate in the first place? Or, rather, just take the usual integral and go back to what a Riemann sum is and write it down; where's the physics here? $\endgroup$ – ACuriousMind Feb 25 '17 at 10:45
  • $\begingroup$ For the sake for understanding. I obviously wouldn't do this on a test. $\endgroup$ – xasthor Feb 25 '17 at 10:46
  • $\begingroup$ Don't you know infinite Riemann sum and integrals are same. If you really want to take a large Riemann sum, I suggest using a computer than doing on a paper. $\endgroup$ – user143678 Feb 25 '17 at 10:55
  • $\begingroup$ Related questions by OP : Question about the use of integration in physics and How can we treat dV like this? $\endgroup$ – sammy gerbil Feb 26 '17 at 19:56

Since in the limit as $\Delta x \to 0$ a Riemann sum becomes a Riemann integral, if you want to find the corresponding sum, you can do the process in reverse. In the case of a rod of length $\ell$ with density $\rho(x) = kx$, one has that its mass is,

$$m = \int_0^\ell k x \, \mathrm dx = \frac12 k \ell^2.$$

This is equivalent to considering the Riemann sum,

$$\sum_{i=0}^{N-1} \rho(x_i) \, \Delta x = k \sum_{i=0}^{N-1} x_i \, \Delta x$$

where $\Delta x = \ell/N$ for $N$ partitions of the interval. As $N \to \infty$ and thus $\Delta x \to 0$ we recover the integral and thus the exact mass of the rod.


I know for a Riemann sum we need to sum up $\sum f(x_i)Δx$ from $i=1$ to $\infty$

It sounds like you're trying to sum over an infinite range of $x$.

To do this numerically you need to use a finite number of steps (not an infinite number) and use one of the tricks on this page.

  • $\begingroup$ The OP is not trying to actually numerically approximate an integral using a Riemann sum; he just wants to understand how to set up the sum. $\endgroup$ – JamalS Feb 25 '17 at 11:27
  • $\begingroup$ That's not my impression. $\endgroup$ – StephenG Feb 25 '17 at 11:29
  • $\begingroup$ Read the comments; he says "for the sake of understanding." $\endgroup$ – JamalS Feb 25 '17 at 11:31
  • $\begingroup$ That doesn't change my interpretation of his problem. $\endgroup$ – StephenG Feb 25 '17 at 11:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.