Geant4  v4-10.4-release
 모두 클래스 네임스페이스들 파일들 함수 변수 타입정의 열거형 타입 열거형 멤버 Friends 매크로 그룹들 페이지들
examples/extended/parallel/MPI/examples/exMPI03/include/MedicalBeam.hh
이 파일의 문서화 페이지로 가기
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // $Id: MedicalBeam.hh 76431 2013-11-10 20:28:49Z kmura $
27 //
30 
31 #ifndef MEDICAL_BEAM_H
32 #define MEDICAL_BEAM_H
33 
34 #include "globals.hh"
35 #include "G4ThreeVector.hh"
37 
39 
41 public:
43 
44  MedicalBeam();
45  ~MedicalBeam();
46 
47  // set/get functions...
50 
51  void SetKineticE(G4double e);
52  G4double GetKineticE() const;
53 
54  void SetSourcePosition(const G4ThreeVector& pos);
56 
57  void SetFieldShape(FieldShape shape);
58  FieldShape GetFieldShape() const;
59 
60  void SetSSD(G4double ssd);
61  G4double GetSSD() const;
62 
63  void SetFieldXY(G4double fx, G4double fy);
64  G4double GetFieldX() const;
65  G4double GetFieldY() const;
66 
67  void SetFieldR(G4double r);
68  G4double GetFieldR() const;
69 
70  // methods...
71  virtual void GeneratePrimaries(G4Event* anEvent);
72 
73 private:
74  // local methods...
76 
80 
81  G4double fSSD; // (SSD= Source Skin Depth)
83  G4double ffieldXY[2];
85 
86 };
87 
88 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
90 {
91  fparticle = pd;
92 }
93 
95 {
96  return fparticle;
97 }
98 
100 {
101  fkineticE = e;
102 }
103 
104 inline G4double MedicalBeam::GetKineticE() const
105 {
106  return fkineticE;
107 }
108 
110 {
112 }
113 
115 {
116  return fsourcePosition;
117 }
118 
120 {
121  ffieldShape = shape;
122 }
123 
125 {
126  return ffieldShape;
127 }
128 
129 inline void MedicalBeam::SetSSD(G4double ssd)
130 {
131  fSSD = ssd;
132 }
133 
134 inline G4double MedicalBeam::GetSSD() const
135 {
136  return fSSD;
137 }
138 
139 inline void MedicalBeam::SetFieldXY(G4double fx, G4double fy)
140 {
141  ffieldXY[0] = fx;
142  ffieldXY[1] = fy;
143 }
144 
145 inline G4double MedicalBeam::GetFieldX() const
146 {
147  return ffieldXY[0];
148 }
149 
150 inline G4double MedicalBeam::GetFieldY() const
151 {
152  return ffieldXY[1];
153 }
154 
155 inline void MedicalBeam::SetFieldR(G4double r)
156 {
157  ffieldR = r;
158 }
159 
160 inline G4double MedicalBeam::GetFieldR() const
161 {
162  return ffieldR;
163 }
164 
165 #endif
static const G4double pos
double G4double
Definition: G4Types.hh:76
const G4ParticleDefinition * GetParticleDefinition() const