The general term in the expansion of (x31−x4)n is given by:
Tr+1=nCr(x−3)n−r(−x4)r=(−1)r⋅nCr⋅x7r−3n
For the coefficient of x7, we set the exponent to 7:
7r1−3n=7⇒r1=73n+7
For the coefficient of x14, we set the exponent to 14:
7r2−3n=14⇒r2=73n+14
Notice that r2=r1+1.
The sum of the coefficients of x7 and x14 is zero:
(−1)r1⋅nCr1+(−1)r2⋅nCr2=0
(−1)r1⋅nCr1+(−1)r1+1⋅nCr1+1=0
(−1)r1(nCr1−nCr1+1)=0
nCr1=nCr1+1
Since r1=r1+1, we must use the property nCx=nCy⇒x+y=n:
r1+(r1+1)=n
2r1+1=n
Substituting r1=73n+7:
2(73n+7)+1=n
76n+14+1=n
6n+14+7=7n
n=21
Answer: 21