source: trunk/examples/extended/analysis/A01/src/A01MuonPhysics.cc @ 807

Last change on this file since 807 was 807, checked in by garnier, 16 years ago

update

File size: 6.1 KB
Line 
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: A01MuonPhysics.cc,v 1.8 2006/06/29 16:33:01 gunter Exp $
27// --------------------------------------------------------------
28//
29// 09-Oct-2003 mu+- tau+- processes are changed by T. Koi
30// 05-Jan-2004 Add Brem. and PairProd. of AlongStepDoit for mu+- by T. Koi
31
32#include "A01MuonPhysics.hh"
33
34#include "globals.hh"
35#include "G4ios.hh"
36#include <iomanip>
37
38
39A01MuonPhysics::A01MuonPhysics(const G4String& name)
40                   :  G4VPhysicsConstructor(name)
41{
42}
43
44A01MuonPhysics::~A01MuonPhysics()
45{
46}
47
48#include "G4ParticleDefinition.hh"
49#include "G4ParticleTable.hh"
50
51#include "G4MuonPlus.hh"
52#include "G4MuonMinus.hh"
53#include "G4TauMinus.hh"
54#include "G4TauPlus.hh"
55
56#include "G4ProcessManager.hh"
57
58void A01MuonPhysics::ConstructProcess()
59{
60   G4ProcessManager * pManager = 0;
61
62   //Muon+
63   pManager = G4MuonPlus::MuonPlus()->GetProcessManager();
64   G4VProcess* thempMultipleScattering = new G4MultipleScattering();
65   G4VProcess* thempBremsstrahlung     = new G4MuBremsstrahlung();
66   G4VProcess* thempPairProduction     = new G4MuPairProduction();
67   G4VProcess* thempIonisation        = new G4MuIonisation();
68   //
69   // add processes
70   pManager->AddProcess(thempIonisation);
71   pManager->AddProcess(thempMultipleScattering);
72   pManager->AddProcess(thempBremsstrahlung);
73   pManager->AddProcess(thempPairProduction);
74   //
75   // set ordering for AlongStepDoIt
76   pManager->SetProcessOrdering(thempMultipleScattering, idxAlongStep,1);
77   pManager->SetProcessOrdering(thempIonisation,        idxAlongStep,2);
78   pManager->SetProcessOrdering(thempBremsstrahlung,     idxAlongStep,3);
79   pManager->SetProcessOrdering(thempPairProduction,     idxAlongStep,4);
80
81   // set ordering for PostStepDoIt
82   pManager->SetProcessOrdering(thempMultipleScattering, idxPostStep,1);
83   pManager->SetProcessOrdering(thempIonisation,        idxPostStep,2);
84   pManager->SetProcessOrdering(thempBremsstrahlung,     idxPostStep,3);
85   pManager->SetProcessOrdering(thempPairProduction,     idxPostStep,4);
86
87   //Muon-
88   pManager = G4MuonMinus::MuonMinus()->GetProcessManager();
89   G4VProcess* themmMultipleScattering = new G4MultipleScattering();
90   G4VProcess* themmBremsstrahlung     = new G4MuBremsstrahlung();
91   G4VProcess* themmPairProduction     = new G4MuPairProduction();
92   G4VProcess* themmIonisation        = new G4MuIonisation();
93   //
94   // add processes
95   pManager->AddProcess(themmIonisation);
96   pManager->AddProcess(themmMultipleScattering);
97   pManager->AddProcess(themmBremsstrahlung);
98   pManager->AddProcess(themmPairProduction);
99   //
100   // set ordering for AlongStepDoIt
101   pManager->SetProcessOrdering(themmMultipleScattering, idxAlongStep,1);
102   pManager->SetProcessOrdering(themmIonisation,        idxAlongStep,2);
103   pManager->SetProcessOrdering(themmBremsstrahlung,     idxAlongStep,3);
104   pManager->SetProcessOrdering(themmPairProduction,     idxAlongStep,4);
105   // set ordering for PostStepDoIt
106   pManager->SetProcessOrdering(themmMultipleScattering, idxPostStep,1);
107   pManager->SetProcessOrdering(themmIonisation,        idxPostStep,2);
108   pManager->SetProcessOrdering(themmBremsstrahlung,     idxPostStep,3);
109   pManager->SetProcessOrdering(themmPairProduction,     idxPostStep,4);
110 
111   // Tau+ Physics
112   pManager = G4TauPlus::TauPlus()->GetProcessManager();
113   G4VProcess* thetpMultipleScattering = new G4MultipleScattering();
114   G4VProcess* thetpIonisation        = new G4hIonisation();
115   //
116   // add processes
117   pManager->AddProcess(thetpIonisation);
118   pManager->AddProcess(thetpMultipleScattering);
119   //
120   // set ordering for AlongStepDoIt
121   pManager->SetProcessOrdering(thetpMultipleScattering, idxAlongStep,1);
122   pManager->SetProcessOrdering(thetpIonisation,        idxAlongStep,2);
123   //
124   // set ordering for PostStepDoIt
125   pManager->SetProcessOrdering(thetpMultipleScattering, idxPostStep,1);
126   pManager->SetProcessOrdering(thetpIonisation,        idxPostStep,2);
127
128   // Tau- Physics
129   pManager = G4TauMinus::TauMinus()->GetProcessManager();
130   G4VProcess* thetmMultipleScattering = new G4MultipleScattering();
131   G4VProcess* thetmIonisation        = new G4hIonisation();
132   //
133   // add processes
134   pManager->AddProcess(thetmIonisation);
135   pManager->AddProcess(thetmMultipleScattering);
136   //
137   // set ordering for AlongStepDoIt
138   pManager->SetProcessOrdering(thetmMultipleScattering, idxAlongStep,1);
139   pManager->SetProcessOrdering(thetmIonisation,        idxAlongStep,2);
140   //
141   // set ordering for PostStepDoIt
142   pManager->SetProcessOrdering(thetmMultipleScattering, idxPostStep,1);
143   pManager->SetProcessOrdering(thetmIonisation,        idxPostStep,2);
144
145}
Note: See TracBrowser for help on using the repository browser.