Changes between Version 3 and Version 4 of Ticket #14567


Ignore:
Timestamp:
05/12/13 18:10:27 (7 years ago)
Author:
vdelecroix
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #14567 – Description

    v3 v4  
    22
    33 1. categories are not properly initialized nor used.
    4  2. it only deals with rational numbers
    5  3. there is no dedicated method for numerical approximations (which is one of the first aim of continued fractions)
    6  4. there is no bridge with quadratic numbers (see also #11345)
    7  5. there is no bridge with words (sage.combinat.words)
     4 2. all arithmetic operations go back and forth with the underlying rational (there are much more direct solutions for taking the negative, inverse and to compare two continued fractions)
     5 3. it only deals with rational numbers
     6 4. there is no dedicated method for numerical approximations (which is one of the first aim of continued fractions)
     7 5. there is no bridge with quadratic numbers (see also #11345)
     8 6. there is no bridge with words (sage.combinat.words)
    89
    9 The patch proposed here develop some general design for dealing with continued fractions and solves the issues 1, 2 and 5 (and I hope 3); see the discussion below.
     10The patch proposed here develop some general design for dealing with continued fractions and solves the issues 1, 2, 3 and 5 (and I hope 4); see the discussion below.
    1011
     12With the patch applied we can do
    1113{{{
     14sage: (117/253).continued_fraction()
     15[0; 2, 6, 6, 3]
    1216sage: K.<sqrt2> = QuadraticField(2)
    1317sage: cff = (sqrt2/3 + 1/4).continued_fraction(); cff