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

Complex/imaginary numbers? #14

Closed
kleiram opened this issue Jan 17, 2017 · 4 comments
Closed

Complex/imaginary numbers? #14

kleiram opened this issue Jan 17, 2017 · 4 comments

Comments

@kleiram
Copy link

kleiram commented Jan 17, 2017

I thought that maybe it'd be nice if complex numbers are supported including their operations.

I've created this issue mainly because I wanted to check if it's actually something @JordanRL wants in this project. If so, I think I can get started on a PR.

@JordanRL
Copy link
Owner

JordanRL commented Mar 5, 2017

Sorry for the delay in replying, I've been very busy the last few months with day-to-day work.

Supporting complex numbers is definitely something I was hoping to add at some point, and unlike things like currency/finance operations, or geometry operations, I think it makes sense to add it into the base Fermat library.

I would definitely welcome work on supporting complex numbers. Make sure to look at the contribution guidelines, but so long as there are tests for the code and it conforms generally to the style used in the rest of the library, any productive work would be greatly appreciated.

I'm currently thinking about ways to increase the precision limits without storing even larger constants, as well as scoping the Fermat-Currency and Fermat-Geometry modules.

@kleiram
Copy link
Author

kleiram commented Mar 17, 2017

No worries about the delay! I know the feeling (as can be seen by my respons time right now).

I'm definitely motivated to start working on this, but I might need a little push in the right direction on how to best structure everything, right now I was thinking of maybe defining a new interface, although maybe even that is not necessary.

I'll create a WIP pull request and start working on that, ok?

@JordanRL
Copy link
Owner

JordanRL commented Apr 7, 2017

Sounds good to me.

A new interface implies new methods. Are you thinking of making new methods that explicitly allow imaginary responses for things like sqrt(), trig functions, etc?

@JordanRL
Copy link
Owner

Hey @kleiram is this still something that you want to help with? I'll be starting on my own implementation of this in the next few weeks, and even if you're not up for writing code I'd certainly welcome your input on how to handle complex numbers in this library.

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

No branches or pull requests

2 participants