Dear G4 experts,
I have defined a volume (G4Box(“volumeName”, 10 * mm, 0.25 * mm, 10 * mm)) with one of its surface made rough by adding (G4UnionSolid) multiple rectangular G4Box(“edges”, 0.0025mm, 0.25mm, 0.0025*mm). With this implementation, as I let a particle, e.g neutrino (nu_e), pass through this volume, it gets stuck in this volume for a very long time. I am attaching a picture of the geometry for better visualization of the problem.
I would really appreciate it if someone can help me understand the problem and suggest some solutions.
Thanks and regards,
What you mean by
“as I let a particle, e.g neutrino (nu_e), pass through this volume, it gets stuck in this volume for a very long time”?
Let me rephrase/correct this statement by providing some more details. In my simulation, the 55Fe isotope decays to 55Mn, and electrons and electron-neutrinos are produced. If an electron-neutrino enters this volume, it gets stuck. I have waited for as long as ~2hours to see if the track progresses, but it did not. This might also happen for other particles as well but I could not check that.
I hope I have answered your question. Let me know if you need some other info.
Start your project considering single layer. if results are as of your choice. Pile up geometry.
The issue can be related with the usage of Boolean operation (multiple union). Try to define the “edges” as separate volumes.
Hi @evc ,
Thank you so much for your reply. Your suggestion solves my problem. However, I would also require these “edges” to be registered as “sensitive” volumes and since there are so many of them (~2000 in one surface) this makes things complicated if I would analyze the output data later. Could you please elaborate why Boolean operation (multiple union) does not work? Please do let me know if you have further suggestions.
You can try to define your volume as G4MultiUnion or G4TessellatedSolid. These classes have internal optimisation and should be much faster in your case.
If you want only the “edges” to be sensitive, then you would be better off defining them as separate volumes, which you place coincident with the surface of your main block. Then you can attach an SD to the one LV you create, and place it many times for all the different edges.
The most efficient way to do that last bit would be with a parameterised or replica placement: you make one LV, and just one actual PV, along with a function (subclass of
G4VPVPararameterisation) which maps a copy number to a placement position. G4 will then use that function to reuse one single PV instance over and over again, for tracking, visualization, etc.
Thank you @evc and @mkelsey for your suggestions.