formulas for CFs

    \begin{align*} \text{For a CF }x&=\cfrac{A}{B+\cfrac{A}{B+\cfrac{A}{B+\dots}}}, \\  x&=\frac{A}{B+x} \to x^2+Bx-A=0 \\ x&=\frac{-B\pm\sqrt{B^2+4A}}{2} \end{align*}

    \[\text{e.g. } \quad \cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\dots}}}=\frac{-1+\sqrt{9}}{2}=1\]

    \begin{align*} \text{For a CF } x&=A+\cfrac{C}{B+\cfrac{C}{B+\cfrac{C}{B+\dots}}} \\ x&=A+\frac{C}{B+x-A} \to x^2+(B-2A)x+A(A-B)-C=0 \\ x&=A+\frac{-B \pm \sqrt{B^2+4C}}{2} \end{align*}

    \[\text{e.g. }\quad 1+\cfrac{2}{3+\cfrac{2}{3+\cfrac{2}{3+\dots}}}=1-3/2+\frac{\sqrt{9+8}}{2}=\frac{\sqrt{17}-1}{2}\]

    \begin{align*} \text{For a CF } x&=A+\cfrac{1}{B+\cfrac{1}{A+\cfrac{1}{B+\dots}}} \\ x&=A+\cfrac{1}{B+\cfrac{1}{x}} \to Bx^2-ABx-A=0 \\ x&=\frac{AB \pm \sqrt{(AB)^2+4AB}}{2B} \\ x&=\frac{P \pm \sqrt{P(P+4)}}{2B} \quad \text{ where }P=AB  \end{align*}

    \[\text{e.g. }\quad 1+\cfrac{1}{2+\cfrac{1}{1+\cfrac{1}{2+\cfrac{1}{1+\dots}}}} =\frac{2+\sqrt{4+8}}{4}=\frac{\sqrt{3}+1}{2}\]

Leave a Reply

Your email address will not be published.