Message: the method to collect OpticalPhotons Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None the method to collect OpticalPhotons 

Forum: Processes Involving Optical Photons
Date: 21 Aug, 2009
From: ylzhang <ylzhang>

I want collect the OpticalPhoton. So i write a "PMT" Volume beside BGO cristal Volume. I use two methods to calculate the OpticalPhotons which are "collected" by PMT. but the results are different. I donnot know why.

//The Code in SteppingAction
//The First one
//
G4VPhysicalVolume* volume1 
= aStep->GetPreStepPoint()->GetTouchableHandle()->GetVolume();
G4VPhysicalVolume* volume2
= aStep->GetPostStepPoint()->GetTouchableHandle()->GetVolume();
if ((volume1 == detector->GetBGO())&&(volume2 == detector->GetPMT()))
  {
    G4Track* aTrack = aStep->GetTrack();
    if(aTrack->GetDefinition() == G4OpticalPhoton::OpticalPhotonDefinition())
      {
	if(aTrack->GetTrackID()>1)
	  {
	    stepInfo.highEnergySecondaryParticleNumber = 1;
	    aTrack->SetTrackStatus(fStopAndKill);
	  }
      }
  }

//
//the Second one
//
if(aTrack->GetTrackID()>1)
  {
    if( (detector->GetCalorimeter() == aTrack->GetVolume()) && ( detector->GetBottom() == aTrack->GetNextVolume() ) )
      {
	if ( aTrack->GetDefinition() == G4OpticalPhoton::OpticalPhotonDefinition() )

	  {
	    aTrack->SetTrackStatus(fStopAndKill);
	    stepInfo.highEnergySecondaryParticleNumber = 1;

	  }
      }
  }

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

1 Feedback: Re: the method to collect OpticalPhotons   (Gumplinger Peter - 21 Aug, 2009)
1 None: Re: the method to collect OpticalPhotons   (ylzhang - 22 Aug, 2009)
2 None: Re: the method to collect OpticalPhotons   (ylzhang - 23 Aug, 2009)
1 Feedback: Re: the method to collect OpticalPhotons   (Gumplinger Peter - 25 Aug, 2009)
... 1 Message(s)
 Add Message Add Message
to: "the method to collect OpticalPhotons"

 Subscribe Subscribe

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