Skip to content

sqrt() approximation #59

@nackstein

Description

@nackstein

Hello,
I'm not sure if it's a bug or a known rounding behavior.
If I compute the sqrt() of a complex number -9+0i the correct solution should be 0+3i
but with this module (I used num crate) I got:
0.00000000000000018369701987210297+3i

As far as I know some math lib implement hard-coded case for some exact value.
Did you considered doing the same?

Luigi

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions