Suppose that we have following quadratic equation containing some constant $a$ $ax^2-(1-2a)x+a-2=0.$ We have to find all integers $a$,for which this equation has rational roots.
First I have tried to determine for which $a$ this equation has a real solution, so I calculated the discriminant (also I guessed that $a$ must not be equal to zero, because in this situation it would be a linear form, namely $-x-2=0$ with the trivial solution $x=-2$).
So $D=(1-2a)^2-4a(a-2)$ if we simplify,we get $D=1-4a+4a^2-4a^2+8a=1+4a$
So we have the roots: $x_1=(1-2a)-\frac{\sqrt{1+4a})}{2a}$ and $x_2=(1-2a)+\frac{\sqrt{1+4a})}{2a}$
Because we are interesting in rational numbers, it is clear that $\sqrt{1+4a}$ must be a perfect square, because $a=0$ I think is not included in solution set,then what i have tried is use $a=2$,$a=6$,$a=12$,but are they the only solutions which I need or how can I find all values of $a$?