Continued Fractions: Haskell, Equational Reasoning, Property

Continued Fractions: Haskell, Equational Reasoning, Property Testing, and Rewrite Rules in Action


Introduction to continued fractions
Let’s start with a challenge. Assume I know how to write down an integer. Now, how can I write down a real number? In school, we’ve all learned a few answers to this question. The big two are
fractions and
decimals.
Fractions have simple forms for rational numbers. Just write two integers, for the numerator and denominator. That’s great! But alas, they are no good at all for irrational numbers like pi, or the square root of 2. I could, of course, write a fraction that’s close to the irrational number, such as 22/7 as an approximation of pi. But this is only good up to a certain limit precision. I could even write an infinite sequence of fractions which converge to the rational number; yet, in the end, I will have wasted a lot of effort. Indeed,

Related Keywords

David Lester , Joachim Breitner , Mobius , Mark Dominu , , Canonical Inf , Canonicalcont Inf , Nonnegative Rational , Convergents Inf , Negative Rational , Semigroup Mobius , Monoid Mobius , Arbitrary Mobius , Todecimal Inf , Rosetta Code , Nonnegative Inf , Integer Valarg , Type Integerrule , Template Haskell , டேவிட் லெஸ்டர் , மொபியஸ் , ரொசெட்டா குறியீடு , வார்ப்புரு ஹ்யாஸ்கல் ,

© 2025 Vimarsana