Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4PSDoseDepositForCylinder3D Class Reference

#include <G4PSDoseDepositForCylinder3D.hh>

+ Inheritance diagram for G4PSDoseDepositForCylinder3D:

Public Member Functions

 G4PSDoseDepositForCylinder3D (G4String name, G4int ni=1, G4int nj=1, G4int nk=1, G4int depi=2, G4int depj=1, G4int depk=0)
 
 G4PSDoseDepositForCylinder3D (G4String name, const G4String &unit, G4int ni=1, G4int nj=1, G4int nk=1, G4int depi=2, G4int depj=1, G4int depk=0)
 
 ~G4PSDoseDepositForCylinder3D () override=default
 
void SetCylinderSize (G4ThreeVector cylSize, G4double startAng, G4double angSpan)
 
void SetNumberOfSegments (G4int nSeg[3])
 
- Public Member Functions inherited from G4PSDoseDeposit3D
 G4PSDoseDeposit3D (G4String name, G4int ni=1, G4int nj=1, G4int nk=1, G4int depi=2, G4int depj=1, G4int depk=0)
 
 G4PSDoseDeposit3D (G4String name, const G4String &unit, G4int ni=1, G4int nj=1, G4int nk=1, G4int depi=2, G4int depj=1, G4int depk=0)
 
 ~G4PSDoseDeposit3D () override=default
 
- Public Member Functions inherited from G4PSDoseDeposit
 G4PSDoseDeposit (G4String name, G4int depth=0)
 
 G4PSDoseDeposit (G4String name, const G4String &unit, G4int depth=0)
 
 ~G4PSDoseDeposit () override=default
 
void Initialize (G4HCofThisEvent *) override
 
void clear () override
 
void PrintAll () override
 
virtual void SetUnit (const G4String &unit)
 
- Public Member Functions inherited from G4VPrimitivePlotter
 ~G4VPrimitivePlotter () override=default
 
void Plot (G4int copyNo, G4int histID)
 
G4int GetNumberOfHist () const
 
 G4VPrimitiveScorer (G4String name, G4int depth=0)
 
- Public Member Functions inherited from G4VPrimitiveScorer
 G4VPrimitiveScorer (G4String name, G4int depth=0)
 
virtual ~G4VPrimitiveScorer ()=default
 
G4int GetCollectionID (G4int)
 
virtual void EndOfEvent (G4HCofThisEvent *)
 
virtual void DrawAll ()
 
void SetUnit (const G4String &unit)
 
const G4StringGetUnit () const
 
G4double GetUnitValue () const
 
void SetMultiFunctionalDetector (G4MultiFunctionalDetector *d)
 
G4MultiFunctionalDetectorGetMultiFunctionalDetector () const
 
G4String GetName () const
 
void SetFilter (G4VSDFilter *f)
 
G4VSDFilterGetFilter () const
 
void SetVerboseLevel (G4int vl)
 
G4int GetVerboseLevel () const
 
void SetNijk (G4int i, G4int j, G4int k)
 

Protected Member Functions

G4double ComputeVolume (G4Step *, G4int idx) override
 
- Protected Member Functions inherited from G4PSDoseDeposit3D
G4int GetIndex (G4Step *) override
 
- Protected Member Functions inherited from G4PSDoseDeposit
G4bool ProcessHits (G4Step *, G4TouchableHistory *) override
 
- Protected Member Functions inherited from G4VPrimitiveScorer
G4VSolidComputeSolid (G4Step *aStep, G4int replicaIdx)
 
G4VSolidComputeCurrentSolid (G4Step *aStep)
 
void CheckAndSetUnit (const G4String &unit, const G4String &category)
 

Additional Inherited Members

- Protected Attributes inherited from G4VPrimitivePlotter
std::map< G4int, G4inthitIDMap
 
- Protected Attributes inherited from G4VPrimitiveScorer
G4String primitiveName
 
G4MultiFunctionalDetectordetector {nullptr}
 
G4VSDFilterfilter {nullptr}
 
G4int verboseLevel {0}
 
G4int indexDepth
 
G4String unitName {"NoUnit"}
 
