Java Math sqrt The standard form of a quadratic equation is. X -b b2-4ac 2a The sign indicates that there will be two roots. A Quadratic Equation has two roots and they depend entirely upon the discriminant.
Secondly you arent looking for the correct input types.
For some reason when a1 b1 c-1 I am not getting the desired result of -16180339887499 and 061803398874989. Double discriminant 0. Double r1 -b Mathsqrt result 2a. Systemoutprintf The roots are r1 and r2.