I've got a microeconomics question that involves rearranging an equation with summation, where the only constant are $1$ and $r$.
Firstly this is the equation stating that across individuals $i=1$ to $n$ demand for period 1 consumption $(x_1)$ should equal the supply of period 1 money $(e_1)$.
$\Sigma_{i=1}^nx_{i1}$($r^*$)=$\Sigma_{i=1}^n$$e_{i1}$ $[1]$
So this states the total demand for money across all individuals is equal to the supply of money in period 1 when the interest rate is optimum, my question is how would you rearrange this equation when the demand function for individual $i$ is substituted in to this equation so when:
$x_{i1}$($r^*$)=$e_{i1}(1+r)+e_{i2}\over(1+r)(1+\beta_i$
So substituting this derived demand function can be plugged into equation $[1]$ gives this:
$\sum_{i=1}^n$$e_{i1}(1+r)+e_{i2}\over(1+r)(1+\beta_i)$$=\Sigma_{i=1}^n e_{i1}$
Ignoring the economic details how do you just make $(1+r)$ the subject of this equation?