[Date Index]
[Thread Index]
[Author Index]
Re: a bug in Mathematica 7.0?
*To*: mathgroup at smc.vnet.net
*Subject*: [mg115950] Re: a bug in Mathematica 7.0?
*From*: yaqi <yaqiwang at gmail.com>
*Date*: Thu, 27 Jan 2011 03:40:10 -0500 (EST)
*References*: <ihh07p$e01$1@smc.vnet.net>
On Jan 23, 3:34 am, Daniel Lichtblau <d... at wolfram.com> wrote:
> ----- Original Message -----
> > From: "yaqi" <yaqiw... at gmail.com>
> > To: mathgr... at smc.vnet.net
> > Sent: Saturday, January 22, 2011 2:22:13 AM
> > Subject: a bug in Mathematica 7.0?
> > Hello,
>
> > I was shocked by the integration result of spherical harmonics given
> > by Mathematica 7.0. The notebook conducting these evaluations is
> > attached at the end of this post.
>
> > Basically, I create a vector of real harmonics Y={Y_{n,k},k=-
> > n,n;n=0,4} and then integrate Y_{n,k}*Y_{n,k}*Omega_y over the entire
> > 2D sphere. The integral should be zero for Y_{2,2}*Y_{4,-4}*Omega_y
> > but Mathematica 7.0 gives me -55*Sqrt[21]/512. Similar for Y_{4,2}
> > *Y_{4,-4}*Omega_y, it should be zero but I get 99*Sqrt[7]/2048.
>
> > So I create another vector of normal spherical harmonics by using
> > 'SphericalHarmonicY' and then map it to the real harmonics and do the
> > integral mentioned above. The only difference is that I have a change
> > of variable in this integral; instead of using the cosine of the polor
> > angle, I used the polor angle for the intergal directly. This time,
> > Mathematica 7.0 gives me correct results.
>
> > The only different between the two results are the two terms I
> > mentioned above. I did the similar thing with Mathematica 5.0.
> > Everything is correct.
>
> > So can somebody take a look on the notebook, see if I messed up some
> > variable usages or this is indeed a bug in Mathematica 7.0? I use
> > Mathematica 7.0 for my regular derivations, this really shocked me!
>
> > I do not know how to attach a file, so I copy and paste the entire
> > notebook and attached below.
>
> > Many thanks.
> > [...]
>
> Please send the integrand and expected result for one of the bad cases. W=
hat you have is a large matrix, and I do not know which examples are proble=
matic, let alone what specific integrands produced them. (For example, I do=
now know what integrand goes with the statement "Y_{2,2}*Y_{4,-4}*Omega_y"=
. Maybe this is inexcusable ignorance on my part. Humor me.)
>
> Can send to any or all of myself, MathGroup, or Wolfram Research Tech Sup=
port.
>
> Daniel Lichtblau
> Wolfram Research- Hide quoted text -
>
> - Show quoted text -
Sorry for the long original post. I separated the problem below:
In[1]:= 1/4 Sqrt[15/\[Pi]] Cos[2 tht] Sin[mu]^2
Out[1]= 1/4 Sqrt[15/\[Pi]] Cos[2 tht] Sin[mu]^2
In[2]:= 3/16 Sqrt[35/\[Pi]] Sin[mu]^4 Sin[4 tht]
Out[2]= 3/16 Sqrt[35/\[Pi]] Sin[mu]^4 Sin[4 tht]
In[3]:= 1/8 E^(-2 I tht) (1 + E^(4 I tht)) Sqrt[15/\[Pi]] Sin[mu]^2
Out[3]= 1/8 E^(-2 I tht) (1 + E^(4 I tht)) Sqrt[15/\[Pi]] Sin[mu]^2
In[4]:= -(3/32) I E^(-4 I tht) (-1 + E^(8 I tht)) Sqrt[35/\[Pi]]
Sin[mu]^4
Out[4]= -(3/32) I E^(-4 I tht) (-1 + E^(8 I tht)) Sqrt[35/\[Pi]]
Sin[mu]^4
In[5]:= Simplify[%3 - %1]
Out[5]= 0
In[6]:= Simplify[%4 - %2]
Out[6]= 0
In[7]:= Integrate[%1*%2*(-Sin[mu]*Cos[tht])*Sin[mu], {mu, 0,
Pi}, {tht, 0, 2*Pi}]
Out[7]= -((55 Sqrt[21])/512)
In[8]:= Integrate[%3*%4*(-Sin[mu]*Cos[tht])*Sin[mu], {mu, 0,
Pi}, {tht, 0, 2*Pi}]
Out[8]= 0
=======================
Out[7] and Out[8] should be the same, but they are not. This is really
troubling me. Am I able to get a patch after it is fixed?
Thanks.
Yaqi
Prev by Date:
**Re: Help with While Loop Function**
Next by Date:
**Re: Time series minima and maxima**
Previous by thread:
**Decalring the golbal variables in Packages**
Next by thread:
**Re: a bug in Mathematica 7.0?**
| |