Package API

This page lists main classes in this package.

beam

shadow4.beam The S4 beam

shadow4.beam.s4_beam

Defines the shadow4 beam and associated methods and utilities.

sources

shadow4.sources The S4 sources

beamline optical elements

shadow4.beamline.optical_elements The S4 optical elements

beamline

shadow4.beamline The S4 beamline

shadow4.beamline.s4_beamline

Defines the S4 beamline.

shadow4.beamline.s4_beamline_element

Defines the S4 beamline element.

shadow4.beamline.s4_beamline_element_movements

Container for the variables describing the movements of a S4 beamline element.

shadow4.beamline.s4_optical_element_decorators

Defines the functionality for shadow4 optical elements.

sources (base classes)

shadow4.sources The S4 source base classes

shadow4.sources.s4_light_source_base

Defines the a Base LightSource to support non-synchrotron sources.

shadow4.sources.s4_light_source

Defines the shadow4 synchrotron LightSource (the base class of beanding magnet, wiggler and undulator lightsources).

shadow4.sources.s4_electron_beam

Defines the shadow4 electron beam.

shadow4.sources.s4_light_source_from_file

Defines the a LightSource with a beam defined in a HDF5 file.

shadow4.sources.s4_light_source_from_beamlines

Defines the a LightSource merging several beamlines.

optical surfaces

shadow4.optical_surfaces The S4 optical surface implementations

shadow4.optical_surfaces.s4_optical_surface

Abstract class defining the interfaces of the optical surfaces to be implemented in the subclasses.

shadow4.optical_surfaces.s4_conic

Defines the shadow4 Conic class to deal with conic surfaces (plane, sphere, ellipsoid, paraboloid and hyperboloid).

shadow4.optical_surfaces.s4_toroid

Defines the shadow4 Toroid class to deal with a toroidal surface (Quartic equation).

shadow4.optical_surfaces.s4_mesh

Defines the shadow4 Mesh class to deal with a numerical surfaces (defined by an array of points).

physical models

shadow4.physical_models Physical model calculators

shadow4.physical_models.bragg.bragg

Crystal structure factor preprocessor for Bragg diffraction calculations.

shadow4.physical_models.mlayer.mlayer

python version of the multilayer code in shadow.

shadow4.physical_models.prerefl.prerefl

python version of the mirror reflectivity code and refractive index calculations in shadow.

tools

shadow4.tools Utility modules

shadow4.tools.arrayofvectors

Operations on arrays of 3D vectors with shape (n_vectors, 3).

shadow4.tools.beamline_tools

Tools (functions) to operate with the beamline (instance of S4Beamline).

shadow4.tools.graphics

Matplotlib-based plotting tools for shadow4 beam data.

shadow4.tools.logger

Logging verbosity helpers for shadow4.