Continued fraction $[a\_0,a\_1,...,a\_n]$ may be expressed as quotient of two polynomials of $(a\_0,a\_1,...,a\_n)$, named continuants (see <http://en.wikipedia.org/wiki/Continuant_%28mathematics%29> )


$[a\_0,a\_1,...,a\_n] = K(a\_0,a\_1,...,a\_n)/K(a\_1,...,a\_n)$


For example $K(a\_0,a\_1,a\_2,a\_3) = a\_{0} a\_{1} a\_{2} a\_{3} + a\_{0} a\_{1} + a\_{0} a\_{3} + a\_{2} a\_{3} + 1$


Continuants has many interesting recurrence relations some of which You may find in Graham, Knuth, Patashnik book "Concrete mathematics". Continuants appears for example in Hopcroft's minimization algorithm. 


I found interesting relation:


$K( a\_0,a\_1,...,a\_k,a\_{(k+1)},...,a\_n ) =$


$K(a\_0,a\_1,...,a\_k,1,1,a\_{(k+1)},...a\_n) - K(a\_0,a\_1,...,a\_k,1,a\_{(k+1)},...a\_n)$


that is - between variables $a\_k$ and $a\_{(k+1)}$ You put two of "1" in the firs and one "1" in the second term... You may consider this as generalisation of Fibonacci recurrence - because if You put all $a\_i =1$ You obtain Fibonacci numbers. 


For example:
$K(a\_0,a\_1,a\_2) = (a\_0 a\_ 1+1)a\_2+a\_0$
$K(a\_0,a\_1,1,1,a\_2) = (2 a\_0 a\_1+ a\_0+2)a\_2+a\_0 a\_1+a\_0+1$
$K(a\_0,a\_1,1,a\_2) = (a\_2+1)(a\_0 a\_1+1)+a\_0 a\_2$


And it is true that:


$K(a\_0,a\_1,a\_2) = K(a\_0,a\_1,1,1,a\_2) - K(a\_0,a\_1,1,a\_2)$


**I am curious - is this known fact? Or something new?**




---


How to proove it - I found finite closed expression for continuant polynomial $K(a\_0,a\_1...a\_n)$ in the form:


(1) $ x = [a\_{0},a\_{1},a\_{2},...a\_{n}] =\frac{K(a\_0,a\_1,...,a\_n)}{K(a\_1,...,a\_n)}= - \frac{1}{2} \frac{Tr \left( M(S- L) \right) }{Tr \left( M(S-T) \right) }$


where M is continuant matrix 2x2 and $S,T,L$ and $I$ (unity matrix) are constant matrices which form base in $SL(2,Z)$ space - they are defined in Sage workbook accesible for download here: <http://fiksacie.wordpress.com/2012/03/17/ulamki-lancuchowe-nonstandard-matrix-representation-of-continued-fractions-cz-5/> There is also several essays about that on my blog - in polish. Proof is simple linear algebra exercise: 


start from monoid formed by $S,T$ generators ( which represent in nonstandard way moves on Stern-Brocot tree - standard way consists of R-ight, and L-eft, RL matrices) and then construct ring over **rationals** with $I,S,T,L$ generators, and then formula above appears. M is defined as follows ( it is continuant matrix representation for given continued fraction $x = [a\_{0},a\_{1},a\_{2},...a\_{n}]$ )


(2) $ M = S \prod\_{i=0}^{n} S(ST)^{a\_{i}}$. 


$S$ is that $S^2 =I$ and $T$ is that $T^2 = I+T$ so 


$I = T^2 -T = S(ST)S(ST) - S(ST)$ 


Then You may insert it in any place between $S(ST)^{a\_{i}}S(ST)^{a\_{i+1}}$ which gives expression above and many more if You consider $T^p$ for $p \in Z$ etc. 




---


It is worth to note that in the general ring $Q[\{I,S,T,L\}]$ matrix $M$ has decomposition in the form $M=aI+bS+cT+dL$ with rational $a,b,c,d$ and that continued fractions form algebraic curve which equations is given by bilinear form $\left| w^TBw \right| = 1$ where $w=[a,b,c,d]$ - column vector where $a,b,c,d$ are integers (there are additional inequalities for this coefficients - because $M$ has to have positive elements)


Please note that (1) and (2) allows similarity transformations, and then You may choose any base in SL(2,Z) space and that whole construction may be easily generalized to bigger than 2x2 dimensional matrices. I have many questions here to ask, some of which are:


(A) are there irreducible representations of this construction in SL(D,Z) spaces where D>2?


(B) are there representations in complex number set ${z\_1,...z\_4}$ which obeys the same multiplication table as for $I,S,T,L$ matrices? How to express (1) in that case? 


(C) probably there is possibility to construct pure algebraical representation in which continued fractions are generalised to values of operator which should be generalisation of rhs of (1). How to do it?


I am not professional mathematician - I have problems if it is worth to publish it, where to do it etc. 



Simple and general relation between continuant polynomials 
As Gerry remarked it follows from the recursion of the continuants.
By the recurrence of the continuants you have
${K\_{k + 3}}({a\_0}, \cdots ,{a\_k},1,1) = {K\_{k + 2}}({a\_0}, \cdots ,{a\_k},1) + {K\_{k + 1}}({a\_0}, \cdots ,{a\_k}).$
Therefore
${K\_{k + 4}}({a\_0}, \cdots ,{a\_k},1,1,{a\_{k + 1}}) = {a\_{k + 1}}{K\_{k + 3}}({a\_0}, \cdots ,{a\_k},1,1) + {K\_{k + 2}}({a\_0}, \cdots ,{a\_k},1)$,
${K\_{k + 3}}({a\_0}, \cdots ,{a\_k},1,{a\_{k + 1}}) = {a\_{k + 1}}{K\_{k + 2}}({a\_0}, \cdots ,{a\_k},1) + {K\_{k + 1}}({a\_0}, \cdots ,{a\_k}),$ 
${K\_{k + 2}}({a\_0}, \cdots ,{a\_k},{a\_{k + 1}}) = {a\_{k + 1}}{K\_{k + 1}}({a\_0}, \cdots ,{a\_k}) + {K\_k}({a\_0}, \cdots ,{a\_{k - 1}}).$
This implies
${K\_{k + 4}}({a\_0}, \cdots ,{a\_k},1,1,{a\_{k + 1}}) = {K\_{k + 3}}({a\_0}, \cdots ,{a\_k},1,{a\_{k + 1}}) + {K\_{k + 2}}({a\_0}, \cdots ,{a\_k},{a\_{k + 1}}).$
By induction your result follows.


