Question and Answers Forum

All Questions      Topic List

Number Theory Questions

Previous in All Question      Next in All Question      

Previous in Number Theory      Next in Number Theory      

Question Number 111541 by Aina Samuel Temidayo last updated on 04/Sep/20

How many natural numbers less than  1000 have the sum of their digits equal  to 5?

$$\mathrm{How}\:\mathrm{many}\:\mathrm{natural}\:\mathrm{numbers}\:\mathrm{less}\:\mathrm{than} \\ $$$$\mathrm{1000}\:\mathrm{have}\:\mathrm{the}\:\mathrm{sum}\:\mathrm{of}\:\mathrm{their}\:\mathrm{digits}\:\mathrm{equal} \\ $$$$\mathrm{to}\:\mathrm{5}? \\ $$

Answered by nimnim last updated on 04/Sep/20

21.

$$\mathrm{21}. \\ $$

Answered by mr W last updated on 04/Sep/20

one digit numbers:  1 number    two digit numbers:  a+b=5  a∈[1,9]  b∈[0,9]  (x+x^2 +x^3 +...)(1+x+x^2 +x^3 +...)  =(x/((1−x)^2 ))  =xΣ_(k=0) ^∞ C_1 ^(k+1) x^k   coef. of x^5  is C_1 ^5 =5  ⇒5 numbers    three digit numbers:  (x+x^2 +x^3 +...)(1+x+x^2 +x^3 +...)^2   (x/((1−x)^3 ))=xΣ_(k=0) ^∞ C_2 ^(k+2) x^k   coef. of x^5  is C_2 ^6 =15  ⇒15 numbers    ⇒total 1+5+15=21 numbers

$${one}\:{digit}\:{numbers}: \\ $$$$\mathrm{1}\:{number} \\ $$$$ \\ $$$${two}\:{digit}\:{numbers}: \\ $$$${a}+{b}=\mathrm{5} \\ $$$${a}\in\left[\mathrm{1},\mathrm{9}\right] \\ $$$${b}\in\left[\mathrm{0},\mathrm{9}\right] \\ $$$$\left({x}+{x}^{\mathrm{2}} +{x}^{\mathrm{3}} +...\right)\left(\mathrm{1}+{x}+{x}^{\mathrm{2}} +{x}^{\mathrm{3}} +...\right) \\ $$$$=\frac{{x}}{\left(\mathrm{1}−{x}\right)^{\mathrm{2}} } \\ $$$$={x}\underset{{k}=\mathrm{0}} {\overset{\infty} {\sum}}{C}_{\mathrm{1}} ^{{k}+\mathrm{1}} {x}^{{k}} \\ $$$${coef}.\:{of}\:{x}^{\mathrm{5}} \:{is}\:{C}_{\mathrm{1}} ^{\mathrm{5}} =\mathrm{5} \\ $$$$\Rightarrow\mathrm{5}\:{numbers} \\ $$$$ \\ $$$${three}\:{digit}\:{numbers}: \\ $$$$\left({x}+{x}^{\mathrm{2}} +{x}^{\mathrm{3}} +...\right)\left(\mathrm{1}+{x}+{x}^{\mathrm{2}} +{x}^{\mathrm{3}} +...\right)^{\mathrm{2}} \\ $$$$\frac{{x}}{\left(\mathrm{1}−{x}\right)^{\mathrm{3}} }={x}\underset{{k}=\mathrm{0}} {\overset{\infty} {\sum}}{C}_{\mathrm{2}} ^{{k}+\mathrm{2}} {x}^{{k}} \\ $$$${coef}.\:{of}\:{x}^{\mathrm{5}} \:{is}\:{C}_{\mathrm{2}} ^{\mathrm{6}} =\mathrm{15} \\ $$$$\Rightarrow\mathrm{15}\:{numbers} \\ $$$$ \\ $$$$\Rightarrow{total}\:\mathrm{1}+\mathrm{5}+\mathrm{15}=\mathrm{21}\:{numbers} \\ $$

Commented by mr W last updated on 04/Sep/20

see also Q102816

$${see}\:{also}\:{Q}\mathrm{102816} \\ $$

Commented by Aina Samuel Temidayo last updated on 04/Sep/20

For the two digit numbers and  three digit numbers,please how did you get  (x+x^2 +x^3 +...)(1+x^2 +x^3 +...) and   (x+x^2 +x^3 +...)(1+x^2 +x^3 +...)^2   respectively?

