Message: Re: What is not correct? Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Re: What is not correct? 

Forum: Geometry
Re: Question What is not correct? (Evgenya)
Date: 03 Nov, 2009
From: Gabriele Cosmo <Gabriele Cosmo>

Hi Evgenia,

>   //create limiting volume
>   G4Tubs* ar_tube = new G4Tubs("ar", 0, 70*mm, 20*mm, 0, 360*deg);
>   G4LogicalVolume* ar_log = new G4LogicalVolume(ar_tube, vac, "ar");
>   G4VPhysicalVolume* ar_phys = new G4PVPlacement(0, G4ThreeVector(0, 0, 60), ar_log, "ar", world_log, false, 0);
> 
>   //create first small detector
>   G4Tubs* det_tube = new G4Tubs("det", 0, 25*mm, 15*mm, 0, 360*deg);
>   G4LogicalVolume* det_log = new G4LogicalVolume(det_tube, detMaterial, "det");
>   G4VPhysicalVolume* det_phys = new G4PVPlacement(0, G4ThreeVector(-25, -25, 0), det_log, "det", ar_log, false, 0);
> 
>   //create second small detector
>   G4Tubs* deta_tube = new G4Tubs("deta", 0, 25*mm, 15*mm, 0, 360*deg);
>   G4LogicalVolume* deta_log = new G4LogicalVolume(deta_tube,detMaterial, "deta");
>   G4VPhysicalVolume* deta_phys = new G4PVPlacement(0, G4ThreeVector(-25, 30, 0), deta_log, "deta", ar_log, false, 0);
> 
>   //create third small detector
>   G4Tubs* detb_tube = new G4Tubs("detb", 0, 25*mm, 15*mm, 0, 360*deg);
>   G4LogicalVolume* detb_log = new G4LogicalVolume(detb_tube, detMaterial, "detb");
>   G4VPhysicalVolume* detb_phys = new G4PVPlacement(0, G4ThreeVector(30, -25, 0), detb_log, "detb", ar_log, false, 0);
> 
>   //create fourth small detector
>   G4Tubs* detc_tube = new G4Tubs("detc", 0, 25*mm, 15*mm, 0, 360*deg);
>   G4LogicalVolume* detc_log = new G4LogicalVolume(detc_tube, detMaterial, "detc");
>   G4VPhysicalVolume* detc_phys = new G4PVPlacement(0, G4ThreeVector(25, 30, 0), detc_log, "detc", air_log, false, 0);
> 
>   // --- sensitive detector ---
>   // I register ar_log as the detector in which I will register energy left in the detector
>   DetectorSD* detectorSD = new DetectorSD("DetectorSD");
>   G4SDManager* sdMan = G4SDManager::GetSDMpointer();
>   sdMan->AddNewDetector(detectorSD);
>   ar_log->SetSensitiveDetector(detectorSD);
> 
> The problem consists in: my sensitive detector registers nothing. Where
> is my mistake? What do I describe not correctly?

according to the code above, you're assigning the sensitive detector to
the "limiting volume" (filled of vacuum, I suppose), not to the detectors
themselves. Is this what is intended?
Also, 'detc' is placed inside 'air_log'. What is 'air_log' ?

Cheers, Gabriele

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

1 Note: Re: What is not correct?   (Evgenya - 05 Nov, 2009)
 Add Message Add Message
to: "Re: What is not correct?"

 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 ]