To the bank comes $N \sim Bin(4, 0.5)$ people
$X_i$ is an indicator of an event- person $i$ has deposited cash, $P(X_i) = 0.5, \quad X_i, X_j$ are independent $\forall i \neq j$
The number of people who deposited cash that day is $X = \displaystyle \sum_{i=1}^N X_i$
I need to calculate $M_x(2)$ where $M_x$ is the MGF of X.
I didn't manage to go too far:
$M_x(t) = M_{\sum_{i=1}^N X_i}(t) = (M_{X_1}(t))^N$
Edit: I came across a solution that states at the beggining : $M_x(t) = M_n(ln(M_{X_1}(t))$ But I don't understand why
There are 4 people who each have a 1/4 chance of depositing cash (1/2 of going to the bank and 1/2 of then depositing cash). Let $Y_{i}$ be the indicator that person $i$ deposits cash, then: $$\begin{align} M_{Y_i}(t) &= E[e^{Y_{i}t}] \\ &= .75e^{0} + .25e^{t} \end{align}$$ The moment generating function for the sum $N = \sum\limits_{i=1}^{4} Y_{i}$ is:
$$\begin{align} M_N(t) &= M_{\sum_{i=1}^4 Y_i}(t) \\ &= (M_{Y_1}(t))^4 \\ &= (.75 + .25e^{t})^4 \end{align}$$ Evaluating this at $t=2$ gives the answer in your textbook: $$\begin{align} M_{N}(2) &= (.75 + .25e^{2})^4 \\ &= 45.5 \end{align}$$