G4double unitValue {1.0}
 
G4int fNi {0}
 
G4int fNj {0}
 
G4int fNk {0}
 

Detailed Description

Definition at line 44 of file G4PSDoseDepositForCylinder3D.hh.

Constructor & Destructor Documentation

◆ G4PSDoseDepositForCylinder3D() [1/2]

G4PSDoseDepositForCylinder3D::G4PSDoseDepositForCylinder3D ( G4String name,
G4int ni = 1,
G4int nj = 1,
G4int nk = 1,
G4int depi = 2,
G4int depj = 1,
G4int depk = 0 )

Definition at line 43 of file G4PSDoseDepositForCylinder3D.cc.

47 : G4PSDoseDeposit3D(name, ni, nj, nk, di, dj, dk)
48{
49 nSegment[0] = nSegment[1] = nSegment[2] = 0;
50}
G4PSDoseDeposit3D(G4String name, G4int ni=1, G4int nj=1, G4int nk=1, G4int depi=2, G4int depj=1, G4int depk=0)

◆ G4PSDoseDepositForCylinder3D() [2/2]

G4PSDoseDepositForCylinder3D::G4PSDoseDepositForCylinder3D ( G4String name,
const G4String & unit,
G4int ni = 1,
G4int nj = 1,
G4int nk = 1,
G4int depi = 2,
G4int depj = 1,
G4int depk = 0 )

Definition at line 52 of file G4PSDoseDepositForCylinder3D.cc.

57 : G4PSDoseDeposit3D(name, unit, ni, nj, nk, di, dj, dk)
58{
59 nSegment[0] = nSegment[1] = nSegment[2] = 0;
60}

◆ ~G4PSDoseDepositForCylinder3D()

G4PSDoseDepositForCylinder3D::~G4PSDoseDepositForCylinder3D ( )
overridedefault

Member Function Documentation

◆ ComputeVolume()

G4double G4PSDoseDepositForCylinder3D::ComputeVolume ( G4Step * ,
G4int idx )
overrideprotectedvirtual

Reimplemented from G4PSDoseDeposit.

Definition at line 74 of file G4PSDoseDepositForCylinder3D.cc.

75{
76 G4double dr = (cylinderSize[1] - cylinderSize[0]) / nSegment[2];
77 G4double r0 = cylinderSize[0] + dr * (idx);
78 G4double r1 = cylinderSize[0] + dr * (idx + 1);
79 G4double dRArea = (r1 * r1 - r0 * r0) * pi;
80
81 // cylinderSize is given in Half Size
82 G4double fullz = cylinderSize[2] / nSegment[0] * 2.;
83 G4double phiRatio = (fAngle[1] / (CLHEP::twopi*rad)) / nSegment[1];
84 G4double v = dRArea * fullz * phiRatio;
85
86 if(verboseLevel > 9)
87 {
88 G4cout << " r0= " << r0 / cm << " r1= " << r1 / cm
89 << " fullz=" << fullz / cm << G4endl;
90 G4cout << " idx= " << idx << " v(cm3)= " << v / cm3 << G4endl;
91 }
92
93 return v;
94}
double G4double
Definition G4Types.hh:83
#define G4endl
Definition G4ios.hh:67
G4GLOB_DLL std::ostream G4cout

◆ SetCylinderSize()

void G4PSDoseDepositForCylinder3D::SetCylinderSize ( G4ThreeVector cylSize,
G4double startAng,
G4double angSpan )

Definition at line 62 of file G4PSDoseDepositForCylinder3D.cc.

63{
64 cylinderSize = cylSize; // rMin, rMax, halfZ
65 fAngle[0] = StartAng;
66 fAngle[1] = AngSpan;
67}

◆ SetNumberOfSegments()

void G4PSDoseDepositForCylinder3D::SetNumberOfSegments ( G4int nSeg[3])

Definition at line 68 of file G4PSDoseDepositForCylinder3D.cc.

69{
70 nSegment[0] = nSeg[0]; // Z
71 nSegment[1] = nSeg[1]; // Phi
72 nSegment[2] = nSeg[2]; // R
73}

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