The cubic formula is the closed-form solution for a cubic equation, i.e., the roots of a cubic polynomial. A general cubic equation is of the form
z^3+a_2z^2+a_1z+a_0==0
(1)
(the coefficient a_3 of z^3 may be taken as 1 without loss of generality by dividing the entire equation through by...