I did some tests with different MAX_FIELD_STEP values using jlabce:2.5 container which has gemc 2.9 and geant4.10.7.p03
The field map used has 1cm grid and -FIELD_PROPERTIES="solenoid_CLEOv8, 1*mm, G4ClassicalRK4,linear"
1st test
high energy tracks of chargedgeantino in vacuum shows a few percent difference between default and 1mm as follows, while 100mm,10mm,1mm don't differ much
(51, 16) pz: 10759.4155951 10759.3373101 10759.3008105 10759.3289386 10759.4650835
check details at ifarm by
cd /group/solid/solid_github/JeffersonLab/solid_gemc_test/analysis/field_test
diff solidgem.txt_max1 solidgem.txt_maxdefault
repeat the test by
cp /group/solid/solid_github/JeffersonLab/solid_gemc_test/analysis/field_test/solidgem.gcard ./
cp /group/solid/solid_github/JeffersonLab/solid_gemc_test/analysis/field_test/solidgem__geometry_Original.txt ./
gemc solidgem.gcard -BEAM_P="chargedgeantino,11GeV,12deg,0deg" -BEAM_V="(0,0,-350)cm" -FIELD_DIR="/group/solid/solid_github/JeffersonLab/solid_gemc_test/field" -HALL_FIELD="solenoid_CLEOv8" -FIELD_PROPERTIES="solenoid_CLEOv8, 1mm, G4ClassicalRK4,linear" -MAX_FIELD_STEP=1
more solidgem.txt
2nd test
testing speed of gemc for 1e6 events and SoLID PVDIS full geometry and 1cm3 grid map at different MAX_FIELD_STEP
0-11GeV electrons entering solid at all angles, the speed is 1:1 for MAX_FIELD_STEP default:10mm
11GeV electrons shooting at 40cm LD2 target, the speed is 1:2.5:15 for MAX_FIELD_STEP default:100mm:10mm
my thoughts
MAX_FIELD_STEP in gemc is fLargestAcceptableStep in geant4 (geometry/navigation/src/G4PropagatorInField.cc) whose default 1000m is too large for both high energy particles shown in my test and low energy particles in clas12 test ("moller electrons were jumping un-physically to unshielded areas")
Maybe it's best for our application with 1cm map grid to use MAX_FIELD_STEP 1cm to balance speed and accuracy.
I did some tests with different MAX_FIELD_STEP values using jlabce:2.5 container which has gemc 2.9 and geant4.10.7.p03 The field map used has 1cm grid and -FIELD_PROPERTIES="solenoid_CLEOv8, 1*mm, G4ClassicalRK4,linear"
1st test high energy tracks of chargedgeantino in vacuum shows a few percent difference between default and 1mm as follows, while 100mm,10mm,1mm don't differ much
2nd test testing speed of gemc for 1e6 events and SoLID PVDIS full geometry and 1cm3 grid map at different MAX_FIELD_STEP 0-11GeV electrons entering solid at all angles, the speed is 1:1 for MAX_FIELD_STEP default:10mm 11GeV electrons shooting at 40cm LD2 target, the speed is 1:2.5:15 for MAX_FIELD_STEP default:100mm:10mm
my thoughts MAX_FIELD_STEP in gemc is fLargestAcceptableStep in geant4 (geometry/navigation/src/G4PropagatorInField.cc) whose default 1000m is too large for both high energy particles shown in my test and low energy particles in clas12 test ("moller electrons were jumping un-physically to unshielded areas") Maybe it's best for our application with 1cm map grid to use MAX_FIELD_STEP 1cm to balance speed and accuracy.