LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
G4PseudoLaser.cc
Go to the documentation of this file.
1 #include "G4PseudoLaser.hh"
2 #include "G4PhysicalConstants.hh"
3 #include "G4SystemOfUnits.hh"
4 #include "G4ParticleTable.hh"
5 
6 #include "G4MuonDecayChannel.hh"
7 #include "G4DecayTable.hh"
8 
9 // ######################################################################
10 // ### MUONPLUS ###
11 // ######################################################################
13 
15 {
16  if (theInstance !=0) return theInstance;
17  const G4String name = "mulaser";
18  // search in particle table]
19  G4ParticleTable* pTable = G4ParticleTable::GetParticleTable();
20  G4ParticleDefinition* anInstance = pTable->FindParticle(name);
21  if (anInstance ==0)
22  {
23  std::cout << "Creating " << name << std::endl;
24  // create particle
25  //
26  // Arguments for constructor are as follows
27  // name mass width charge
28  // 2*spin parity C-conjugation
29  // 2*Isospin 2*Isospin3 G-parity
30  // type lepton number baryon number PDG encoding
31  // stable lifetime decay table
32  // shortlived subType anti_encoding
33  anInstance = new G4ParticleDefinition(
34  name, 0.1056583715*GeV, 2.99598e-16*MeV, +1.*eplus,
35  1, 0, 0,
36  0, 0, 0,
37  "lepton", -1, 0, 66613,
38  true/*false*/, 2196.98*ns, NULL,
39  false, "mu"
40  );
41  // Bohr Magnetron
42  G4double muB = 0.5*eplus*hbar_Planck/(anInstance->GetPDGMass()/c_squared) ;
43 
44  anInstance->SetPDGMagneticMoment( muB * 1.0011659209);
45 
46  //create Decay Table
47  /*
48  G4DecayTable* table = new G4DecayTable();
49  // create a decay channel
50  G4VDecayChannel* mode = new G4MuonDecayChannel("mulaser",1.00);
51  table->Insert(mode);
52  anInstance->SetDecayTable(table);
53  */
54  }
55 
56  theInstance = reinterpret_cast<G4PseudoLaser*>(anInstance);
57  std::cout << "Returning " << theInstance << std::endl;
58  return theInstance;
59 }
60 
62 {
63  return Definition();
64 }
65 
67 {
68  return Definition();
69 }
70 
static G4PseudoLaser * PseudoLaser()
static G4PseudoLaser * theInstance
static G4PseudoLaser * PseudoLaserDefinition()
static G4PseudoLaser * Definition()
Float_t e
Definition: plot.C:35