Hi, On Thu, Jun 16, 2011 at 9:27 PM, Brian Granger <[email protected]> wrote: > Sean, > > Here are some notes I sent to you earlier in the summer. The points > made here are quite important.. > > So there are some things you should know about the Wigner D matrix: > > * While I implemented it, I have 0 confidence that the current > implementation is free of bugs. Because of this, one of the first > tasks should be to test this part of the code extensively, both for > numerical and symbolic arguments. > > I would test the D and d matrix code thoroughly *before* moving on to > anything else. It would be great to see a pull request for that.
+1 > > * The current method of computing the D matrix is not optimal. This > is because we probably want to use a different form for the integer > and half integer spin values. This is to get the canonical forms > where, for 1/2 integer spins there are things like sin(theta/2) and > cos(theta/2), but for integer spins, sin(theta) and cos(theta) appear. > This should be implemented and then tested extensively. > > This will also help in testing and comparing to the tables in Varsh. > > * Let's use the convention of Varshalovich for the D-matrices. He > follows the convention of most of the other main people in the field > (see Table 4.2 for a list). > > * We should use his convention for Euler angles as well. > > * Because of the intimate relationship between CG, Wigner 3j6j, etc > and the rotation matrices, we probably want to have a symbolic DMatrix > class that we can use when we are representing various sum and > integrals symbolically. This should be separate from the rotation > matrix operator and should be in the same category object as the GC > and Wigner symbols. This will allow us to implement all of the > symmetry relationships that D satisfies as well. > > * Currently I have implemented one of the differential representations > of d(J,m,m') from section 4.3.2. I think that is probably OK for > integer spin, but for half integer spins we should use one of the > formulas from section 4.3.1 that are a sum over k. > > This very important I think... > > * When testing d(j,m,m') we probably want to simply go through the > specific cases from Tables 4.3, 4.4, 4.5 (j=1/2,1,3/2). > > It looks like Ondrej has helped to track down the actual bug in the > current implementation, BUT that does solve the issue of the tests and > implementing a different approach for 1/2 in integer spins. I absolutely agree with everything that Brian just said. I have been a little unsure about the actual implementations, as I haven't been using these things much. However, that has just changed. I obtained the Varshalovich book, and I spent several hours today studying it, and the Wigner matrices and so on. I think I now understand what is going on, and suddenly everything that Brian said makes sense to me. Sean, if something is not clear, just ask, I will gladly explain in more details. So the TODO list: 1) Finish the current pull request #431, just address all the comments, but don't do more tests (unless you can do it very quickly). Important is to get this in and then improve 2) After #431 is in, start digging into the algorithm for small "d" function, fix it, and then test it for all values of all the arguments, create a new pull request, get it in 3) Test the "D" function, both symbolic and numeric. Write tests. Maybe you can merge this with 2) 4) Fix the spin bases and conversions, it will probably "just" work, but just write thorough tests, as Brian suggested in the pull request After this is done, we'll go to the CG() stuff. In the meantime, I will try to finish my TableForm pull request, and then we'll write some examples to generate the exact tables in Varshalovich, and put it into examples/ in sympy, so that we can just run it, and then compare with the tables in the book. That will be easiest to quickly check that all is good by hand. Ondrej -- You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/sympy?hl=en.
