I am taking images of a spherical ball with a fast neutron detector (OPPAC). I am able to detect protons and record positions and every without problems. Now I want to activate optical photons in my detector but I cannot detect any optical photons. In my physics I have this hoping it can help me create optical photons but I still cannot see any optical photons produce. Does anyone have an idea how to do this?
“”
// Neutron Physics
RegisterPhysics( new NeutronHPphysics(“neutronHP”));
// Optical Physics
RegisterPhysics(new G4EmStandardPhysics_option4());
G4OpticalPhysics* opticalPhysics = new G4OpticalPhysics();
RegisterPhysics(opticalPhysics);
“”
Geant4 Version: geant4-v11.1.3
_Operating System: Ubuntu 20.04.6 LTS
_Compiler/Version: c++
_CMake Version: VERSION 2.6 FATAL_ERROR
In order to transport the optical photons, materials must have defined a refractive index, see for example the detector constructor of this example provided by Geant4.
There are other optical properties that may be of interest for your application, as explained in the docs.
Since version 11, some optical properties are predefined for you, as explained here.
Usually the scintillators are in contact with a reflective surface, so definition of such boundary is also needed.
In addition to the official documentation, optical physics is also covered during the Geant4 advance course, e.g. 2023 edition. The recording of the session are available as well in CDS or indico.
thank you for your responds I did define the parameters following the guide but I still cant detect optical photons. this is the part I have in my construction.
sorry for the late reply but I get error when I tried to add this.
/home/harriet/Geant4/neutron_example/Neutron_optical_detector/sim.cc:19:10: fatal error: FTFP_BERT_EMZ_HP.hh: No such file or directory
19 | #include “FTFP_BERT_EMZ_HP.hh”
| ^~~~~~~~~~~~~~~~~~~~~
Sorry, may you try with the Physics Lists Factory, as explained in this example?
// To be able to use and combine the refrence physics lists
#include "G4PhysListFactory.hh"
#include "G4ThermalNeutrons.hh"
...
int main()
...
const G4String plName = "FTFP_BERT_EMZ";
G4PhysListFactory plFactory;
G4VModularPhysicsList *pl = plFactory.GetReferencePhysList( plName );
runManager->SetUserInitialization( pl );
sorry, Optical Physics has to be registered into the G4VModularPhysicsList object before registering the Physics list into the run manager,
// To be able to use and combine the refrence physics lists
#include "G4PhysListFactory.hh"
#include "G4ThermalNeutrons.hh"
...
int main()
...
const G4String plName = "FTFP_BERT_EMZ";
G4PhysListFactory plFactory;
G4VModularPhysicsList *pl = plFactory.GetReferencePhysList( plName );
pl->RegisterPhysics(new G4OpticalPhysics);
runManager->SetUserInitialization( pl );