pyPENELOPE

util – Utilities for PENEPMA results

penelopetools.api.result.penepma.util.real_intensity(intensity, energy_channel_width, solid_angle=1.0, beam_current=1.0, live_time=1.0, detector_efficiency=1.0)

Returns the real intensity and its error at a given energy.

Parameters:
  • energy – energy of interest (in eV).
  • solid_angle – solid angle of the x-ray detector (in steradians)
  • beam_current – beam current of the microscope (in nA)
  • live_time – live time of the x-ray acquisition (in seconds)
  • detector_efficiency – efficiency of the detector
Return type:

Magnitude

penelopetools.api.result.penepma.util.subshell_total_intensity(atomicnumber, subshell, spectrum, transitiondata)

Returns the intensity of all the X-ray lines in a subshell. The subshells are either

  • K (SUBSHELL_K)
  • LIII (SUBSHELL_LIII)
  • MV (SUBSHELL_MV)
penelopetools.api.result.penepma.util.to_emsa(spectrum, options, detector_id)

Converts a spectrum to the standard MSA/EMAS file format. To complete the optional fields on the file, the options and the photondetector used in the simulation of this spectrum can be provided. They are however optional.

Parameters:
  • spectrum (PhotonSpectrum) – any photon spectrum
  • options (_Options) – options of the simulation that generated this spectrum
  • photondetector (PhotonDetector) – photon detector parameters of this spectrum
Return type:

Emsa