GGEMS  1.1
GPU GEant4-based Monte Carlo Simulations
GGEMSEMProcess.hh
Go to the documentation of this file.
1 #ifndef GUARD_GGEMS_PHYSICS_GGEMSEMPROCESS_HH
2 #define GUARD_GGEMS_PHYSICS_GGEMSEMPROCESS_HH
3 
4 // ************************************************************************
5 // * This file is part of GGEMS. *
6 // * *
7 // * GGEMS is free software: you can redistribute it and/or modify *
8 // * it under the terms of the GNU General Public License as published by *
9 // * the Free Software Foundation, either version 3 of the License, or *
10 // * (at your option) any later version. *
11 // * *
12 // * GGEMS is distributed in the hope that it will be useful, *
13 // * but WITHOUT ANY WARRANTY; without even the implied warranty of *
14 // * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
15 // * GNU General Public License for more details. *
16 // * *
17 // * You should have received a copy of the GNU General Public License *
18 // * along with GGEMS. If not, see <https://www.gnu.org/licenses/>. *
19 // * *
20 // ************************************************************************
21 
34 #ifdef _MSC_VER
35 #pragma warning(disable: 4251) // Deleting warning exporting STL members!!!
36 #endif
37 
41 
46 class GGEMS_EXPORT GGEMSEMProcess
47 {
48  public:
52  GGEMSEMProcess(void);
53 
57  virtual ~GGEMSEMProcess(void);
58 
64  GGEMSEMProcess(GGEMSEMProcess const& em_process) = delete;
65 
71  GGEMSEMProcess& operator=(GGEMSEMProcess const& em_process) = delete;
72 
78  GGEMSEMProcess(GGEMSEMProcess const&& em_process) = delete;
79 
85  GGEMSEMProcess& operator=(GGEMSEMProcess const&& em_process) = delete;
86 
92  inline std::string GetProcessName(void) const {return process_name_;}
93 
101  virtual void BuildCrossSectionTables(cl::Buffer* particle_cross_sections, cl::Buffer* material_tables, GGsize const& thread_index);
102 
103  protected:
113  GGfloat ComputeCrossSectionPerMaterial(GGEMSParticleCrossSections* cross_section, GGEMSMaterialTables const* material_tables, GGsize const& material_index, GGsize const& energy_index);
114 
122  virtual GGfloat ComputeCrossSectionPerAtom(GGfloat const& energy, GGuchar const& atomic_number) const = 0;
123 
124  protected:
126  std::string process_name_;
127  std::string primary_particle_;
128  std::string secondary_particle_;
130 };
131 
132 #endif // End of GUARD_GGEMS_PHYSICS_GGEMSEMPROCESS_HH
GGEMSEMProcess::primary_particle_
std::string primary_particle_
Definition: GGEMSEMProcess.hh:127
GGEMSEMProcess::operator=
GGEMSEMProcess & operator=(GGEMSEMProcess const &&em_process)=delete
Avoid copy by rvalue reference.
GGEMSParticleCrossSections_t
Structure storing the photon cross sections for OpenCL device.
Definition: GGEMSParticleCrossSections.hh:41
GGEMSEMProcess::secondary_particle_
std::string secondary_particle_
Definition: GGEMSEMProcess.hh:128
GGEMSEMProcess::process_name_
std::string process_name_
Definition: GGEMSEMProcess.hh:126
GGchar
#define GGchar
Definition: GGEMSTypes.hh:196
GGEMSEMProcess::GetProcessName
std::string GetProcessName(void) const
get the name of the process
Definition: GGEMSEMProcess.hh:92
GGsize
#define GGsize
Definition: GGEMSTypes.hh:252
GGEMSEMProcess
GGEMS mother class for electromagnectic process.
Definition: GGEMSEMProcess.hh:47
GGEMSParticleCrossSections.hh
Structure storing the particle (photon, electron, positron) cross sections for OpenCL device.
GGEMSMaterialTables.hh
Structure storing the material tables on OpenCL device.
GGEMSEMProcess::is_secondaries_
bool is_secondaries_
Definition: GGEMSEMProcess.hh:129
GGEMSEMProcess::operator=
GGEMSEMProcess & operator=(GGEMSEMProcess const &em_process)=delete
Avoid assignement by reference.
GGEMSMaterialTables_t
Structure storing the material tables on OpenCL device.
Definition: GGEMSMaterialTables.hh:42
GGEMSEMProcess::GGEMSEMProcess
GGEMSEMProcess(GGEMSEMProcess const &em_process)=delete
Avoid copy by reference.
GGEMSEMProcess::ComputeCrossSectionPerAtom
virtual GGfloat ComputeCrossSectionPerAtom(GGfloat const &energy, GGuchar const &atomic_number) const =0
compute a cross section for an atom
GGEMSOpenCLManager.hh
Singleton class storing all informations about OpenCL and managing GPU/CPU devices,...
GGEMSEMProcess::process_id_
GGchar process_id_
Definition: GGEMSEMProcess.hh:125
GGEMSEMProcess::GGEMSEMProcess
GGEMSEMProcess(GGEMSEMProcess const &&em_process)=delete
Avoid copy by rvalue reference.
GGuchar
#define GGuchar
Definition: GGEMSTypes.hh:203
GGfloat
#define GGfloat
Definition: GGEMSTypes.hh:273