alcap-org / g4sim

Simulation toolkit based on Geant4 and ROOT
http://wuchen1106.github.io/g4sim/
2 stars 2 forks source link

Dehardcode the rotation of primaries in target position mode #30

Closed AndrewEdmonds11 closed 10 years ago

AndrewEdmonds11 commented 10 years ago

At the moment, to determine whether a primary in target position mode is definitely in the target, we generate a random position within the same size area as the target geometry and then we rotate this with hard-coded values and check that the final position is in the target volume.

For the tolerances study, we want to rotate the target and so we would ideally dehardcode the rotations to avoid g4sim slowing down again.

Also, as an addition I've just thought of, we might also want to do the same thing for the translations.

AndrewEdmonds11 commented 10 years ago

So I'm not going to bother with this since there is no difference in the running time when the hard-coded rotations are correct or not. And it still works! Here's a plot of the positions (x, y and z not the origin values ox, oy and oz which all seem to be the same) of the primaries (oprocess == NULL)

test_base_10degcw

So I'm going to merge in what I have now and start getting some large scale runs done