Bug in calculating quadratic equation

Issue #339 duplicate
Former user created an issue

Originally reported on Google Code with ID 339 ``` The formula for quadratic equation gives wrong values for x1 and x2 when values for a,b and c are set. The formula is wrongly defined in the program as: x1 = (-b + sqrt(b^2 - 4*a*c)) / 2*a x2 = (-b - sqrt(b^2 - 4*a*c)) / 2*a

whereas the correct formula should be:

x1 = (-b + sqrt(b^2 - 4*a*c)) / (2*a) x2 = (-b - sqrt(b^2 - 4*a*c)) / (2*a) (note the parentheses around the expression 2*a)

Version is 0.10.1 ```

Reported by `mehtaraman22` on 2010-04-10 10:12:30

Comments (1)

  1. Former user Account Deleted

    Reported by `helder.pereira.correia` on 2010-04-14 20:32:21 - Status changed: `Duplicate` - Merged into: #197

  2. Log in to comment