Let $x\in \mathbb{R}$ be a random variable. Given the finite number of moments of random variable $x$, e.g., $E[x^{\alpha}], \alpha = 0,...,N$, how we can generate random numbers with the distribution of $x$ ?
1 Answer
If you know the moments until order $N$ you can approximate the moment generating function (MGF) of $X$ —M_X(t)— with a Taylor polynomial of order $N$, since $$M_X(t)=1+E(X)t+\frac{E(X^2)}{2!}t^2+\frac{E(X^3)}{3!}t^3+\cdots+\frac{E(X^N)}{N!}t^N+\mathcal O(t^{N+1}),$$ (provided there is a moment of order $N+1$).
There are procedures to simulate observations of $X$ given its MGF (in this case an approximation), but the descriptions are quite technical. If you're patient, maybe you can check this paper out.