Answer on Question #69951 – Math – Discrete Mathematics
Question
Find the number of integer solutions to the equation x1+x2+x3=40 where
6≤x1≤15,5≤x2≤20and10≤x3≤25.Solution
Method 1
Let x1,x2,…,xm be integers. Then the number of solutions to the equation
x1+x2+⋯+xm=n
subject to the conditions a1≤x1≤b1, a2≤x2≤b2, ..., am≤xm≤bm
is equal to the coefficient of xn in
(xa1+xa1+1+⋯+xb1)⋅(xa2+xa2+1+⋯+xb2)⋯(xam+xam+1+⋯+xbm).
(see http://www.careerbless.com/aptitude/qa/permutations_combinations_imp8.php)
Applying this theorem to this problem one gets that the number of solutions to the equation
x1+x2+x3=40
subject to conditions
6=a1≤x1≤b1=15,5=a2≤x2≤b2=20,…,10=a3≤x3≤b3=25
is equal to the coefficient of x40 in
(x6+x7+x8+x9+x10+x11+x12+x13+x14+x15).(x5+x6+x7+x8+x9+x10+x11+x12+x13+x14+x15+x16+x17+x18+x19+x20).(x10+x11+x12+x13+x14+x15+x16+x17+x18+x19+x20+x21+x22+x23+x24+x25)==x6x5x10(1+x+x2+x3+x4+x5+x6+x7+x8+x9).⋅(1+x+x2+x3+x4+x5+x6+x7+x8+x9+x10+x11+x12+x13+x14+x15).⋅(1+x+x2+x3+x4+x5+x6+x7+x8+x9+x10+x11+x12+x13+x14+x15)==x21(1+x+x2+x3+x4+x5+x6+x7+x8+x9).⋅(1+x+x2+x3+x4+x5+x6+x7+x8+x9+x10+x11+x12+x13+x14+x15).⋅(1+x+x2+x3+x4+x5+x6+x7+x8+x9+x10+x11+x12+x13+x14+x15)
Thus, the number of integer solutions is 135.
Method 2
From the equation x1+x2+x3=40 we can express one of variables in terms of others: x3=40−(x1+x2). Thus, 10≤40−(x1+x2)≤25, or, −30≤−(x1+x2)≤−15, or 15≤x1+x2≤30.
For each integer from 15 to 30 let's count the number of pairs of integers (x1,x2) such that 6≤x1≤15, 5≤x2≤20.
Let x1+x2=n, where 15≤n≤30. The minimal value of x1 (even less than 6) for which there exists x2 such that x1+x2=n is n−20, i.e. n minus upper limit of x2. Taking into account the lower limit of x1 being 6, the minimal value of x1 really is max{(n−20),6}. Similarly, the maximal value of x2 (even greater than 15) for which there exists appropriate x2 is n−5, i.e. n minus lower limit of x2. Taking into account the upper limit of x1 being 15, the maximal value of x1 really is min{(n−5),15}. Then the number of pairs of integers (x1,x2) such that 6≤x1≤15, 5≤x2≤20 and x1+x2=n is the number of integers between an=max{(n−20),6} and bn=min{(n−5),15}, i.e. (bn−an+1). In the table below columns correspond to value of n while blue cells in each column correspond to valid values of x1:

For 15≤n≤26, an=6 and for the rest, 27≤n≤30, an=n−20. For 15≤n≤19, bn=n−5, and for the rest, 20≤n≤30, bn=15. Dividing n into three groups: below 20 (A), above 26 (B) and between (C):
A=∑n=1519(bn−an+1)=∑n=1519((n−5)−6+1)=∑n=1519(n−10)=∑n=59n=(9−5+1)29+5=5×7=35.B=n=20∑26(bn−an+1)=n=20∑26(15−6+1)=n=20∑2610=10(26−20+1)=10×7=70.C=∑n=2730(bn−an+1)=∑n=2730(15−(n−20)+1)=∑n=2730(36−n)=∑n=36−2736−30n=∑n=96n=∑n=69n=(9−6+1)26+9=4×7.5=30.N=A+B+C=35+70+30=135.
Answer: 135.
Answer provided by https://www.AssignmentExpert.com