170 likes | 180 Views
McXtrace, an X-ray Monte Carlo ray-tracing software, offers advanced code structures for developers, interactions with X-ray waves & matter, clever sampling techniques, and parallel performance enhancements. It includes tie-ins with external software, such as MCNPx and TRIPOLI4, and provides examples like JJ-Xray SAX and ESRF ID11. The funding from NABIIT supports future advancements and invites contributions to the open-source project. Hands-on experience with neutron code, contact Peter Willendrup.
E N D
Erik Knudsen, Peter Willendrup, Søren Schmidt Risø-DTU Kim Lefmann University of Copenhagen McXtrace - an X-ray Monte Carlo ray-tracing software package Erik Knudsen SMEXOS
Erik Knudsen SMEXOS Code structure • Kernel vs. Component developer Kernel: • Propagation between components • Positioning • Code generation Component developer • Physics • Interactions X-ray<->Matter
Erik Knudsen SMEXOS Code structure • Component vs. Instrument Instrument: • Relative positions of components • Interaction with simulator Components: • Interaction with X-ray wave packet Kernel generated c: • Not seen by users
Erik Knudsen SMEXOS Component code
Erik Knudsen SMEXOS Instrument file
Erik Knudsen SMEXOS Generated code “buzzwords” • “Embarrasingly parallel” - linear speedup <1000 nodes via MPI (as tested on Teragrid) • Clever sampling • SPLIT • Focus windows • Rudimentary adaptive source • Mersenne Twister random generator
Erik Knudsen SMEXOS How? • Initially • Independent particles • State parameters • Time domain prop. => k domain prop. X-RAY (r,k,p,f) etc. NEUTRON (r,v,p,s)
Erik Knudsen SMEXOS Tie-ins with external software • General Philosophy: • If someone else does it well, interface not reinventBUT • Have very simple versions in-house • Examples: • Sources: Event files (from MCNPx, TRIPOLI4) • Samples: S(q,w) (ab.initio model from VASP)
Erik Knudsen SMEXOS Sources NEUTRON X-RAY MCNPx TRIPOLI4 etc. SPECTRA XOP URGENT etc. Event File/ Brilliance Spectra Event File McStas McXtrace Virtual Source Virtual Source
Erik Knudsen SMEXOS Interface CGRAPH CGRAPH Reflection list Powder / Single Crystal component
Erik Knudsen SMEXOS Examples and milestones Als-Nielsen pet project JJ-Xray SAX ESRF ID11
Erik Knudsen SMEXOS Als-Nielsen pet-project Image size h=(f1 / p) Compact Be lens (f1)1/2=(f2)1/2=c Source size H f1 p f2 ✔ ✔ ✔ Example :
Erik Knudsen SMEXOS JJ-Xray SAX ✔✘ ✔ ✔ ✔ ✘ ✘
Erik Knudsen SMEXOS ID11 Primary optics
Erik Knudsen SMEXOS ID11 Focussing Optics
Erik Knudsen SMEXOS Funding • NABIIT • 4 years funding • 2 postdoc., 2 Ph.D.-students • Simulation • Experimentation w. SAX on Nanodiscs • Validation of Simulations
Erik Knudsen SMEXOS Going forward • General invitation to everyone: • Contribute as much as you wish! • Open Source (GPL) => Copyleft • Website: www.mcxtrace.org • Mailing list: mcxtrace-users@mcxtrace.org Hands-on experience of neutron code: contact Peter Willendrup.