Why does this alternative to the Quadratic Formula not always work? $x=\frac1a\left(-b+\sqrt{\frac12(b^2-2ac\pm b\sqrt{b^2-4ac})}\right)$ I was playing with quadratic formula a while ago and I was able to accidentally arrive at:
$$x=\frac{1}{a}\left(-b+\sqrt{\frac{(b^2-2ac)±b\sqrt{b^2-4ac}}{2}}\right) \tag{1}$$
However, I have not been able to solve it from scratch but I simplified it in some way to arrive back at the general quadratic equation. Here we go:
$$x=\frac{1}{a}\left(-b+\sqrt{\frac{(b^2-2ac)±b\sqrt{b^2-4ac}}{2}}\right)$$
$$2(ax+b)^2=b^2-2ac±b\sqrt{b^2-4ac}$$
$$2a^2x^2+4abx+b^2+2ac=±b\sqrt{b^2-4ac}$$
From the original quadratic formula, we know that
$$2ax+b=±\sqrt{b^2-4ac}$$
So
$$2a^2x^2+4abx+b^2+2ac=b(2ax+b)$$
$$2a^2x^2+2abx+2ac=0 \tag{2}$$
Dividing (2) by $a$ as $a≠0$, we have
$$ax^2+bx+c=0$$
Looks practically perfect, right?
I gave this to one of the maths experts in my environment for verification. Unfortunately, he was able to give a quadratic equation for which (1) could not solve and that is:
$$x^2-4x+4=0$$
After a thorough re-check through a series of examples, if we let $x_1$ and $x_2$ be the values of (1), i realized that the formula could find only one root if and only if
$$|x_1|=|x_2|$$

Question: what could be wrong with (1)? 
I am not claiming to have discovered a new quadratic formula, I am just curious about why (1) doesn't work generally.

 A: Your formula finds a zero of the polynomial
$$
(a^2 x^2 + 3 a b x + a c + 2 b^2) (a x^2 + b x + c)
$$
So it could be a zero of $a x^2 + b x + c$, but it also could be a zero of $a^2 x^2 + 3 a b x + a c + 2 b^2$.
A: I see two problematic steps in your derivation. One is the very first step of your calculations. You get
$$2(ax+b)^2=b^2-2ac±b\sqrt{b^2-4ac}, \tag2$$
which is a true equation in all cases where $x$ is a solution of $p(x)=ax^2+bx+c=0.$
But it is possible that for one or both of the true roots of $p(x)$ the expression $ax+b$ is negative, whereas your formula takes the positive square root of the right-hand side of $(2)$ and therefore is consistent with the original problem only for roots $x$ such that $ax+b\geq 0.$
This causes you not to find the correct root in such cases.
The other problematic step is at the end, where you suppose it is OK to replace the $x$ on the right side of
$$a^2+2bx+c = bx \tag3$$
with the formula for the two roots of $p(x).$
By doing this, you have actually created two quadratic equations, one for each root of $p(x).$
If $x_1$ and $x_2$ are those roots, one of the equations you have created is
$$a^2+2bx+c = bx_1, \tag4$$
and while it is true that $x_1$ is a root of $(4),$ $x_2$ is not generally a root. Usually $(4)$ will have two roots and one will be spurious, that is, introduced by this step and not a solution of the original equation.
If we run your derivation backwards, it first introduces up to two spurious solutions by introducing two new quadratic equations, and then it loses up to two solutions by taking a positive square root for each of the new quadratic equations.
For example, try $x^2-3x+2.$
For that equation, $ax+b$ is negative for both roots, so your formula gives two wrong answers.
A: Here is a better alternative for the quadratic formula:
Start with $ax^2+bx+c=0$.  We complete the square ... backwards, so to speak:
$(a-\frac{b^2}{4c})x^2+(\frac{b^2}{4c})(x+\frac{b}{2c})^2=0$
$(a-\frac{b^2}{4c})+(\frac{b^2}{4c})(1+\frac{b}{2cx})^2=0$
$(b+\frac{1}{2cx})^2=b^2-4ac$
$\color{blue}{x=\dfrac{2c}{-b\pm\sqrt{b^2-4ac}}}$
This formula finds use in computer programming, where it gives a better-conditioned result than the usual version of the quadratic formula when $|a|<|c|$. It also avoids division by zero if we are analyzing conditions where $c$ does not change sign but $a$ does so.
