Calculating Moments The following problem is from a Schaum book on statistics. While I thought I did it right, I did not come up with the right answer. Therefore, I am thinking I did something wrong.
Problem: Find (a) the moment generating function of the random variable
$ x = \begin{cases}
    \, \frac{1}{2} &\text{ prob. 1/2} \\
    -\frac{1}{2} &\text{ prob. 1/2} \\
    \end{cases}
$
and (b) the first four moments about the origin.
Answer:
The moment generating function for $x$ is:
$M_x(t) = E(e^{tx})$
Since $x$ can have only two values, this gives us the following function:
$
M_x(t) = \frac{1}{2}e^{\frac{t}{2}} + \frac{1}{2}e^{-\frac{t}{2}}
$
Now to find the first four moments about the origin, I compute the first four
derivatives of $M_x(t)$.
$ M_x'(t) = \frac{1}{4}e^{\frac{t}{2}} - \frac{1}{4}e^{-\frac{t}{2}} $
$ M_x''(t) = \frac{1}{8}e^{\frac{t}{2}} + \frac{1}{8}e^{-\frac{t}{2}} $
$ M_x'''(t) = \frac{1}{16}e^{\frac{t}{2}} - \frac{1}{16}e^{-\frac{t}{2}} $
$ M_x''''(t) = \frac{1}{32}e^{\frac{t}{2}} + \frac{1}{32}e^{-\frac{t}{2}} $
Now, let $u_1, u_2, u_3, u_4$ be the first four moments of $x$.
$ u_1 = M_x'(0) = \frac{1}{4}e^{\frac{0}{2}} - \frac{1}{4}e^{-\frac{0}{2}} $
$ u_1 = \frac{1}{4} - \frac{1}{4} = 0 $
$ u_2 = M_x''(0) = \frac{1}{8}e^{\frac{0}{2}} + \frac{1}{8}e^{-\frac{0}{2}} $
$ u_2 = \frac{1}{8} + \frac{1}{8} = \frac{1}{4} $ 
$ u_3 = M_x'''(0) =
    \frac{1}{16}e^{\frac{0}{2}} - \frac{1}{16}e^{-\frac{0}{2}} $
$u_3 = \frac{1}{16} - \frac{1}{16} = 0 $
$ u_4 = M_x''''(0) =
    \frac{1}{32}e^{\frac{0}{2}} + \frac{1}{32}e^{-\frac{0}{2}} $
$ u_4 = \frac{1}{32} + \frac{1}{32} = \frac{1}{16} $
However, the books answer is:
$ u_1 = 0 $
$ u_2 = 1 $
$ u_3 = 0 $
$u_4 = 1 $
I do not understand what I am doing wrong and I am hoping that somebody here
can tell me.
Thanks
Bob

You work seems correct. For example, without using the moment generating function 
$$
E[X^2] = (1/2)^2 (1/2) + (-1/2)^2(1/2) = 1/8+1/8 = 1/4. 
$$
It seems the book chose to change the random variable to $\tilde{x}$ where $$\tilde{x} = \begin{cases} 1 & \text{ with probability $1/2$} \\ -1  & \text{ with probability $1/2$} \end{cases}$$
