MGF of Poisson Z=X+2Y If $X\sim P(2)$ and $Y \sim P(3)$ using the moment generating function, what kind of distribution has random variable $Z=X+2Y$.
So far as I know :
$$
M_X(t)=e^{-\lambda(1-e^t)}=e^{-2(1-e^t)}
$$
$$
M_Y(t)=e^{-\lambda(1-e^t)}=e^{-3(1-e^t)}
$$
$$
M_{2Y}(t)=e^{-\lambda(1-e^t)}=e^{-3(1-e^{2t})}
$$
$$
M_{X+Y}(t)=e^{-5(1-e^t)}
$$
Since
$$
X+Y \sim P(\lambda_1+\lambda_2)
$$
so I am guessing that $$ Z=X+2Y \sim P(\lambda_1+2\lambda_2)$$ but I can find it from the equation
$$M_{X+2Y}(t)=e^{-2(1-e^t)} e^{-3(1-e^{2t})}=e^{(-2(1-e^t)-3(1-e^{2t})}$$
I don't know how to rearrange this equation to get the distribution.
How to get rid of "$2t$".
 A: Taking the characteristic functions of the underlying random variables you have:
$$\begin{equation} \begin{aligned}
\varphi_X(t) &= \exp \Big( 2 (e^{it}-1) \Big), \\[6pt]
\varphi_{2Y}(t) &= \exp \Big( 3 (e^{2it}-1) \Big). \\[6pt]
\end{aligned} \end{equation}$$
Assuming that $X$ and $Y$ are independent, you then have:
$$\varphi_Z(t) = \varphi_{X}(t) \cdot \varphi_{2Y}(t) = \exp \Big( 3 e^{2it} +2 e^{it} -5 \Big).$$
The distribution of $Z$ can be obtained by inverting the characteristic function via standard methods for inverse-Fourier transformation.  Using a well-known inversion formula we have:
$$\begin{equation} \begin{aligned}
p_Z(z) 
&= \lim_{T \rightarrow \infty} \frac{1}{2T} \int \limits_{-T}^{+T} e^{-itz} \varphi_Z(t) dt \\[6pt]
&= \lim_{T \rightarrow \infty} \frac{1}{2T} \int \limits_{-T}^{+T} \exp \Big( 3 e^{2it} +2 e^{it} - itz -5 \Big) dt \\[6pt]
\end{aligned} \end{equation}$$
This integral is hard to solve, so it is easier to proceed in this case by taking a standard convolution.  Doing this yields the closed form solution:
$$\begin{equation} \begin{aligned}
p_Z(z) 
&= \sum_{y=0}^{\lfloor z/2 \rfloor} p_Y(y) \cdot p_X(z-2y) \\[6pt]
&= \exp(-5) \sum_{y=0}^{\lfloor z/2 \rfloor} \frac{3^y 2^{z-2y}}{y! (z-2y)!} \\[6pt]
&= 2^z \exp(-5) \sum_{y=0}^{\lfloor z/2 \rfloor} \frac{(\tfrac{3}{4})^y}{y! (z-2y)!}. \\[6pt]
\end{aligned} \end{equation}$$
You can create a function for this PMF in R as follows:
#Create probability mass function for Z
PMF <- function(z) { YY <- floor(z/2);
                     Y <- 0:YY;
                     for (i in 0:YY) { Y[i+1] <- dpois(i, 3)*dpois(z-2*i, 2); }
                     sum(Y); }

#Create data frame of PMF values from Z = 0,...,25
ZZ   <- 25;
Z    <- 0:ZZ;
Prob <- rep(0,length(ZZ));
for (z in 0:ZZ) { Prob[z+1] <- PMF(z) }
DATA <- data.frame(z = Z, Prob =  Prob)

#Plot the PMF
library(ggplot2);

FIGURE <- ggplot(data = DATA, aes(x = z, y = Prob)) +
          geom_bar(stat = 'identity', fill = 'red') +
          theme(plot.title = element_text(hjust = 0.5, face = 'bold')) + 
          ggtitle('Probability Mass Function') +
          xlab('z') + ylab('Probability');
FIGURE;


