In this section, we want to extend the basic polarized reflectometry tutorial to simulate spin-flip reflectivity. For this purpose, we want to parametrize the magnetization by the angle $\alpha$ between the magnetization and the spin of the incoming neutrons and its magnitude $\left| \mathbf{M} \right|$: $$\mathbf M = \left| \mathbf{M} \right| \left( \sin \alpha, \cos \alpha, 0\right)^\mathrm{T}$$ In practice, the construction of the magnetization vector in Python then proceeds as follows:
magnetizationMagnitude = 1e8
angle = 30 * deg
magnetizationVector = R3(
magnetizationMagnitude * numpy.sin(angle),
magnetizationMagnitude * numpy.cos(angle),
0)
In addition to the non-spin-flip channels, we simulate the spin-flip channels (up-down and down-up) with the following function calls
results_pm = run_simulation(R3(0, 1, 0),
R3(0, -1, 0))
results_mp = run_simulation(R3(0, -1, 0),
R3(0, 1, 0))
Running the full script that is given below, we obtain the following simulation result:
This plot shows the resulting reflectivity in all four channels. The non-spin-flip channels (up-up and down-down) are similar to the result without spin flip. As expected, both spin-flip channels are identical.
Here is the complete example:
|
|