20{
21 P4EEtaPhiM theP4EEtaPhiM(10.,1.,2.,0.);
22 P4EEtaPhiM twoP4EEtaPhiM(10.,1.3,2.4,0.);
23 P4PxPyPzE theP4PxPyPzE(0.,3.,4.,5.);
24 P4IPtCotThPhiM theP4IPtCotThPhiM(0.5,1.,2.,0.);
25 P4EEtaPhiM threeP4EEtaPhiM(theP4IPtCotThPhiM);
26 P4PtEtaPhiM fourP4PtEtaPhiM(theP4IPtCotThPhiM);
27
28
29 double aux [[maybe_unused]] = theP4EEtaPhiM.px();
30 aux+=theP4PxPyPzE.px();
31 aux+=theP4IPtCotThPhiM.px();
33 std::cout << "P4DummyTest: theDeltaR1= " << theDeltaR1 << std::endl ;
35 std::cout << "P4DummyTesters: theDeltaR2= " << theDeltaR2 << std::endl ;
37 std::cout << "P4DummyTest: theDeltaR3= " << theDeltaR3 << std::endl ;
38 CLHEP::HepLorentzVector theHlv=twoP4EEtaPhiM.hlv() ;
40 std::cout << "P4DummyTest: theDeltaR4= " << theDeltaR4 << std::endl ;
41
42
44 std::cout << "P4DummyTest: theDeltaR5= " << theDeltaR5 << " [=R2]"<< std::endl ;
45
46
47
49 std::cout << "P4DummyTest: dPhi1= " << dPhi1 << std::endl;
50
52 std::cout << "P4DummyTest: dPhi2= " << dPhi2 << std::endl;
53
55 std::cout << "P4DummyTest: dPhi3= " << dPhi3 << std::endl;
56
58 std::cout << "P4DummyTest: dPhi4= " << dPhi4 << std::endl;
59
61 std::cout << "P4DummyTest: dPhi5= " << dPhi5 << " [=dPhi2]"<< std::endl;
62
63
64
65
66 std::cout << "P4DummyTest: --- Test 2-body invariant mass ---" << std::endl;
68 std::cout << "P4DummyTest: inv2Mass1= " << inv2Mass1 << std::endl;
69
71 std::cout << "P4DummyTest: inv2Mass2= " << inv2Mass2 << std::endl;
72
74 std::cout << "P4DummyTest: inv2Mass3= " << inv2Mass3 << std::endl;
75
77 std::cout << "P4DummyTest: inv2Mass4= " << inv2Mass4 << std::endl;
78
80 std::cout << "P4DummyTest: inv2Mass5= " << inv2Mass5 << " [=mass2]"<< std::endl;
81
82
83 std::cout << "P4DummyTest: --- Test 4-body invariant mass ---" << std::endl;
85 theP4EEtaPhiM, theP4IPtCotThPhiM );
86 std::cout << "P4DummyTest: inv4Mass1= " << inv4Mass1 << std::endl;
87
89 theP4EEtaPhiM, threeP4EEtaPhiM );
90 std::cout << "P4DummyTest: inv4Mass2= " << inv4Mass2 << std::endl;
91
93 theP4EEtaPhiM, twoP4EEtaPhiM );
94 std::cout << "P4DummyTesters: inv4Mass3= " << inv4Mass3 << std::endl;
95
97 P4PxPyPzE(theHlv), theP4EEtaPhiM );
98 std::cout << "P4DummyTest: inv4Mass4= " << inv4Mass4 << std::endl;
99
101 theP4EEtaPhiM, fourP4PtEtaPhiM );
102 std::cout << "P4DummyTest: inv4Mass5= " << inv4Mass5 << " [=Mass2]"<< std::endl;
103
104
105
106}
double invMass(const I4Momentum &pA, const I4Momentum &pB)
invariant mass from two I4momentum references
double deltaR(const I4Momentum &p4, double eta, double phi)
from 1 I4Momentum
double deltaPhi(double phiA, double phiB)
delta Phi in range [-pi,pi[