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

Possible error in the documentation for math.nthRoots(x) #1855

Closed
skgadi opened this issue May 13, 2020 · 3 comments
Closed

Possible error in the documentation for math.nthRoots(x) #1855

skgadi opened this issue May 13, 2020 · 3 comments
Labels

Comments

@skgadi
Copy link

skgadi commented May 13, 2020

Hi,

I am trying to use math.nthRoots(x) for matrices but it seems not working. The documentation says it takes the inputs "number | BigNumber | Fraction | Complex | Array | Matrix", but when I use matrices, system throws error "Uncaught TypeError: Unexpected type of argument in function nthRoots (expected: Complex or number or Fraction or string or BigNumber, actual: Matrix, index: 0)"

Also, it seems the parameter description, return value description are incorrect.

Please look into it. Thank you.

Best regards

@josdejong
Copy link
Owner

Thanks for bringing this up, it's an error in the documentation indeed. The implementation only supports scalars: https://github.com/josdejong/mathjs/blob/develop/src/function/arithmetic/nthRoots.js#L39-L43

@josdejong
Copy link
Owner

Docs are fixed now in v7.0.1

@skgadi
Copy link
Author

skgadi commented May 30, 2020

Thank you.

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

No branches or pull requests

2 participants