Hi @jangelmm
Welcome to the Geant4 forum!
Thank you for your question, it is very interesting.
The “0 fm” cases may be related to numerical precision in the overlap checking algorithm.
The overlaps of 20–35 µm may be worth to investigate them. As @Zhao_Shihan said, for many particle simulations they may be small, but optical photons are more sensitive because reflections and refractions depend directly on the exact position of geometry boundaries. If an overlap affects the definition of an interface, it can change the optical response.
To answer your questions:
-
In principle, overlaps should be avoided. The impact depends on how often particles interact with the affected regions. Note that even if the depth of the protrusion is small, the total overlap section may be big (800 points out of 10000, so 8% of the surface)
-
It is normal to see these warnings in
/geometry/test/runbut not during normal tracking. The test checks many random points on all surfaces, while real events may never hit some of these problematic regions. -
Ideally, overlaps should be zero. In practice, small numerical overlaps can happen with CAD geometries, but values of tens of microns are usually worth investigating.
Looking at your geometry, most overlaps seem to come from (thin?) wrapping layers (Tape → Teflon → Air) around the scintillator.
If these layers are only used to reproduce reflective optical behaviour, one simple option is to remove them and use a G4LogicalSkinSurface (or G4LogicalBorderSurface) directly on the scintillator. In this case, the optical reflection is handled by the surface model [link to optical physics documentation], and the extra volumes are not needed. This also removes the source of many overlaps.
However, if you want to keep the real wrapping materials around the scintillator (for example to model more realistic optical behaviour, including effects related to diffuse reflection and refractive index changes), another possibility is to build the wrapper layers using G4ScaledSolid [link to scaled solid documentation]. Instead of importing several independent CAD meshes for Tape, Teflon, and Air, you can import only the scintillator mesh and create the surrounding layers by scaling it. Alternatively, you can scale the solid manually. This is only useful if you really need the physical layers. Otherwise, the skin surface approach is simpler.
As a final note, you may be interested in this post: https://geant4-forum.web.cern.ch/t/importing-cad-geometries-into-geant4-practical-notes-and-common-pitfalls/14912
Thank you for your time.
Best,
Alvaro