Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Find sum of numbers from $1$ to $100$ which are not divisible by $3$ and $5$?

I can understand that the here we require to sum up these numbers:

$1+2+4+7+8+11+13+14+16+17+19+22+23+26+28+29+31+32+34$ $+37+38+41+43+44+46+47+49+52+53 +56+58+59+61+62+64+67+68+71$ $+73+74+76+77+79+82+83+86+88+89+91+92+94+97+98$

Which gives the sum $= 2632$,but I any didn't relation among the numbers in this series,any ideas? Also,I am supposed to do this under a mint so please hint/answer accordingly.

share|improve this question
4  
In my opinion, there would be a problem if a test question was worded exactly like the above, for there is ambiguity. The phrase "not divisible by $3$ and $5$" could be interpreted by a student as meaning not divisible by both of $3$ and $5$, that is, everybody but the multiples of $15$. The wording "divisible neither by $3$ nor by $5$" is, by contrast, unambiguous. –  André Nicolas Jul 20 '11 at 22:23
    
Yes,initially I was only taking out the multiples of $15$ from $5050$. –  Quixotic Jul 22 '11 at 18:27
1  
That was a sensible interpretation of the substandard wording used in the problem. –  André Nicolas Jul 22 '11 at 19:28
    
but certainly giving me an answer that is not in any of the options and which tends me to check my calculations again and hence waste of precious seconds!:/ –  Quixotic Jul 22 '11 at 19:32

4 Answers 4

up vote 16 down vote accepted

This is a combinatorial argument called Inclusion-exclusion principle: $$X=1+\ldots+100 - 3(1+\ldots+33) - 5(1+\ldots+20) + 15(1+\ldots+6)$$

First we add all the numbers, then we remove all those which are divisible by $3$, and those divisible by $5$. But wait a minute! What about $15$? We removed that number twice! We therefore need to add it once, as well the rest of its multiples below $100$.

Now using the summation formula: $1+\ldots+n = \frac{n(n+1)}{2}$ the answer follows.

share|improve this answer
    
+1,nice explanation. –  Quixotic Jul 20 '11 at 22:02

There's something called inclusion-exclusion you wanna use : sum all integers up to 100, remove those divisible by 3, remove those divisible by 5, then add those divisible by 15. =)

share|improve this answer

The sum of the numbers which are divisible by $3$ in this range is $$ 3+6+\cdots+99=3(1+2+\cdots+33) $$ and likewise the sum of those divisible by $5$ is $$ 5+10+\cdots+100=5(1+2+\cdots+20). $$ You should be aware of a quick formula to add these two sums. Be careful to add back all the numbers that are divisible by $15$, as they have been subtracted twice. Thanks to Gauss, we know that the sum of the first $100$ integers is $5050$, and after doing the arithmetic you get your answer.

share|improve this answer

Hint: First try finding the sum of numbers which are divisible by $3$ or $5$

share|improve this answer
    
Sub-hint: find the sum of numbers which are divisible by 3, then the sum of those divisible by 5, and finally the sum of those divisible by 15. –  Did Jul 20 '11 at 21:49
    
Okay,for that I have to sum up two G.P series for $3$ and $5$ respectively,then subtract the $15$ series and then subtract this whole result from $5050$? Do you mean this? –  Quixotic Jul 20 '11 at 21:51
    
@Debanjan: They are not GP. They are AP. –  Aryabhata Jul 20 '11 at 21:54
    
Yeps,A.P indeed. –  Quixotic Jul 20 '11 at 22:01
    
Accepting this one as hint is enough for me in this case. –  Quixotic Jul 20 '11 at 22:02

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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