Q:

Equation for real number to binary conversion

A real number can be converted into binary as given in the attached figure. How can we represent this process using an equation?
The method of converting a real number to binary

A:

Let $x\in\mathbb{R}$ and $p>1$ be an integer.  Is this what you are asking for (with $p=2$)
$$x=\text{sign}(x)\,\sum_{k=-\infty}^{+\infty}\,{\Big(\left\lfloor p^{-k}\, |x|\right\rfloor\text{ mod }p\Big)}{p^k}\,?$$

