Hyperbinary representation
= Hyperbinary representation
A representation $n=\sum_{i\ge0}a_i2^i$ with $a_i\in\{0,1,2\}$ and only finitely many nonzero coefficients. If $h(n)$ counts these representations, then $h(0)=1$, $h(2m+1)=h(m)$, and $h(2m)=h(m)+h(m-1)$ for $m\ge1$. The <integer parity> of $n$ determines whether the coefficient of $2^0$ must be 1 or may be 0 or 2.