Letting $a\_1,a\_2,\cdots,a\_r$ be integers which are larger than or equal to $2$, let us define 
$$[a\_1,a\_2,\cdots,a\_r]=\cfrac{1}{a\_1-\cfrac{1}{a\_2-\cfrac{1}{\ddots-\cfrac{1}{a\_r}}}}$$


(Note that the **negative signs** are used)


Also, let $X, Y, Z$ be positive integers which satisfy
$$Z\lt X+Y,\ Z\gt X,\ Z\gt Y$$
and let 
$$\frac XZ=[a\_1,a\_2,\cdots,a\_r],\ \frac YZ=[b\_1,b\_2,\cdots,b\_s].$$


Then, here is my question.


**Question** : Is the following true?


"There exist $r^{\prime}\le r, s^{\prime}\le s$ such that 
$$[a\_1,a\_2,\cdots,a\_{r^{\prime}}]+[b\_1,b\_2,\cdots,b\_{s^{\prime}}]=1$$
for any $(X,Y,Z)$."


**Remark** : Observing the initial numbers is not sufficient because the nearer to $1$ the value $\frac XZ+\frac YZ$ is, the harder it is to find the answer (see example 2). 


This question has been [asked previously on math.SE](https://math.stackexchange.com/questions/518995/about-two-negative-continued-fractions-whose-sum-equals-1) without receiving any answers. 


**Examples** :


1. $\frac XZ=\frac 37=[3,2,2]$ and $\frac YZ=\frac 57=[2,2,3]$ leads $[3]+[2,2]=\frac 13+\frac 23=1$ where $\frac 37+\frac 57=\frac 87\approx 1.143$
2. $\frac XZ=\frac{901}{2067}=[3,2,2,4,2]$ and $\frac YZ=\frac{1170}{2067}=[2,5,2,2,3]$ leads $[3,2,2,4]+[2,5,2,2]=\frac{10}{23}+\frac{13}{23}=1$ where $\frac XZ+\frac YZ=\frac{2071}{2067}\approx 1.002.$


**Motivation** : I've got an algorithm to find $b\_1,b\_2,\cdots,b\_s$ such that 
$$1-x=[b\_1,b\_2,\cdots,b\_s]$$
for any given $x=[a\_1,a\_2,\cdots,a\_r]$.


**Algorithm** : Supposing that $2^r$ represents $r$-consecutive $2$s, I'm going to write 
$$[a\_1,a\_2,\cdots,a\_r]=[2^{q\_1},p\_1,2^{q\_2},p\_2,\cdots,2^{q\_s},p\_s,2^{q\_{s+1}}]$$
where $p\_i\ge 3\in \mathbb N, q\_i\ge 0\in \mathbb Z$. For example, $[2,2,5,3,2,4]=[2^2,5,2^0,3,2^1,4,2^0]$.


Then, the algorithm is 
$$1-[2^{q\_1},p\_1,2^{q\_2},p\_2,\cdots,2^{q\_s},p\_s,2^{q\_{s+1}}]$$
$$=[(q\_1+2),2^{(p\_1-3)},(q\_2+3),2^{(p\_2-3)},(q\_3+3),2^{(p\_3-3)},\cdots,(q\_s+3),2^{(p\_s-3)},(q\_{s+1}+2)].$$


After getting this algorithm, I reached the above expectation. I can neither find any counterexample even by using computer nor prove that the expectation is true. Can anyone help?



About two 'negative' continued fractions whose sum equals $1$
The answer is **YES** even for numbers $\alpha$, $\beta$ of the form $\alpha=\frac X{Z\_1}$, $\beta=\frac Y{Z\_2}$. Suppose we look for convergents $\bar\alpha$, $\bar\beta$ to $\alpha$, $\beta$ such that $\bar\alpha+\bar\beta=1$.


If both numbers $\alpha$, $\beta$ are not less when $1/2$ an answer is trivial: $\bar\alpha=\bar\beta=1/2$. So we can assume that $\alpha<1/2$ and $\alpha+\beta>1$.
It means that $$\tag{1}\alpha=[a-\alpha']$$ for some $a\ge 3$ and $\alpha'\in[0,1)$. Then $\alpha<\frac1{a-1}$ and $\beta>1-\alpha>1-\frac1{a-1}$. From last inequality follows that continued fraction expansion (CF) for number $\beta$ has the form $$\beta=[\underbrace{2,\ldots,2-\delta}\_{a-2}]=\frac{a-2-(a-3)\delta}{a-1-(a-2)\delta}\tag{2}$$ with $\delta\in[0,1)$. If we have one more digit $2$ in CF for $\beta$ then we have a solution, because
$$\bar\beta=[\underbrace{2,\ldots,2}\_{a-1}]=\frac{a-1}{a}$$ and we can take $\bar\alpha=\frac 1a$.


If next digit in CF for $\beta$ is not equal to $2$, then $\delta=[b\_1,b\_2,\ldots]$, where $b\_1\ge 3$. From (1) and (2) follows that inequality $\alpha+\beta>1$ equivalent to 
$$\alpha'+\beta'>1,$$ where $\alpha'$ is defined in (1) and $$\beta'=\frac{\delta}{1-\delta}=[b\_1-1,b\_2,\ldots].$$ The formula $\bar\alpha+\bar\beta=1$ is equivalent to
$\bar\alpha'+\bar\beta'=1$, so we reduced our problem from $\alpha$, $\beta$ to simpler numbers $\alpha'$, $\beta'$.


