You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Similar to generating functions, another useful trick for calculating moments of various distributions is to use Feynman's integral trick (differentiating under the integral sign). The main idea is to introduce a fictitious parameter and rewrite the integrand as some derivative with respect to this parameter. (Note that this trick can also be used when evaluating expectation values for discrete distributions). Let me illustrate this for moments of the Gaussian distribution, which appear in the primer. Consider the integral
In order to evaluate the above expression, we introduce a parameter in the probability density function
Notice that this integral can be rewritten as
This is just a Gaussian integral, and so we find
Finally, we recover the desired result by setting the parameter to 1,
The text was updated successfully, but these errors were encountered:
Similar to generating functions, another useful trick for calculating moments of various distributions is to use Feynman's integral trick (differentiating under the integral sign). The main idea is to introduce a fictitious parameter and rewrite the integrand as some derivative with respect to this parameter. (Note that this trick can also be used when evaluating expectation values for discrete distributions). Let me illustrate this for moments of the Gaussian distribution, which appear in the primer. Consider the integral
In order to evaluate the above expression, we introduce a parameter in the probability density function
Notice that this integral can be rewritten as
This is just a Gaussian integral, and so we find
Finally, we recover the desired result by setting the parameter to 1,
The text was updated successfully, but these errors were encountered: