Modifier and Type | Field and Description |
---|---|
private double |
_Aeff |
private List<Integer> |
_atoms |
(package private) double |
_density |
private List<MaterialElement> |
_elements |
(package private) String |
_formula |
(package private) boolean |
_isElement |
private List<Double> |
_massFractions |
(package private) String |
_name |
(package private) int |
_nComponents |
(package private) int |
_nComponentsMax |
(package private) int |
_nElements |
(package private) double |
_nuclearInteractionLength |
(package private) double |
_nuclearInteractionLengthWithDensity |
(package private) double |
_radiationLength |
(package private) double |
_radiationLengthWithDensity |
(package private) MaterialState |
_state |
private double |
_Zeff |
static double |
DEFAULT_PRESSURE |
static double |
DEFAULT_TEMPERATURE |
private static double |
MAX_LAMBDA |
private static double |
MAX_X0 |
Constructor and Description |
---|
Material(String name,
int nComponents,
double density,
MaterialState state)
Construct a material with a number of sub-components, which will be
either a set of mass fractions or set of number of atoms.
|
Material(String matName,
String formula,
double z,
double a,
double density,
double X0,
double lambda,
MaterialState state)
This is a constructor for materials that are chemical elements.
|
Modifier and Type | Method and Description |
---|---|
protected void |
addElement(MaterialElement element,
double fraction)
Add chemical element to the material by fraction of mass.
|
protected void |
addElement(MaterialElement element,
int nAtoms)
Add an element to the material by atom count.
|
void |
addMaterial(Material material,
double fraction)
Add a component material by fraction of mass.
|
private void |
checkMassSum()
Check that the massFractions list adds up to 1.0.
|
private double |
computeAeff()
Compute the effective A for this material using its element list.
|
private void |
computeDerivedQuantities()
Computes and caches derived computed quantities after all components have been added to the material.
|
private void |
computeNuclearInteractionLength()
Compute the nuclear interaction length (lambda).
|
private void |
computeRadiationLength()
Compute the radiation length (x0) based on mass fractions of elements.
|
private double |
computeZeff()
Compute the effective Z for this material using its element list.
|
double |
getA()
Get the A of this Material, which is a computed, effective A.
|
double |
getAeff() |
double |
getDensity()
Get the density (g/cm^3).
|
List<MaterialElement> |
getElements()
Get the list of component MaterialElements referenced by this material.
|
List<Double> |
getMassFractions() |
String |
getName()
Get the name of the Material.
|
protected int |
getNComponents() |
protected int |
getNComponentsMax() |
protected int |
getNElements() |
double |
getNuclearInteractionLength()
Get the nuclear interaction length in g/cm2.
|
double |
getNuclearInteractionLengthWithDensity()
Get the nuclear interaction length in g/cm2.
|
protected int |
getNumberOfElements() |
double |
getPressure()
Get the pressure of the material in atmospheres.
|
double |
getRadiationLength()
Get the radiation length in g/cm2.
|
double |
getRadiationLengthWithDensity()
Get the radiation length in cm.
|
MaterialState |
getState()
Get the state of this material, either liquid, gas, solid, or unknown.
|
double |
getTemperature()
Get the temperature of the material in Kelvin.
|
double |
getZ()
Get the Z of this Material, which is a computed, effective Z.
|
double |
getZeff() |
boolean |
isElement() |
protected boolean |
isFilled()
True if all components have been added; false if not.
|
String |
toString()
Translate this material to a human-readable string.
|
public static final double DEFAULT_TEMPERATURE
public static final double DEFAULT_PRESSURE
private static final double MAX_X0
private static final double MAX_LAMBDA
double _density
boolean _isElement
private double _Zeff
private double _Aeff
MaterialState _state
String _name
String _formula
int _nComponents
int _nComponentsMax
int _nElements
private List<MaterialElement> _elements
double _radiationLength
double _radiationLengthWithDensity
double _nuclearInteractionLength
double _nuclearInteractionLengthWithDensity
Material(String matName, String formula, double z, double a, double density, double X0, double lambda, MaterialState state)
matName
- The full name of the material (e.g. "Tungsten").formula
- The formula of the element (e.g. "W" for Tungsten).z
- The atomic number.a
- The atomic weight.density
- The density in g/cm3.X0
- The radiation length in g/cm-2.lambda
- The nuclear interaction length in g/cm-2.state
- The state of the element (liquid, gas, solid, or unknown).public Material(String name, int nComponents, double density, MaterialState state)
public String getName()
public double getDensity()
getDensity
in interface IMaterial
public boolean isElement()
public double getZeff()
public double getAeff()
protected int getNComponentsMax()
protected int getNComponents()
protected int getNElements()
public MaterialState getState()
IMaterial
public double getRadiationLength()
IMaterial
getRadiationLength
in interface IMaterial
public double getNuclearInteractionLength()
IMaterial
getNuclearInteractionLength
in interface IMaterial
public double getNuclearInteractionLengthWithDensity()
IMaterial
getNuclearInteractionLengthWithDensity
in interface IMaterial
public double getRadiationLengthWithDensity()
IMaterial
getRadiationLengthWithDensity
in interface IMaterial
protected int getNumberOfElements()
public List<MaterialElement> getElements()
public List<Double> getMassFractions()
protected void addElement(MaterialElement element, int nAtoms)
protected void addElement(MaterialElement element, double fraction)
public void addMaterial(Material material, double fraction)
The
- material to add.The
- fraction of total which must be > 0 and <= 1.public double getPressure()
IMaterial
getPressure
in interface IMaterial
public double getTemperature()
IMaterial
getTemperature
in interface IMaterial
public String toString()
protected boolean isFilled()
private void checkMassSum()
private double computeZeff()
private double computeAeff()
private void computeNuclearInteractionLength()
private void computeRadiationLength()
private void computeDerivedQuantities()
public double getA()
Copyright © 2016 Linear Collider Detector (LCD). All rights reserved.