[mcstas-users] Pol_simpleBfield : wrong intensity(?)
André Kusmin
a.kusmin at tudelft.nl
Mon Mar 2 13:43:10 CET 2015
Hi everyone,
I noticed that in a simple polarized neutron instrument
made of source, polarizer, precession field, analyzer
the resulting signal, as expected, oscillates as cos(const*lambda*B*L)
but at B=0, the intensity of the signal is less than 100% (see attached
PNG, plotted intensity against two different lengths of magnetic field
regions).
It turns out that intensity at B*L=0 is correct.
For 100 % polarized beam and zero precession field the intensity after
the analyzer is 4.2e-14
(with TestLarmor.out)
The same intensity I get with ./TestLarmorOnlysource.out
but when I set non zero field in precession region I get even larger
intensity, which is impossible.
Test can be done with two attached instr files and commands:
./TestLarmor.out By1=0 -n 1e5 DLambda=0.000001
./TestLarmor.out By1=0.000001 -n 1e5 DLambda=0.000001
./TestLarmorOnlysource.out -n 1e5 DLambda=0.000001
could anyone please check if this is reproducible?
perhaps I miss something.
I have McStas pre2.2 (compiled from SVN) on linux multilib 64 bit
(Slackware)
best regards
Andre
-------------- next part --------------
/*******************************************************************************
* McStas instrument definition URL=http://www.mcstas.org
*
* Instrument: TestLarmor
*
* %Identification
* Release: McStas 2.2
*
* %Description
* Toy model to test Larmor precessions
*
**
* %End
*******************************************************************************/
DEFINE INSTRUMENT TestLarmor(
Lambda= 2.1,
DLambda= 0.1,
sourcefocusdist = 100,
detsize=0.5,
//polarization
initialpol = 1.0,
polarizerpos = 0.5,
//fields
Bfield1start = 1,
BsizeX = 0.5,
BsizeY = 0.05,
BsizeZ = 2,
// field strength
By1 = 0.001
)
DECLARE
%{
double Bfield1stop;
%}
INITIALIZE
%{
Bfield1stop=Bfield1start+BsizeZ;
%}
TRACE
COMPONENT Origin = Progress_bar()
AT (0, 0, 0) ABSOLUTE
COMPONENT Source = Source_simple(
radius = 0.00,
yheight = 0.01,
xwidth = 0.01,
dist = sourcefocusdist,
focus_xw = 0.01, focus_yh = 0.01,
lambda0 = Lambda,
dlambda = DLambda * Lambda)
AT (0, 0, 0) RELATIVE Origin
COMPONENT polariser = Set_pol(px=initialpol)
AT (0, 0, polarizerpos) RELATIVE Origin
COMPONENT B_field1=Pol_simpleBfield(xwidth=BsizeX, yheight=BsizeY, zdepth=BsizeZ, Bx=0, By=By1, Bz=0)
AT (0, 0, Bfield1start) RELATIVE Origin
COMPONENT B_field_stop1=Pol_simpleBfield_stop(magnet_comp_stop=B_field1)
AT (0, 0, Bfield1stop) RELATIVE Origin
// *************************
// analyzer and detectors
// *************************
COMPONENT analyser = Analyser_ideal(mx=1, my=0, mz=0)
AT (0, 0, Bfield1stop+1) RELATIVE Origin
COMPONENT PSD = PSD_monitor(nx=1, ny=1, filename="PSD", xwidth=detsize, yheight=detsize)
AT (0, 0, Bfield1stop+1.0002) RELATIVE Origin
FINALLY
%{
%}
END
-------------- next part --------------
/*******************************************************************************
* McStas instrument definition URL=http://www.mcstas.org
*
* Instrument: TestLarmorOnlysource
*
* %Identification
* Release: McStas 2.2
*
* %Description
* only source and detector
*
*
* %End
*******************************************************************************/
DEFINE INSTRUMENT TestLarmorOnlysource(
Lambda= 2.1,
DLambda= 0.1,
sourcefocusdist = 100,
detsize=0.5,
polarizerpos = 0.5
)
DECLARE
%{
%}
INITIALIZE
%{
%}
TRACE
COMPONENT Origin = Progress_bar()
AT (0, 0, 0) ABSOLUTE
COMPONENT Source = Source_simple(
radius = 0.00,
yheight = 0.01,
xwidth = 0.01,
dist = sourcefocusdist,
focus_xw = 0.01, focus_yh = 0.01,
lambda0 = Lambda,
dlambda = DLambda * Lambda)
AT (0, 0, 0) RELATIVE Origin
COMPONENT PSD = PSD_monitor(nx=1, ny=1, filename="PSD", xwidth=detsize, yheight=detsize)
AT (0, 0, polarizerpos+1.0002) RELATIVE Origin
FINALLY
%{
%}
END
-------------- next part --------------
A non-text attachment was scrubbed...
Name: example-Larmor-shift-linlin-01.png
Type: image/png
Size: 62092 bytes
Desc: not available
URL: <http://mailman2.mcstas.org/pipermail/mcstas-users/attachments/20150302/f38c0634/attachment.png>
More information about the mcstas-users
mailing list