#include <DetDesc/Mixture.h>
Inheritance diagram for Mixture:
Public Types | |
typedef std::pair< double, SmartRef< Element > > | Entry |
typedef std::vector< Entry > | Elements |
typedef std::vector< int > | Atoms |
typedef SmartRefVector< TabulatedProperty > | Tables |
Public Member Functions | |
Mixture (const std::string &name="", const double a=0, const double z=0, const double i=0, const double density=0, const double rl=0, const double al=0, const double temp=Gaudi::Units::STP_Temperature, const double press=Gaudi::Units::STP_Pressure, const eState s=stateUndefined) | |
Constructors for simple materials. | |
virtual | ~Mixture () |
Destructor. | |
int | nOfItems () const |
Number of components in the material mixture. | |
void | addElement (const SmartRef< Element > &e, const int nOfAtoms, const bool comp=false) |
Add an element into the mixture by specifying: a) the fraction of the mass ( material mixture ) b) the number of the atoms ( material compund ). | |
void | addElement (const SmartRef< Element > &e, const double fraction, const bool comp=false) |
void | addMixture (const SmartRef< Mixture > &mx, const double fraction, const bool comp=false) |
Add another mixture into this mixture by specifying its fraction of the mass. | |
const SmartRef< Element > & | element (const unsigned int i) const |
Return i-th element's pointer. | |
SmartRef< Element > & | element (const unsigned int i) |
const Elements & | elements () const |
return all elements | |
Elements & | elements () |
StatusCode | compute () |
compute all quantities | |
double | elementFraction (const unsigned int i) const |
Return fraction of mass of the i-th element. | |
virtual double | A () const |
Atomic mass [g/mole]. | |
virtual void | setA (const double value) |
virtual double | Z () const |
Atomic number. | |
virtual void | setZ (const double value) |
virtual double | I () const |
Mean excitation energy. | |
virtual void | setI (const double value) |
virtual double | C () const |
Parameters for Density Effect Correction. | |
virtual void | setC (const double value) |
virtual double | a () const |
virtual void | seta (const double value) |
virtual double | m () const |
virtual void | setm (const double value) |
virtual double | X0 () const |
virtual void | setX0 (const double value) |
virtual double | X1 () const |
virtual void | setX1 (const double value) |
virtual double | N () const |
Number of nucleons. | |
virtual const CLID & | clID () const |
virtual std::ostream & | fillStream (std::ostream &s) const |
Fill the output stream (ASCII). | |
virtual MsgStream & | fillStream (MsgStream &s) const |
Fill the output stream (ASCII). | |
bool | operator== (const Material *right) const |
Equality operators, NOTE! These operator work with pointers. | |
bool | operator!= (const Material *right) const |
virtual const std::string & | name () const |
Material name accessors. | |
virtual void | setName (const std::string &value) |
virtual double | density () const |
Material density accessors [g/cm3]. | |
virtual void | setDensity (const double value) |
virtual double | temperature () const |
Material temperature, by default is STP [K]. | |
virtual void | setTemperature (const double value) |
virtual double | pressure () const |
Material pressure, by default is STP [atm]. | |
virtual void | setPressure (const double value) |
virtual eState | state () const |
Material state, by default is stateUndefined. | |
virtual void | setState (const eState value) |
virtual double | radiationLength () const |
Material radiation length [cm]. | |
virtual void | setRadiationLength (const double value) |
virtual double | absorptionLength () const |
Material absorption length [cm]. | |
virtual void | setAbsorptionLength (const double value) |
Tables & | tabulatedProperties () |
some tabulated properties | |
const Tables & | tabulatedProperties () const |
void | setRegistry (IRegistry *pRegistry) |
IRegistry * | registry () const |
LinkManager * | linkMgr () const |
unsigned char | version () const |
void | setVersion (unsigned char vsn) |
unsigned long | refCount () const |
virtual unsigned long | addRef () |
virtual unsigned long | release () |
virtual StreamBuffer & | serialize (StreamBuffer &s) |
virtual StreamBuffer & | serialize (StreamBuffer &s) const |
Static Public Member Functions | |
static const CLID & | classID () |
Protected Member Functions | |
StatusCode | addMyself () |
StatusCode | computeByAtoms () |
Compute effective A,Z,I and fractions for compounds. | |
StatusCode | computeByFraction () |
Compute effective A,Z,I and number of atoms per volume for each element. | |
Private Attributes | |
Elements | m_elements |
Vector of elements. | |
Atoms | m_atoms |
Corresponding number of atoms for each element. | |
Element * | m_own |
own element (if needed) | |
double | m_A |
double | m_Z |
double | m_I |
double | m_a |
double | m_m |
double | m_C |
double | m_X0 |
double | m_X1 |
Friends | |
friend std::ostream & | operator<< (std::ostream &s, const DataObject &obj) |
Mixture of elements can be compoased either by fraction of the mass or by number of atoms of the each component. Mixture of mixtures and elements is composed only by fraction of the mass.
Definition at line 25 of file Mixture.h.
typedef std::pair<double,SmartRef<Element> > Mixture::Entry |
typedef std::vector<Entry> Mixture::Elements |
typedef std::vector<int> Mixture::Atoms |
typedef SmartRefVector<TabulatedProperty> Material::Tables [inherited] |
Definition at line 37 of file Material.h.
Mixture::Mixture | ( | const std::string & | name = "" , |
|
const double | a = 0 , |
|||
const double | z = 0 , |
|||
const double | i = 0 , |
|||
const double | density = 0 , |
|||
const double | rl = 0 , |
|||
const double | al = 0 , |
|||
const double | temp = Gaudi::Units::STP_Temperature , |
|||
const double | press = Gaudi::Units::STP_Pressure , |
|||
const eState | s = stateUndefined | |||
) |
Constructors for simple materials.
virtual Mixture::~Mixture | ( | ) | [virtual] |
Destructor.
int Mixture::nOfItems | ( | ) | const [inline] |
Number of components in the material mixture.
void Mixture::addElement | ( | const SmartRef< Element > & | e, | |
const int | nOfAtoms, | |||
const bool | comp = false | |||
) |
Add an element into the mixture by specifying: a) the fraction of the mass ( material mixture ) b) the number of the atoms ( material compund ).
void Mixture::addElement | ( | const SmartRef< Element > & | e, | |
const double | fraction, | |||
const bool | comp = false | |||
) |
void Mixture::addMixture | ( | const SmartRef< Mixture > & | mx, | |
const double | fraction, | |||
const bool | comp = false | |||
) |
Add another mixture into this mixture by specifying its fraction of the mass.
Return i-th element's pointer.
const Elements& Mixture::elements | ( | ) | const [inline] |
return all elements
Elements& Mixture::elements | ( | ) | [inline] |
StatusCode Mixture::compute | ( | ) |
compute all quantities
double Mixture::elementFraction | ( | const unsigned int | i | ) | const |
Return fraction of mass of the i-th element.
virtual double Mixture::A | ( | ) | const [inline, virtual] |
virtual void Mixture::setA | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::Z | ( | ) | const [inline, virtual] |
virtual void Mixture::setZ | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::I | ( | ) | const [inline, virtual] |
virtual void Mixture::setI | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::C | ( | ) | const [inline, virtual] |
virtual void Mixture::setC | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::a | ( | ) | const [inline, virtual] |
Implements Material.
virtual void Mixture::seta | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::m | ( | ) | const [inline, virtual] |
Implements Material.
virtual void Mixture::setm | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::X0 | ( | ) | const [inline, virtual] |
Implements Material.
virtual void Mixture::setX0 | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::X1 | ( | ) | const [inline, virtual] |
Implements Material.
virtual void Mixture::setX1 | ( | const double | value | ) | [inline, virtual] |
Implements Material.
virtual double Mixture::N | ( | ) | const [inline, virtual] |
virtual const CLID& Mixture::clID | ( | ) | const [inline, virtual] |
Reimplemented from DataObject.
Definition at line 112 of file Mixture.h.
00112 { return Mixture::classID(); }
static const CLID& Mixture::classID | ( | ) | [inline, static] |
Reimplemented from DataObject.
Definition at line 113 of file Mixture.h.
00113 { return CLID_Mixture ; }
virtual std::ostream& Mixture::fillStream | ( | std::ostream & | s | ) | const [virtual] |
StatusCode Mixture::addMyself | ( | ) | [protected] |
StatusCode Mixture::computeByAtoms | ( | ) | [protected] |
Compute effective A,Z,I and fractions for compounds.
StatusCode Mixture::computeByFraction | ( | ) | [protected] |
Compute effective A,Z,I and number of atoms per volume for each element.
bool Material::operator== | ( | const Material * | right | ) | const [inherited] |
Equality operators, NOTE! These operator work with pointers.
bool Material::operator!= | ( | const Material * | right | ) | const [inherited] |
virtual const std::string& Material::name | ( | ) | const [virtual, inherited] |
virtual void Material::setName | ( | const std::string & | value | ) | [virtual, inherited] |
virtual double Material::density | ( | ) | const [virtual, inherited] |
Material density accessors [g/cm3].
virtual void Material::setDensity | ( | const double | value | ) | [virtual, inherited] |
virtual double Material::temperature | ( | ) | const [virtual, inherited] |
Material temperature, by default is STP [K].
virtual void Material::setTemperature | ( | const double | value | ) | [virtual, inherited] |
virtual double Material::pressure | ( | ) | const [virtual, inherited] |
Material pressure, by default is STP [atm].
virtual void Material::setPressure | ( | const double | value | ) | [virtual, inherited] |
virtual eState Material::state | ( | ) | const [virtual, inherited] |
Material state, by default is stateUndefined.
virtual void Material::setState | ( | const eState | value | ) | [virtual, inherited] |
virtual double Material::radiationLength | ( | ) | const [virtual, inherited] |
Material radiation length [cm].
virtual void Material::setRadiationLength | ( | const double | value | ) | [virtual, inherited] |
virtual double Material::absorptionLength | ( | ) | const [virtual, inherited] |
Material absorption length [cm].
virtual void Material::setAbsorptionLength | ( | const double | value | ) | [virtual, inherited] |
Tables& Material::tabulatedProperties | ( | ) | [inline, inherited] |
some tabulated properties
const Tables& Material::tabulatedProperties | ( | ) | const [inline, inherited] |
Elements Mixture::m_elements [private] |
Atoms Mixture::m_atoms [private] |
Element* Mixture::m_own [private] |
double Mixture::m_A [private] |
double Mixture::m_Z [private] |
double Mixture::m_I [private] |
double Mixture::m_a [private] |
double Mixture::m_m [private] |
double Mixture::m_C [private] |
double Mixture::m_X0 [private] |
double Mixture::m_X1 [private] |