p=\sum_{n=1}^\infty\frac{d_n}{2^n}