continued_fraction function
The continued fraction of a rational number, as a list.
How to write it
continued_fraction(x)
- x
- A rational number. Takes a number.
Examples
continued_fraction(7/3)In the solver,
Open in the solvercontinued_fraction(7/3)gives[2, 3].
Related functions
- from_continued_fraction
The number a continued fraction stands for.
- convergents
The convergents of a continued fraction.
- chinese_remainder
The number that leaves given remainders on division by given moduli.
- discrete_log
The exponent that takes a base to a value modulo a number.
- catalan_number
The n-th Catalan number.
- divisor_count
How many positive divisors a whole number has.