# Failure to understand a basic integral application

1. Aug 30, 2012

### cantRemember

I will show you my (obviously wrong) way of thinking when i have to apply an integral.
Please correct me where i'm wrong.

(imaginary question)
Suppose you have a mass distribution across a line, where the mass of each point is given by the equation f(x)=a*x (assume a is a constant)
find the total mass, if the line is c meters long (beggining @ x=0)

(My stupid train of thought)
We have to add up all the individual masses on the line.
so devide the line into n segments, calculate the mass for each one and add them up
f(x1)+f(x2)+...+f(xn)=
a*x1+a*x2+...+a*xn=
a(x1+x2+...+xn)=
a*c

What am i doing wrong?
(Besides the language use, i'm not a native and have little experience in such teminology)

2. Aug 30, 2012

### kapital

I think first line (f(x1)+f(x2)+...+f(xn) =) is alredy wrong.

I think you shoud write it like this:

f(x1)*Δx+ f(x2)*Δx+f(x3)*Δx+f(x4)*Δx+........+f(xc)*Δx=

Try to calculate using this expresion.

3. Aug 30, 2012

### kapital

Although something else is weird at this example. Ussualy, that kind of examples give the function of density and not mass. If each point has some nonzero mass on some interval, that the whole mass on the interval should be infinity. Correct me if I am wrong.

4. Aug 30, 2012

### sophiecentaur

@cantRemember
Your mistake is when you go from

"a(x1+x2+...+xn)="
to
"a*c"

the Sum of the integers 1+2+3+4+....+n
is NOT c
it's c(c+1)/2 (ultimately the area of a triangle - not the length of the rod).

You could get the right answer using
ax1 +a(x2-x1) +a(x3-x2) +a(x4-x3) + .. + a(xn-xn-1)
which would be adding up the masses of the individual lengths. This, of course, simplifies into a xn
which is the value ac you wanted!

5. Aug 30, 2012

### kapital

But shouldnt be that infinity, since we have an infinity mass points?

6. Aug 30, 2012

### sophiecentaur

That would be the next step in the argument - i.e. going from a simple summation to an integration. The OP has not gone as far as to take the limit as Δx→0. In that case, the answer is still ac, where a is the mass per unit length.

7. Aug 30, 2012

it's correct that the problem of infinity will arise when we take limit n-> infinity... I think cantRemember is looking for a way to look at his simplified version of the problem...
so if we divide the length c into n segments (each segment of length c/n) and assume that the mass of segment number i is f(xi) = a*xi, where xi is the coordinate of the center of the segment, then....

total mass = f(x1)+f(x2)+...+f(xn)
= a*x1+a*x2+...+a*xn
= a(x1+x2+...+xn)...... (cantRemember is right till here)
= a*c/n * (1+2+3+....+n)....... (what sophiecentaur said)
= a*c/n * n*(n+1)/2 ..... (the summation in the brackets will not give c*(c+1)/2)
= a*c*(n+1)/2

NOT a*c

8. Aug 30, 2012

sophiecentaur's solution would be correct if in f(x) = a*x, x is the length of the segment under consideration and not the x co-ordinate of the segment

9. Aug 30, 2012

### sophiecentaur

This thread is not being rigorous enough, I think. It would be far better to start with some basic Maths and a book would be a better way through. Question and answer doesn't deal with this sort of thing very well as the threads ramble far too much..
I am not sure that I actually answered the question he posed and I may have added confusion. Step by step through a page of book-work would sort it all out.

10. Aug 30, 2012

### voko

The mistake is in how you add "all the individual masses". In any of your segments, there are infinitely many of them, so you cannot just take one value of f(x) at the end of a segment.

Instead, you assume that the segment is so small, that f(x) does not change much in it, then the max of the segment can be approximated by the length of the segment multiplied by the value of f(x) somewhere in that segment. So you end up summing these: $f(\xi_i)(x_i - x_{i - 1})$, where $\xi_i \in [x_{i - 1}, x_i]$. Because you assume that f(x) does not change much in a segment, you can just take $x_i$ for $\xi_i$, so we will sum $f(\xi_i)(x_i - x_{i - 1}) = ax_i(x_i - x_{i - 1})$. You can further take all the segments to be of the same length $d = (B - A)/N$, where $A$ and $B$ are the limits of integration, and $N$ is the number of segments, thus getting the sum of $f(\xi_i)(x_i - x_{i - 1}) = ax_i(x_i - x_{i - 1}) = a(A + di)(d)$. Putting all together, the integral then becomes $$\sum_{i = 1}^{N}ad(A + di) = ad\frac N 2 (A + B)$$ because it is just the sum of arithmetic progression, and plugging there the definition of $d$ you obtain $a\frac {B^2 - A^2} {2}$.

In this particular case we did not actually have to go to the limit of the sum with N growing infinitely, but that is because f(x) was linear. With more complex functions, we would have to.