Garfield++ v2r0
A toolkit for the detailed simulation of particle detectors based on ionisation measurement in gases and semiconductors
Loading...
Searching...
No Matches
Heed::EnTransfCS_BGM Class Reference

Energy transfer cross-section. More...

#include <EnTransfCS_BGM.h>

+ Inheritance diagram for Heed::EnTransfCS_BGM:

Public Member Functions

 EnTransfCS_BGM (void)
 Default constructor.
 
 EnTransfCS_BGM (double fparticle_mass, PassivePtr< BGMesh > fmesh, int fs_primary_electron, HeedMatterDef *fhmd, long fparticle_charge=1)
 Constructor.
 
virtual EnTransfCS_BGMcopy () const
 
virtual void print (std::ostream &file, int l) const
 
- Public Member Functions inherited from Heed::RegPassivePtr
 RegPassivePtr (void)
 
 RegPassivePtr (char fs_ban_del, char fs_ban_sub, char fs_ban_cop=0)
 
 RegPassivePtr (const RegPassivePtr &f)
 
RegPassivePtroperator= (const RegPassivePtr &f)
 
CountPP_ns::CountPassivePtrbook (void) const
 
void clear_pointers (void) const
 
virtual RegPassivePtrcopy () const
 
virtual ~RegPassivePtr ()
 
virtual void print (std::ostream &file, int l=1) const
 
void set_s_ban_del (char fs_ban_del)
 
char get_s_ban_del (void) const
 
void set_s_ban_sub (char fs_ban_sub)
 
char get_s_ban_sub (void) const
 
void set_s_ban_cop (char fs_ban_cop)
 
char get_s_ban_cop (void) const
 
void set_s_allow_del_at_zero_count (char fs_allow_del_at_zero_count)
 
char get_s_allow_del_at_zero_count (void) const
 
long get_total_number_of_references (void) const
 

Public Attributes

double particle_mass
 
long particle_charge
 
int s_primary_electron
 Sign that the primary particle is an electron.
 
PassivePtr< HeedMatterDefhmd
 
PassivePtr< BGMeshmesh
 
std::vector< EnTransfCSetcs_bgm
 

Additional Inherited Members

- Static Public Member Functions inherited from Heed::RegPassivePtr
static void set_s_ban_del_ignore (char fs_ban_del_ignore)
 
static char get_s_ban_del_ignore (void)
 
static void set_s_print_adr_cpp (char fs_print_adr_cpp)
 
static char get_s_print_adr_cpp (void)
 

Detailed Description

Energy transfer cross-section.

Definition at line 10 of file EnTransfCS_BGM.h.

Constructor & Destructor Documentation

◆ EnTransfCS_BGM() [1/2]

Heed::EnTransfCS_BGM::EnTransfCS_BGM ( void  )

Default constructor.

Referenced by copy().

◆ EnTransfCS_BGM() [2/2]

Heed::EnTransfCS_BGM::EnTransfCS_BGM ( double  fparticle_mass,
PassivePtr< BGMesh fmesh,
int  fs_primary_electron,
HeedMatterDef fhmd,
long  fparticle_charge = 1 
)

Constructor.

Definition at line 7 of file EnTransfCS_BGM.cpp.

10 : particle_mass(fparticle_mass),
11 particle_charge(fparticle_charge),
12 s_primary_electron(fs_primary_electron),
13 hmd(fhmd),
14 mesh(fmesh) {
15 mfunnamep("EnTransfCS_BGM::EnTransfCS_BGM(...)");
16
17 const long q = mesh->q;
18 etcs_bgm.resize(q);
19 for (long n = 0; n < q; n++) {
20 double bg = mesh->x[n];
21 // gamma - 1
22 double gamma_1 = sqrt(1.0 + (bg * bg)) - 1.0;
23 etcs_bgm[n] = EnTransfCS(fparticle_mass, gamma_1, fs_primary_electron, fhmd,
24 fparticle_charge);
25 }
26}
#define mfunnamep(string)
Definition: FunNameStack.h:49
std::vector< EnTransfCS > etcs_bgm
PassivePtr< HeedMatterDef > hmd
int s_primary_electron
Sign that the primary particle is an electron.
PassivePtr< BGMesh > mesh
DoubleAc sqrt(const DoubleAc &f)
Definition: DoubleAc.cpp:314

Member Function Documentation

◆ copy()

virtual EnTransfCS_BGM * Heed::EnTransfCS_BGM::copy ( ) const
inlinevirtual

Reimplemented from Heed::RegPassivePtr.

Definition at line 32 of file EnTransfCS_BGM.h.

32{ return new EnTransfCS_BGM(*this); }
EnTransfCS_BGM(void)
Default constructor.

◆ print()

void Heed::EnTransfCS_BGM::print ( std::ostream &  file,
int  l 
) const
virtual

Reimplemented from Heed::RegPassivePtr.

Definition at line 28 of file EnTransfCS_BGM.cpp.

28 {
29 if (l <= 0) return;
30 Ifile << "EnTransfCS_BGM(l=" << l << "):\n";
31 indn.n += 2;
32 Ifile << "particle_mass=" << particle_mass
33 << " particle_charge=" << particle_charge << std::endl;
34 Ifile << "s_primary_electron=" << s_primary_electron << std::endl;
35 Ifile << "hmd:\n";
36 hmd->print(file, 1);
37 Ifile << "mesh:\n";
38 mesh->print(file, 1);
39
40 Ifile << "Array of Cross Section:\n";
41 Ifile << "Number of elements = " << etcs_bgm.size() << '\n';
42
43 if (l >= 2) {
44 const long q = mesh->q;
45 for (long n = 0; n < q; n++) {
46 Ifile << "n=" << std::setw(5) << n << " bg=" << std::setw(14)
47 << mesh->x[n] << " quan=" << std::setw(14) << etcs_bgm[n].quanC;
48#ifndef EXCLUDE_MEAN
49 file << " mean=" << std::setw(14) << etcs_bgm[n].meanC;
50#endif
51 file << '\n';
52 }
53 }
54 indn.n -= 2;
55}
indentation indn
Definition: prstream.cpp:15
#define Ifile
Definition: prstream.h:196

Member Data Documentation

◆ etcs_bgm

std::vector<EnTransfCS> Heed::EnTransfCS_BGM::etcs_bgm

Definition at line 23 of file EnTransfCS_BGM.h.

Referenced by EnTransfCS_BGM(), Heed::HeedParticle_BGM::physics(), and print().

◆ hmd

PassivePtr<HeedMatterDef> Heed::EnTransfCS_BGM::hmd

Definition at line 21 of file EnTransfCS_BGM.h.

Referenced by Heed::HeedParticle_BGM::physics(), and print().

◆ mesh

PassivePtr<BGMesh> Heed::EnTransfCS_BGM::mesh

Definition at line 22 of file EnTransfCS_BGM.h.

Referenced by EnTransfCS_BGM(), Heed::HeedParticle_BGM::physics(), and print().

◆ particle_charge

long Heed::EnTransfCS_BGM::particle_charge

Particle charge in units of electron charges. It is squared, therefore the sign does not matter.

Definition at line 17 of file EnTransfCS_BGM.h.

Referenced by print().

◆ particle_mass

double Heed::EnTransfCS_BGM::particle_mass

Definition at line 14 of file EnTransfCS_BGM.h.

Referenced by print().

◆ s_primary_electron

int Heed::EnTransfCS_BGM::s_primary_electron

Sign that the primary particle is an electron.

Definition at line 19 of file EnTransfCS_BGM.h.

Referenced by print().


The documentation for this class was generated from the following files: