I am observing a weird result when looking at tracking details within two concentric tori (toruses?). The following results are from Geant4 version 7.1, but I get the same using pre-release version 7.1.ref03. This is the code I use in DetectorConstruction to create the concentric tori: @--------------------------------------------------------@ //--------- Definitions of Solids, Logical Volumes, Physical Volumes -------- //------------------------------ // World //------------------------------ G4double HalfWorldLength = 50.*m; G4Box* solidWorld = new G4Box("world",HalfWorldLength,HalfWorldLength,HalfWorldLength); G4LogicalVolume* logicWorld = new G4LogicalVolume(solidWorld,Vacuum,"World",0,0,0); logicWorld->SetVisAttributes(G4VisAttributes::Invisible); physiWorld = new G4PVPlacement(0,0,logicWorld,"World",0,false,0); //------------------------- // Toroidal fiber //------------------------- G4Torus* solidFiber = new G4Torus("clad",0.,1.*cm,10.*cm,0.*deg,180.*deg); G4LogicalVolume* logicFiber = new G4LogicalVolume(solidFiber,Glue,"FiberClad",0,0,0); new G4PVPlacement(0,0,logicFiber,"FiberClad",logicWorld,false,0); //------------------------- // Toroidal fiber core //------------------------- G4Torus* solidCore = new G4Torus("core",0.,0.5*cm,10.*cm,0.*deg,180.*deg); G4LogicalVolume* logicCore = new G4LogicalVolume(solidCore,Scintillator,"FiberCore",0,0,0); new G4PVPlacement(0,0,logicCore,"FiberCore",logicFiber,false,0); @-------------------------------------------------------------@ I then shoot an up-going geantino from 0,0,0 with @-------------------------------------------------------------@ G4ParticleTable* particleTable = G4ParticleTable::GetParticleTable(); G4ParticleDefinition* particle = particleTable->FindParticle("geantino"); particleGun->SetParticleDefinition(particle); particleGun->SetParticlePosition(G4ThreeVector(0.*cm,0.*cm,0.*cm)); particleGun->SetParticleMomentumDirection(G4ThreeVector(0.,1.,0.)); particleGun->SetParticleEnergy(100.*MeV); @-------------------------------------------------------------@ If I now look at tracking output, this is what I see: @-------------------------------------------------------------@ #Step# 0 --- Pre-Step status World 0 fm 0 fm 0 fm --- Post-Step status World 0 fm 0 fm 0 fm --- Step quantities Step Length 0 fm Track Length 0 fm Process initStep #Step# 1 --- Pre-Step status World 0 fm 0 fm 0 fm --- Post-Step status FiberClad 0 fm 9 cm 0 fm --- Step quantities Step Length 9 cm Track Length 9 cm Process Transportation #Step# 2 --- Pre-Step status FiberClad 0 fm 9 cm 0 fm --- Post-Step status FiberCore 0 fm 9.5 cm 0 fm --- Step quantities Step Length 5 mm Track Length 9.5 cm Process Transportation #Step# 3 --- Pre-Step status FiberCore 0 fm 9.5 cm 0 fm --- Post-Step status World 0 fm 10.5 cm 0 fm --- Step quantities Step Length 1 cm Track Length 10.5 cm Process Transportation #Step# 4 --- Pre-Step status World 0 fm 10.5 cm 0 fm --- Post-Step status FiberClad 0 fm 11 cm 0 fm --- Step quantities Step Length 5 mm Track Length 11 cm Process Transportation #Step# 5 --- Pre-Step status FiberClad 0 fm 11 cm 0 fm --- Post-Step status World 0 fm 11 cm 0 fm --- Step quantities Step Length 0 fm Track Length 11 cm Process Transportation #Step# 6 --- Pre-Step status World 0 fm 11 cm 0 fm --- Post-Step status OutOfWorld 0 fm 50 m 0 fm --- Step quantities Step Length 49.9 m Track Length 50 m Process Transportation @-------------------------------------------------------------@ I am worried about the 0-length step number 5 and about the fact that step number 3 ends in the "World" volume rather than the expected "FiberClad" (or "FiberCore"?). I am not sure if this is a problem, but I would like to understand why this happens. Thanks Emanuele Leonardi
Bug fixws in G4Torus::Inside method for phi sections.