-
-
Notifications
You must be signed in to change notification settings - Fork 40
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
Refactor Polynomials: Extract Method to Introduce RootFinder Factory Method and Tighten Encapsulation #322
Conversation
…s roots in order.
…lgorithm with the desired precision.
…(in this case the test) needs.
…he coefficients correspond to.
@@ -26,6 +26,15 @@ PMPolynomial class >> coefficients: anArray [ | |||
^self new initialize: anArray reverse | |||
] | |||
|
|||
{ #category : #information } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure I would put this method on the class side but I could understand.
Now why the PMNewtonZeroFinder does not define a creation class method desiredPrecision: like that you do not need this method and the class PMNewtonZeroFinder gets improved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I saw that you did it :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I had to take smaller steps in order to keep our tests green.
Another test might be to test roots that are in the Complex plane.