1. May 10, 2005

### slug

is there a formula to solve a long series of addition of say 18 through 10748
instead of doing the tedious summing of 18+19+20+...+10748
there probably is but i found a formula yesterday and I want see if it is the same

how about multiplication - is there an easy way of computing 97! (factorial)
instead of using a computer or multiplying 1*2*3*4...*97

2. May 10, 2005

### shmoe

There's the old standby $\sum_{i=1}^{n}i=\frac{n(n+1)}{2}$ that will handle your sum problem with little difficulty.

You could use Stirling's series to approximate a factorial.

3. May 11, 2005

### HallsofIvy

So that, of course, 18+19+20+...+10748= (1+ 2+ ...+ 10748)- (1+ 2+ ...+ 17)= (10749)(10748)/2- (18)(17)/2= (10749)(5374)- (9)17= 57764973.

4. May 14, 2005

### AntonVrba

$$\sum_{i=a}^{n}i=\frac{(n-a+1)(n+a)}{2}$$

will also do

5. May 14, 2005

### shmoe

Thats the same thing, only slightly simplified.

6. May 15, 2005

### BenGoodchild

I prefer to think of it in this way:

Please follow my thinking, it is the same as that of Gauss with his SUM(1:100) problem. To solve it you pair off each number, starting with the largest (LA) and smallest (s) andsathen take (L-1) and (S+1) sand so on. With an even number as the largest number, there is always one number that cannot be paired up, once this is found, one subtracts the smallest number from it, to give the number of complete pairs, and multiplies by the sum of L and S. Tsa give the final answer, one then adds the number that cannot be paired.

Take the largest numebr in numberoup (10748) and the smallest (18).

Add them together (10766) , and divide by two (5383). This gives the number that does not have a pair.

Now, subtract 18 from this number (5365). Multiply 5365 by 10766 to give 57759590. Now add on to this 5383, and one gets 57764973

AlgebraiclAlgebraicallyr no miktex but i have never known how to use it in forums).

( { ( (L+S) / 2 ) - S } {L+S}) + { ( L + S ) / 2 } = answer

If one take L+s = T

Then it is much easier to say,
T{(T^2)/2) - ST} + {T/2}

I hope somebody could put that mess into MiXTeX or LaTeX - but i hope my logic comes through.

Regards,

Ben

Last edited by a moderator: May 16, 2005
7. May 15, 2005

### shmoe

Halls answer is correct. Do you not believe the formula in my post?

"Take the largest numebr in numberoup (10478) and the smallest (18)."

You've transposed the digits 4 and 7, the sum he calculated was from 18 to 10748.

8. May 16, 2005

### BenGoodchild

Post corrected

Ben

9. May 17, 2005

### slug

its not possible simplify factorials is it? it tried but i just end up with long polynomials