Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Simplify this expression with Mathematica

  1. May 15, 2010 #1
    I know this expression should return a Gaussian distribution but I can't get Mathematica to simplify the integral. What am I missing?

    [tex]
    \text{Simplify}\left[\frac{\text{Product}\left[\text{PDF}\left[\text{NormalDistribution}[y,\sigma ],x_i\right],\{i,n\}\right]\text{PDF}[\text{NormalDistribution}[\mu ,\phi ],y]}{\text{Integrate}\left[\text{Product}\left[\text{PDF}\left[\text{NormalDistribution}[y,\sigma ],x_i\right],\{i,n\}\right]\text{PDF}[\text{NormalDistribution}[\mu ,\phi ],y],\{y,-\text{Infinity},\text{Infinity}\},\text{Assumptions}\to \{\sigma >0,\phi >0\}\right]},\{\sigma >0,\phi >0\}\right]
    [/tex]
     
  2. jcsd
  3. May 17, 2010 #2
    Kinda' messy dab. Runs right off the right side of my computer. Try FullSimplify and just on the part you need to simplify. Then start adding things back to the expression one by one to see if that helps.
     
  4. May 22, 2010 #3
    Ok, so I am trying to integrate this with no success

    FullSimplify[
    Integrate[
    Product[PDF[NormalDistribution[y, \[Sigma]], Subscript[x, i]], {i,
    n}]

    PDF[NormalDistribution[\[Mu], \[Phi]], y],
    {y, -Infinity, Infinity},
    Assumptions -> {\[Sigma] >= 0, \[Phi] >= 0}]]
     
  5. May 22, 2010 #4

    Hepth

    User Avatar
    Gold Member

    Im not sure what "n" is, but if its 1, what you need to do is change the greater than equals signs to just greater than signs, I get:

    Code (Text):
    n = 1
    Integrate[
      Product[PDF[NormalDistribution[y, \[Sigma]], Subscript[x, i]], {i,
         n}] PDF[NormalDistribution[\[Mu], \[Phi]], y], {y, -Infinity,
       Infinity},
      Assumptions -> {\[Sigma] > 0, \[Phi] > 0}] // FullSimplify
     
    [tex]
    \frac{e^{-\frac{\left(\mu -x_1\right){}^2}{2 \left(\sigma ^2+\phi ^2\right)}}}{\sqrt{2 \pi } \sqrt{\sigma ^2+\phi ^2}}
    [/tex]
     
  6. May 23, 2010 #5
    By letting n=1 you eliminate the product and that is not what I meant.
    n is simply the upper limit of the product, i.e., 'i' goes from 1 to 'n'.

    Thanks.
     
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook