What does it mean that two volumes touch each other (definition of the boundary surface)?

Hi Geant’ers

I want to say that I have read Physics Reference Manual and Book For Application Developers (at least those parts which, I think, related to my question) and still have no answers.

So imagine I want to specify a boundary surface between two dielectrics (n1 and n2). Ideally these media must touch but due to some limitations (discrete nature of computer numbers, for example) one can’t be sure it always true. So I probably have the following configuration (in order to avoid overlapping):

n1 | gap | n2

But then I use the G4LogicalBorderSurface constructor providing volumes n1 and n2 as arguments which “builds” a boundary between n1 and n1. Question is : how Geant knows that the gap between n1 and n2 doesn’t count when an optical photon goes through it?

The geometry and tracking systems include a “tolerance” parameter. So long as the “gap” you describe is narrower than that tolerance, it will be ignored.

Oh, thank you for answer. Should I use G4GeometryTolerance singleton to get this parameter:



Yes, that’s it. You can inquire about it, but you most likely don’t want to change it.

Ok, I just want to read its value.