[neutron-mc] Problems in Powder2.comp
Chapon, LC (Laurent)
L.C.Chapon at rl.ac.uk
Tue Mar 29 13:13:34 CEST 2005
Hi,
I think there are possibly two problems in the component Powder2:
Line 105 : I think it should be l=v*(dt-t0) instead of v*dt. The
attenuation due to scattering was therefore much larger than expected.
103 dt = rand01()*(t1 - t0) + t0; /* Time of scattering */
104 PROP_DT(dt); /* Point of scattering */
105 l = v*dt; /* Penetration in sample */
The other problem is on line 170 : When using focus_aw and focus_ah. The
angles should be provided in radians and not degrees as suggested in the
component. Otherwise, DEG2RAD should be use to convert the focus_aw and
focus_ah parameters when calling the routine
randvec_target_rect_angular.
170 randvec_target_rect_angular(&vx, &vy, &vz, &solid_angle,
171 aim_x, aim_y, aim_z,
focus_aw, focus_ah, ROT_A_CURRENT_COMP);
______________________________________
Dr Laurent Chapon
Instrument Scientist
ISIS department
Bldg R3
Rutherford Appleton Laboratory
Chilton, Didcot
OX11 0QX
UK
+44(0)1235-446090
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman2.mcstas.org/pipermail/mcstas-users/attachments/20050329/87309338/attachment.html>
More information about the mcstas-users
mailing list