Forum: Biasing and Scoring Not Logged In (login)
Show subscribers

Biasing and scoring in Geant4

The email gateway for this forum is: biasing_scoring-g4hn@slac.stanford.edu


Inline Depth:
 0 0
 1 1
Add message: (add)

Question Peaks in PhotoPeak Efficiency  by KUKI <KUKI>,   Oct 26, 21:10
I have recently started work in geant4. I am trying to calculate the efficiency of the NaI detector and HPGe detector.

I have defined the detector geometry, a simple cylinder. The total Efficiency has a normal decreasing trend with increasing gamma energy. However,Photo peak efficiency with gamma ray energy has certain peaks at about 1 MeV, 2 MeV, 4 Mev and 8 MeV from 0.5 to 10 MeV gamma energy range. This behavior is independent of detector's material. I am unable to sort the problem out. I would be grateful if you could help me in this regard. Following are the relevant portions of the code.

void SteppingAction::UserSteppingAction(const G4Step* aStep)
{
        G4StepPoint* prePoint = aStep->GetPreStepPoint();
 
 {
 const G4VPhysicalVolume* logvol = aStep->GetPreStepPoint()->GetTouchableHandle()->GetVolume();
 if (logvol==detector->GetphysiAbsorber())
  {
  G4double EdepStep = aStep->GetTotalEnergyDeposit();
 
  if (EdepStep > 0.)
 
  evtAct -> AddEdeposit(EdepStep);
  }
 }
 
}

void EventAction::EndOfEventAction(const G4Event* evt)
{
 
        if (Edeposit > 0.)
 {
 myRunAction -> TotalCounts(Edeposit);
 }
 ......
 ......
}

void RunAction::TotalCounts(G4double Ed)
{
 G4ParticleDefinition* particle =
                            primary->GetParticleGun()->GetParticleDefinition();
 Particle = particle->GetParticleName();   
 energy = primary->GetParticleGun()->GetParticleEnergy();
 Total ++;
 if (Ed==energy){
 pphoton++;
 }
}

void RunAction::EndOfRunAction(const G4Run* aRun)
{
        G4double PhotonEffic = pphoton/NbOfEvents;

 G4double TotalEffic = Total/NbOfEvents;
}


looking forward
best regards
 
Kuki
Question More than one detector  by Matt Worden <Matt Worden>,   Sep 18, 11:21
Hello, I have constructed a block with many parrallel channels. I have one detector at the end catching particles coming down all the channels. I would like to have a separate detector at the end of each channel so I can tell which channel each particle went down. Does anyone have any suggestions. I am not sure if I should put a different detector and manager at the end of each channel, or if I should use one and report which area of the detector the hits happen.

Any advise or suggestions are welcome

Thanks for your time

Question ElectronNuclearProcess Biasing   by wangym <wangym>,   Aug 11, 06:52
Hi, In my physicslist,I write as follow, G4ElectronNuclearProcess* theElectronNuclearProcess; G4ElectroNuclearReaction* theElectroReaction; theElectronNuclearProcess = new G4ElectronNuclearProcess; theElectroReaction = new G4ElectroNuclearReaction; theElectronNuclearProcess->RegisterMe(theElectroReaction); theElectronNuclearProcess->BiasCrossSectionByFactor(100); pmanager->AddDiscreteProcess(theElectronNuclearProcess);

so, My weight is 1/100, How many second protons producedHif a second proton produced, I multiply 1/100. then I plus them. But in your PPT, see Attach files ,the weight is not 1/100. Am I rightH

   Attachment:
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/08/11/06.52-73537-E._biasing.hadronics.pdf

None Get Size of the Mesh RE03 and RE02 error compilation  by Olivier Dadoun <Olivier Dadoun>,   Jun 30, 08:56
Hello,

I am playing with RE03 example to see how I can use the Scoring. I have a simple question: how can I retrieve the size of the mesh from the RE03UserScoreWriter class ?

by advance thank you Olivier

None Re: Get Size of the Mesh RE03 and RE02 error compilation  by Akinori Kimura <Akinori Kimura>,   Jul 06, 20:52
Re: None Get Size of the Mesh RE03 and RE02 error compilation (Olivier Dadoun)
RE03UserScoreWriter class has been derived from the G4VScoreWriter class. The G4VScoreWriter has an attribute of the mesh size, G4int fNMeshSegments[3]. That attribute is assigned the mesh size when G4ScoringManager::DumpQuantityToFile(...) or G4ScoringManager::DumpAllQuantitiesToFile(...) method is invoked. Those Dump methods are invoked by the UI commands: /socre/dumpQuantityToFile or /socre/dumpAllQuantitiesToFile .

The RE03UserScoreWriter::DumpQuantityToFile(...) is invoked in G4ScoringManager after the assingment of the mesh size. Therefore, fNMeshSegments[3] assigned the mesh size is available in the RE03UserScoreWirter::DumpQuantityToFile(...).

Question why there are no entries in my G4HCofThisEvent ?   by <xfgu@ihep.ac.cn>,   13 May, 2009
I want use Sensitive Detector,Hit and Hits Collection to calculate energy deposit, but it doesn't work. There is no any entry in my G4HCofThisEvent.

And I have spent about one week to check and compares with other programs, just want to find whether there is a mistake in my program, but I didn't find.

Any answer will be helpful, thank you so much.

There must be somebody can take me away from this trouble.

I appreciate your help.

I have changed *.hh to *.h

   Attachment:
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-45513-EnDepMainTest.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-98391-epDetectorConstruction.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-81116-EnDepEventAction.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-4194-EnDepHit.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-31459-EnDepPhysicsList.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-1854-PrimaryGeneratorAction.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-1804-EnDepRunAciton.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-58170-EnDepSD.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-94045-EnDepSteppingAction.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.26-59783-EnDepSteppingVerbose.cc
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.27-3956-DepDetectorConstruction.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-56108-EnDepHit.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-15281-EnDepEventAction.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-39497-EnDepPhysicsList.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-48130-pPrimaryGeneratorAction.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-21319-EnDepRunAction.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-11115-EnDepSD.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-34763-EnDepSteppingAction.h
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2009/05/13/08.29-74816-EnDepSteppingVerbose.h

Note Re: why there are no entries in my G4HCofThisEvent ?   by <xfgu@ihep.ac.cn>,   13 May, 2009
Re: Question why there are no entries in my G4HCofThisEvent ?
It seems that the function "G4bool EnDepSD::ProcessHits(G4Step* aStep,G4TouchableHistory*)" never start to run.

Anybody know why?

Thank you very much.

Question GDML Scoring through G4MultiFunctionalDetector and Primitive Scorers ?  by Victor Gabriel <Victor Gabriel>,   24 Feb, 2009
Hello Everybody,

I've already installed Geant4.9.2 by CLHEP 2.0.4.2, GDML with Xerces 2.8.0, and AIDA on Ubuntu 8.10.

I've been modifying auxiliary.gdml example file within G01 example. The auxiliary information of geometry isn't coded in C++, so I couldn't get my logical volumes to assign with the primitive scorers (G4PSDoseScorer).

Where Will I need to modify DetectorConstruction.hh ?

Best regards,

Victor Gabriel

 Add Message Add Message
to: "Biasing and Scoring"

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