`a)`
`x^2+4x=12`
`<=> x^2+4x-12=0`
`<=> x^2-2x+6x-12=0`
`<=> x(x-2)+6(x-2)=0`
`<=> (x+6)(x-2)=0`
`<=> [(x+6=0),(x-2=0):} <=> [(x=-6),(x=2):}`
Vậy `x in {-6;2}`
`b)`
`x^2-3x+1=0`
`<=> x^2-2.x . 3/2+9/4+1-9/4=0`
`<=> (x-3/2)^2-5/4=0`
`<=> (x-3/2)^2=5/4`
`<=>` \(\left[ \begin{array}{l}x-\dfrac{3}{2}=\dfrac{\sqrt{5}}{2}\\x-\dfrac{3}{2}=-\dfrac{\sqrt{5}}{2}\end{array} \right.\) `<=>`\(\left[ \begin{array}{l}x=\dfrac{3+\sqrt{5}}{2}\\x=\dfrac{3-\sqrt{5}}{2}\end{array} \right.\)
Vậy `x in {(3+-sqrt5)/2}`