# If the roots of the equation are integers then find the value of $k$.

The question says roots of $x^2-kx+36=0$ are integers then the number of values for $k$ are?

I know roots are integral if discriminant is a perfect square of an integer, but using this I get infinite values for $k$. Which values should I reject?

The product of the roots is $36$, and the sum is $k$. There are $5$ ways to decompose $36$ as a product of positive factors, if order does not count, and an equal number of ways to decompose $36$ as a product of negative factors.

Thus there are $10$ possible values of $k$.

HINT:

Let $k^2-4\cdot1\cdot36=y^2\iff(k+y)(k-y)=144$

As $k+y\pm(k-y)$ are even, $k-y,k+y$ have the same parity, hence both must be even

$$\dfrac{k+y}2\cdot\dfrac{k-y}2=\dfrac{144}4=?$$

What are the positive divisors of $36?$

Also as $k+y\ge k-y,36=\dfrac{k+y}2\cdot\dfrac{k-y}2\le\dfrac{(k+y)^2}4$

$\implies k+y\ge\sqrt{4\cdot36}$ as $k+y>0$

$\implies\dfrac{k+y}2\ge6$ and must divide $36$

• cant we solve this by knowing that roots are integral only when discriminant is square of integer – danny Jul 30 '16 at 5:13
• @danny, That's what I've utilized, $y^2$ is a perfect square. The rest method is to minimize the number possible values of $\dfrac{k+y}2$ – lab bhattacharjee Jul 30 '16 at 5:15
• what is parity? – danny Jul 30 '16 at 5:18
• @danny, See mathsisfun.com/numbers/even-odd.html – lab bhattacharjee Jul 30 '16 at 5:25