Integral roots in quadratic equation

quadratics

The smallest possible natural number $n$, for which the equation $x^{2}-n x+2014=0$ has integral roots, is

I know the discriminant will be a perfect square, but I am struck on equation of discriminant.

Best Answer

The prime factorisation of $2014$ is $2 \times 19 \times 53$. $2$ is obviously a factor, so you need to find the factors of $1007$ by hand. To do this, you only need to check the primes less than $\sqrt{1007} \approx 31.7$ of which there aren't many.

This gives the factor pairs $(1, 2014); (2, 1007); (19, 106)$ and $(38, 53)$. By Vieta's formulas, the sum of the two roots is $\frac{-b}{a}$ in $ax^2+bx+c$, or $-\frac{-n}{1} = n$ in your case. From here, you can immediately observe what the smallest value of $n$ should be.