[mcstas-users] Including the complex part of the optical potential of Neutron in McStas

Robert Dalgliesh - STFC UKRI robert.dalgliesh at stfc.ac.uk
Mon Nov 6 15:50:21 CET 2023


Hi Both,
The model in the multi-layer sample is a very simple one and doesn't include the complex part. I wrote the component for simple sample consisting of 1 or 2 layers of material. Everything was done for speed so as to not introduce a really complicated calculation into the simulation.
I guess that this could be pre-calculated and then interpolation used to be more efficient having read the simulated data from a file.

It would be easy enough for someone to write a new version of the multi-layer to use the more complicated expressions using a similar setup to the one I wrote as the routine calls the gsl to do the complex maths. It just needs somebody to take a day or two to work it out.
The biggest problem you will find will be how to input the parameters required to set up the simulation of the model but I guess you could make use of a setup file somewhere to do this in a similar way to the files used for the crystallographic samples.

Rob

From: mcstas-users <mcstas-users-bounces at mcstas.org> On Behalf Of Kim Lefmann
Sent: Sunday, November 5, 2023 9:38 PM
To: Ahmad Alqaisi <aalqais2 at asu.edu>; mcstas-users at mcstas.org
Cc: Snow, William Michael <wsnow at indiana.edu>
Subject: Re: [mcstas-users] Including the complex part of the optical potential of Neutron in McStas


Dear Ahmad,



The short reply is: no, this is not included. Neutron guide reflectivities are calculated from fitted experimental data, not from reflectivity equations.



To implement this, you would need to come up with the full reflectivity curve, R(q), for a given surface. One of the former reflectivity samples could take as input exactly a file of this sort and use it for the purpose, but I think this is no longer a part of the distribution.



There is also the Multilayer_Sample, which is a contributed component by Robert Dalgliesh. You could look into that and/or contact Robert. This is likely the closest we get to something that fit your needs.



best, Kim

________________________________
From: mcstas-users <mcstas-users-bounces at mcstas.org<mailto:mcstas-users-bounces at mcstas.org>> on behalf of Ahmad Alqaisi <aalqais2 at asu.edu<mailto:aalqais2 at asu.edu>>
Sent: Sunday, November 5, 2023 9:52:02 PM
To: mcstas-users at mcstas.org<mailto:mcstas-users at mcstas.org>
Cc: Snow, William Michael
Subject: [mcstas-users] Including the complex part of the optical potential of Neutron in McStas

You don't often get email from aalqais2 at asu.edu<mailto:aalqais2 at asu.edu>. Learn why this is important<https://aka.ms/LearnAboutSenderIdentification>
Dear McStas team,

I'm new to McStas simulations. I would like to ask about the complex part of the optical potential of Neutrons
                                              U=V-iW
Is it included in the reflectivity calculations for Neutron Guides?

If not, is there a way to add it to McStas? Can the complex part be added as an additional formula to McStas? for example by adding a formula like the one attached to this email

If you can provide me with a guidance on the script lines that would achieve such a goal, that would be great

Best,
Ahmad Alqaisi,
Student Researcher at
Indiana University Bloomington, US
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman2.mcstas.org/pipermail/mcstas-users/attachments/20231106/0622d114/attachment-0001.html>


More information about the mcstas-users mailing list