this is a cubic solver that finds all the roots of a cubic equation