Message: setPhi() method for G4ThreeVector Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question setPhi() method for G4ThreeVector 

Forum: Event and Track Management
Date: 22 Mar, 2012
From: <Santos>

Hi all,

This is a little piece of my program
  G4ThreeVector momDir(0.,0.,1.);

  G4cout<<"momDir.phi() "<<momDir.phi() <<G4endl;
  G4cout<<"momDir.theta() "<<momDir.theta() <<G4endl;
  G4cout<<"momDir "<<momDir<<G4endl;

This is the output:

momDir.phi() 0 momDir.theta() 0.785398 momDir (0.707107,0,0.707107)

Now, momDir.phi() is 0 no matter what value I assign. This page:

describes the setPhi() method, and G4ThreeVector is just GEANT reusing Hep3Vector.

Could you, please, tell me what is wrong. By the way, I am using geant4.9.4.p02

Thank you.

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

1 None: Re: setPhi() method for G4ThreeVector   (Michael H. Kelsey - 23 Mar, 2012)
 Add Message Add Message
to: "setPhi() method for G4ThreeVector"

 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 ]