Message: Problem with sensitivity of mother to doughter volumes Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Problem with sensitivity of mother to doughter volumes  

Keywords: Doughter volume is sensitive, but only for last mother volume layer. Problem with pointers?
Forum: Hits, Digitization and Pileup
Date: 24 Nov, 2005
From: Petr Mikes <mikes@fzu.cz>

I have some problem with sensitivity for mother and doughter volumes.

I have folowing Detector construction where logicSi is sensitive.

//----------------------------------------------------------
solidLayerAll = new G4Box("Layer_All", LayerThicknessAll/2, CalorSizeYZ/2,CalorSizeYZ/2);
logicLayerAll = new G4LogicalVolume(solidLayerAll, defaultMaterial,"Layer_All");
for (int i = 0; i<NbOfLayers1; i++)
{
posLayer = - i*LayerThicknessAll + CalorThickness/2 - LayerThicknessAll/2;
physiLayerAll = new G4PVPlacement(0,G4ThreeVector(posLayer,0,0),
	 			 logicLayerAll,
				 "Layer_All",
				 logicCalor,
				 false,
				 0);

}
//--------------------------------------------------------
solidLayer = new G4Box("Layer", LayerThickness/2, CalorSizeYZ/2,CalorSizeYZ/2);
logicLayer = new G4LogicalVolume(solidLayer, defaultMaterial,"Layer");
physiLayer = new G4PVPlacement(0,G4ThreeVector(LayerElThickness/2,0,0),
	 			 logicLayer,
				 "Layer",
				 logicLayerAll,
				 false,
				 0);

//--------------------------------------------
 G4double CrystalY = CalorSizeYZ/(nY);
 G4double CrystalZ = CalorSizeYZ/(nZ);

solidSi = new G4Box("Silicon", SiThickness/2, CrystalY/2, CrystalZ/2); logicSi = new G4LogicalVolume(solidSi,SiMaterial,"Silicon");

  G4int copyNo=0;
  G4double yTlate, zTlate;

   for (G4int j = 0; j < nY; j++)															
    {zTlate =-CalorSizeYZ/2+CrystalZ/2+j*CrystalZ;
     for (G4int i = 0; i < nZ; i++)
	{yTlate =-CalorSizeYZ/2+CrystalY/2+i*CrystalY;
	 physiSi = new G4PVPlacement(0,G4ThreeVector(-WThickness/2,yTlate,zTlate),logicSi,"Silicon",logicLayer,false,copyNo++);

	}
    }

And Si is sensitive:

//---------Senzitive Detector
  G4SDManager* SDman = G4SDManager::GetSDMpointer();
  SDman->AddNewDetector(EMCalorimetr);
  logicSi->SetSensitiveDetector(EMCalorimetr);

but the sensitivity for Si is set only for last layer.

When logicSi was doughter only of Calorimeter everything was ok. Is there some problem with poiners when I use this structure?

Thank you. Petr

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 None: Re: Problem with sensitivity of mother to doughter volumes   (Makoto Asai - 24 Nov, 2005)
1 Question: Re: Problem with sensitivity of mother to doughter volumes   (Petr Mikes - 28 Nov, 2005)
3 None: Re: Problem with sensitivity of mother to doughter volumes   (Luís Perles - 30 Nov, 2005)
 Add Message Add Message
to: "Problem with sensitivity of mother to doughter volumes "

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]