[904] | 1 | <!-- ******************************************************** --> |
---|
| 2 | <!-- --> |
---|
| 3 | <!-- [History] --> |
---|
| 4 | <!-- Created by: Makoto Asai, 14-Apr-2003 --> |
---|
| 5 | <!-- Converted to DocBook: Katsuya Amako, Aug-2006 --> |
---|
| 6 | <!-- --> |
---|
| 7 | <!-- ******************************************************** --> |
---|
| 8 | |
---|
| 9 | |
---|
| 10 | <!-- ******************* Section (Level#1) ****************** --> |
---|
| 11 | <sect1 id="sect.CutReg"> |
---|
| 12 | <title> |
---|
| 13 | Cuts per Region |
---|
| 14 | </title> |
---|
| 15 | |
---|
| 16 | |
---|
| 17 | <!-- ******************* Section (Level#2) ****************** --> |
---|
| 18 | <sect2 id="sect.CutReg.Gene"> |
---|
| 19 | <title> |
---|
| 20 | General Concepts |
---|
| 21 | </title> |
---|
| 22 | |
---|
| 23 | <para> |
---|
| 24 | Beginning with Geant4 version 5.1, the concept of a region has been |
---|
| 25 | defined for use in geometrical descriptions. Details about regions |
---|
| 26 | and how to use them are available in |
---|
| 27 | <xref linkend="sect.Geom.LogVol.SubReg" />. |
---|
| 28 | As an example, suppose a user defines three regions, corresponding to |
---|
| 29 | the tracking volume, the calorimeter and the bulk structure of a |
---|
| 30 | detector. For performance reasons, the user may not be interested |
---|
| 31 | in the detailed development of electromagnetic showers in the |
---|
| 32 | insensitive bulk structure, but wishes to maintain the best |
---|
| 33 | possible accuracy in the tracking region. In such a use case, |
---|
| 34 | Geant4 allows the user to set different production thresholds |
---|
| 35 | ("cuts") for each geometrical region. This ability, referred to as |
---|
| 36 | "cuts per region", is also a new feature provided by the Geant4 5.1 |
---|
| 37 | release. The general concepts of production thresholds were |
---|
| 38 | presented in the <xref linkend="sect.ProThres" />. |
---|
| 39 | </para> |
---|
| 40 | |
---|
| 41 | <para> |
---|
| 42 | Please note that this new feature is intended only for users |
---|
| 43 | who |
---|
| 44 | |
---|
| 45 | <orderedlist spacing="compact"> |
---|
| 46 | <listitem><para> |
---|
| 47 | are simulating the most complex geometries, such as an LHC |
---|
| 48 | detector, and |
---|
| 49 | </para></listitem> |
---|
| 50 | <listitem><para> |
---|
| 51 | are experienced in simulating electromagnetic showers in |
---|
| 52 | matter. |
---|
| 53 | </para></listitem> |
---|
| 54 | </orderedlist> |
---|
| 55 | </para> |
---|
| 56 | |
---|
| 57 | <para> |
---|
| 58 | We strongly recommend that results generated with this new feature |
---|
| 59 | be compared with results using the same geometry and uniform |
---|
| 60 | production thresholds. Setting completely different cut values for |
---|
| 61 | individual regions may break the coherent and comprehensive |
---|
| 62 | accuracy of the simulation. Therefore cut values should be |
---|
| 63 | carefully optimized, based on a comparison with results obtained |
---|
| 64 | using uniform cuts. |
---|
| 65 | </para> |
---|
| 66 | |
---|
| 67 | </sect2> |
---|
| 68 | |
---|
| 69 | |
---|
| 70 | <!-- ******************* Section (Level#2) ****************** --> |
---|
| 71 | <sect2 id="sect.CutReg.DefReg"> |
---|
| 72 | <title> |
---|
| 73 | Default Region |
---|
| 74 | </title> |
---|
| 75 | |
---|
| 76 | <para> |
---|
| 77 | The world volume is treated as a region by default. A |
---|
| 78 | <emphasis>G4Region</emphasis> object is automatically assigned to the world |
---|
| 79 | volume and is referred to as the "default region". The production |
---|
| 80 | cuts for this region are the defaults which are defined in the |
---|
| 81 | <emphasis>UserPhysicsList</emphasis>. Unless the user defines different cut |
---|
| 82 | values for other regions, the cuts in the default region will be |
---|
| 83 | used for the entire geometry. |
---|
| 84 | </para> |
---|
| 85 | |
---|
| 86 | <para> |
---|
| 87 | Please note that the default region and its default production |
---|
| 88 | cuts are created and set automatically by <emphasis>G4RunManager</emphasis>. |
---|
| 89 | The user is <emphasis role="bold">not</emphasis> allowed to set a region to |
---|
| 90 | the world volume, <emphasis role="bold">nor</emphasis> to assign other |
---|
| 91 | production cuts to the default region. |
---|
| 92 | </para> |
---|
| 93 | |
---|
| 94 | </sect2> |
---|
| 95 | |
---|
| 96 | |
---|
| 97 | <!-- ******************* Section (Level#2) ****************** --> |
---|
| 98 | <sect2 id="sect.CutReg.Assig"> |
---|
| 99 | <title> |
---|
| 100 | Assigning Production Cuts to a Region |
---|
| 101 | </title> |
---|
| 102 | |
---|
| 103 | <para> |
---|
| 104 | In the <literal>SetCuts()</literal> method of the user's physics list, the |
---|
| 105 | user must first define the default cuts. Then a |
---|
| 106 | <emphasis>G4ProductionCuts</emphasis> object must be created and initialized with |
---|
| 107 | the cut value desired for a given region. This object must in turn |
---|
| 108 | be assigned to the region object, which can be accessed by name |
---|
| 109 | from the <emphasis>G4RegionStore</emphasis>. An example <literal>SetCuts()</literal> |
---|
| 110 | code follows. |
---|
| 111 | |
---|
| 112 | <example id="programlist_CutReg_1"> |
---|
| 113 | <title> |
---|
| 114 | <literal>Setting production cuts to a region</literal> |
---|
| 115 | </title> |
---|
| 116 | |
---|
| 117 | <programlisting> |
---|
| 118 | void MyPhysicsList::SetCuts() |
---|
| 119 | { |
---|
| 120 | // default production thresholds for the world volume |
---|
| 121 | SetCutsWithDefault(); |
---|
| 122 | |
---|
| 123 | // Production thresholds for detector regions |
---|
| 124 | G4Region* region; |
---|
| 125 | G4String regName; |
---|
| 126 | G4ProductionCuts* cuts; |
---|
| 127 | |
---|
| 128 | regName = "tracker"; |
---|
| 129 | region = G4RegionStore::GetInstance()->GetRegion(regName); |
---|
| 130 | cuts = new G4ProductionCuts; |
---|
| 131 | cuts->SetProductionCut(0.01*mm); // same cuts for gamma, e- and e+ |
---|
| 132 | region->SetProductionCuts(cuts); |
---|
| 133 | |
---|
| 134 | regName = "calorimeter"; |
---|
| 135 | region = G4RegionStore::GetInstance()->GetRegion(regName); |
---|
| 136 | cuts = new G4ProductionCuts; |
---|
| 137 | cuts->SetProductionCut(0.01*mm,G4ProductionCuts::GetIndex("gamma")); |
---|
| 138 | cuts->SetProductionCut(0.1*mm,G4ProductionCuts::GetIndex("e-")); |
---|
| 139 | cuts->SetProductionCut(0.1*mm,G4ProductionCuts::GetIndex("e+")); |
---|
| 140 | region->SetProductionCuts(cuts); |
---|
| 141 | } |
---|
| 142 | </programlisting> |
---|
| 143 | </example> |
---|
| 144 | </para> |
---|
| 145 | |
---|
| 146 | |
---|
| 147 | </sect2> |
---|
| 148 | </sect1> |
---|