Class PressureCalculation

java.lang.Object
gda.exafs.mucal.PressureCalculation

public class PressureCalculation extends Object
A class which calculates pressure in the ion chamber. The default behaviour is to use XRayLib to provide the absorption coefficients used in the calculation; in order to use this class with Mucal, set useMucal = true and make sure you have bin/mucal.bin in your configuration path.
  • Method Details

    • getAbsorptionCoeffMucal

      public static double getAbsorptionCoeffMucal(int atomicNumber, double workingEnergyKev) throws Exception
      Run mucal code and return absorption coefficient for element of given atomic number at specified photon energy Refactored from PressureCalculation.getPressure(...) function.
      Parameters:
      atomicNumber -
      workingEnergyKev - [keV]
      Returns:
      Absorption coefficient [cm2/g]
      Throws:
      Exception
      Since:
      23/6/2016
    • getPressure

      public static PressureBean getPressure(IonChamberParameters bean) throws Exception
      Run mucal code and return gas pressure for given set of IonChamberParameters
      Parameters:
      bean -
      Returns:
      the pressure calculated, null if the software mucal is not available.
      Throws:
      Exception
    • getAbsorptionCoeffXrayLib

      public static double getAbsorptionCoeffXrayLib(int atomicNumber, double energyKev)
      Return value of absorption coefficient using functions XrayLib.
      Parameters:
      atomicNumber -
      energyKev -
      Returns:
      absorption coefficient (cm2/g)
    • isUseMucal

      public static boolean isUseMucal()
    • setUseMucal

      public static void setUseMucal(boolean useMucal)
    • getAbsorptionCoeff

      public static double getAbsorptionCoeff(int atomicNumber, double workingEnergyKev) throws Exception
      Throws:
      Exception