Special tools - Xray tools

Posted on Sun 26 June 2022 in Scientific software/Special Tools - Xray tools


X-ray raytracing

XOP and shadow raytracing http://www.esrf.eu/home/Instrumentation/software/data-analysis/xop2.4/extensions.html

Ray-UI  http://www.helmholtz-berlin.de/forschung/oe/fg/nanometeroptik/science/layout/ray_de.html%20

XrayTracer Geant4 http://xraytracer.com/

I stumbled over a new tool for x-ray and optical https://pypi.python.org/pypi/xrt

X-ray source simulation:

While they are part of GEANT or any raytracing code from above there are a few specialized codes out there. For undulators and similar things the defacto standard is SPECTRA: http://radiant.harima.riken.go.jp/spectra/

For x-ray tubes i found: pyPENELOPE very useful: https://sourceforge.net/projects/pypenelope

X-ray analysis

new things are always coming, neXus seems to be a general data format based on hdf5. This gui has a build in interface to lmfit http://nexpy.github.io/nexpy/pythongui.html

There is a lot of specialized software for analysing and simulating x-ray optics/experiments this page offers a overview http://www.esrf.eu/Instrumentation/software/data-analysis

A good start is the IFEFFIT package it contains http://cars9.uchicago.edu/ifeffit/

or the updated version called Demeter http://bruceravel.github.io/demeter/ a database program called Hephaestus for looking up nearly everything a spectroscopist could need Athena a data reduction and preanalysis program Artemis a EXAFS fitting program and some more speciallised tools are included there too

Different X-ray tools for differenet tasks

curves simulation there are two tools “FEFF” costs money http://leonardo.phys.washington.edu/feff/

A free tool calculation similar features is  http://neel.cnrs.fr/spip.php?rubrique1007&lang=fr

As a fitting tools for NEXAFS i recommend  http://xafs.org/Software/FitIt

http://xafs.org/ Is a page with a lot of informations and tutorials

comfortably displaying of fluoresence data the PyMCA tool from the ESRF is quite usefull http://pymca.sourceforge.net/index.html

Moldraw also shows the molecular data, additionally it can export FEFF input files, so can be used to convert structure files into feff input files http://rsc.anu.edu.au/opensource/index.php?option=com_docman&task=cat_view&gid=69&Itemid=32

X-ray diffraction analysis

I have not yet collected much experience with the available free software suites. In the past I have used CaRiNE and VESTA with success

X-ray emission spectroscopy calculations

This is a little python module to predict the measured flux in a emission spectroscopy setup. At the moment it is written for a crystal based setup, however with a few tricks it can be used for microcalorimeters too(drop me a mail to get explanations). The Knut och Alice Wallenbergs Stiftelse financed me during the stay at the ESRF during which this code was written and I am very grateful for their support. Simply double click the “gui_generated.py”.  each field has its explanations if you hover over it. The basis of this program is the xraylib library from the ESRF. I however compiled a offline version of the tool, so it can be run without the library installed. The gui is only the frontend and dumps all information first in three pandas.Dataframe and then as Ascii in three files on the disc. After this it calls the functions from “python_calculation.py” By using the functions from “python_calculation.py” in the command line the information can be used further. “python_calculation.py” runs if not otherwise set the “standard”experiment which is the last run. So i mostly use the gui to set the values and then go to the command line In the gui: (floating the mouse over a field gives a text which might help to use the tool) pressing enter in any text field executes the program and gives the expected countrate for the settings the same does clicking on “run single”. The “run loop” function loops over different parameters. I programmed two loops. the inner loop is designed to be run over many values and typically is used for energy scans and the like. The outer loop is run over any of the parameters but takes much longer for large sets of data if the loop is run the results are shown in a plot. command line:     emission_detection() runs the tool once and gives the expected emission intensity                             run_loop_from_save()  runs the loops I tried to comment each function extensively, if you have questions however don’t hesitate to drop me an email or leave a comment. I’m actively working on the tool so there might still be some bugs and i’m working on more functionality. Just let me know about bugs or wishes and i will try to fix/include them. Hint beside the standard python modules you will need the python “wx” and “pandas” packages. They come with most installations based on Pythonxy or EPD (see Coding. Under Linux you will have to install these packages. The first start might take a few seconds, since some modules will be precompiled. Broadband calculation: make a plot with emission intensity as function of incoming photon energy and a fixed number of incoming photons. Multiply this afterwards with the source spectrum For microcalorimeter: set the fudge factor 1, the reflectivity 1, one crystal and the diameter corresponding to the effective area of the detector. After the emission is calculated multiply with the spectral sensitivity of the detector, et voila I moved the whole project to github now to enable active contributions from other people, please find the latest version here: https://github.com/erdzeichen/calculate_measured_XES_intensity