Re: [ROOT] Azimuth angle definition

From: Rene Brun (Rene.Brun@cern.ch)
Date: Wed Feb 12 2003 - 18:46:19 MET


Hi Yuri,

I am afraid that you are right. These two packages were developed by
different authors at different times.

We imported TLorentzVector from the CLHEP library and did not want
to change the convention.

I have added comments in the relevant header files to clarify the return range.

Thanks for sending this remark.

Rene Brun

Yuri Kharlov wrote:
> 
> Hi!
> 
> There are at least two definition of the azimuth angle in root:
> 
> 1) TLorentzVector::Phi() and TVector3::Phi() returns phi from -pi to pi:
> TMath::ATan2(fY,fX).
> 
> 2) TParticle::Phi() returns phi from 0 to 2pi:
> kPI+TMath::ATan2(-fPy,-fPx)
> 
> Sometimes it is confusing when comparing azimuth angles of different
> objects.
> 
> Is it intentional?
> 
> Yuri Kharlov.



This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:09 MET