-
Notifications
You must be signed in to change notification settings - Fork 41
Open
Description
I tried the web demo out on the two cases of the quadratic formula, and the negative case (-b - sqrt(b^2 - 4*a*c)) / (2a) produced this output: https://herbie.uwplse.org/demo/7c3b374107c5177485bdae893a16bc32fd361b84.b7c88a7d879b959f14e63c59c9c933cbdc874ea9/graph.html#reproduce
This features the answer -0.5 * (2 * (c/b)) (the result of taylor expanding around -inf) for b < -something*10^-93. This produces super wrong results for totally normal negative b values (for example, at a=1, b=-1, c=-6, it produces -6 instead of the correct -2).
When I tried the positive case, it worked great, splitting into 4 regimes: https://herbie.uwplse.org/demo/500fb1a758f004adc50b440bb74877e556b2c3b7.b7c88a7d879b959f14e63c59c9c933cbdc874ea9/graph.html.
kamiyo
Metadata
Metadata
Assignees
Labels
No labels