1 | #ifndef G4INUCL_NUCLEI_HH |
---|
2 | #define G4INUCL_NUCLEI_HH |
---|
3 | // |
---|
4 | // ******************************************************************** |
---|
5 | // * License and Disclaimer * |
---|
6 | // * * |
---|
7 | // * The Geant4 software is copyright of the Copyright Holders of * |
---|
8 | // * the Geant4 Collaboration. It is provided under the terms and * |
---|
9 | // * conditions of the Geant4 Software License, included in the file * |
---|
10 | // * LICENSE and available at http://cern.ch/geant4/license . These * |
---|
11 | // * include a list of copyright holders. * |
---|
12 | // * * |
---|
13 | // * Neither the authors of this software system, nor their employing * |
---|
14 | // * institutes,nor the agencies providing financial support for this * |
---|
15 | // * work make any representation or warranty, express or implied, * |
---|
16 | // * regarding this software system or assume any liability for its * |
---|
17 | // * use. Please see the license in the file LICENSE and URL above * |
---|
18 | // * for the full disclaimer and the limitation of liability. * |
---|
19 | // * * |
---|
20 | // * This code implementation is the result of the scientific and * |
---|
21 | // * technical work of the GEANT4 collaboration. * |
---|
22 | // * By using, copying, modifying or distributing the software (or * |
---|
23 | // * any work based on the software) you agree to acknowledge its * |
---|
24 | // * use in resulting scientific publications, and indicate your * |
---|
25 | // * acceptance of all terms of the Geant4 Software license. * |
---|
26 | // ******************************************************************** |
---|
27 | // $Id: G4InuclNuclei.hh,v 1.16 2010/04/09 19:33:11 mkelsey Exp $ |
---|
28 | // Geant4 tag: $Name: geant4-09-04-beta-cand-01 $ |
---|
29 | // |
---|
30 | // 20100112 Michael Kelsey -- Replace G4CascadeMomentum with G4LorentzVector |
---|
31 | // 20100301 M. Kelsey -- Add function to create unphysical nuclei for use |
---|
32 | // as temporary final-state fragments. |
---|
33 | // 20100319 M. Kelsey -- Remove "using" directory and unnecessary #includes. |
---|
34 | // 20100409 M. Kelsey -- Drop unused string argument from ctors. |
---|
35 | |
---|
36 | #include "G4InuclParticle.hh" |
---|
37 | #include "G4ExitonConfiguration.hh" |
---|
38 | |
---|
39 | class G4ParticleDefinition; |
---|
40 | |
---|
41 | class G4InuclNuclei : public G4InuclParticle { |
---|
42 | public: |
---|
43 | G4InuclNuclei() : G4InuclParticle() {} |
---|
44 | |
---|
45 | G4InuclNuclei(G4double a, G4double z) |
---|
46 | : G4InuclParticle(makeDefinition(a,z)), |
---|
47 | exitationEnergy(0.0) {} |
---|
48 | |
---|
49 | G4InuclNuclei(const G4LorentzVector& mom, G4double a, G4double z) |
---|
50 | : G4InuclParticle(makeDefinition(a,z), mom), |
---|
51 | exitationEnergy(0.0) {} |
---|
52 | |
---|
53 | G4InuclNuclei(G4double ekin, G4double a, G4double z) |
---|
54 | : G4InuclParticle(makeDefinition(a,z), ekin), |
---|
55 | exitationEnergy(0.0) {} |
---|
56 | |
---|
57 | virtual ~G4InuclNuclei() {} |
---|
58 | |
---|
59 | // Copy and assignment constructors for use with std::vector<> |
---|
60 | G4InuclNuclei(const G4InuclNuclei& right) |
---|
61 | : G4InuclParticle(right), exitationEnergy(right.exitationEnergy), |
---|
62 | theExitonConfiguration(right.theExitonConfiguration) {} |
---|
63 | |
---|
64 | G4InuclNuclei& operator=(const G4InuclNuclei& right); |
---|
65 | |
---|
66 | void setExitationEnergy(G4double e) { exitationEnergy = e; } |
---|
67 | |
---|
68 | void setExitonConfiguration(const G4ExitonConfiguration& config) { |
---|
69 | theExitonConfiguration = config; |
---|
70 | } |
---|
71 | |
---|
72 | G4double getA() const { return getDefinition()->GetAtomicMass(); } |
---|
73 | |
---|
74 | G4double getZ() const { return getDefinition()->GetAtomicNumber(); } |
---|
75 | |
---|
76 | G4double getExitationEnergy() const { return exitationEnergy; } |
---|
77 | |
---|
78 | G4double getExitationEnergyInGeV() const { |
---|
79 | return 0.001 * exitationEnergy; |
---|
80 | } |
---|
81 | |
---|
82 | const G4ExitonConfiguration& getExitonConfiguration() const { |
---|
83 | return theExitonConfiguration; |
---|
84 | } |
---|
85 | |
---|
86 | static G4double getNucleiMass(G4double a, G4double z); |
---|
87 | |
---|
88 | virtual void printParticle() const { |
---|
89 | G4cout << " A " << getA() << " Z " << getZ() << " mass " |
---|
90 | << getMass() << " Eex (MeV) " << exitationEnergy << G4endl; |
---|
91 | G4InuclParticle::printParticle(); |
---|
92 | } |
---|
93 | |
---|
94 | protected: |
---|
95 | // Convert nuclear configuration to standard GEANT4 pointer |
---|
96 | static G4ParticleDefinition* |
---|
97 | makeDefinition(G4double a, G4double z, G4double exc=0.); |
---|
98 | |
---|
99 | static G4ParticleDefinition* |
---|
100 | makeNuclearFragment(G4double a, G4double z, G4double exc=0.); |
---|
101 | |
---|
102 | private: |
---|
103 | G4double exitationEnergy; |
---|
104 | G4ExitonConfiguration theExitonConfiguration; |
---|
105 | }; |
---|
106 | |
---|
107 | #endif // G4INUCL_NUCLEI_HH |
---|
108 | |
---|
109 | |
---|
110 | |
---|
111 | |
---|
112 | |
---|
113 | |
---|