Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong answers in the specific case #3

Open
batist73 opened this issue Mar 4, 2024 · 4 comments
Open

Wrong answers in the specific case #3

batist73 opened this issue Mar 4, 2024 · 4 comments

Comments

@batist73
Copy link

batist73 commented Mar 4, 2024

Hello!
I've tried next coefficient in the program: 1, -2, -1, 1.
So it's the equation x^3 - 2 * x^2 - x + 1 = 0.
And I've got the answers 2.1776150834928703, -2.0236846915106783, -0.15393039198219122.
But the correct answers are -0.80194, 0.55496, 2.2470 (checked in the Wolfram Alpha).
I hope, that this will help you.

@BaseMax
Copy link
Owner

BaseMax commented Mar 4, 2024

Hi @batist73 thank you for your feedback.
do you have time to fix this issue?

https://github.com/BaseMax/CubicEquationCalculator/pull/2/files
maybe this merge request can help about this issue, i am not sure.

Best
M.

@bubbatls
Copy link

Yes, you should merge this.
I've tested this merge request massively, it gives the same result as math.polynomialRoot (from project mathjs) but very very faster

Thanks for your works, simple fast module like this is why I need

@BaseMax
Copy link
Owner

BaseMax commented Mar 22, 2024

Hey, di d you manage to fix above issue on this js/lib?

@bubbatls
Copy link

hello, I just applied the merge request manually on a local version

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants