Dose Discrepancy with and without boundary skipping in regular navigation

I have set up a project with a voxelized volume, with the goal of determining the total dose to a subset of the voxels. I was initially using nested parameterisation with G4PSEnergyDeposit3D, and defined dose as the sum of energy deposit in the voxels divided by the total mass of those voxels.

I recently discovered the G4PhantomParameterisation class, and found that it is significantly more CPU efficient when the option SetSkipEqualMaterials(true) is set. However, I also found that the dose values were consistently a factor of ~2 greater than those from the simulations using nested parameterisation.

I then tried using the phantom parameterisation without boundary skipping, i.e. SetSkipEqualMaterials(false), and the dose results suddenly matched the nested parameterisation, but the CPU speedup disappeared, of course.

Finally, I tried defining a simple voxelized phantom with a single material and I still observed the 2x higher dose when using boundary skipping.

Has anyone noticed something like this?

I have used G4PhantomParameterisation many times and got the correct dose deposition, with or without SkipEqualMaterials. Can you send me (privately if you prefer) you code?

Hello Pedro,

Thank you very much for your response. I was preparing my code to send it to you by removing all of the auxiliary classes that were irrelevant (or so I thought) to the issue, only to notice that the problem went away.

It turns out that the cause of the issue is that I had a parallel world in my geometry. I am not sure though why this would only impact the results when boundary skipping is turned on.

I have also run with parallel geometries without problem. You may send me your code if you want me to see if the problem is en the Geant4 code

Hello Pedro,

I have actually figured out a solution to my problem. There were two issues:

  1. When registering physics for the parallel world, it is necessary to include the true argument, e.g.:

physics->RegisterPhysics(new G4ParallelWorldPhysics(parallelWorldName,true));

  1. The phantom parameterization needed to be in the parallel world, not the primary world.