Note, the typo is not in equations 8.197a-c on page 319, only in the first equation of the rotation matrix elements.
Regards, Edward On Thu, Mar 12, 2009 at 8:23 PM, Edward d'Auvergne <edward.dauver...@gmail.com> wrote: > On Thu, Mar 12, 2009 at 7:04 PM, Sébastien Morin > <sebastien.mori...@ulaval.ca> wrote: >> Edward d'Auvergne wrote: >>> On Thu, Mar 12, 2009 at 6:05 PM, Sébastien Morin >>> <sebastien.mori...@ulaval.ca> wrote: >>> >>>> Hi, >>>> >>>> In an attempt to find the problem causing this bug, I dug into the code >>>> and found something which could be erroneous... This alone does not fix >>>> the bug, but may be part of the fix (or not)... >>>> >>>> In function math_fns/direction_cosine.calc_ellipsoid_di(), there could >>>> be an error at line 229: >>>> >>>> diff_data.dz[1] = data.sin_b * data.sin_g >>>> >>>> If I am right (?), this part of the code is related to page 193 of >>>> Edward d'Auvergne's thesis: >>>> >>>> c11 = diff_data.dx[0] >>>> c21 = diff_data.dx[1] >>>> c31 = diff_data.dx[2] >>>> >>>> c12 = diff_data.dy[0] >>>> c22 = diff_data.dy[1] >>>> c32 = diff_data.dy[2] >>>> >>>> c13 = diff_data.dz[0] >>>> c23 = diff_data.dz[1] --> FALSE !!!! >>>> c33 = diff_data.dz[2] >>>> >>>> Indeed, >>>> c23 = sin(beta) * cos(gamma), >>>> whereas >>>> diff_data.dz[1] = data.sin_b * data.sin_g >>>> >>>> >>>> Thus, either me, the code or Edward's thesis are erroneous here... >>>> >>>> Am I right ? >>>> >>> >>> These unit vectors are the columns of the reverse matrix, or the >>> transpose, or simply rows of the normal matrix. This depends if you >>> are defining the rotation from being from the diffusion tensor frame >>> to the lab frame or the reverse - both are related by the transpose. >>> Hence this value is c32 which in my thesis is sin(alpha)*sin(beta). >>> Does this answer your question and solve the issue? There could be >>> bugs elsewhere in here though because of this. >>> >>> >> Ok... I am far from an expert in trigonometry... :p >> >> If I understand well what you wrote, there is no error in the code or >> the thesis ? Or should something be corrected ? > > Sorry, I had a much closer look and you are correct - there is an > error there. The problem is a typo in equation 6.61 (page 193) of my > thesis, c23 should be sin(beta) * sin(gamma). I double checked using > wikipedia and tracked it back to the thesis. Glad that it's in the > thesis and not the code!!! > > Cheers, > > Edward > > > P.S. It would be useful if you could confirm that the problem is > indeed in the thesis and not the code ;) > _______________________________________________ relax (http://nmr-relax.com) This is the relax-users mailing list relax-users@gna.org To unsubscribe from this list, get a password reminder, or change your subscription options, visit the list information page at https://mail.gna.org/listinfo/relax-users