|
FlyoDoc_2011 Pisa 2011 by GmP --- 011
|
#include <anak3pi.h>
Public Member Functions | |
| AnaK3pi () | |
| int | Fisica () |
| void | Reset_parm () |
| void | print_scale () |
| int | Vertice () |
| void | Ordina () |
Public Attributes | |
| double | maspi |
| int | nd |
| float | ss [3] |
| float | su |
| float | sv |
| float | kcog |
| float | vx |
| float | vy |
| float | vz |
| float | chisq |
| int | np |
| float | pmis [3] |
| float | charge |
| float | mkmis |
| float | pkmis |
| float | ptksq |
| float | fi3 |
| float | cogm1 |
| float | cogm1x |
| float | cogm1y |
| double | chicomb |
| gvet | P1 |
| gvet | P2 |
| gvet | P3 |
| gvet | V0 |
| gvet | V1 |
| gvet | V2 |
| gvet | V3 |
| gvet | Noto |
| gvet | PV |
| gvet | Cog3p |
| gvet | VM1 |
| gvet | VM2 |
| gvet | VM3 |
| gvet | DP1 |
| gvet | DP2 |
| gvet | DP3 |
| qvet | Q1 |
| qvet | Q2 |
| qvet | Q3 |
| qvet | QT |
| qvet | QC |
| AnaK3pi::AnaK3pi | ( | ) |
Ipotesi K-> 3 pi carichi.
Definition at line 49 of file anak3pi.cpp.
{
tipo=4;nfit=3;titol="K--> 3 pio_ch";nome="K3pi";
nd=np=0;
maspi=.13956;
Ird0=Ird1=Ird2=0;
Icb0=Icb1=Icb2=0;
Gout<<"\n Attivato il fit di "<<titol;
if(Le_Tracce==0)
{
Gout<<"\n Error.. K3pi analisys ... Tracks non defined!"<<std::endl;
exit(0);
}
}
| int AnaK3pi::Fisica | ( | ) | [virtual] |
loop for the best combination...test on the vertex chiq
Reimplemented from Analisi.
Definition at line 66 of file anak3pi.cpp.
{
np=nd=0;
np=Le_Tracce->Tot_trk+1;
// Gout<<"\n Nhit: "<<np;
if(np<3||np>6){np=0;getta_ch++;return(-1);}
nd=3;
carica=.0;
// define the coupling number (1,4,10,20)
int trial=1;
if(np>3)trial=(np*(np-1)*(np-2))/6;
chisq=300.;
for (int i=0;i<trial;i++)
{
count_call++;
// get track index
Icb0=combine[i][0];
Icb1=combine[i][1];
Icb2=combine[i][2];
double etot= Tracc[Icb0]->Get_P()[3]+Tracc[Icb1]->Get_P()[3]+Tracc[Icb2]->Get_P()[3];
if(etot<10. ){getta_en++;continue;} //return -2;};
carica=Tracc[Icb0]->charge+Tracc[Icb1]->charge+Tracc[Icb2]->charge;
// get the index order...Ird0,Ird1 (same charge as above) Ird3 is the odd charge
if( carica!=1&&carica!=-1 ) {getta_char++;continue;}
Ordina(); // ordina le tracce da essere (++-) o (--+)
P1=Tracc[Ird0]->Get_Pc1();
P2=Tracc[Ird1]->Get_Pc1();
P3=Tracc[Ird2]->Get_Pc1();
if(Vertice()<1){getta_fit++;continue;} //return -3;};
if(chicomb<chisq)
{chisq=chicomb;
charge=carica;
PVsave=PV;
Isv0=Ird0; Isv1=Ird1;Isv2=Ird2;
}
}
if(chisq>200.)return -3; // see Vertice()
if(trial>1) // get the saved values by the best fit for trial >1
{Ird0=Isv0;Ird1=Isv1;Ird2=Isv2;
P1=Tracc[Ird0]->Get_Pc1();
P2=Tracc[Ird1]->Get_Pc1();
P3=Tracc[Ird2]->Get_Pc1();
PV=PVsave;
}
pmis[0]=Tracc[Ird0]->ptrk;
pmis[1]=Tracc[Ird1]->ptrk;
pmis[2]=Tracc[Ird2]->ptrk;
// calcolo il cog at lkr
Cog3p=(Tracc[Ird0]->Xlk*pmis[0]+Tracc[Ird1]->Xlk*pmis[1] +Tracc[Ird2]->Xlk*pmis[2]);
Cog3p/=(pmis[0]+pmis[1]+pmis[2]);
kcog = Cog3p.XYNorma();
cogm1x=Cog3p[0];
cogm1y=Cog3p[1];
cogm1 =kcog;
PV.putv(vx,vy,vz);
V1= P1-PV; V1.Norma();V1=V1.Verso()*pmis[0];
V2= P2-PV; V2.Norma();V2=V2.Verso()*pmis[1];
V3= P3-PV; V3.Norma();V3=V3.Verso()*pmis[2];
// calcolo della massa invariante
Q1.setvn(V1,maspi);
Q2.setvn(V2,maspi);
Q3.setvn(V3,maspi);
QT=Q1+Q2+Q3;
mkmis=QT.Invar();
pkmis=QT.norma;
ptksq=(QT&PV).Norma()/PV.norma;
// Calcolo dei parametri s1,s2,s3,su..
// con rinomalizzazione della massa invariante a quella del k !!
//
// qvet QC = dQT/dcorr quadrivettore derivato rispetti alla correzione
QC.setqn(V1+V2+V3, Q1.normaq/Q1.e+Q2.normaq/Q2.e+Q3.normaq/Q3.e);
// QC.print("QC");
double corr=1.- (QT.m-MASK)*QT.m/(QC*QT);
// Gout<<"\n Correzione = %12.7lf %12.5lf ",corr,QT*QC);
Q1.setvn(V1*corr,maspi);
Q2.setvn(V2*corr,maspi);
Q3.setvn(V3*corr,maspi);
QT=Q1+Q2+Q3; QT.Invar();
// QT.print("QTcorr");
fi3=atan2(Q3[1],Q3[0]);
ss[0]=(QT-Q1).Invarq();
ss[1]=(QT-Q2).Invarq();
ss[2]=(QT-Q3).Invarq();
su = (ss[2]-SS0)/MPICQ; // u
sv = 0.433013*(ss[1]-ss[0])/MPICQ; // v
count_wnt++;
return(1);
}