$$\mathrm{For}\:\mathrm{the}\:\mathrm{two}\:\mathrm{digit}\:\mathrm{numbers}\:\mathrm{and} \\ $$$$\mathrm{three}\:\mathrm{digit}\:\mathrm{numbers},\mathrm{please}\:\mathrm{how}\:\mathrm{did}\:\mathrm{you}\:\mathrm{get} \\ $$$$\left(\mathrm{x}+\mathrm{x}^{\mathrm{2}} +\mathrm{x}^{\mathrm{3}} +...\right)\left(\mathrm{1}+\mathrm{x}^{\mathrm{2}} +\mathrm{x}^{\mathrm{3}} +...\right)\:\mathrm{and}\: \\ $$$$\left(\mathrm{x}+\mathrm{x}^{\mathrm{2}} +\mathrm{x}^{\mathrm{3}} +...\right)\left(\mathrm{1}+\mathrm{x}^{\mathrm{2}} +\mathrm{x}^{\mathrm{3}} +...\right)^{\mathrm{2}} \:\:\mathrm{respectively}? \\ $$$$ \\ $$

Commented by mr W last updated on 04/Sep/20

Answered by 1549442205PVT last updated on 04/Sep/20

The numbers have  three digits:  5=5+0+0=4+1+0=3+2+0=3+1+1  =2+2+1  (5,0,0):one number :500  (4,1,0):four numbers:410,401,104,140  (3,2,0):four numbers:320,302,203,230  (3,1,1):three nimbers:311,131,113  (2,2,1):three numbers:212,221,122  The numbers have two digits :  50,41,14,32,23  The numbers have one digits:5  Thus,all has 21 numbers smaller than  1000 sum their digits  whose equal to 5

$$\mathrm{The}\:\mathrm{numbers}\:\mathrm{have}\:\:\mathrm{three}\:\mathrm{digits}: \\ $$$$\mathrm{5}=\mathrm{5}+\mathrm{0}+\mathrm{0}=\mathrm{4}+\mathrm{1}+\mathrm{0}=\mathrm{3}+\mathrm{2}+\mathrm{0}=\mathrm{3}+\mathrm{1}+\mathrm{1} \\ $$$$=\mathrm{2}+\mathrm{2}+\mathrm{1} \\ $$$$\left(\mathrm{5},\mathrm{0},\mathrm{0}\right):\mathrm{one}\:\mathrm{number}\::\mathrm{500} \\ $$$$\left(\mathrm{4},\mathrm{1},\mathrm{0}\right):\mathrm{four}\:\mathrm{numbers}:\mathrm{410},\mathrm{401},\mathrm{104},\mathrm{140} \\ $$$$\left(\mathrm{3},\mathrm{2},\mathrm{0}\right):\mathrm{four}\:\mathrm{numbers}:\mathrm{320},\mathrm{302},\mathrm{203},\mathrm{230} \\ $$$$\left(\mathrm{3},\mathrm{1},\mathrm{1}\right):\mathrm{three}\:\mathrm{nimbers}:\mathrm{311},\mathrm{131},\mathrm{113} \\ $$$$\left(\mathrm{2},\mathrm{2},\mathrm{1}\right):\mathrm{three}\:\mathrm{numbers}:\mathrm{212},\mathrm{221},\mathrm{122} \\ $$$$\mathrm{The}\:\mathrm{numbers}\:\mathrm{have}\:\mathrm{two}\:\mathrm{digits}\:: \\ $$$$\mathrm{50},\mathrm{41},\mathrm{14},\mathrm{32},\mathrm{23} \\ $$$$\mathrm{The}\:\mathrm{numbers}\:\mathrm{have}\:\mathrm{one}\:\mathrm{digits}:\mathrm{5} \\ $$$$\mathrm{Thus},\mathrm{all}\:\mathrm{has}\:\mathrm{21}\:\mathrm{numbers}\:\mathrm{smaller}\:\mathrm{than} \\ $$$$\mathrm{1000}\:\mathrm{sum}\:\mathrm{their}\:\mathrm{digits}\:\:\mathrm{whose}\:\mathrm{equal}\:\mathrm{to}\:\mathrm{5} \\ $$

Terms of Service

Privacy Policy

Contact: info@tinkutara.com