Exercises - Day 2 (May 20th)

Content:
Introduction
Exercises
Part I
Part II
Part III
Part IV

Solutions:
Part I
Part II
Part III
Part IV

Web:
SW references

Manual:
Appl. Dev. Man

Presentations:
Slides

Main:
Main

Introduction

Today's exercises cover the following items:

A Geant4 application example is provided, which serves as basis of the exercises. The exercises include the modification and/or extension of the following classes:

Exercises

Part I - Introductory exercises

Exercise 2-1
Get familiar with the classes of the example application, that correspond to the topic of the exercises (see the
list above).

The following diagram shows the class hierarchy of the detector (click here for a pdf file):

Class Diagram 4A (Day 4)

The class hierarchy of the primary generator is shown in the second diagram (click here for a pdf file):

Class Diagram 4B (Day 4)

Answer the following questions:

Part II - Materials

Exercise 2-2
In the class DetectorConstruction.cc define the following G4Isotopes (stable isotopes of germanium); then define a G4Element, which is germanium enriched in Ge-76. This material is used for neutrinoless double-beta decay experiments.

Define a G4Material, as metallic germaniumm with density=5.32 g/cm3.

Exercise 2-3

  1. Define a G4Material, liquid nitrogen , consisting of one element (nitrogen):
    • Z=7,
    • A=14.01 g/mole,
    • density=0.808 g/cm3,
    • temperature=77 K

  2. Define a gaseous G4Material, air, as a mixture of nitrogen (80% in mass) and oxygen (20% in mass).
    • Density=1.290 mg/cm3,
    • pressure=1 atm,
    • temperature=300 K.
    • Elemental properties of nitrogen are listed in point (1). For oxygen: Z=8 and A=15.9994 g/mole

Part III - Geometry

Exercise 2-4

  1. Replace the material of the world volume (worldVolLogic): from vacuum to air
  2. Include in the setup a cylinder made of liquid nitrogen, radius = 10 cm, height=20 cm.
    This volume should be daughter of the world volume and mother of the silicon box
  3. Place the nitrogen volume in the centre of the air world volume
  4. Rotate the liquid nitrogen volume, in such a way that the cylinder axis corresponds to the x-axis, rather than the z-axis (default). This corresponds to rotate the cylinder of π/2 with respect to the y/axis
  5. This volume is not sensitive.
  6. Define detVolPhys as a daugther of the nitrogen cylinder. Keep the same translation as before, namely (0,0,boxLenght*0.5) with respect to the global coordinate system. Be careful: the mother volume is rotated!

Exercise 2-5

  1. Re-define the material of detVolLogic from silicon to enriched germanium
  2. Change the minimum step size in the detVolLogic from 1.0 micrometer to 0.5 micrometer (note: this can be also changed interactively with the command /detector/maxStepSize). Set the minimum step size in liquid nitrogen to 0.1 mm.
  3. Do you need to re-define or update the read-out geometry? Why?

Part IV - Primary generator

Exercise 2-6
In the default case, the primary particle is a 1-MeV electron impinging perpendicularly on a side of the detector box. The impinging angle can be changed interactively by the command /source/incidentAngle

  1. for each event, draw a random number x in (0,1) using G4UniformRand(), and shoot an electron if x<0.5 and a positron (G4Positron) if x>0.5
  2. what does it happen if you generate a positron at rest (namely zero kinetic energy)?

Exercise 2-7
Remove the code produced within the previous exercise, and replace the "pencil beam" defined by default with a isotropic point source.

The source should be placed 1 cm above the centre of the detector (on z axis).
It emits 662-keV gamma-rays with isotropic angular distribution (note: what does "isotropic mean"? How theta and phi should be sampled?)

Exercise 2-8
Generate a point source, as before, emitting gamma-rays of 122 keV (branching ratio: 86%) and 136 keV (branching ratio: 14%)