GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » Event Generators » PndBoxGenerator
PndBoxGenerator [message #4298] Tue, 22 May 2007 18:59 Go to previous message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *physik.uni-giessen.de
After some discussions I wrote a new box generator inside pgenerators directory: PndBoxGenerator.

PndBoxGenerator is like CbmBoxGenerator, but I put one function in order to set uniform distributions in cos(theta), and not in theta as it is done by default.

Example:

If you want to have a unifor distribution i theta, you have to type in your simulation macro:


PndBoxGenerator* boxGen = new PndBoxGenerator(13, 1);
boxGen->SetPRange(1.,1.); // GeV/c
boxGen->SetPhiRange(0., 360.); // Azimuth angle range [degree]
boxGen->SetThetaRange(0., 180.); // Polar angle in lab system range [degree]
boxGen->SetXYZ(0., 0., 0.); // vertex coordinates [cm]
primGen->AddGenerator(boxGen);



IF you want to have a unifor distribution in cos(theta):

PndBoxGenerator* boxGen = new PndBoxGenerator(13, 1);
boxGen->SetPRange(1.,1.); // GeV/c
boxGen->SetPhiRange(0., 360.); // Azimuth angle range [degree]
boxGen->SetThetaRange(0., 180.); // Polar angle in lab system range [degree]
boxGen->SetCosTheta(); // Set uniform ditribution in cos(theta)
boxGen->SetXYZ(0., 0., 0.); // vertex coordinates [cm]
primGen->AddGenerator(boxGen);


And that's all.
Enjoy...

Ste



[Updated on: Fri, 20 July 2007 13:51]

Report message to a moderator

 
Read Message
Read Message
Read Message
Previous Topic: fluka events for test purposes
Next Topic: Basic Documentation
Goto Forum:
  


Current Time: Wed Jun 19 20:17:19 CEST 2024

Total time taken to generate the page: 0.00906 seconds