so we let $X_1....X_n$ be iid random variables from the exp($\theta$) distribution.
Find the distribution of S=$2\theta\sum_{i=1}^n(X_i)$
and hence show that S is a pivot.
Now i understand that the first step would be to find the moment generation function of S; but i may be missing something here, should i set $X_i$ in S to be the exponential distribution and then find the moment generating function? and once that is found ( if that is the right first step) how would i proceed?
$$M_S(t)=E[e^{tS}]=E[e^{t2\theta\sum_{i=1}^n{X_i}}]$$
$$E[e^{t2\theta\sum_{i=1}^n{X_i}}]=E[\prod_{i=1}^n e^{t2\theta X_i}]$$ Let $u=2t\theta$, and using the iid property, we have $$E[\prod_{i=1}^n e^{t2\theta X_i}]=\prod_{i=1}^nE[ e^{t2\theta X_i}]=\prod_{i=1}^nE[ e^{u X_i}]=E[ e^{u X_i}]^n$$
Let $M_E(t)$ denote the moment generating function of an exponential distribution with parameter $\theta$. We have $$M_S(t)=M_E(u)^n=\left(\frac{1}{1-\frac{u}{\theta}}\right)^n=\left(\frac{1}{1-2t}\right)^n$$
If you are familiar with the Gamma distribution, you will realize that $S$ is a Gamma distribution of parameters $(2,n)$