[VMC] How to set maximal step value in GEANT-4 ?

From: Y. Shitov (shitov@cenbg.in2p3.fr)
Date: Fri Dec 03 2004 - 18:51:10 MET


Dear VMC users,

I found that flag stemax - maximum step permitted - set for particular
media in TGeoMedium, works only in G3 but not in G4!  Is it possible
to set maximal step size for partical tracking media in G4 uder VMC?

It seems, that I can do something like:
TG4Limits->SetMaxAllowedStep() (?)

But it's global cut for all media, while I want to set stemax only for
special crucial media(volume).

Another solution:
(http://www-hades.gsi.de/~dbertini/Geant45Doc/G4gstmed_8cc.html)

{
  // get the pointer to material nmat
  G4Material* material = G3Mat.get(nmat);

  // NB. there is the possibility for redundancy in the mag
  //     and user limits objects. Who cares.
  // Generate the mag field object
  // $$$ G4MagneticField* field = new G4MagneticField(ifield,fieldm, tmaxfd);

  G4MagneticField* field = 0;
  	
  // Generate the user limits object
  // !!! only "stemax" has its equivalent in G4  
  G4UserLimits* limits = 0;
  if (useG3TMLimits) {
  limits = new G4UserLimits();
  limits->SetMaxAllowedStep(stemax*cm);

  // limits->SetG3DefaultCuts();
  // this is arranged globally by physics manager
  }
  
  // Store this medium in the G3Med structure
  G3Med.put(itmed, material, field, limits, isvol);
}

can't be applied in our case as we have no G4-geometry classes.

Any ideas?

And more general question: I know that for G3 stemax is essential
parameter for low energy simulation (10 kev - 10 MeV), what's about G4?

Best,
Yuri



This archive was generated by hypermail 2b29 : Sun Jan 02 2005 - 11:25:00 MET