What's the number of ways we can write $n\in\mathbb{N}$ as:
$n=d_1+2d_2+3d_3+\ldots+n\cdot d_n$, where $d_i$ is either $0$ or $1$?
By number of ways I mean how many different sets $\{d_1,\ldots,d_n\}$ are there. For example, $2=0+2\cdot 1$, and that's the only one way ($d_1=0, d_2=1$).
I noticed that if $d_n=1$, then $d_1,\ldots,d_{n-1}$ must be zero or if $d_n=0$ and $d_{n-1}=1$, then $d_1$ must be 1 and $d_2,\ldots,d_{m-2}$ must be zero. But that does not help much and I'd really appreciate some help. Maybe there is some technique that is applicable to this problem?