Tutorial on Beamline Simulation - �Example Beamline in OASYS2.0 – BL18 HAXPES�
1
Oasys2/Shadow4 Concepts Explored
2
BL18 Model - Oasys Widgets Employed
3
SSRL BL18 HAXPES – IVU w/ DCM and 2-Stage Focusing
4
SSRL BL18 HAXPES Optics Model
5
Idealized Geometric Source
6
Advantages
Disadvantages
Where can I find SPEAR electron source characteristics?
Shadow4 Geometric Source - “BL18 Undulator”
7
execute & write file
Shadow4 Geometric Source - “BL18 Undulator”
8
SSRL BL18 HAXPES Optics Model - Mirrors
9
Side Deflecting, Focusing Mirror - hKB
10
side deflecting
Focusing Mirror – DABAM Shape Error
11
Focusing Mirror – DABAM Shape Error
12
Focusing Mirror – Incorporating Height Error Data
13
mm units
Side Deflecting Optic Rotates Coordinate System
14
Often easier to keep track if you rotate the coordinate system back to the lab frame after a side deflecting optic. Use the empty element to do so.
SSRL BL18 HAXPES Optics Model - Monochromator
15
Double Crystal Mono (DCM)
16
For DCM2 dispersive to DCM1, add DCM2 1st crystal with 0° rotation
wrt DCM1 2nd crystal and
DCM2 2nd crystal with 180°
rotation wrt DCM2 1st crystal
DCM1 2nd crystal orientation 180° with appropriately small source plane distance
DCM1 1st crystal
Native Loop Single Variable Scan – DBA size
17
BL18 uses two-stage horizontal focusing where hKB focuses on a beam defining aperture (BDA) and hKB2 images the BDA to the sample position with 3:1 demagnification. This is a good opportunity to explore the effect of changing BDA size on the focus by scanning the BDA in a loop.
Native Loop Single Variable Scan – DBA size
18
linger mouse to display variable name
clear stored data before starting scan!!!
Native Loop Single Variable Scan – DBA size
19
horizontal focus vs BDA size
Native Loop Scan with Attribute Files – hKB2 Shape Error
20
hKB2 images the BDA to the sample with 3:1 demagnification, but the image quality is impacted by hKB2 shape error. This is a good opportunity to explore the effect of changing hKB2 shape error in an attribute file scan loop.
Native Loop Scan with Attribute Files – hKB2 Shape Error
21
Native Loop Scan with Attribute Files – hKB2 Shape Error
22
Undulator Beam Structure
23
slit accept
A real undulator beam has structure at harmonics of the fundamental photon energy. Flux curve below shows 7th (left) and 8th (right) harmonics.
emission not Gaussian
Undulator Beam Structure
24
A real undultor provides a more complex emission spectra that varies with undulator gap, slit acceptance, and mono photon energy
Undulator Beam Structure
25
A real undultor provides a more complex emission spectra that varies with undulator gap, slit acceptance, and mono photon energy
Undulator Source Build and Save for Repetitive Use
26
One of the compromises to converting Shadow to Python for maintenance simplification is it slowed down the execution especially, seemingly, the undulator simulation. A work around is to save the undulator rays to a named file for later read in.
https://journals.iucr.org/s/issues/2025/02/00/yn5118/index.html
Source – Undulator Monte Carlo Scaling to Photon Flux
27
(the end)
28