Skip to content

Conversation

@simonbyrne
Copy link

This is not quite ready to be merged, but I thought I would get your thoughts. It changes a few things to allow for infinite length expansions for irrational numbers.

Still to do:

  • Add a QuadraticSurd type for repeating expansions.
  • Docs and tests.

@anthonyclays
Copy link
Collaborator

Great work! I took the liberty of looking over your code (John Myles White said he isn't actively supporting this package anymore).

I very much like the idea of finite and irrational continued fractions as different types. Your compute! function is also a great idea to lazily calculate to a desired precision.

Thanks for all the work!

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this need a generic parameter T? Isn't that parameter implied by CF?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You might not always want them to be the same, e.g. you might want T to be BigInts (to avoid overflow), whereas the iterator might just give you Ints.

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

Successfully merging this pull request may close these issues.

2 participants