<rss xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" version="2.0">
  <channel>
    <title>MaplePrimes - answers and comments on Question, How do I find the moment generating function from a given PDF?</title>
    <link>http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating</link>
    <language>en-us</language>
    <copyright>2026 Maplesoft, A Division of Waterloo Maple Inc.</copyright>
    <generator>Maplesoft Document System</generator>
    <lastBuildDate>Sun, 14 Jun 2026 02:35:05 GMT</lastBuildDate>
    <pubDate>Sun, 14 Jun 2026 02:35:05 GMT</pubDate>
    <itunes:subtitle />
    <itunes:summary />
    <description>The latest answers and comments added to the Question, How do I find the moment generating function from a given PDF?</description>
    <image>
      <url>http://www.mapleprimes.com/images/mapleprimeswhite.jpg</url>
      <title>MaplePrimes - answers and comments on Question, How do I find the moment generating function from a given PDF?</title>
      <link>http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating</link>
    </image>
    <item>
      <title>It can be done with Maple</title>
      <link>http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating?ref=Feed:MaplePrimes:How do I find the moment generating function from a given PDF?:Comments#answer139339</link>
      <itunes:summary>&lt;p&gt;Up to Wiki (see &lt;a href="http://en.wikipedia.org/wiki/Moment-generating_function"&gt;http://en.wikipedia.org/wiki/Moment-generating_function&lt;/a&gt; ), &lt;br&gt;the moment-generating function M[X](t) of an absolutely continuous random variable X&lt;br&gt;can be calculated in such a way&lt;br&gt;M[X](t):=unapply(int(exp(t*u)*PDF(X,u),u=-infinity..infinity),t).&lt;br&gt;For example,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;form name="worksheet_form"&gt;
&lt;table style="width: 576px;" align="center"&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #ff0000; font-size: 100%; font-family: Courier New,monospace; font-weight: bold; font-style: normal;"&gt;&amp;nbsp; &lt;/span&gt; &lt;br&gt; &lt;img style="vertical-align: -24;" src="/view.aspx?sf=139339/446268/f8a78be3f76b64a116bb83331a88365d.gif" alt="with(Statistics):" width="600" height="47" align="middle"&gt;&lt;/p&gt;
&lt;table&gt;
&lt;tbody&gt;
&lt;tr valign="baseline"&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="center"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/425cecde249f3c37ac112e7e6b5693cb.gif" alt="_R" width="22" height="23"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;td style="color: #000000; font-family: Times, serif; font-weight: bold; font-style: normal;" align="right"&gt;(1)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #ff0000; font-size: 100%; font-family: Courier New,monospace; font-weight: bold; font-style: normal;"&gt;&amp;nbsp; &lt;/span&gt;&lt;/p&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;img style="vertical-align: -23;" src="/view.aspx?sf=139339/446268/52f3902bebc0b9e53febea638fc50afb.gif" alt="M := `assuming`([unapply(int(exp(t*u)*PDF(X, u), u = -infinity .. infinity), t)], [sigma &amp;gt; 0])" width="576" height="40" align="middle"&gt;&lt;/p&gt;
&lt;table&gt;
&lt;tbody&gt;
&lt;tr valign="baseline"&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="center"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/b2ae2c4f27e7228b1ffd6d2c213ed05c.gif" alt="proc (t) options operator, arrow; exp((1/2)*t*(t*sigma^4+2*a)) end proc" width="119" height="42"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;td style="color: #000000; font-family: Times, serif; font-weight: bold; font-style: normal;" align="right"&gt;(2)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #000000; font-size: 100%; font-family: Times New Roman,serif; font-weight: normal; font-style: normal;"&gt;Let's find the fifth moment of X:&lt;/span&gt; &lt;br&gt; &lt;img style="vertical-align: -24;" src="/view.aspx?sf=139339/446268/7b1df6563efcba4cc5c22546fa97925f.gif" alt="m[5] := eval(diff(M(t), `$`(t, 5)), t = 0)" width="600" height="41" align="middle"&gt;&lt;/p&gt;
&lt;table&gt;
&lt;tbody&gt;
&lt;tr valign="baseline"&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="center"&gt;&lt;img style="vertical-align: -7;" src="/view.aspx?sf=139339/446268/54385dffda5701c15c0578877e428edf.gif" alt="15*sigma^8*a+10*sigma^4*a^3+a^5" width="151" height="30"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;td style="color: #000000; font-family: Times, serif; font-weight: bold; font-style: normal;" align="right"&gt;(3)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #ff0000; font-size: 100%; font-family: Courier New,monospace; font-weight: bold; font-style: normal;"&gt;&amp;nbsp; &lt;/span&gt;&lt;/p&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/0ac333ffd2aaf544bbdf8f9b032cb624.gif" alt="``" width="11" height="23"&gt;&lt;/p&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/ce5c1135bd39622ec64e3d9c7115cfb2.gif" alt="``" width="11" height="23"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;input type="hidden" name="sequence" value="1"&gt; &lt;input type="hidden" name="cmd" value="none"&gt;&lt;/form&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;a href="/view.aspx?sf=139339/446268/moment.mw"&gt;Download moment.mw&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;See &lt;a href="http://www.maplesoft.com/support/help/search.aspx?term=Statistics[ProbabilityDensityFunction]"&gt;?Statistics[ProbabilityDensityFunction]&lt;/a&gt; for more details.&lt;/p&gt;
&lt;p&gt;Edit. The definition of M[X](t).&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;/p&gt;</itunes:summary>
      <description>&lt;p&gt;Up to Wiki (see &lt;a href="http://en.wikipedia.org/wiki/Moment-generating_function"&gt;http://en.wikipedia.org/wiki/Moment-generating_function&lt;/a&gt; ), &lt;br&gt;the moment-generating function M[X](t) of an absolutely continuous random variable X&lt;br&gt;can be calculated in such a way&lt;br&gt;M[X](t):=unapply(int(exp(t*u)*PDF(X,u),u=-infinity..infinity),t).&lt;br&gt;For example,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;form name="worksheet_form"&gt;
&lt;table style="width: 576px;" align="center"&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #ff0000; font-size: 100%; font-family: Courier New,monospace; font-weight: bold; font-style: normal;"&gt;&amp;nbsp; &lt;/span&gt; &lt;br&gt; &lt;img style="vertical-align: -24;" src="/view.aspx?sf=139339/446268/f8a78be3f76b64a116bb83331a88365d.gif" alt="with(Statistics):" width="600" height="47" align="middle"&gt;&lt;/p&gt;
&lt;table&gt;
&lt;tbody&gt;
&lt;tr valign="baseline"&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="center"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/425cecde249f3c37ac112e7e6b5693cb.gif" alt="_R" width="22" height="23"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;td style="color: #000000; font-family: Times, serif; font-weight: bold; font-style: normal;" align="right"&gt;(1)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #ff0000; font-size: 100%; font-family: Courier New,monospace; font-weight: bold; font-style: normal;"&gt;&amp;nbsp; &lt;/span&gt;&lt;/p&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;img style="vertical-align: -23;" src="/view.aspx?sf=139339/446268/52f3902bebc0b9e53febea638fc50afb.gif" alt="M := `assuming`([unapply(int(exp(t*u)*PDF(X, u), u = -infinity .. infinity), t)], [sigma &amp;gt; 0])" width="576" height="40" align="middle"&gt;&lt;/p&gt;
&lt;table&gt;
&lt;tbody&gt;
&lt;tr valign="baseline"&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="center"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/b2ae2c4f27e7228b1ffd6d2c213ed05c.gif" alt="proc (t) options operator, arrow; exp((1/2)*t*(t*sigma^4+2*a)) end proc" width="119" height="42"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;td style="color: #000000; font-family: Times, serif; font-weight: bold; font-style: normal;" align="right"&gt;(2)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #000000; font-size: 100%; font-family: Times New Roman,serif; font-weight: normal; font-style: normal;"&gt;Let's find the fifth moment of X:&lt;/span&gt; &lt;br&gt; &lt;img style="vertical-align: -24;" src="/view.aspx?sf=139339/446268/7b1df6563efcba4cc5c22546fa97925f.gif" alt="m[5] := eval(diff(M(t), `$`(t, 5)), t = 0)" width="600" height="41" align="middle"&gt;&lt;/p&gt;
&lt;table&gt;
&lt;tbody&gt;
&lt;tr valign="baseline"&gt;
&lt;td&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="center"&gt;&lt;img style="vertical-align: -7;" src="/view.aspx?sf=139339/446268/54385dffda5701c15c0578877e428edf.gif" alt="15*sigma^8*a+10*sigma^4*a^3+a^5" width="151" height="30"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;td style="color: #000000; font-family: Times, serif; font-weight: bold; font-style: normal;" align="right"&gt;(3)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;span style="color: #ff0000; font-size: 100%; font-family: Courier New,monospace; font-weight: bold; font-style: normal;"&gt;&amp;nbsp; &lt;/span&gt;&lt;/p&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/0ac333ffd2aaf544bbdf8f9b032cb624.gif" alt="``" width="11" height="23"&gt;&lt;/p&gt;
&lt;p style="margin: 0 0 0 0; padding-top: 0px; padding-bottom: 0px;" align="left"&gt;&lt;img style="vertical-align: -6;" src="/view.aspx?sf=139339/446268/ce5c1135bd39622ec64e3d9c7115cfb2.gif" alt="``" width="11" height="23"&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;input type="hidden" name="sequence" value="1"&gt; &lt;input type="hidden" name="cmd" value="none"&gt;&lt;/form&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;a href="/view.aspx?sf=139339/446268/moment.mw"&gt;Download moment.mw&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;See &lt;a href="http://www.maplesoft.com/support/help/search.aspx?term=Statistics[ProbabilityDensityFunction]"&gt;?Statistics[ProbabilityDensityFunction]&lt;/a&gt; for more details.&lt;/p&gt;
&lt;p&gt;Edit. The definition of M[X](t).&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;/p&gt;</description>
      <guid>139339</guid>
      <pubDate>Thu, 08 Nov 2012 22:22:22 Z</pubDate>
      <itunes:author>Markiyan Hirnyk</itunes:author>
      <author>Markiyan Hirnyk</author>
    </item>
    <item>
      <title>Moment</title>
      <link>http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating?ref=Feed:MaplePrimes:How do I find the moment generating function from a given PDF?:Comments#answer139342</link>
      <itunes:summary>&lt;p&gt;You can use the Statistics:-Moment command.&lt;/p&gt;
&lt;p&gt;You could do this starting with a random variable produced wih the RandomVariable command. But you mentioned getting there from the pdf, so let's start with that:&lt;/p&gt;
&lt;pre&gt;restart:
with(Statistics):

assume(sigma::real):
pdf:=(1/2)*2^(1/2)*exp(-(1/2)*(t-a)^2/sigma^4)/(Pi^(1/2)*sigma^2):

X:=Distribution(PDF=unapply( pdf, t )):

Moment(X,5);
                 5       3      4             8
                a  + 10 a  sigma  + 15 a sigma 

restart:
with(Statistics):

pdf:=(1/2)*2^(1/2)*exp(-(1/2)*(t-a)^2/sigma^4)/(Pi^(1/2)*sigma^2):

X:=Distribution(PDF=unapply( pdf, t )):

Moment(X,5):
simplify(%)  assuming sigma::real;

                 / 4       2      4           8\
               a \a  + 10 a  sigma  + 15 sigma /
&lt;/pre&gt;
&lt;!--break--&gt;
&lt;p&gt;acer&lt;/p&gt;</itunes:summary>
      <description>&lt;p&gt;You can use the Statistics:-Moment command.&lt;/p&gt;
&lt;p&gt;You could do this starting with a random variable produced wih the RandomVariable command. But you mentioned getting there from the pdf, so let's start with that:&lt;/p&gt;
&lt;pre&gt;restart:
with(Statistics):

assume(sigma::real):
pdf:=(1/2)*2^(1/2)*exp(-(1/2)*(t-a)^2/sigma^4)/(Pi^(1/2)*sigma^2):

X:=Distribution(PDF=unapply( pdf, t )):

Moment(X,5);
                 5       3      4             8
                a  + 10 a  sigma  + 15 a sigma 

restart:
with(Statistics):

pdf:=(1/2)*2^(1/2)*exp(-(1/2)*(t-a)^2/sigma^4)/(Pi^(1/2)*sigma^2):

X:=Distribution(PDF=unapply( pdf, t )):

Moment(X,5):
simplify(%)  assuming sigma::real;

                 / 4       2      4           8\
               a \a  + 10 a  sigma  + 15 sigma /
&lt;/pre&gt;
&lt;!--break--&gt;
&lt;p&gt;acer&lt;/p&gt;</description>
      <guid>139342</guid>
      <pubDate>Thu, 08 Nov 2012 23:30:07 Z</pubDate>
      <itunes:author>acer</itunes:author>
      <author>acer</author>
    </item>
    <item>
      <title>Addition</title>
      <link>http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating?ref=Feed:MaplePrimes:How do I find the moment generating function from a given PDF?:Comments#comment139348</link>
      <itunes:summary>&lt;p&gt;Take a look at &lt;a href='http://www.maplesoft.com/support/help/search.aspx?term=Statistics[MomentGeneratingFunction]' target='_new'&gt;?Statistics[MomentGeneratingFunction]&lt;/a&gt; .&lt;br&gt;&lt;br&gt;&lt;/p&gt;</itunes:summary>
      <description>&lt;p&gt;Take a look at &lt;a href='http://www.maplesoft.com/support/help/search.aspx?term=Statistics[MomentGeneratingFunction]' target='_new'&gt;?Statistics[MomentGeneratingFunction]&lt;/a&gt; .&lt;br&gt;&lt;br&gt;&lt;/p&gt;</description>
      <guid>139348</guid>
      <pubDate>Fri, 09 Nov 2012 00:30:39 Z</pubDate>
      <itunes:author>Markiyan Hirnyk</itunes:author>
      <author>Markiyan Hirnyk</author>
    </item>
    <item>
      <title>Moment-generating function, not moments</title>
      <link>http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating?ref=Feed:MaplePrimes:How do I find the moment generating function from a given PDF?:Comments#comment139347</link>
      <itunes:summary>&lt;p&gt;The question is how to find the moment-generating function of an absolutely continuous random variable, not its moments.&lt;/p&gt;</itunes:summary>
      <description>&lt;p&gt;The question is how to find the moment-generating function of an absolutely continuous random variable, not its moments.&lt;/p&gt;</description>
      <guid>139347</guid>
      <pubDate>Fri, 09 Nov 2012 00:09:44 Z</pubDate>
      <itunes:author>Markiyan Hirnyk</itunes:author>
      <author>Markiyan Hirnyk</author>
    </item>
    <item>
      <title>careless</title>
      <link>http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating?ref=Feed:MaplePrimes:How do I find the moment generating function from a given PDF?:Comments#comment139352</link>
      <itunes:summary>&lt;p&gt;&lt;a href="http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating#comment139347"&gt;@Markiyan Hirnyk&lt;/a&gt; Sorry, that was careless of me; I didn't read the question at all carefully.&lt;/p&gt;</itunes:summary>
      <description>&lt;p&gt;&lt;a href="http://www.mapleprimes.com/questions/139333-How-Do-I-Find-The-Moment-Generating#comment139347"&gt;@Markiyan Hirnyk&lt;/a&gt; Sorry, that was careless of me; I didn't read the question at all carefully.&lt;/p&gt;</description>
      <guid>139352</guid>
      <pubDate>Fri, 09 Nov 2012 01:03:45 Z</pubDate>
      <itunes:author>acer</itunes:author>
      <author>acer</author>
    </item>
  </channel>
</rss>