Use continued fractions to find a rational number which approximates $\sqrt{11}$ to within $10^{−4}$.

I know how to solve for continued fractions like this: $$\sqrt{11}=3+x$$ $$11=9+6x+x^2$$ $$11=9+(6+x)x$$ $$2=x(6+x)$$ $$x=\frac{2}{6+x}=\frac{1}{3+\frac{x}2}=\frac{1}{3+\frac{1}{6+x}}$$

therefore, $$\sqrt{11}=[3;\overline{3,6}]$$

How do I find out where to terminate the fraction so as to obtain close value with error less than the mentioned limit

  • 3
    $\begingroup$ Look for a convergent with denominator $>100$. $\endgroup$ – Lord Shark the Unknown May 28 at 6:30
  • $\begingroup$ You could just try terminating it as various places until you find one that works. Don't worry, it won't take too long. $\endgroup$ – Gerry Myerson May 28 at 7:21

Theorem: Let $p_k/q_k$ is the $k$-th convergent of a positive real $x$ then

$$ \Bigg|x - \frac{p_k}{q_k}\Bigg| \le \frac{1}{q_k q_{k+1}} < \frac{1}{q_k^2} $$

So to approximate within $10^{-4}$, $q_k > 100$ sufficient not always necessary because in general you can get the same accuracy with a smaller denominator if $q_k q_{k+1} > 10^4$.


It's a fact that if $m/n$ is a convergent in the continued fraction expansion of $x$, and $m$ and $n$ are relatively prime, then $| x - m/n | < 1/n^2$. This allows you to bound the error in your approximation.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.