Status: New
Owner: ----
Labels: Type-Enhancement Priority-Medium NumberTheory

New issue 4122 by lucasbro...@gmail.com: Egyptian fractions
http://code.google.com/p/sympy/issues/detail?id=4122

Input a rational between 0 and 1, receive a list of the denominators of an Egyptian fraction expansion of said rational. I can see this done in one of two ways: as a method attatched to Rational(,) objects or as a standalone (suite of) functions.

For example:

As a method attached to Rational(,)s:
Rational(3,7).egypt() would produce [3, 11, 231].
Rational(5,121).egypt.greedy() would evaluate to [25, 757, 763309, 873960180913, 1527612795642093418846225].
Rational(5,121).egypt.algorithm1() would return [33, 121, 363].
and so forth.

As a standalone class, we would supply the numerator and denominator individually as the two arguments of each function:
egypt.greedy(41, 42) --> [2, 3, 7]
egypt.method1(5, 121) --> [33, 121, 363]
egypt.greedy(5,121) --> [25, 757, 763309, 873960180913, 1527612795642093418846225]
etc.

If the project decides to implement multiple expansion algorithms, perhaps an additional method could be added to expand the fraction via /all/ the available algorithms and then return the shortest result.


--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"sympy-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sympy-issues+unsubscr...@googlegroups.com.
To post to this group, send email to sympy-issues@googlegroups.com.
Visit this group at http://groups.google.com/group/sympy-issues.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to