Message: Re: Number of Photons in different parts of the detector Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Number of Photons in different parts of the detector 

Forum: Processes Involving Optical Photons
Re: Question Number of Photons in different parts of the detector (Kanishka)
Date: Feb 12, 13:16
From: Daren Sawkey <Daren Sawkey>

Hi, this is an analysis question, not optical. If this answer doesn't help maybe try the analysis forum.

> "No. of photons1" and "No. of photons2" should be different

countPhotons is being used for two different things. Think about what happens if both 'if' statements are false.

> Also everytime I run the code it shows different set of numbers.

It's not really clear what you are doing or how you expect it to work. Probably countPhotons isn't initialized properly. If this is UserSteppingAction the value likely isn't persisting for different tracks either. Have a look at the examples. A good one to follow is extended/electromagnetic/TestEm5.

-- Daren.

 Add Message Add Message
to: "Re: Number of Photons in different parts of the detector"

 Subscribe Subscribe

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