Bender from Phillip Bernhard

Rob Kreuger R.Kreuger at IRI.TUDELFT.NL
Tue Mar 27 16:34:58 CEST 2001


kim.le> Hi everybody,
kim.le> 
kim.le> I just want to answer to the question of Ulrich about the
kim.le> new versions of the Bender (22 Feb 1999). I am sorry that
kim.le> there was still the old version (7 Feb 1999) in the mcstas
kim.le> archive.  The small bug is not easy to see. The problem is
kim.le> that in the old version one variable was not initiated by
kim.le> 0.0 as it should be. If your compiler does this
kim.le> automatically for you, everything is fine. If not, you

I don't think that this problem would be solved by a compiler initializing
variables to zero. The variable has to be reset every time a neutron
enters this component. Since such a component is part of a main program, a
compiler could only set it once (for the very first neutron) to zero,
which is not enough. This variable has to be set ot zero for all neutrons
being tracked in the component.

kim.le> will see differences, whenever neutrons are absorbed on
kim.le> the top and the bottom side caused by too big divergence
kim.le> (argument of the tanh-function bigger than 10 like the
kim.le> standard guide component).  Then all following neutrons,
kim.le> which Q-value is smaller than Qcs will also be absorbed in
kim.le> the old version, which is the bug.

+--------------------------------------------------------------------+
| Rob Kreuger                    | Email: Rob.Kreuger at iri.tudelft.nl |
| Tel: (+31) 015 278 3900        |                                   |
+--------------------------------+-----------------------------------+
| Radiation Technology group     | Neutron Scattering group          |
| GEM project                    | Scans PROJECT                     |
| Tel: (+31) 015 278(5244)       | Tel: (+31) 015 278(6814)          |
| Fax: (+31) 015 278(6422)       | Fax: (+31) 015 278(8303)          |
+--------------------------------+-----------------------------------+
| IRI                            | Mekelweg 15	                     |
| Delft University of Technology | 2629 JB  Delft                    |
| Tel: (+31) 015 278(5022)       | Netherlands                       |
+--------------------------------------------------------------------+







More information about the mcstas-users mailing list