CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_2_SLHC4_patch1/src/L1Trigger/CSCTrackFinder/src/CSCTFPtMethods.cc

Go to the documentation of this file.
00001 #include <L1Trigger/CSCTrackFinder/interface/CSCTFPtMethods.h>
00002 #include <DataFormats/L1CSCTrackFinder/interface/CSCTFConstants.h>
00003 
00004 #include <cmath>
00005 
00006 //-----------------
00007 // Static variables
00008 //-----------------
00009 
00010 //L1MuTriggerPtScale CSCTFPtMethods::trigger_scale;
00011 
00012 // Global scale factor to multiply all parameterizations by
00013 //const float CSCTFPtMethods::kGlobalScaleFactor = 1.055;
00014 // Now scale to 90% effic definition like in old ORCA
00015 const float CSCTFPtMethods::kGlobalScaleFactor = 1.36;
00016 
00017 // First ME1andME2, then ME1andME3, then MB1andME2
00018 // units are radians*GeV
00019 
00020 
00021 // These arrays contain the values for the best fit parameters for three station measurements
00022 
00023 const float CSCTFPtMethods::AkLowEta_Fit1[kME2andMB2][CSCTFPtMethods::kMaxParameters] = 
00024   {
00025     //    {-4.026, 8.139, -5.350, 1.176},                               //hit detectors 1 and 2
00026     //???    {0.5170, -11.13, 8.255, -1.980},                           //hit detectors 1 and 2
00027     {3.900, -8.391, 6.062, -1.436},                             //hit detectors 1 and 2
00028     //    {-2.241, 4.405, -2.756, 0.5878},      //13
00029     {8.03602, -17.5355, 12.7725, -3.0616 },     //13
00030     {0.8372, -2.220, 1.908, -0.5233},                   //23
00031     {-0.04389, 0.05174, 0.0, 0.0},                              //24
00032     {-0.5519E-02, 0.8496E-02, 0.0, 0.0},                //34
00033     {-4.228, 8.546, -5.617, 1.235},                             //12
00034     {0.80, -0.54, 0.0, 0.0},                            //25
00035     {0.80, -0.54, 0.0, 0.0},                            //26
00036   };
00037 
00038 const float CSCTFPtMethods::AkHighEta_Fit1[kME2andMB2][CSCTFPtMethods::kMaxParameters] = 
00039   {
00040     //    {0.6644, -0.2312, 0.0, 0.0},                  //12
00041     {0.6275, -0.2133, 0.0, 0.0},                        //12
00042     {-1.124, 2.492, -1.347, 0.2204},            //13
00043     {0.5214, -0.7536, 0.3913, -.06739},         //23
00044     {1.394, -1.886, 0.8809, -0.1369},           //24
00045     {-0.5519E-02, 0.8496E-02, 0.0, 0.0},        //34
00046     {0.6644, -0.2312, 0.0, 0.0},                        //12
00047     {0.80, -0.54, 0.0, 0.0},                    //25
00048     {0.80, -0.54, 0.0, 0.0},                    //26
00049   };
00050 
00051 // These arrays contain the values for the best fit parameters found imperically to determine Pt for a two station measurement
00052 // The realtionship is dphi = A/Pt + B/Pt^2
00053 const float CSCTFPtMethods::AkLowEta_Fit2[kME2andMB2][CSCTFPtMethods::kMaxParameters] = 
00054   {
00055     //    {-3.198, 6.703, -4.539, 1.028},                       //12
00056     {-0.6131, 0.6870, 0.0285, -0.1147},                 //12
00057     //  {-6.705, 14.52, -10.32, 2.449},                 //13
00058     {8.03602, -17.5355, 12.7725, -3.0616 },     //13
00059     {5.765, -12.85, 9.543, -2.345},                     //23
00060     {-4.068, 8.254, -5.491, 1.214},                     //24
00061     {-.02974, .04816, -.02105, .003640},        //34
00062     {-3.358, 7.038, -4.766, 1.079},                     //12
00063     {0.80, -0.54, 0.0, 0.0},                    //25
00064     {0.80, -0.54, 0.0, 0.0},                    //26
00065   };
00066 const float CSCTFPtMethods::AkHighEta_Fit2[kME2andMB2][CSCTFPtMethods::kMaxParameters] = 
00067   {
00068     {0.6425, -0.2308, 0.0, 0.0},                                //12
00069     {0.6923, -0.2336, 0.0, 0.0},                                //13
00070     {-0.7147, .01117, -0.5255E-04, 0.7991E-07}, //23
00071     {-1.377, 2.150, -1.046, 0.1667},                    //24
00072     {-.02974, .04816, -.02105, .003640},                //34
00073     {0.6425, -0.2308, 0.0, 0.0},                                //12
00074     {0.80, -0.54, 0.0, 0.0},                            //25
00075     {0.80, -0.54, 0.0, 0.0},                            //26
00076   };
00077 
00078 const float CSCTFPtMethods::BkLowEta_Fit2[kME2andMB2][CSCTFPtMethods::kMaxParameters] = 
00079   {
00080     //    {-0.5873, 0.0802, 0.2337, 0.0},       //12
00081     {7.0509, -7.3282, -0.1465, 1.308},  //12
00082     //    {-0.5677, 1.907, -1.365, 0.2899},     //13
00083     {0.0, 0.0, 0.0, 0.0},       //13
00084     {-38.55, 82.95, -59.66, 14.29},             //23
00085     {20.71, -45.34, 32.05, -7.415},             //24
00086     {0.0, 0.0, 0.0, 0.0},                               //34
00087     {-0.6167, 0.08421, 0.2454, 0.0},    //12
00088     {0.0, 0.0, 0.0, 0.0},                               //25
00089     {0.0, 0.0, 0.0, 0.0}                                //26
00090   };
00091 const float CSCTFPtMethods::BkHighEta_Fit2[kME2andMB2][CSCTFPtMethods::kMaxParameters] = 
00092   {
00093     {14.79, -21.10, 10.16, -1.623},             //12
00094     {70.67, -105.7, 52.49, -8.631},             //13
00095     {15.70, -23.94, 11.89, -1.939},             //23
00096     {17.18, -26.38, 13.13, -2.139},             //24
00097     {0.0, 0.0, 0.0, 0.0},                               //34
00098     {14.79, -21.10, 10.16, -1.623},             //12
00099     {0.0, 0.0, 0.0, 0.0},                               //25
00100     {0.0, 0.0, 0.0, 0.0}                                //26
00101   };
00102 
00103 const float CSCTFPtMethods::FRCorrLowEta[kME2andMB2][2] = 
00104   {
00105 //    {1.13, 0.87}, //12
00106 //    {1.14, 0.85},   //13
00107     {1.30, 1.0}, //12
00108     {1.30, 1.0},   //13
00109     {1.0, 1.0},   //23
00110     {1.0, 1.0},   //24
00111     {1.0, 1.0},   //34
00112     {1.0, 1.0},   //12
00113     {1.0, 1.0},   //25
00114     {1.0, 1.0}    //26
00115   };
00116 const float CSCTFPtMethods::FRCorrHighEta[kME2andMB2][2] = 
00117   {
00118 //    {0.92, 1.12}, //12
00119 //    {0.92, 1.12},   //13
00120     {0.966, 1.176}, //12
00121     {0.966, 1.176},   //13
00122     {1.0, 1.0},   //23
00123     {1.0, 1.0},   //24
00124     {1.0, 1.0},   //34
00125     {1.0, 1.0},   //12
00126     {1.0, 1.0},   //25
00127     {1.0, 1.0}    //26
00128   };
00129 
00130 // Anna's 2011 parametrization
00131 
00132 double CSCTFPtMethods::AB_mu12FnoME11[4][15] = 
00133     {
00134   {0, 0, 0, 0.089491067646809183134, 0.10739646024310070538, 0.12549844133338972085, 0.11746188101535759429, 0.11365654376086815891, 0, 0, 0, 0, 0, 0, 0},
00135   {0, 0, 0, -0.16463359422729287318, -0.18522613297525072906, -0.17065296570525056996, -0.11673113772749151018, -0.096673008784020367234, 0, 0, 0, 0, 0, 0, 0},
00136   {0, 0, 0, 5.0479701928535670313e-06, -8.5107255627149016024e-05, -0.00031591725812981632723, 2.8829297417277944225e-05, -3.3664459708458401629e-05, 0, 0, 0, 0, 0, 0, 0},
00137   {0, 0, 0, 1.6276716966428210753, 1.1244502885068945464, 0.44061802755260442988, 0.82271567628154873564, 0.65764083792276606388, 0, 0, 0, 0, 0, 0, 0}
00138   };
00139 double CSCTFPtMethods::AB_mu13FnoME11[4][15] = 
00140     {
00141   {0, 0, 0, 0.11479489063486028599, 0.1385846143670735886, 0.16069130395935576905, 0.16229285551120029019, 0.15970793987729367536, 0, 0, 0, 0, 0, 0, 0},
00142   {0, 0, 0, -0.31624871209539057171, -0.37204708239816158821, -0.35001738011313637822, -0.28067946142333310977, -0.22587297159275510072, 0, 0, 0, 0, 0, 0, 0},
00143   {0, 0, 0, 4.5422334693538224219e-05, -0.0001534874341906974503, -0.00049456554072302828882, -0.00040362112138876319418, -0.00037532294041719521617, 0, 0, 0, 0, 0, 0, 0},
00144   {0, 0, 0, 1.3698214790637726068, 0.83827124867878388681, 0.35268421062422455892, 0.30966868638086236798, 0.39552380610102405578, 0, 0, 0, 0, 0, 0, 0}
00145   };
00146 double CSCTFPtMethods::AB_mu14FnoME11[4][15] = 
00147     {
00148   {0, 0, 0, 0, 0.10167174785035071327, 0.072305163037876873933, 0.12811797755236814522, 0.15630771929281417343, 0, 0, 0, 0, 0, 0, 0},
00149   {0, 0, 0, 0, -0.2851531414997146574, -0.12625245577882274195, -0.2693337001449228052, -0.35816854038946227545, 0, 0, 0, 0, 0, 0, 0},
00150   {0, 0, 0, 0, 0.0016536940782984094634, 0.0032050914503555030799, 0.0017500898659728782863, 0.0014193550176488352668, 0, 0, 0, 0, 0, 0, 0},
00151   {0, 0, 0, 0, 1.8999999999960794916, 1.8999999999875891721, 1.1603749006227730423, 0.36919547110219635977, 0, 0, 0, 0, 0, 0, 0}
00152   };
00153 double CSCTFPtMethods::AB_mu12RnoME11[4][15] = 
00154     {
00155   {0, 0.1017548888755877845, 0.13020457985822880831, 0.11777472840868662141, 0.1352735458205116259, 0.14797523226644127003, 0.14891234013414389459, 0, 0, 0, 0, 0, 0, 0, 0},
00156   {0, -0.40835812179222591434, -0.4909339449226597929, -0.19396964458569518341, -0.18405457126044733052, -0.15348184403810183341, -0.11949446624665205352, 0, 0, 0, 0, 0, 0, 0, 0},
00157   {0, -0.00046324193156588387276, -0.0012328343527384165272, 5.8536010291841255454e-05, 5.3175743777652564014e-05, -0.00027992198289290446886, 0.00017291608058844862988, 0, 0, 0, 0, 0, 0, 0, 0},
00158   {0, 0.82326825991227925439, 0.66225151266154569374, 1.6047267765109303195, 1.172660602794620921, 0.91611151466846096891, 0.923434361821059424, 0, 0, 0, 0, 0, 0, 0, 0}
00159   };
00160 double CSCTFPtMethods::AB_mu13RnoME11[4][15] = 
00161     {
00162   {0, 0, 0, 0.17152643870188713504, 0.18220699353677527466, 0.19718061346676321599, 0.20409261783490945108, 0, 0, 0, 0, 0, 0, 0, 0},
00163   {0, 0, 0, -0.51329151983333287657, -0.43421697939765058205, -0.38701854807672181336, -0.29367743292763504037, 0, 0, 0, 0, 0, 0, 0, 0},
00164   {0, 0, 0, -0.00028330256767296205581, -0.00011104889576832950495, -0.0003659472931155986178, -0.0004494825869971541348, 0, 0, 0, 0, 0, 0, 0, 0},
00165   {0, 0, 0, 1.0806773148892279135, 0.81710737240426545291, 0.49165515886235822141, 0.40288815951359424616, 0, 0, 0, 0, 0, 0, 0, 0}
00166   };
00167 double CSCTFPtMethods::AB_mu14RnoME11[4][15] = 
00168     {
00169   {0, 0, 0, 0.11411457974213083666, 0.14612498789299999125, 0.15438328053344949065, 0.17021962182813230036, 0, 0, 0, 0, 0, 0, 0, 0},
00170   {0, 0, 0, -0.32211539883453449429, -0.3332077022119345755, -0.28947013547326555516, -0.31678412927379157038, 0, 0, 0, 0, 0, 0, 0, 0},
00171   {0, 0, 0, 0.0021189308480414714535, 0.0017232488622970817526, 0.0014181868364706309241, 0.0020581588744611055593, 0, 0, 0, 0, 0, 0, 0, 0},
00172   {0, 0, 0, 1.8999999998213816799, 1.8999999999320695832, 1.2588510283946776624, 0.91969335359675130626, 0, 0, 0, 0, 0, 0, 0, 0}
00173   };
00174 double CSCTFPtMethods::AB_mu12FME11[4][15] = 
00175     {
00176   {0, 0, 0, 0, 0, 0, 0, 0.30997988806094234349, 0.2960464576032310613, 0.26865522361643923155, 0.24306471114654951138, 0.21612598016341960649, 0.20916086000526656896, 0.14505390185826338989, 0.19626640578808879356},
00177   {0, 0, 0, 0, 0, 0, 0, -0.18938263233962521204, -0.18099881965541908535, -0.15817156292403300455, -0.13527092529520332032, -0.11802970951212833628, -0.13142443653269073045, -0.081045302368033256268, -0.16548691953190999837},
00178   {0, 0, 0, 0, 0, 0, 0, 1.9132754352698083493e-05, 0.0001244919158836254626, -0.00036815494148734217474, -0.0003021495594158459864, 0.00032190104529820852321, 5.9699515482881178492e-05, 0.0035011369787794933972, -0.0021251348628855359045},
00179   {0, 0, 0, 0, 0, 0, 0, 1.2633991230895826874, 1.2237510610710955472, 1.2446734233372107603, 1.2072459880229720053, 1.2073932498298223237, 0.64342700161682475635, 1.0965614756840385002, 0.41184878672694380519}
00180   };
00181 double CSCTFPtMethods::AB_mu13FME11[4][15] = 
00182     {
00183   {0, 0, 0, 0, 0, 0, 0.17684262466990949281, 0.34711584948456875033, 0.34173632193931768875, 0.31856060138741582044, 0.29169375726034846297, 0.24666606646956890092, 0.21434901698955760585, 0.22194241387027591195, 0.13650791328679393044},
00184   {0, 0, 0, 0, 0, 0, 0.99999999999949551466, 0.99999999999457755973, -0.30995317528055632561, -0.26510423524582477084, -0.22052246537701888918, -0.1597247313884862796, -0.14032250966056744601, -0.14430798488566201621, -0.075894576731296098382},
00185   {0, 0, 0, 0, 0, 0, 0.010426580434797315736, 0.00056720513052092998933, -0.00047916406780649806879, -0.00043513801305821104073, -0.00035934925416836774022, 0.00064159373840440422562, 0.0011012063282968072471, 0.00059066112387542329433, 0.0061369729760295480686},
00186   {0, 0, 0, 0, 0, 0, -0.46194813956282321232, -2.1380051317667612132, 0.99475655086418368622, 1.0240107231697159751, 1.0710375546859214335, 1.1466745846418702204, 1.0634581787492956018, 0.35737857407704720636, 1.1165504043676175439}
00187   };
00188 double CSCTFPtMethods::AB_mu14FME11[4][15] = 
00189     {
00190   {0, 0, 0, 0, 0, 0, 0, 0, 0.21118188098880102954, 0.33402008586605308471, 0.29298980221468984286, 0.26806296448653738063, 0.23720733268363508595, 0.2510285652964933667, 0.14583302968662079091},
00191   {0, 0, 0, 0, 0, 0, 0, 0, -0.14883704087325219656, -0.39197899608005709604, -0.28520435482868433663, -0.23819454759756183981, -0.2024802801289519727, -0.2369976701205682712, -0.086510146140783658608},
00192   {0, 0, 0, 0, 0, 0, 0, 0, 0.010748111373072187155, -0.00054440793841566191644, -6.6117096422286744401e-05, 0.00032426109337843134813, 0.00086123563095007638242, 0.00046858791450944800496, 0.0055934740677286293176},
00193   {0, 0, 0, 0, 0, 0, 0, 0, 1.8177576283415954883, 0.90124364385162747393, 1.0058576108118726378, 0.97434013632935245752, 0.75135849774137752899, 0.090012990328703759713, 1.1491738867249043921}
00194   };
00195 double CSCTFPtMethods::AB_mu12RME11[4][15] = 
00196     {
00197   {0, 0, 0, 0, 0, 0, 0, 0.27354810039733407079, 0.25530642585169710523, 0.2281232078009739761, 0.20002002697391027541, 0.18418628467434680629, 0.1691868825133146792, 0.15081083142497944682, 0.11470950819931940989},
00198   {0, 0, 0, 0, 0, 0, 0, -0.16735504499789077837, -0.15229365225374749682, -0.12925824722117412735, -0.10394284592720609561, -0.093240817997744127044, -0.073171468346305876262, -0.088574463929812302654, -0.066404461904397707461},
00199   {0, 0, 0, 0, 0, 0, 0, -0.00050299673411093688211, 5.1602356927429220493e-05, -3.0794024894263357945e-05, 0.0004052733857930102164, -7.420268691546845442e-05, 0.00011377542095117624751, 0.002401982811750403863, 0.0024540507098964291222},
00200   {0, 0, 0, 0, 0, 0, 0, 1.1883256550892249415, 1.1930557391196678907, 1.1956122499877577248, 1.2507536548522568687, 1.1818664879149434199, 0.74072892184538741134, 0.4975999389532442807, 1.0630008076007997353}
00201   };
00202 double CSCTFPtMethods::AB_mu13RME11[4][15] = 
00203     {
00204   {0, 0, 0, 0, 0, 0, 0, 0.28630621682529061589, 0.29827733143141249572, 0.27230375589683164517, 0.23990484313749371736, 0.21461969319969206871, 0.20904691221965984727, 0.17455215996464093497, 0.10530528191221873169},
00205   {0, 0, 0, 0, 0, 0, 0, -0.21320341298073050562, -0.27792002471345611525, -0.22893879370711203713, -0.17267579393860862935, -0.13655560753368203852, -0.13221415752155918355, -0.092817386598587681146, -0.047633722138851357364},
00206   {0, 0, 0, 0, 0, 0, 0, 0.0012300659344863943204, -0.00026218872327451808128, -0.00020411464851349467309, 8.8191777702590311294e-05, 0.00044047024925421437123, -0.00067348979494906663183, 0.0026726730924768165448, 0.0067869186945352134865},
00207   {0, 0, 0, 0, 0, 0, 0, 1.2315550372405590362, 0.86296110777082257748, 0.94745955410457627366, 1.0617206089293684812, 1.0876186592684131682, 0.81349751399897141102, 0.51174005862466220851, 1.3970393153313427348}
00208   };
00209 double CSCTFPtMethods::AB_mu14RME11[4][15] = 
00210     {
00211   {0, 0, 0, 0, 0, 0, 0, 0.2321760802583729133, 0.17425716826944270821, 0.28951128850821888916, 0.26122027532891867185, 0.23988161223010590062, 0.21857963541150710052, 0.15353493229255876784, 0.09952290576921750398},
00212   {0, 0, 0, 0, 0, 0, 0, -0.20453745460356828612, -0.15291198577104561651, -0.370982786914061613, -0.27553292468971468665, -0.22166866616439959148, -0.17253577136118664059, -0.10047612457180872536, -0.044726719317877430826},
00213   {0, 0, 0, 0, 0, 0, 0, 0.0075216673069431437548, 0.0091493927899154794958, -0.00026846347496581161613, -0.00028436379808289408404, -0.00033797061806371863149, -0.00032290147294330767604, 0.0043983126453711971632, 0.0087398021641503856327},
00214   {0, 0, 0, 0, 0, 0, 0, 1.4021232447364970763, 1.6613910381816205941, 0.73820877609189006208, 0.87917756535000690654, 0.86376276633863802168, 0.64791792386852542496, 1.0974109668506901727, 1.475947804634221372}
00215   };
00216 double CSCTFPtMethods::AB_sig12FnoME11[4][15] = 
00217     {
00218   {0, 0, 0, -0.0076412310580529349199, 0.013106555291144636813, 0.025063779434470568469, 0.0087226608724667777789, -0.0012964802596261630445, 0, 0, 0, 0, 0, 0, 0},
00219   {0, 0, 0, 0.11492024270448454593, 0.021102150917381608253, -4.2436183419689021967e-08, 0.072972237191400349254, 0.19729003982512077764, 0, 0, 0, 0, 0, 0, 0},
00220   {0, 0, 0, 0.0021104070024291496713, 0.0018253795336503611177, 0.0016311827288382637312, 0.0024898068482018614021, 0.0023171447579502014481, 0, 0, 0, 0, 0, 0, 0},
00221   {0, 0, 0, 0.90082232171804188514, 1.4715701060292549762, 0.38179435996930433106, -0.31089206041852102125, -1.8605481532163505864, 0, 0, 0, 0, 0, 0, 0}
00222   };
00223 double CSCTFPtMethods::AB_sig13FnoME11[4][15] = 
00224     {
00225   {0, 0, 0, -0.013922695503875197331, -0.0018020343253406317062, 0.017121560844724798001, 0.018609272384097541586, -0.0050380425848817458542, 0, 0, 0, 0, 0, 0, 0},
00226   {0, 0, 0, 0.36952186524609842433, 0.29771940602043445168, 0.25881377301982183559, 0.21522443888607742379, 0.59520725339836588752, 0, 0, 0, 0, 0, 0, 0},
00227   {0, 0, 0, 0.0021171146723497585689, 0.001962910013039776292, 0.0016295699065661407162, 0.0017542445121842159018, 0.0018291018059847885362, 0, 0, 0, 0, 0, 0, 0},
00228   {0, 0, 0, -0.24903532893487495548, -0.20762623792196052697, -1.23723285975173658, -0.93877564336741559092, -2.7137466589111389759, 0, 0, 0, 0, 0, 0, 0}
00229   };
00230 double CSCTFPtMethods::AB_sig14FnoME11[4][15] = 
00231     {
00232   {0, 0, 0, 0, -0.049226069782944893716, -0.05447625811386536121, 0.024782117383430092572, 0.0087723204390127967195, 0, 0, 0, 0, 0, 0, 0},
00233   {0, 0, 0, 0, 0.96194395556167033856, 1.9107390804546595664, 0.10243277620694382635, 0.29010825363315317915, 0, 0, 0, 0, 0, 0, 0},
00234   {0, 0, 0, 0, 0.0025849149683154332667, 0.0022908589943121454233, 0.0017080431015829389101, 0.0022045212844627971524, 0, 0, 0, 0, 0, 0, 0},
00235   {0, 0, 0, 0, -1.2932328975948934602, -4.7562023014669927434, 0.78711144534012145169, -0.57517454556474645333, 0, 0, 0, 0, 0, 0, 0}
00236   };
00237 double CSCTFPtMethods::AB_sig12RnoME11[4][15] = 
00238     {
00239   {0, -0.024837587047074519142, -0.038443755326854262, 0.010789426545740953695, 0.016714316978066363906, 0.036977680482507623017, 0.023903736191005935108, 0, 0, 0, 0, 0, 0, 0, 0},
00240   {0, 0.44916461963533510504, 0.54293566642571933212, 0.018977673263371359902, 0.007932079958008179596, -9.4309201558850225267e-08, 5.2699963039304353885e-09, 0, 0, 0, 0, 0, 0, 0, 0},
00241   {0, 0.0022745078222873717048, 0.0026499504248443657255, 0.0019347176520538985831, 0.0018882668324742895791, 0.0015313004238581028917, 0.0027721700163088574924, 0, 0, 0, 0, 0, 0, 0, 0},
00242   {0, -0.87241910961768964761, -1.0549928243465211963, 1.8999999999485288615, 1.6191292705343984792, -0.63912490618228612327, 0.6398194632982362462, 0, 0, 0, 0, 0, 0, 0, 0}
00243   };
00244 double CSCTFPtMethods::AB_sig13RnoME11[4][15] = 
00245     {
00246   {0, 0, 0, 0.0036225404374523491324, 0.020602869778294785608, 0.031371735116656827846, 0.044385023713376312027, 0, 0, 0, 0, 0, 0, 0, 0},
00247   {0, 0, 0, 0.40723755341312423139, 0.24719809506286585798, 0.23886286984905105713, 0.092388265632692603835, 0, 0, 0, 0, 0, 0, 0, 0},
00248   {0, 0, 0, 0.0018900875181423510037, 0.0016683560130446085414, 0.0015517088923086459762, 0.0014400104759778459274, 0, 0, 0, 0, 0, 0, 0, 0},
00249   {0, 0, 0, -0.50487582216370696653, -0.21797446389232158492, -0.76054681766358056549, -0.16793042826918122556, 0, 0, 0, 0, 0, 0, 0, 0}
00250   };
00251 double CSCTFPtMethods::AB_sig14RnoME11[4][15] = 
00252     {
00253   {0, 0, 0, -0.035861540596622137889, -0.1163451242952821818, -0.3223054960806409075, 0.028427718090213778546, 0, 0, 0, 0, 0, 0, 0, 0},
00254   {0, 0, 0, 0.91272061044138930175, 1.0649835191592700312, 3.75045883898615795, 0.20554379357162461117, 0, 0, 0, 0, 0, 0, 0, 0},
00255   {0, 0, 0, 0.0023100741888551377598, 0.0065631885708627574205, 0.010122343115052657297, 0.0021541859801294522929, 0, 0, 0, 0, 0, 0, 0, 0},
00256   {0, 0, 0, -0.85246870399928331707, -1.26158946908596592, -4.209205295019181392, 0.071706289987386498397, 0, 0, 0, 0, 0, 0, 0, 0}
00257   };
00258 double CSCTFPtMethods::AB_sig12FME11[4][15] = 
00259     {
00260   {0, 0, 0, 0, 0, 0, 0, 0.05458876370405055245, 0.014223815371885261197, 0.051739718849001303802, 0.0043781295277517066206, -0.073251670679359628946, 0.016350518117378025351, 0.024953176408713924339, 0.018013937106717257258},
00261   {0, 0, 0, 0, 0, 0, 0, -0.037781377479947614306, 0.80848693770251023327, 0.1697030494994675176, 0.78252633158781936817, 1.2537997106918414847, 0.10612967759966565606, -9.206320800321521336e-08, 2.2213840653040328732e-07},
00262   {0, 0, 0, 0, 0, 0, 0, 0.0013753615162960116606, 0.0017341536986479849473, 0.0013675349666495530479, 0.0017609996279085446749, 0.0046166207484297843919, 0.00495761383888420476, 0.0050988257402144569752, 0.0064203615570604640264},
00263   {0, 0, 0, 0, 0, 0, 0, 1.8999999999988979038, -3.2324234827503541823, -0.81829590015205422304, -2.7507108181454631435, -1.7359928981630718958, 0.40689058927975751967, 1.4828812725128097672, 1.5951851243514818535}
00264   };
00265 double CSCTFPtMethods::AB_sig13FME11[4][15] = 
00266     {
00267   {0, 0, 0, 0, 0, 0, -0.19347059395018284533, 0.072568004970527941189, 0.08577237659734933406, 0.078682638529076837086, 0.077062920521249994588, 0.080098726616512086474, 0.023748955156449799708, 0.015834208336261056116, -0.021587059944354128338},
00268   {0, 0, 0, 0, 0, 0, 2.6546929735503304038, -0.040973653768088071081, -0.063777717641833361895, -0.050952537148763105135, -0.044007209248372716748, -0.044262064708301115945, 0.29785332091460725579, 0.71835272096206526093, 0.65633476797761147736},
00269   {0, 0, 0, 0, 0, 0, 0.0065104044193550428959, 0.0011700415681633554756, 0.00045437269348538639104, 0.0008801332589677031415, 0.00078367838118213598627, 0.00060453583918787642728, 0.004657287607776092013, 0.0037849066904824596111, 0.0061259831222526071187},
00270   {0, 0, 0, 0, 0, 0, -4.9999999979557490093, 1.1707517726253902079, 1.0992454619450249265, 1.2206213897813062985, 1.2578764060460077001, 1.3625276752124573232, -1.0956263938322794438, -2.8508701454429501432, -2.1472735770040620729}
00271   };
00272 double CSCTFPtMethods::AB_sig14FME11[4][15] = 
00273     {
00274   {0, 0, 0, 0, 0, 0, 0, 0, 0.0011704660991897508117, 0.084739514416067682201, 0.086139578586588813613, 0.093199773864805768309, 0.0068597584931722067197, 0.073137137801632320921, -0.024117519905137906056},
00275   {0, 0, 0, 0, 0, 0, 0, 0, 0.7338374554546823747, -0.036989032906862853722, -0.038391760412970953042, -0.046077469375633541004, 0.62423005995004055002, -0.040314539852839455236, 0.63248947781334297069},
00276   {0, 0, 0, 0, 0, 0, 0, 0, 0.0031924502818212936207, 0.0010331185400558220815, 0.0010342430652703427443, 0.00092674943585657754141, 0.0050760196464007447531, 0.0032319531506008868788, 0.0067125188107654068514},
00277   {0, 0, 0, 0, 0, 0, 0, 0, -1.785448670968939, 1.3255257799041022526, 1.3571670682651415518, 1.3337095100618956423, -2.0375413343465438309, 1.4881244856244408847, -1.5048835864460361478}
00278   };
00279 double CSCTFPtMethods::AB_sig12RME11[4][15] = 
00280     {
00281   {0, 0, 0, 0, 0, 0, 0, 0.029083895221947490134, 0.02931261189231387787, -0.035917405392017993926, 0.02606608527812858539, -0.032213952425992904705, 0.034901077580037881409, 0.038079609520293045133, -0.087892299038559315583},
00282   {0, 0, 0, 0, 0, 0, 0, 0.41762122325588330041, 0.24571503336772770876, 1.382448398827999192, 0.59561568267877507132, 1.3203480961328621923, -2.9132130347376411494e-08, -4.2309101866118761781e-07, 1.3315902017409027014},
00283   {0, 0, 0, 0, 0, 0, 0, 0.0019308246518827238379, 0.0018496885043595501577, 0.0027736328929315792052, 0.0017558352623714590553, 0.0025111400562270263202, 0.0029777661938234362138, 0.0043603459843407146868, 0.0076843830249820627848},
00284   {0, 0, 0, 0, 0, 0, 0, -2.0511755338229731294, -0.82689722791688569092, -4.4494753588966791114, -2.9771639615408234114, -4.4060610830752349187, 0.96642022916504122243, 0.27488639218488036819, -4.9999999999412514384}
00285   };
00286 double CSCTFPtMethods::AB_sig13RME11[4][15] = 
00287     {
00288   {0, 0, 0, 0, 0, 0, 0, 0.069382927814675421363, 0.062546773192992718982, 0.066219648548532128451, 0.066114165177748651647, 0.06496853782135392219, 0.051540701102725301752, -0.14520516691085255667, -0.029300158926639723045},
00289   {0, 0, 0, 0, 0, 0, 0, -0.03808324381918145457, -0.02868588030414172263, -0.031288010457747920945, -0.030725505585511597717, -0.02843978176922726947, 8.9697287389278734793e-07, 1.7723836220217532578, 0.79014048067174824652},
00290   {0, 0, 0, 0, 0, 0, 0, 0.00031828670642815944016, 0.0012881264558822541535, 0.00092903731815034164537, 0.0011795342397226430894, 0.00083538336551440930174, 0.0027329868075334912136, 0.0097615976891543883992, 0.0062076155203765765594},
00291   {0, 0, 0, 0, 0, 0, 0, 1.3727842579605455953, 1.5374702505093122973, 1.4476836940454602676, 1.4342564093482235155, 1.3613055874742052698, 0.85184697646817630901, -3.994547310920665506, -2.8070031114324471844}
00292   };
00293 double CSCTFPtMethods::AB_sig14RME11[4][15] = 
00294     {
00295   {0, 0, 0, 0, 0, 0, 0, 0.082096556211616628085, -0.15497763380540566236, 0.077768957501462190884, 0.079360215708304482352, 0.070390471145737557035, 0.045116756706396796139, -0.064677235510244679428, 0.042981004219577227665},
00296   {0, 0, 0, 0, 0, 0, 0, -0.046354224360547445494, 3.4600023508388892957, -0.029070628904851493479, -0.030476400557346697284, -0.023356274628402451388, 0.42581998625965733485, 1.1914459601216282891, 0.11545316275932009098},
00297   {0, 0, 0, 0, 0, 0, 0, 0.0018078552644396556418, 0.0040218048707196616537, 0.00086395925657936829302, 0.0010071336547866846251, 0.0010978456712284635072, 0.002842508081006394835, 0.0071491121214516993934, 0.0050018422461340821331},
00298   {0, 0, 0, 0, 0, 0, 0, 1.2752968417470296192, -4.9999999984414591481, 1.5920301262211007387, 1.5139579024840714716, 1.5241944165676217793, -2.2799951898153256735, -3.0288054012274616689, -0.35716168503710210569}
00299   };
00300 double CSCTFPtMethods::AB_mu12F[4][15] = 
00301     {
00302   {0, 0, 0, 0.089491067646809183134, 0.10739646024310070538, 0.12549844133338972085, 0.1194760053165676017, 0.30626893792235526659, 0.30009410052196983099, 0.2690532347360728993, 0.23688757461948814487, 0.21899489554680626191, 0.21285418228245533978, 0.15525112596260939868, 0.1770936851403528689},
00303   {0, 0, 0, -0.16463359422729287318, -0.18522613297525072906, -0.17065296570525056996, -0.1155394236109319045, -0.18380971440851143206, -0.1859966131117936905, -0.15845841533583629457, -0.12868208564229521862, -0.11875959710980291129, -0.13461549793851387835, -0.090885866696312114787, -0.14347961143957646546},
00304   {0, 0, 0, 5.0479701928535670313e-06, -8.5107255627149016024e-05, -0.00031591725812981632723, -0.00010313307150067754737, 6.1998863886012596167e-05, 3.5535741450015050427e-05, -0.00033034534768735314718, 0.00025570884563717226432, -3.2430491772480606483e-05, -3.928192779951495588e-05, 0.0028259336045576349469, -0.00124297387660909117},
00305   {0, 0, 0, 1.6276716966428210753, 1.1244502885068945464, 0.44061802755260442988, 0.68081944372417602107, 1.2892912513078853554, 1.2098030702058406582, 1.2406526312160988113, 1.2588644895814975477, 1.2343544778925670258, 0.59901494992516879368, 0.9845753793507600049, 0.72134724334000244195}
00306   };
00307 double CSCTFPtMethods::AB_mu13F[4][15] = 
00308     {
00309   {0, 0, 0, 0.11794009048617049018, 0.14086291718874013879, 0.16139997805131156561, 0.15937656116892420788, 0.34414162356457134173, 0.34440937003010801964, 0.31471704006829814837, 0.27226322158180205069, 0.24550847587442392594, 0.24463956799494918082, 0.16276628030235296141, 0.183078101259807835},
00310   {0, 0, 0, -0.33781826981928775311, -0.37684193029815427067, -0.3462789133929889962, -0.25060466660909758163, 0.99999999999361011138, -0.31182750009024823301, -0.25849818207822566896, -0.19230025423676194718, -0.15638199224610474514, -0.1860677216141479462, -0.089736178206281214109, -0.12591247971454427867},
00311   {0, 0, 0, -1.8754239266677112923e-05, -0.00019673769085880689952, -0.00052669062346466261493, -0.00030449439108233132979, 0.00071230918348081078556, -0.00045941836356435766754, -0.00045256277284001311754, 0.00064215185932415489584, 0.00046541851817373622747, 0.00019049878005133037782, 0.0043442731774379211851, 0.0015460291314785047125},
00312   {0, 0, 0, 1.2452803747346312679, 0.74944265252708708314, 0.37224767027460281543, 0.31339057767893530038, -2.0890914872066272956, 0.95830873379506731347, 1.0457163419608694888, 1.1230565694613476868, 1.1770351235140514845, 0.65014435708651741042, 1.129972103442078657, 0.68378819802357770907}
00313   };
00314 double CSCTFPtMethods::AB_mu14F[4][15] = 
00315     {
00316   {0, 0, 0, 0.12104944074518421415, 0.10503732418316034936, 0.099386285225076712035, 0.15823526186568545593, 0.25605688745800425643, 0.39267951247468363407, 0.32990417209085837191, 0.29155610498631334693, 0.25993455189370084923, 0.27876104145873625839, 0.17123500452830145435, 0.1377101784898823178},
00317   {0, 0, 0, -0.34834159047255092156, -0.3100051372552997675, -0.19689884687529440876, -0.42846101907983596968, -0.19825501228941203036, -0.69127391031064666649, -0.37799519092326222536, -0.2813623780771447036, -0.21851172477385713555, -0.29451256139301251746, -0.11968566909919842178, -0.082430041079910781887},
00318   {0, 0, 0, 0.0006127466960683334565, 0.0018163416142308417157, 0.0023773788535300438216, 0.0015618030372482551073, 0.0074745015886553429346, 0.018200042017815356438, -0.00044263832599834499045, -0.00013173112084098321899, 0.00048044142847010538715, -0.00028331509653057088387, 0.0047044170533411542104, 0.0077579174433774081635},
00319   {0, 0, 0, 1.8999999999207801693, 1.3811827661042299642, 1.361253443017911513, 0.16448981101549500772, 1.7211759130995385458, 0.30399083099267765196, 0.92381972077138352351, 0.98949705099683071818, 1.0305604944719717331, 0.18365768267421325732, 0.96525152167887728893, 1.1235655996998157313}
00320   };
00321 double CSCTFPtMethods::AB_mu12R[4][15] = 
00322     {
00323   {0, 0.1017548888755877845, 0.13020457985822880831, 0.11777472840868662141, 0.1352735458205116259, 0.14797523226644127003, 0.14891234013414389459, 0.27354809992824791198, 0.25530642162633726544, 0.22812303598569572127, 0.20002002697417936572, 0.18418627647990021279, 0.16918688305075030298, 0.1508108314248207682, 0.11470950874198342084},
00324   {0, -0.40835812179222591434, -0.4909339449226597929, -0.19396964458569518341, -0.18405457126044733052, -0.15348184403810183341, -0.11949446624665205352, -0.16735504431990988472, -0.15229364636923176102, -0.1292580848284842765, -0.10394284592826465163, -0.093240808678399900167, -0.073171468194201616519, -0.088574463928718608074, -0.066404462713869835677},
00325   {0, -0.00046324193156588387276, -0.0012328343527384165272, 5.8536010291841255454e-05, 5.3175743777652564014e-05, -0.00027992198289290446886, 0.00017291608058844862988, -0.00050299670363365375, 5.1602382309461525441e-05, -3.0783724988483899057e-05, 0.00040527338575157016622, -7.4202404535834238977e-05, 0.00011377538633743067547, 0.0024019828117533849852, 0.0024540507720086741569},
00326   {0, 0.82326825991227925439, 0.66225151266154569374, 1.6047267765109303195, 1.172660602794620921, 0.91611151466846096891, 0.923434361821059424, 1.188325655620871224, 1.1930557749505621423, 1.1956156176382155554, 1.2507536548585385106, 1.1818666483459900896, 0.74072890966654614253, 0.49759993894696635808, 1.0630007937555521202}
00327   };
00328 double CSCTFPtMethods::AB_mu13R[4][15] = 
00329     {
00330   {0, 0, 0, 0.17152643870188713504, 0.18220699353677527466, 0.19718061346676321599, 0.20409261783490945108, 0.28630621673439216046, 0.29827733143097401314, 0.27230375589695204885, 0.23990484313734378174, 0.21461969319950535695, 0.20904691238932027186, 0.17455215996309358939, 0.10530527961885094435},
00331   {0, 0, 0, -0.51329151983333287657, -0.43421697939765058205, -0.38701854807672181336, -0.29367743292763504037, -0.21320341238440754239, -0.27792002471255045082, -0.22893879370744105173, -0.17267579393834603385, -0.13655560753345002967, -0.13221415770245384391, -0.092817386598829765276, -0.047633719610788972931},
00332   {0, 0, 0, -0.00028330256767296205581, -0.00011104889576832950495, -0.0003659472931155986178, -0.0004494825869971541348, 0.0012300659193085917292, -0.00026218872326014996304, -0.00020411464851317293609, 8.8191777707538176329e-05, 0.0004404702492616239173, -0.00067348981143074907862, 0.0026726730925728564743, 0.0067869187519593900115},
00333   {0, 0, 0, 1.0806773148892279135, 0.81710737240426545291, 0.49165515886235822141, 0.40288815951359424616, 1.2315550399117412006, 0.86296110777384626989, 0.94745955410233306804, 1.0617206089312878348, 1.0876186592703975808, 0.81349751271060222191, 0.51174005866205685145, 1.3970393581376403525}
00334   };
00335 double CSCTFPtMethods::AB_mu14R[4][15] = 
00336     {
00337   {0, 0, 0, 0.11411457974213083666, 0.14612498789299999125, 0.15438328053344949065, 0.17021962182813230036, 0.23217608026225655671, 0.17425716827684778476, 0.28951128865791975198, 0.26122027861775976021, 0.23988161223077880679, 0.21857963541170638555, 0.15353493229270298581, 0.099522853724256579722},
00338   {0, 0, 0, -0.32211539883453449429, -0.3332077022119345755, -0.28947013547326555516, -0.31678412927379157038, -0.20453745460807634671, -0.15291198578472323111, -0.37098278728491984602, -0.2755329314623077841, -0.22166866616574540383, -0.17253577136159981009, -0.10047612457203594638, -0.044726394456946053091},
00339   {0, 0, 0, 0.0021189308480414714535, 0.0017232488622970817526, 0.0014181868364706309241, 0.0020581588744611055593, 0.0075216673068132632735, 0.0091493927895737042766, -0.00026846347791510813061, -0.00028436387259422706009, -0.00033797061809048655314, -0.00032290147294203845477, 0.0043983126453652227755, 0.0087398105487928243185},
00340   {0, 0, 0, 1.8999999998213816799, 1.8999999999320695832, 1.2588510283946776624, 0.91969335359675130626, 1.402123244759204912, 1.6613910381353069745, 0.73820877543905039087, 0.87917754884863041909, 0.86376276633290960394, 0.6479179238685032205, 1.0974109668483333913, 1.4759522529227795395}
00341   };
00342 double CSCTFPtMethods::AB_sig12F[4][15] = 
00343     {
00344   {0, 0, 0, -0.0076412310580529349199, 0.013106555291144636813, 0.025063779434470568469, 0.01934375127428624927, 0.053326545670601563365, 0.0093197497326487303143, 0.0564902513339693782, 0.032206519204039697757, -0.035023660563668873591, 0.028213900213068406758, 0.022784114759202493683, 0.042615038347082211112},
00345   {0, 0, 0, 0.11492024270448454593, 0.021102150917381608253, -4.2436183419689021967e-08, 1.3095720405656430252e-08, -0.037472879155788924033, 0.84044166517252949511, 0.15966830269465748238, 0.37149319186299001316, 0.84416754574977770353, 0.033343799149249016278, 6.6539790067633719506e-08, -1.3686068460749822862e-06},
00346   {0, 0, 0, 0.0021104070024291496713, 0.0018253795336503611177, 0.0016311827288382637312, 0.0021015267562687076422, 0.0014715412047011698984, 0.0018518237493182830404, 0.0011606808553826068482, 0.0013698268430796098002, 0.0034437807938464026943, 0.004439146916271847175, 0.0056493862115556715831, 0.0036722950074267479183},
00347   {0, 0, 0, 0.90082232171804188514, 1.4715701060292549762, 0.38179435996930433106, 0.90052675260749392994, 1.8999999999893364411, -3.1887755118603267057, -0.93952603198035322674, -1.4200273548894686293, -1.3313935786554595975, 0.84940608722578914147, 1.5495399676596248728, 0.1693217499087649458}
00348   };
00349 double CSCTFPtMethods::AB_sig13F[4][15] = 
00350     {
00351   {0, 0, 0, -0.016313221502792758094, -0.0012344271616210600317, 0.022739050214132340566, 0.019894322103056659434, 0.070152538754905693907, 0.079150371235280320148, 0.079140295486563524974, 0.073877518420634002982, 0.082767871936852088766, 0.021369139940037504971, -0.16477473035652481781, -0.055605012351420450567},
00352   {0, 0, 0, 0.40633016978672931163, 0.31906794350617523337, 0.18604815325310422591, 0.22274309425577301647, -0.038098997442242876765, -0.054611240400435009934, -0.050739779309414811959, -0.040691137768363160043, -0.046730053313388586478, 0.34160850069918163863, 2.4811837846155828657, 1.1192582255168381788},
00353   {0, 0, 0, 0.002149342213264975824, 0.0019487436377840527436, 0.0015505100309095498287, 0.0017303935347270330437, 0.0012782681837905638701, 0.00077081684260600570775, 0.00078212255888550081661, 0.00085709016208379811951, 0.00040671635301994584974, 0.0047052241934661294398, 0.0091387563643038176309, 0.0065810423040581775625},
00354   {0, 0, 0, -0.47422656465701568118, -0.40214476680739164038, -0.807446632577722756, -1.1159653538458467192, 1.1939302604989951995, 1.2565879679975411332, 1.2135620508983242516, 1.3126461466411822876, 1.3303466630446105778, -1.3225160658785197754, -4.99999996608921915, -3.3146932668018336265}
00355   };
00356 double CSCTFPtMethods::AB_sig14F[4][15] = 
00357     {
00358   {0, 0, 0, -0.023008179953388042255, -0.087196623845599563474, 0.014221968418245287125, -0.021787486380662964697, 0.066204099694590276548, 0.13000102518515968542, 0.086982120087735009806, 0.086006702272218293892, 0.090001124258988041138, 0.013343436845426187576, 0.058197437679117815235, 0.015055422275464733217},
00359   {0, 0, 0, 0.58165240914811378037, 1.6572607614650631813, 0.26374858984348420465, 0.56929114216912790614, -0.031761470721266109318, 6.8045996289272520086e-06, -0.040675205849149999315, -0.038282822732629118168, -0.041914122856581741139, 0.73743983985226857492, -0.015956321538818291073, 0.31976184596833290286},
00360   {0, 0, 0, 0.0021194192496740956247, 0.0031051396726804536899, 0.0016030344438190185716, 0.0037337124950505506081, 0.00038923034858751352164, 0.00435858958532461295, 0.00085195563700394898957, 0.0011709394391764601367, 0.0007183252935922569693, 0.0048589598885515790372, 0.0035711294225182332179, 0.0063024666771318840416},
00361   {0, 0, 0, -0.11185686895850970035, -2.8414639600328577274, -0.10356160152745381986, -1.2383039973901615038, 1.8999999999999264144, -1.1268332104959208895, 1.3399041969100440319, 1.3441201753115872286, 1.4026191965547902818, -2.9935330315178338978, 1.8045262655928504536, -1.0659192090967317679}
00362   };
00363 double CSCTFPtMethods::AB_sig12R[4][15] = 
00364     {
00365   {0, -0.024837587047074519142, -0.038443755326854262, 0.010789426545740953695, 0.016714316978066363906, 0.036977680482507623017, 0.023903736191005935108, 0.029083895240537907534, 0.029312604029813168344, -0.035917405187485026974, 0.026066086885230148329, -0.032213952427413247714, 0.034901078113956519877, 0.038079760873761171747, -0.087892299405550919356},
00366   {0, 0.44916461963533510504, 0.54293566642571933212, 0.018977673263371359902, 0.007932079958008179596, -9.4309201558850225267e-08, 5.2699963039304353885e-09, 0.41762122295566816987, 0.24571510737505500299, 1.3824483935622682296, 0.59561566602531357262, 1.3203480960823190671, -2.930413320681446443e-08, 6.1897109794855492693e-08, 1.3315902039120812717},
00367   {0, 0.0022745078222873717048, 0.0026499504248443657255, 0.0019347176520538985831, 0.0018882668324742895791, 0.0015313004238581028917, 0.0027721700163088574924, 0.0019308246515342586576, 0.0018496886131083114559, 0.0027736328912367847269, 0.0017558352148668789246, 0.0025111400562838814485, 0.0029777661392665598361, 0.0043603280275831372836, 0.0076843830377456264283},
00368   {0, -0.87241910961768964761, -1.0549928243465211963, 1.8999999999485288615, 1.6191292705343984792, -0.63912490618228612327, 0.6398194632982362462, -2.0511755324568126113, -0.82689751226606089674, -4.4494753423464956654, -2.9771639242617897736, -4.40606108289291587, 0.96642021015404266926, 0.27486695110845749124, -4.9999999999409219242}
00369   };
00370 double CSCTFPtMethods::AB_sig13R[4][15] = 
00371     {
00372   {0, 0, 0, 0.0036225404374523491324, 0.020602869778294785608, 0.031371735116656827846, 0.044385023713376312027, 0.069382928901304388725, 0.062546773237833669379, 0.066219648548455148362, 0.066114165216842671335, 0.064968538738919279218, 0.051540701111634862341, -0.14520516686903245374, -0.029300157343301824753},
00373   {0, 0, 0, 0.40723755341312423139, 0.24719809506286585798, 0.23886286984905105713, 0.092388265632692603835, -0.038083245108582644556, -0.028685880355116981366, -0.031288010457665590969, -0.03072550558016601957, -0.028439782714834840882, 8.984728870169156334e-07, 1.7723836216527502074, 0.79014046453097108724},
00374   {0, 0, 0, 0.0018900875181423510037, 0.0016683560130446085414, 0.0015517088923086459762, 0.0014400104759778459274, 0.00031828667387254205856, 0.0012881264560692922555, 0.00092903731815355522061, 0.0011795342366973096335, 0.00083538332113278278117, 0.0027329868075049237874, 0.0097615976878032660602, 0.0062076155003686038503},
00375   {0, 0, 0, -0.50487582216370696653, -0.21797446389232158492, -0.76054681766358056549, -0.16793042826918122556, 1.3727842428768588512, 1.5374702497476731011, 1.4476836940468174042, 1.4342564113548856852, 1.3613055688979065483, 0.85184694861412824096, -3.9945473104690254473, -2.8070030811132413717}
00376   };
00377 double CSCTFPtMethods::AB_sig14R[4][15] = 
00378     {
00379   {0, 0, 0, -0.035861540596622137889, -0.1163451242952821818, -0.3223054960806409075, 0.028427718090213778546, 0.082096556211394805525, -0.15497655162567502973, 0.077768957491548482142, 0.079360069813406791672, 0.070390471478570457164, 0.045116757562121037606, -0.064677236200079091244, 0.042980998502111025794},
00380   {0, 0, 0, 0.91272061044138930175, 1.0649835191592700312, 3.75045883898615795, 0.20554379357162461117, -0.046354224360297492658, 3.4599916691801695379, -0.029070628890768772379, -0.03047627128290695056, -0.02335627487211913364, 0.42581999019359662029, 1.1914459601497096042, 0.11545322117611778179},
00381   {0, 0, 0, 0.0023100741888551377598, 0.0065631885708627574205, 0.010122343115052657297, 0.0021541859801294522929, 0.0018078552644429368712, 0.0040217835853228389373, 0.00086395925415043829752, 0.0010071371561587601478, 0.0010978456762463116234, 0.0028425080621485550661, 0.0071491121463381828924, 0.0050018423505071209906},
00382   {0, 0, 0, -0.85246870399928331707, -1.26158946908596592, -4.209205295019181392, 0.071706289987386498397, 1.2752968417552010827, -4.9999999999938600226, 1.5920301264071463621, 1.5139604617023065813, 1.5241944088777494848, -2.2799952377707408679, -3.0288053889674522168, -0.35716203827983550312}
00383   };
00384 double CSCTFPtMethods::AB_mu23[4][15] = 
00385     {
00386   {0, 0, 0.040640362633691015648, 0.04143975404558240816, 0.04469283410800238554, 0.050265056377639047436, 0.057855720910264404888, 0.040911062522024761734, 0.054867130272661442103, 0.054846907254368672258, 0.046280965740868151848, 0.038682214878367017497, 0.047358821703414828719, 0.037269955397813366027, 0.015397788631092694522},
00387   {0, 0, -0.30371495175799717581, -0.27234040198084696893, -0.27046501071411871431, -0.26067833814957336314, -0.26954736490580177843, -0.1426457415021130104, -0.23307410221367635961, -0.18779763084602629775, -0.11810763599908662147, -0.072929591279204522558, -0.079006610877654537273, -0.042031527428910676891, 0.46158743398909729549},
00388   {0, 0, -0.00025828047348465653929, -0.00027808828382601912237, -0.00020419752504549583318, -0.00028862468215624839229, -0.00051268154965345151715, 0.00019102278127906206339, -0.00054091437361434690362, -0.00041573301097917752687, -0.000207953040744469843, 0.0001988367837501522125, -0.00031823156270582506067, 0.00033071671524661735465, 0.00045799410811140088724},
00389   {0, 0, 0.72752266254137853974, 1.0478492412845885617, 0.60915246815134527214, 0.26469232068298520488, 0.036425986309331782886, 0.7132004473344412121, 0.4197273677305951578, 0.44676889254736196211, 0.60643361041043153392, 0.7258089895367305644, 0.21165518657016521575, 0.40994342351793594537, -4.9999999982804226306}
00390   };
00391 double CSCTFPtMethods::AB_mu24[4][15] = 
00392     {
00393   {0, 0, 0, 0.053011865513752004508, 0.062832623407280213668, 0.052170541013462037871, 0.041027537810126024631, 0.040854761324689348179, 0.071402550009543430676, 0.076745077029754082965, 0.079391267110108354466, 0.061688220309377483908, 0.067651891693652002613, 0.053009728431201032228, 0.046716301280283124842},
00394   {0, 0, 0, -0.3616747887108062165, -0.45141581345418907434, -0.28705970459229912528, -0.2938013269353861312, -0.27050961323017558291, -0.55762354970371696972, -0.39024523502067204328, -0.31496123297823475085, -0.1983420756482438263, -0.17915991058479247, -0.1008896787182539112, -0.055261431747836577133},
00395   {0, 0, 0, -0.00011948386184051261938, -0.00041171189171825890067, 4.5077223215480308541e-05, 0.00064791923408717482999, 0.00079626044366867831676, -0.00020119232396926791046, -0.00036565327240405023478, -0.00092893743231344070178, -0.00011554026166780945835, -0.00037143262941893379287, 0.00034827979969636918729, 0.00038063971268359605635},
00396   {0, 0, 0, 1.2751116233058998883, 0.70084162417453721439, 0.90478318682312330878, 0.6800676895845826353, 0.50537353022178055362, 0.054689818098332523832, 0.35827703859892973126, 0.37385157757276732404, 0.50609881884151997067, 0.24620464307424153039, 0.33739943648039177893, 0.61708181749152601903}
00397   };
00398 double CSCTFPtMethods::AB_mu34[4][15] = 
00399     {
00400   {0, 0, 0, 0.019865692759581058541, 0.028670254062000518486, 0.0062000769568667634529, 0.059000642112303595954, 0.021075145497371470388, -0.058857073670921543351, 0.022193946634618946789, 0.032900966871925077517, 0.022468452340586538007, 0.017925131684213620187, 0.021562743542542832376, 0.0096332062965229867807},
00401   {0, 0, 0, -0.16028204223466294143, -0.24129340031911647446, -0.12167938296678502963, -0.48887217760468759664, -0.41129235965903232497, -0.0044574375495286568116, -0.20497526229305951251, -0.20945390137984670753, -0.133016919476993567, -0.09164367838969658675, -0.078156831196806775264, -0.027061677954361280235},
00402   {0, 0, 0, -7.2934093657490810247e-05, -0.0005630858306214800782, 0.00056399922304054862787, -0.0014284170932996325277, 0.00026420696996418537115, 0.0019432020683277269335, 5.0465562334091047629e-05, -0.00051405817655614813658, -0.0001476820743599914173, 6.32019763480822774e-05, -0.00034513677440660433691, 0.00057652344564092553817},
00403   {0, 0, 0, 1.4981302006935997007, 0.74196319813429467693, 1.0145720473926143068, -0.61744054266046588531, -0.95877986541993265313, 1.2494500863514628186, 0.39038293713197214085, 0.24923581566989111424, 0.37358913393430570604, 0.3656156971405563616, 0.18480549227136852664, 0.58966094664056056818}
00404   };
00405 double CSCTFPtMethods::AB_mu51[4][15] = 
00406     {
00407   {0.30091153701686212951, 0.21726754617902110933, 0.1456728385238945378, 0.043250093988852815474, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00408   {-0.29502353719653978681, -0.19109266041343297982, -0.12108184175216289702, 0.72288502126591014374, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00409   {0.00012873560389623916068, 4.9291809907909536412e-05, -0.00021151799450913838594, 0.00032645001523661659488, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00410   {1.5787330473223266658, 1.6594505002776189784, 1.8999999999615408974, -4.9999999999974642506, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00411   };
00412 double CSCTFPtMethods::AB_mu52[4][15] = 
00413     {
00414   {0, 0.28757434234141143747, 0.22290303793570814817, 0.17273536730279337448, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00415   {0, -0.42706501927164292054, -0.32770564806566382376, -0.24329418737097086023, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00416   {0, -1.4010615867360699891e-05, -0.00025119211587389166183, 0.0004052999487437024392, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00417   {0, 1.3739531719045416924, 1.2264113571191062046, 1.5786429063982712062, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00418   };
00419 double CSCTFPtMethods::AB_mu53[4][15] = 
00420     {
00421   {0, 0, 0.26147063359849342934, 0.21941755760197284575, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00422   {0, 0, -0.62831662471165483641, -0.5360020970162280296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00423   {0, 0, -0.00054456170542904129128, -5.2823850021272572564e-05, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00424   {0, 0, 0.90160457604797583642, 0.89939017343329996645, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00425   };
00426 double CSCTFPtMethods::AB_mu5[4][15] = 
00427     {
00428   {-21.733893412375444143, -20.005957733042006197, -17.376452159382715479, -17.985193664266713398, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00429   {16.418302072038855499, 13.469008846185953843, 12.429426411511585115, 13.9963454706980297, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00430   {-0.055045848107516816283, -0.040869122792827908275, -0.025980934073070366397, 0.24210701585155450233, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00431   {1.8999999999801029382, 1.7642902553920492004, 1.8222993024358542513, 1.7990108859658437979, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00432   };
00433 double CSCTFPtMethods::AB_sig23[4][15] = 
00434     {
00435   {0, 0, -0.010357268292725162889, -0.016380566175621592839, -0.019840699509577841564, -0.0086381386262834487788, -0.003374013086892733819, -0.011814434815520722527, -0.00084060561010774765417, -0.017179591290799121894, 0.0035639959717427907582, 0.0047700899414562444867, 0.010577222576560912568, 0.02059122419865432041, 0.011800502388303060752},
00436   {0, 0, 0.14187419330052780664, 0.23041504331599421684, 0.31155426692107951459, 0.26259379394895659976, 0.22004268983078550947, 0.34945904479011519195, 0.26666091393686436328, 0.38600077292544848762, 0.18137548923438057136, 0.12968791855407682534, 0.083124796029554012811, 0.010205021983518632739, 0.071807703627737515251},
00437   {0, 0, 0.0021465575441230368842, 0.0022224405572812359205, 0.002251545746496887504, 0.0020929103385102986942, 0.0020355680620528313757, 0.0020702424442080634773, 0.0018383336874655056836, 0.0025004017593913750554, 0.001949774989293934788, 0.001939959052276510592, 0.0017195026729185311498, 0.0017139698182589511305, 0.0019431688340545527453},
00438   {0, 0, 1.0630745945983459677, 0.3265773132215800123, -0.65134529804641994044, -1.0524984197072553282, -1.0511032049676600764, -1.8483720507053891247, -1.3389601882033761449, -1.8551069091565570712, -0.98414331636612584209, -0.6063730875586622604, -0.38865902654376205394, 0.43290122641744543941, -0.53818963658092677793}
00439   };
00440 double CSCTFPtMethods::AB_sig24[4][15] = 
00441     {
00442   {0, 0, 0, -0.019324652110983078085, -0.012002425151063148695, -0.02231499394993846988, -0.020935767372829247601, -0.066886386651832344108, -0.04726302695322702474, -0.04612160370322201941, -0.0015531365858601525916, 0.013723579428071824154, 0.016617430908367349096, 0.030685502798890051251, 0.002966505822064327124},
00443   {0, 0, 0, 0.38549899615915406148, 0.32619220210735977439, 0.34706342932948464064, 0.68304114341992616666, 0.9242780677421167379, 0.9319676477585573382, 0.81979381283063590402, 0.4452794101956150663, 0.25406245303464969343, 0.16553792723142907173, 0.11438558724198649719, 0.32271248995562107353},
00444   {0, 0, 0, 0.0022171043021711415305, 0.0021520852248391748179, 0.0029359514546444223822, 0.0021275297531913790229, 0.0033328143360110804201, 0.0024627396815788253105, 0.0037704003574912637285, 0.0023868429840302176834, 0.0020064709921131366512, 0.0021463956760972590677, 0.0015026596429240307931, 0.0023198792169650144825},
00445   {0, 0, 0, 0.086888271968145289192, 0.019758737551725517878, -0.17987080158763540938, -1.7261300785529098967, -2.6644913692232643498, -2.3141437377987581492, -1.8966055410735647158, -1.2208593823013969004, -0.653071688514877291, -0.34080947192812982571, -0.40136037854760781007, -1.4481957993152787534}
00446   };
00447 double CSCTFPtMethods::AB_sig34[4][15] = 
00448     {
00449   {0, 0, 0, -0.012400659358070893756, -0.009978612935288379282, -0.038466135371859951075, -0.01237181151567546232, -0.055252999880455823389, 0.044965296368124886561, 0.0020215713950015390746, 0.0018486442968475248413, -0.011461744909954231161, 0.00041337329418400558037, 0.013323692621683664444, -0.0011526907758626363416},
00450   {0, 0, 0, 0.11483786317689233247, 0.17614008187718299681, 0.35943587710185270767, 0.31393248752071051255, 0.81003852118825403483, 2.8222370465191132238e-07, 0.15870310756426259102, 0.18489150278200164323, 0.2277514636318530572, 0.10863865522427501586, 0.0081807264119966201232, 0.10304189680104243465},
00451   {0, 0, 0, 0.0023086535455528549819, 0.002110004845191660542, 0.0030013629537848584249, 0.0021561954526101824794, 0.0029044705640973510034, 0.001129264217117841116, 0.0020148575420415437004, 0.0022924616641584912025, 0.0022462281749858711323, 0.001953151997646814745, 0.0022772917353313174016, 0.002205332383050566912},
00452   {0, 0, 0, 1.4465873202620711524, 0.018290937265976234261, -1.0034048194561047129, -1.5842206847979445339, -3.6001627650055127994, 0.54269742517812191718, -0.54629346359450747794, -0.88004590995407039333, -1.0607951764628562596, -0.386770214915317323, 0.73185507165720742329, -0.7791766852022135037}
00453   };
00454 double CSCTFPtMethods::AB_sig51[4][15] = 
00455     {
00456   {0.0019758831360956788901, 0.046577756215196844392, -0.05341714103952534265, 0.038119020055320480822, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00457   {0.85917433021287148431, 3.6326347655629698252e-08, 1.2753791210899891873, -0.02296026572998403209, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00458   {0.0018421521390111581656, 0.0013309336424003853465, 0.0024439910926895226824, 0.00084506127844618638811, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00459   {-2.8012298341138666125, 0.89678691204809468651, -4.9999999999931583616, 1.899999999961135444, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00460   };
00461 double CSCTFPtMethods::AB_sig52[4][15] = 
00462     {
00463   {0, 0.015190485414726475483, 0.029402840059661459332, -0.03788341461455211473, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00464   {0, 0.57880911770054299659, 0.086708840790683153199, 0.96143975820959226564, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00465   {0, 0.0017431812547872745089, 0.0016439557621822475496, 0.0024073931799825833838, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00466   {0, -1.4962480474138397657, 0.43719757342237014486, -2.5570410154645890621, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00467   };
00468 double CSCTFPtMethods::AB_sig53[4][15] = 
00469     {
00470   {0, 0, 0.0048807272389305694088, 0.072311934401593946919, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00471   {0, 0, 0.58247011082391897396, -0.031665576145842380673, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00472   {0, 0, 0.0019289670515048294459, -0.00057867999502623438789, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00473   {0, 0, -1.1919870686056455167, 1.8999999999981564969, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00474   };
00475 double CSCTFPtMethods::AB_sig5[4][15] = 
00476     {
00477   {8.0056375707676412645, 2.9947749309947320207, 1.2367570923503916624, 19.305763753429292962, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00478   {-30.026695140142752649, 8.307837839928444712e-06, -2.4301404809023985365e-06, -99.99999999998537703, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00479   {0.49287055372768900918, 0.59795299802278500945, 0.72517967446074338422, 1.499999999999955147, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00480   {-4.7146152770331735127, -1.6075341775064360128, 0.81763143841002616785, -2.2550678981626472996, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00481   };
00482 double CSCTFPtMethods::AB_rho123F[5][15] = 
00483     {
00484   {0, 0, 0, 0.22630471857151249204, -0.013379305064225920779, -0.095121706310405507168, 0.090200403370782444856, 0.068042852566437661554, 0.079571614226972439687, 0.088219335458001243988, 0.11303324434571153378, 0.10710141493712137251, 0.026455786925147606325, 0.046817553749737651769, 0.039162183157051222437},
00485   {0, 0, 0, -0.10527570667400622251, 0.12879264930099568187, 0.15092684710998546804, 0.007231087835331297814, -0.015515942667432135182, -0.028054920465640682814, -0.025513746642979444335, -0.038661914393439029969, -0.033319542824023648531, 0.017459601922314698513, -0.015147480411169431461, -0.0040274062679487923622},
00486   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00487   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00488   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00489   };
00490 double CSCTFPtMethods::AB_rho123R[5][15] = 
00491     {
00492   {0, 0, 0, -0.50534064712241677508, 0.15886026549683709974, 0.24117112423743908289, 0.19155165906038881807, 0.082144222540501604657, 0.079920425013872073428, 0.10933442504482954183, 0.11216820513068381793, 0.14139192912438111605, 0.081067695752670754228, 0.068628530591297767782, 0.105151142748966267},
00493   {0, 0, 0, 0.4061798017233729241, -0.036885583937586396974, -0.10109132139709975373, -0.093632233538226902758, -0.023232568114674286008, -0.0085349848344330059985, -0.030347560681224468315, -0.04053489453902145434, -0.065178885697974128788, -0.016390211022617402759, -0.016822502733541477155, -0.062227091495819800149},
00494   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00495   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00496   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00497   };
00498 double CSCTFPtMethods::AB_rho124F[5][15] = 
00499     {
00500   {0, 0, 0, -0.58347458948865937867, 0.40592680503129663361, 0.01641809001879873664, 0.11475806753693058859, -0.18048876743928712885, 0.0068468168498605876462, -0.030777506509684072339, 0.054741994048828152009, 0.097187337842417537148, 0.025067334674935798366, 0.075946312071830973656, 0.085523782829277653073},
00501   {0, 0, 0, 0.4258108214245352463, -0.23106738109445768004, 0.052661321450187599524, -0.038151728575192320192, 0.1458955237360785584, 0.024582860384737240111, 0.040630008358215272124, -0.0014353305569224008437, -0.020931085629827921035, 0.029892828324785188088, -0.014638662581363729928, -0.031371352411171941899},
00502   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00503   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00504   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00505   };
00506 double CSCTFPtMethods::AB_rho124R[5][15] = 
00507     {
00508   {0, 0, 0, -0.36581744112230984989, -0.016324931472307423197, -0.208168363607231649, -0.15220265819093764526, 0.049548837240151813455, -0.046656697978846251029, 0.037095174357064712722, 0.035330048922600804095, 0.074157637081893032494, 0.036436813593929799626, 0.14420567874993162061, 0.19071920385708884815},
00509   {0, 0, 0, 0.29009232235255510979, 0.053824155318333753717, 0.11835331987655291208, 0.10356729636019955387, 0.0067230075967922332814, 0.11622283669531324746, 0.0088495323612498635879, 0.010530505354448004701, -0.015216911572413798284, 0.029269517338766565251, -0.060899379503146208736, -0.10887509306211247406},
00510   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00511   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00512   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00513   };
00514 double CSCTFPtMethods::AB_rho134F[5][15] = 
00515     {
00516   {0, 0, 0, -0.18585738888975150696, 0.13519522007618323123, 0.28221167590680890092, 0.18146765887707849707, 0.1244677849160726324, 0.31105116640597857414, -0.16202243055042145348, 0.039896884577315043507, -0.37248330593247946929, -0.17019868779262120606, -0.029323371944494535518, 0.149148671625682544},
00517   {0, 0, 0, 0.14049664985969073649, -0.0029515280689123499225, -0.14984825183404815174, -0.053408519838017261272, -0.055260431588822184201, -0.24961446622059946243, 0.16914774696773446361, 0.026377838114293443439, 0.38350727297664199966, 0.20884886406321828689, 0.088477254929584317478, -0.049311016665284521099},
00518   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00519   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00520   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00521   };
00522 double CSCTFPtMethods::AB_rho134R[5][15] = 
00523     {
00524   {0, 0, 0, -0.32424288544586399308, 0.065574046096960866836, -0.49534925125377193833, -0.41401921450752909859, 0, -0.054897105600349827004, -0.054121337557626672532, -0.29310761272328111904, -0.15103243717763431553, -0.24914325132296299969, 0.07909932691386906134, 0.12529327248093721781},
00525   {0, 0, 0, 0.27459892265632174224, -0.0040433910166926267937, 0.37706697672498318274, 0.4151086501992986566, 0, 0.096654494887792055668, 0.085974946019564915667, 0.29549944312402365298, 0.18974566842525927846, 0.29979099594550706609, 0.0234247525877835025, -0.040829919454425725456},
00526   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00527   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00528   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00529   };
00530 double CSCTFPtMethods::AB_rho234[5][15] = 
00531     {
00532   {0, 0, 0, -0.66569231418957641733, -0.16487806934241325263, -0.31385730203879769196, 0.52187103693478709143, 0.37489404891915861784, 0.29994883232428287689, -0.12176552846395131968, 0.023619718470720949682, -0.1231122737596004324, -0.013562360832243002678, 0.153600562632957377, 0.21939787654152581586},
00533   {0, 0, 0, 0.5208746747250042608, 0.18612484901444453778, 0.27332732398493131409, -0.23999307292846960848, -0.25179957455310036929, -0.18381974435716647021, 0.20095666079537191639, 0.099861239186999406492, 0.23937023494386369671, 0.16677027620912032724, 0.030275177235765518557, -0.0069954356449047749161},
00534   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00535   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00536   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00537   };
00538 double CSCTFPtMethods::AB_rho512[5][15] = 
00539     {
00540   {0, -0.10435343690000213612, 0.057141083389519162217, 0.023329220607928163878, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00541   {0, 0.061466220874112284522, -0.001239563289620342415, -0.028051900619679361049, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00542   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00543   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00544   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00545   };
00546 double CSCTFPtMethods::AB_rho513[5][15] = 
00547     {
00548   {0, 0, -0.089534856488077518843, -0.084337975857153926751, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00549   {0, 0, 0.058028755308100914145, 0.033446616671726735193, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00550   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00551   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00552   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00553   };
00554 double CSCTFPtMethods::AB_rho523[5][15] = 
00555     {
00556   {0, -0.48242311538441046137, 0.25779875833780019345, -0.45638836512748476304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00557   {0, 0.28941463846496195966, -0.15113497713160561897, 0.36832995181674366147, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00558   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00559   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00560   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00561   };
00562 double CSCTFPtMethods::AB_rho51B[5][15] = 
00563     {
00564   {98.146234211833089489, 199.99999999999047873, 199.99591177997166369, -3.3007364270967505249, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00565   {-198.36420128721084666, 199.99999999971919351, -68.130825896452520851, 5.6331862234953877788, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00566   {138.59040321786872596, -199.99999999975074161, -75.103918757648003179, -3.3878388130039773785, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00567   {-35.107257005538130556, -78.172491143917071099, 0.25111444908575936141, 0.62856545928460827444, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00568   {3.1832394351004249522, 4.981276803141434506, 4.5629636390469778817, 1.1898949050757507973, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00569   };
00570 double CSCTFPtMethods::AB_rho52B[5][15] = 
00571     {
00572   {0, -7.746830214751867949, -0.46812267787622985349, -0.41343591928047368489, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00573   {0, 12.920758877131683917, 2.1193678084821674368, 0.85191889903041662091, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00574   {0, -7.1168839095051934507, -2.1008659109588445624, -0.69884960118479577673, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00575   {0, 1.239800569290119725, 0.49720027595717164459, 0.15699136302342500682, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00576   {0, 1.2582151000263612772, 1.2238929501776998343, 0.88233142702097189236, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00577   };
00578 double CSCTFPtMethods::AB_rho53B[5][15] = 
00579     {
00580   {0, 0, 105.35018363918895545, 62.071727282426813588, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00581   {0, 0, -180.24672833591944254, -170.8283169841847382, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00582   {0, 0, 109.89608697213377297, 171.57904987557179766, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00583   {0, 0, -25.005328082184355765, -60.507830469988306277, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00584   {0, 0, 3.0701361165201541681, 4.0540449945183194558, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00585   };
00586 
00587 /*
00588 double CSCTFPtMethods::AB_mu12F[4][15] = 
00589     {
00590   {0, 0, 0, 0.089491197077583115038, 0.10739646114119137665, 0.12484612309276715836, 0.12107457559814104042, 0.32100648056577807399, 0.31559934186960514335, 0.27904201938970829566, 0.24107252259247277659, 0.22375609791218128986, 0.21315488055164613646, 0.15525112328982976218, 0.1770936432612582323},
00591   {0, 0, 0, -0.16463926016624763626, -0.18522613246415364774, -0.16806343812839372176, -0.11970576992958406604, -0.20980687790723681618, -0.21121432405796525256, -0.17357771168403127171, -0.13447695742874665736, -0.12462497601448342677, -0.13288174494405455284, -0.090885863966620059062, -0.14347955581137328274},
00592   {0, 0, 0, 5.3268434221882604226e-06, -8.5107300514016459483e-05, -0.00030578974891000469888, -0.0001603418756362900272, -0.00053214670979622651168, -0.00055664627477279766433, -0.00067837769016207102087, 9.8375418692391242495e-05, -0.00022734717951328333807, -4.6067317621643834487e-05, 0.0028259338550636840109, -0.0012429687928150318348},
00593   {0, 0, 0, 1.6276107021895365179, 1.1244503234167095851, 0.48381199206753811026, 0.6521829384503078364, 1.1967186256839628111, 1.0895619640773057668, 1.1511732463823045602, 1.1902521254981024423, 1.1633346478091382004, 0.57785407327314464165, 0.98457540775822882662, 0.72134750742279629687}
00594   };
00595 double CSCTFPtMethods::AB_mu13F[4][15] = 
00596     {
00597   {0, 0, 0, 0.11794009048617049018, 0.14088759484277332823, 0.16139997805145156473, 0.15924014633426775145, 0.34166140488658447438, 0.34702413335511289594, 0.32010695305030567592, 0.2754515982876076241, 0.24995233529692478802, 0.24473952965767659107, 0.16276629881527174271, 0.18307810125970991333},
00598   {0, 0, 0, -0.33781826981928775311, -0.37697407458444626149, -0.34627891339356470235, -0.2495281510358635102, 0.99999999999997757349, -0.31970550241711948036, -0.27098552536887665632, -0.19871096917742270271, -0.16382565983962907308, -0.18583964558555723934, -0.089736193434904326649, -0.12591247971420319041},
00599   {0, 0, 0, -1.8754239266677112923e-05, -0.00019661947183321836592, -0.00052669062346857333217, -0.00031426336450206927104, 0.00074135784198859060873, -0.00055327447631547889591, -0.00061397357196147500646, 0.0005513478108715907846, 0.00030281795212565223042, 0.00018809277538133742542, 0.0043442716153720252817, 0.0015460291315088062116},
00600   {0, 0, 0, 1.2452803747346312679, 0.74899299728776114193, 0.3722476702724113462, 0.32663500009046370076, -2.0530993850153551605, 0.94271305514658809699, 1.0071853490324427227, 1.0853085211028365986, 1.1204909555426088019, 0.64565209089225994443, 1.1299720140519045053, 0.68378819801841583814}
00601   };
00602 double CSCTFPtMethods::AB_mu14F[4][15] = 
00603     {
00604   {0, 0, 0, 0.12104944074518421415, 0.10503732418316034936, 0.099386285225076712035, 0.15823526186568545593, 0.25605688745800425643, 0.39267951247468363407, 0.32713902125758226314, 0.29153130557246226262, 0.26057754487562223566, 0.2787610414578671203, 0.17123500452835416219, 0.13771017848907712855},
00605   {0, 0, 0, -0.34834159047255092156, -0.3100051372552997675, -0.19689884687529440876, -0.42846101907983596968, -0.19825501228941203036, -0.69127391031064666649, -0.37133716526774046551, -0.28129274363985412588, -0.22005378496424787826, -0.29451256139072762297, -0.11968566909928436692, -0.082430041078971602597},
00606   {0, 0, 0, 0.0006127466960683334565, 0.0018163416142308417157, 0.0023773788535300438216, 0.0015618030372482551073, 0.0074745015886553429346, 0.018200042017815356438, -0.00037850173062430958817, -0.0001310013795632218917, 0.0004588064301207423791, -0.00028331509652615585, 0.0047044170533407638976, 0.0077579174434402355109},
00607   {0, 0, 0, 1.8999999999207801693, 1.3811827661042299642, 1.361253443017911513, 0.16448981101549500772, 1.7211759130995385458, 0.30399083099267765196, 0.93667281777770805551, 0.98970790081004300642, 1.0239036500876732561, 0.18365768268235896366, 0.9652515216778745355, 1.1235655997117797167}
00608   };
00609 double CSCTFPtMethods::AB_mu12R[4][15] = 
00610     {
00611   {0, 0.1017548888755877845, 0.13020457923539549561, 0.11777472840871647253, 0.135259653412823172, 0.15046936351520370789, 0.15033311904520965663, 0.27592431185059518306, 0.26261203783391384725, 0.23590422375068151317, 0.20542666917863602882, 0.18571989573685471209, 0.16892774190980749949, 0.15081083142543386111, 0.11470950869186374854},
00612   {0, -0.40835812179222591434, -0.49093394317051980424, -0.19396964458572663048, -0.18295086340095234601, -0.15883083260793051661, -0.12180030676387867961, -0.17142280024651118664, -0.16303048487901222741, -0.13932305333731584418, -0.10994759868937176162, -0.094596273339978872996, -0.074565522370199435742, -0.088574463930121957733, -0.066404462635971134299},
00613   {0, -0.00046324193156588387276, -0.0012328343343721989093, 5.853601028974310741e-05, 4.6551402962594318029e-05, -0.00037379710698656352843, 0.00013027765573736787424, -0.00058774094710430232688, -0.00026013465704373937588, -0.00031686525863970090673, 0.00019995024156887846161, -0.00013201225684480750316, 0.00012138566102844140695, 0.0024019828116854068101, 0.002454050768466287287},
00614   {0, 0.82326825991227925439, 0.6622515135971137612, 1.604726776511440578, 1.1913289041725036999, 0.92295363547504083446, 0.88387376488231517158, 1.1710955379641101448, 1.1237408525988819008, 1.090451903341310258, 1.1596094691084575246, 1.1568643334317050275, 0.75952946727681092121, 0.49759993894885606869, 1.063000794824717099}
00615   };
00616 double CSCTFPtMethods::AB_mu13R[4][15] = 
00617     {
00618   {0, 0, 0, 0.17151724172609877916, 0.18220699354740277354, 0.1971806134666532484, 0.20374010863761735091, 0.28349946603158304725, 0.29955890850476568632, 0.27687904734885987468, 0.24303184602970617778, 0.21558087490443028633, 0.20880080988319943414, 0.17455215996556627811, 0.10530527997452461542},
00619   {0, 0, 0, -0.51324304402681020232, -0.43421697944855691675, -0.38701854807632224409, -0.29241935343763897359, -0.20871597367009694923, -0.28188419096433631195, -0.24021461843739672082, -0.17856499996545552311, -0.13799534780447694771, -0.13259660131895426027, -0.092817386598798845565, -0.047633720002815273242},
00620   {0, 0, 0, -0.0002832228831297351054, -0.00011104889602297010609, -0.00036594729311201532962, -0.00045307390748000288998, 0.0013004023247916438651, -0.00030382496669450169283, -0.00035621571030299009489, -1.5526317287871784553e-05, 0.00040373454108751040317, -0.00066646698390456816929, 0.0026726730924115484414, 0.0067869187429414031335},
00621   {0, 0, 0, 1.0807877438092829969, 0.81710737216052486964, 0.4916551588634892056, 0.41353040356462944516, 1.2440300524121079562, 0.85083388011817795427, 0.89970477318504005204, 1.0198709857106920129, 1.0706254801939762977, 0.82353411895961936562, 0.51174005860627325148, 1.3970393515240444593}
00622   };
00623 double CSCTFPtMethods::AB_mu14R[4][15] = 
00624     {
00625   {0, 0, 0, 0.11411457974213083666, 0.14612498789299999125, 0.15438328053344949065, 0.17021962182813230036, 0.23217608026225655671, 0.17425716827684778476, 0.28951128865791975198, 0.26122027861775976021, 0.24000759859415121689, 0.21857963541141381403, 0.1535349322927131166, 0.099523188319583275052},
00626   {0, 0, 0, -0.32211539883453449429, -0.3332077022119345755, -0.28947013547326555516, -0.31678412927379157038, -0.20453745460807634671, -0.15291198578472323111, -0.37098278728491984602, -0.2755329314623077841, -0.22199156842477890672, -0.17253577136104261691, -0.10047612457202366454, -0.044726844357957776244},
00627   {0, 0, 0, 0.0021189308480414714535, 0.0017232488622970817526, 0.0014181868364706309241, 0.0020581588744611055593, 0.0075216673068132632735, 0.0091493927895737042766, -0.00026846347791510813061, -0.00028436387259422706009, -0.00034200230860254732116, -0.00032290147293964632531, 0.0043983126453619632301, 0.0087397754915012667437},
00628   {0, 0, 0, 1.8999999998213816799, 1.8999999999320695832, 1.2588510283946776624, 0.91969335359675130626, 1.402123244759204912, 1.6613910381353069745, 0.73820877543905039087, 0.87917754884863041909, 0.86223584668569153155, 0.64791792386949675908, 1.0974109668486700109, 1.4759477521933648259}
00629   };
00630 double CSCTFPtMethods::AB_sig12F[4][15] = 
00631     {
00632   {0, 0, 0, -0.0072662909883246416462, 0.013719915012791324485, 0.025391731980074987163, 0.019339420068030886007, 0.053326545665516936201, 0.0093197486670135200326, 0.056490074687743196957, 0.032206767426382759689, -0.035023634200557013374, 0.028213900230512060918, 0.022784146439966394826, 0.042614741605066668029},
00633   {0, 0, 0, 0.10823046777530002938, 0.01878931206060864903, 7.6655861869050212487e-08, 2.6103505241896474143e-08, -0.037472879148333762545, 0.84044168914522066061, 0.1596730107851508651, 0.37148947348342054031, 0.84416665360404552487, 0.033343799167991072796, -3.0637296741242714404e-08, 1.0763679972065204327e-07},
00634   {0, 0, 0, 0.0021057909484815525922, 0.001787927570908084832, 0.0016044920308954427855, 0.0021017028916686941731, 0.0014715412052789850379, 0.0018518237683180956143, 0.0011606826124997866867, 0.0013698228830716840596, 0.0034437828228962175797, 0.0044391469161792901366, 0.0056493798171646505621, 0.0036723245279772593827},
00635   {0, 0, 0, 0.99067714489116509569, 1.5044636171885787945, 0.35129633070368504466, 0.90079093171596547052, 1.8999999999893355529, -3.1887755854982775539, -0.93955730039878893045, -1.4200124454624811765, -1.3313909517381459224, 0.84940608625462010739, 1.5495433266818319229, 0.16930559499641162358}
00636   };
00637 double CSCTFPtMethods::AB_sig13F[4][15] = 
00638     {
00639   {0, 0, 0, -0.018414620671899382953, -0.0063421183947521258401, 0.019621855504556442312, 0.022067753543131330557, 0.070152538754796989195, 0.079150371235707506212, 0.079140295486170103567, 0.073877518421508400759, 0.082767871937039536046, 0.021369139938776086918, -0.16477473170806974934, -0.055605010807305503551},
00640   {0, 0, 0, 0.43219221841769328574, 0.38483806508941348357, 0.21697207053032832591, 0.2101344849017230676, -0.038098997442349964715, -0.054611240401914125375, -0.050739779308866243823, -0.040691137769481910968, -0.046730053313653409364, 0.34160850071169007736, 2.4811837948791053421, 1.119258204820076763},
00641   {0, 0, 0, 0.0021781382803023824693, 0.0019875143955268028371, 0.0016285688513061977872, 0.0016305488842204146627, 0.0012782681837918978725, 0.00077081684258208809941, 0.00078212255890452531213, 0.00085709016204132926989, 0.00040671635300752262757, 0.0047052241935035543641, 0.009138756403904884848, 0.006581042287601297433},
00642   {0, 0, 0, -0.57972924553460980501, -0.68468820136347818828, -0.97038451810774917217, -1.0717793859812905222, 1.1939302605060790885, 1.256587967991098731, 1.2135620509254290145, 1.3126461466228707131, 1.3303466630418721017, -1.3225160659219186154, -4.9999999661396543615, -3.3146932332622203177}
00643   };
00644 double CSCTFPtMethods::AB_sig14F[4][15] = 
00645     {
00646   {0, 0, 0, -0.023008179953388042255, -0.087196623845599563474, 0.014221968418245287125, -0.021787486380662964697, 0.066204099694590276548, 0.13000102518515968542, 0.088152940985918665229, 0.086006702296547610231, 0.090001124259240672387, 0.013343436852110169069, 0.058197437719081840379, 0.01505542228323810891},
00647   {0, 0, 0, 0.58165240914811378037, 1.6572607614650631813, 0.26374858984348420465, 0.56929114216912790614, -0.031761470721266109318, 6.8045996289272520086e-06, -0.041841810393849120098, -0.038282822754810812149, -0.041914122856969986131, 0.7374398397890853385, -0.015956321800768006464, 0.3197618459139073277},
00648   {0, 0, 0, 0.0021194192496740956247, 0.0031051396726804536899, 0.0016030344438190185716, 0.0037337124950505506081, 0.00038923034858751352164, 0.00435858958532461295, 0.00082943931444573449057, 0.0011709394337778087757, 0.00071832529359430491878, 0.0048589598883952743805, 0.0035711294356746648912, 0.0063024666768379707105},
00649   {0, 0, 0, -0.11185686895850970035, -2.8414639600328577274, -0.10356160152745381986, -1.2383039973901615038, 1.8999999999999264144, -1.1268332104959208895, 1.3179872870842119781, 1.3441201747507667275, 1.4026191965487366797, -2.9935330314488335368, 1.8045262602213363312, -1.0659192089400841841}
00650   };
00651 double CSCTFPtMethods::AB_sig12R[4][15] = 
00652     {
00653   {0, -0.024707713454999773173, -0.038443755326060806421, 0.010871842479360502298, 0.016714368961743577419, 0.038685029953164279393, 0.02390372984130531564, 0.029083895236059510714, 0.029312604030381151504, -0.035917405189748431715, 0.026066042529095882763, -0.032213952423461089669, 0.034901078112193437142, 0.038079734973208073656, -0.087892299438871682171},
00654   {0, 0.40843932424117945779, 0.54293566641814372531, 0.018832795613827488235, 0.0079319743967482744806, -1.3344384624776675641e-07, 2.4731323841273300523e-08, 0.41762122302294357734, 0.2457151073649548878, 1.3824483935679199309, 0.59561752502182341296, 1.3203480959501494585, -2.9300474866690573439e-08, -5.0505151304169881854e-08, 1.33159020410869533},
00655   {0, 0.0023254028360933497871, 0.002649950424820056178, 0.0019277178040729803059, 0.0018882653538893393562, 0.0014641263016252968436, 0.0027721702922578615909, 0.0019308246516262011702, 0.0018496886131080477779, 0.0027736328913035065286, 0.0017558336048563169887, 0.0025111400562683348567, 0.0029777661394122844143, 0.0043603321450967087031, 0.0076843830389115574953},
00656   {0, -0.57683271957068615876, -1.054992824312653843, 1.899999999963281061, 1.6191284732501969312, -0.81388064201435006417, 0.63981909200404141203, -2.051175532753063635, -0.82689751221137741677, -4.4494753422774939722, -2.9771693614691576713, -4.4060610825726218565, 0.96642021012703760441, 0.2748708997533949594, -4.9999999999408935025}
00657   };
00658 double CSCTFPtMethods::AB_sig13R[4][15] = 
00659     {
00660   {0, 0, 0, 0.00360542021125605152, 0.020602869777912733579, 0.03338432349679926886, 0.044385023713335559903, 0.069822381089744381399, 0.062546773236855104927, 0.066219648547959142348, 0.06611416521692425885, 0.06497177188943759063, 0.051540701348302922491, -0.14520516680358769301, -0.029300157339847341526},
00661   {0, 0, 0, 0.4085534255831447803, 0.24719809506838325008, 0.22799199818643953175, 0.092388265633298341517, -0.038646029439082504875, -0.028685880353590667569, -0.031288010457215374716, -0.030725505580235051156, -0.028415643540171672127, 9.3603867356737910366e-07, 1.7723836209535592801, 0.79014046450754893414},
00662   {0, 0, 0, 0.0018866521687494811326, 0.0016683560130498699577, 0.0014583718343991452365, 0.0014400104759788815573, 0.00030960964835738120741, 0.0012881264560630871496, 0.00092903731815353960809, 0.0011795342366904821955, 0.00083536183942388160095, 0.0027329868065747320999, 0.0097615976862859086399, 0.0062076155002320975926},
00663   {0, 0, 0, -0.51153770481744431642, -0.21797446392083433264, -0.73366402168423128227, -0.16793042827415577412, 1.3634759226070360949, 1.5374702497725512007, 1.4476836940432020739, 1.4342564113539701953, 1.3603273178484918127, 0.85184624997002589275, -3.994547309503146959, -2.8070030810796544607}
00664   };
00665 double CSCTFPtMethods::AB_sig14R[4][15] = 
00666     {
00667   {0, 0, 0, -0.035861540596622137889, -0.1163451242952821818, -0.3223054960806409075, 0.028427718090213778546, 0.082096556211394805525, -0.15497655162567502973, 0.077768957491548482142, 0.079360069813406791672, 0.070390830092954659314, 0.045116757562570351803, -0.064677236200661736287, 0.042980998498605572922},
00668   {0, 0, 0, 0.91272061044138930175, 1.0649835191592700312, 3.75045883898615795, 0.20554379357162461117, -0.046354224360297492658, 3.4599916691801695379, -0.029070628890768772379, -0.03047627128290695056, -0.023352404883102650252, 0.42581999018403432489, 1.1914459601584066473, 0.11545322121954273986},
00669   {0, 0, 0, 0.0023100741888551377598, 0.0065631885708627574205, 0.010122343115052657297, 0.0021541859801294522929, 0.0018078552644429368712, 0.0040217835853228389373, 0.00086395925415043829752, 0.0010071371561587601478, 0.0010978464681265795791, 0.0028425080621420056176, 0.007149112146344593563, 0.0050018423505699708895},
00670   {0, 0, 0, -0.85246870399928331707, -1.26158946908596592, -4.209205295019181392, 0.071706289987386498397, 1.2752968417552010827, -4.9999999999938600226, 1.5920301264071463621, 1.5139604617023065813, 1.5240783568834928019, -2.2799952377284649074, -3.0288053889868216118, -0.35716203856376926851}
00671   };
00672 double CSCTFPtMethods::AB_mu23[4][15] = 
00673     {
00674   {0, 0, 0.040640362633691015648, 0.041439895659457770538, 0.044692834118692070788, 0.050265059196205767733, 0.057855781845786831419, 0.040911062011686524786, 0.054867129215603105408, 0.054950002550886931085, 0.04628096985537989011, 0.0386822143533562951, 0.047358821668104643388, 0.037269724720912909832, 0.015397965365282755001},
00675   {0, 0, -0.30371495175799717581, -0.27234144993672854129, -0.27046501074758982908, -0.26067835847765863377, -0.26954762805984294749, -0.1426457406009814799, -0.23307410258067257081, -0.18832397122889199537, -0.11810764453638407379, -0.07292958939195615109, -0.079006610759413689604, -0.042031026026755985425, 0.46158683411526485463},
00676   {0, 0, -0.00025828047348465653929, -0.00027809037187354816549, -0.00020419752530604902245, -0.00028862476294847243165, -0.0005126844925482460175, 0.00019102281095152457563, -0.00054091429879001191611, -0.00041787351999948647895, -0.00020795331916966821283, 0.00019883680996083264846, -0.00031823156140864297236, 0.00033073555709824023052, 0.00045798264976761775616},
00677   {0, 0, 0.72752266254137853974, 1.0478460846247070748, 0.60915246823586477465, 0.26469225006383612087, 0.03642520365582532782, 0.71320044222334588735, 0.41972736248122854974, 0.44434170513663123758, 0.60643357599054859008, 0.72580899653377339842, 0.21165518987418086017, 0.40996107847780505207, -4.9999999999467634737}
00678   };
00679 double CSCTFPtMethods::AB_mu24[4][15] = 
00680     {
00681   {0, 0, 0, 0.053011865513752004508, 0.06313177697029372093, 0.05352084682330453258, 0.041027537820005684222, 0.040854761316574075836, 0.071402550245544899044, 0.07736719855382165334, 0.079438040698963527375, 0.061688220302594951039, 0.067651891731527510898, 0.052963807889076452984, 0.046716371658662027289},
00682   {0, 0, 0, -0.3616747887108062165, -0.44478796457305330714, -0.29166259789877752029, -0.29380132699441008359, -0.27050961328514633308, -0.55762354967613492196, -0.3936011893747999868, -0.31526772180018108882, -0.19834207563864661439, -0.17915991072026557496, -0.10076823982822344372, -0.055261578442674569311},
00683   {0, 0, 0, -0.00011948386184051261938, -0.0004377035707288234748, -1.5096856666038595447e-06, 0.00064791923379202854411, 0.00079626044396309916297, -0.00020119232514042466927, -0.00038577749709032405209, -0.00093011706547101180315, -0.00011554026119632592904, -0.00037143263105509765351, 0.00035067034962929022942, 0.00038063551578985043659},
00684   {0, 0, 0, 1.2751116233058998883, 0.73216838887711510608, 0.89682810391191047916, 0.68006768939986506073, 0.50537352978830141215, 0.054689817039132032628, 0.3551147830680470574, 0.37259002091189941108, 0.50609881889683205891, 0.24620464257366159178, 0.33817952977709087037, 0.61708106073631430188}
00685   };
00686 double CSCTFPtMethods::AB_mu34[4][15] = 
00687     {
00688   {0, 0, 0, 0.019865692759581058541, 0.028669852043158385729, 0.0061995800427958030338, 0.059000299883545020974, 0.021075145735423551907, -0.058857041409780444519, 0.024667592379148572251, 0.032653808103308000488, 0.022458031770245540787, 0.01792514222572837157, 0.021562783607549321913, 0.0096216089563556771863},
00689   {0, 0, 0, -0.16028204223466294143, -0.24129291619361287191, -0.12167690740695827345, -0.48886768749438458403, -0.41129236199911262117, -0.0044580020884623077632, -0.21747416644594624868, -0.20792639176268520873, -0.13295152726891287798, -0.091643743275156591688, -0.078156998408433070447, -0.027032449911459321273},
00690   {0, 0, 0, -7.2934093657490810247e-05, -0.00056307052572997283533, 0.00056401627209529397056, -0.001428418455371307811, 0.00026420696280349427725, 0.0019432058653304881864, -1.4101588242989779309e-05, -0.00050638968612514670842, -0.00014734760272619207332, 6.320198060251979149e-05, -0.00034513817764213352126, 0.00057747077087608850686},
00691   {0, 0, 0, 1.4981302006935997007, 0.74195678633729156282, 1.0145865296590363958, -0.61742551412101398522, -0.95877987406953490979, 1.2494426320923743834, 0.36142361465918354524, 0.25628769594642597518, 0.3741147629105586736, 0.365615069336391596, 0.18480357829838381378, 0.5901979250242155306}
00692   };
00693 double CSCTFPtMethods::AB_mu51[4][15] = 
00694     {
00695   {0.30968585217406008336, 0.22114029366912527075, 0.14560838945559098634, 0.043050218711845451847, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00696   {-0.317391172523608045, -0.19748764832039111816, -0.12103956190508825819, 0.72463403638600509815, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00697   {-0.00010752106748940020668, -4.6072314728751336248e-05, -0.00020800584810109703929, 0.00033077669460946062651, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00698   {1.5451989748370562605, 1.5930686622089456073, 1.8999999999979138021, -4.9999999999877386969, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00699   };
00700 double CSCTFPtMethods::AB_mu52[4][15] = 
00701     {
00702   {0, 0.29089555712829096024, 0.22409035657291778709, 0.17273536730257388339, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00703   {0, -0.43681921590138955702, -0.33001737647025841671, -0.24329418737026767272, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00704   {0, -0.00010643314222352778407, -0.00031956169647435724371, 0.00040529994876056351771, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00705   {0, 1.3951067657640845443, 1.2698178861615445623, 1.5786429063985620846, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00706   };
00707 double CSCTFPtMethods::AB_mu53[4][15] = 
00708     {
00709   {0, 0, 0.26038412925299281309, 0.21941755760271858255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00710   {0, 0, -0.61721194828669312393, -0.53600209701934642403, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00711   {0, 0, -0.00056428232649683839756, -5.2823850044021085706e-05, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00712   {0, 0, 0.94850025872825582951, 0.89939017342749116857, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00713   };
00714 double CSCTFPtMethods::AB_mu5[4][15] = 
00715     {
00716   {-21.773943957733699506, -20.451306495642462835, -17.619293017663956391, -17.985193664137248959, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00717   {15.981287025955555947, 13.662338397855792849, 12.698834069804624036, 13.996345470486554419, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00718   {-0.061346409143613597759, -0.030528939724191926641, -0.021492236674697007964, 0.24210701584829638633, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00719   {1.8075565358091265633, 1.6365385762740469744, 1.7445149566969406774, 1.7990108859790623352, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00720   };
00721 double CSCTFPtMethods::AB_sig23[4][15] = 
00722     {
00723   {0, 0, -0.0094472830143822704441, -0.010353883065660221541, -0.015601327378638136373, -0.0083991887622088135662, -0.0038116819341330646607, 0.017694776574912907813, -3.0418423374763137179e-05, -0.017083474678572161537, 0.0030620488929764769909, 0.017250003890826686587, 0.0093475052428345049849, 0.020375148710649073486, 0.010825941272754753195},
00724   {0, 0, 0.12318105169788677589, 0.16505972139582619773, 0.263159083213652778, 0.26421790122008942392, 0.23011122781312612351, -0.0029907504110232440049, 0.2662480243269049196, 0.37307765589709518395, 0.18835664858385614551, -0.0037750353709654835277, 0.098617292357490976551, 0.012272312117637594608, 0.08273140888309518659},
00725   {0, 0, 0.0021613847603855311508, 0.0021330265880287833241, 0.0021695206819646582243, 0.0020640370557124072468, 0.0020048207254594494972, 0.0014767405252029560357, 0.0017674128894213845219, 0.0025204999982808081078, 0.0019567585272304921853, 0.0017176170124729862442, 0.0017211733630609592216, 0.0017231460782773917826, 0.0019575057733585408438},
00726   {0, 0, 1.2774261918853997422, 0.78296130809877573231, -0.37439956367077026345, -1.069757156759185035, -1.1169051718060274414, 1.8723437538832861105, -1.3529025051179361938, -1.7597610310938422984, -1.0397927716846628865, 1.751460152036041773, -0.5607845639862726328, 0.38169069644802128272, -0.67820448402866129189}
00727   };
00728 double CSCTFPtMethods::AB_sig24[4][15] = 
00729     {
00730   {0, 0, 0, -0.019324652110983078085, -0.014097627204506661333, -0.024009933572701678411, -0.020935767487239648893, -0.066886386670231376406, -0.04726302695081713301, -0.04581885223042039823, -0.0022530391239994115166, 0.012941230376038602781, 0.015015675163022421112, 0.040290964473749905916, 0.00057743831082023152831},
00731   {0, 0, 0, 0.38549899615915406148, 0.36399829139474371154, 0.35169918487968249154, 0.68304114463142939773, 0.924278067861450503, 0.93196764772733042825, 0.81473285865204680967, 0.45546643991332796952, 0.26322508591964527414, 0.1818180989316907914, 0.043498303978469606002, 0.34659825827423174083},
00732   {0, 0, 0, 0.0022171043021711415305, 0.0021747338101839835782, 0.0029940267352052294877, 0.0021275297553744344087, 0.00333281433667635121, 0.0024627396815433810068, 0.0037669222073941294529, 0.0023976648979574955584, 0.0020217750711657845979, 0.0021837076490728861596, 0.0012144425569054367355, 0.002374985696282168237},
00733   {0, 0, 0, 0.086888271968145289192, -0.16601964501317648115, -0.17314993364576378165, -1.7261300821354781387, -2.664491369228591644, -2.3141437377298186284, -1.8792879627112784036, -1.2606774796648803072, -0.69467662222261306049, -0.43108677719729054933, 0.10302409352825184219, -1.5414538145867078267}
00734   };
00735 double CSCTFPtMethods::AB_sig34[4][15] = 
00736     {
00737   {0, 0, 0, -0.011900935391395110405, -0.0099786129323683296632, -0.03846567510080637492, -0.012370991149719094346, -0.055252999502503549745, 0.044966193083524036433, -0.00027213472446938578864, 0.0021399237064631750245, -0.012043959370962682362, 0.00030539002522898643643, 0.013165853183139508698, 0.00031172134354808022152},
00738   {0, 0, 0, 0.111273956912252725, 0.1761400818445788552, 0.35943108699238940362, 0.31392703938750776693, 0.81003851538686244549, 7.9026928716339345238e-07, 0.17123782818945096351, 0.18309348520126816906, 0.23474101370135130873, 0.10971023080469560762, 0.010540318711930948131, 0.097075156214686139644},
00739   {0, 0, 0, 0.0023008684843514003171, 0.0021100048451113389419, 0.0030013525121405674675, 0.0021561747583490843347, 0.0029044705579195947802, 0.0011292473915371563191, 0.0020602518937551739589, 0.0022831018423480099744, 0.0022549864255083677464, 0.0019554188567418107417, 0.0022790974638247727541, 0.002187312548748918551},
00740   {0, 0, 0, 1.4773740578325260664, 0.018290937563995572634, -1.0033798535764466564, -1.5842086993923574223, -3.6001627441020871423, 0.54264104475808871975, -0.59687853097356946552, -0.87818291672479875665, -1.1101641260377899112, -0.39819220908857072549, 0.64153798465161648856, -0.77169187422540497234}
00741   };
00742 double CSCTFPtMethods::AB_sig51[4][15] = 
00743     {
00744   {0.00020466983430282321282, 0.047505782475661187392, -0.053417141048077265708, 0.039017115805722264732, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00745   {0.91340592460032132838, -2.3265261778725176978e-09, 1.2753791211682063977, -0.024097491702141229236, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00746   {0.0018152770979815904123, 0.0012666078956331508661, 0.0024439910928461300484, 0.00081068594431841524677, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00747   {-2.9577250260529730497, 0.83105421659328959638, -4.9999999999931565853, 1.8999999999836647557, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00748   };
00749 double CSCTFPtMethods::AB_sig52[4][15] = 
00750     {
00751   {0, 0.013024634848957779287, 0.030326831867631701134, -0.037883414612387561471, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00752   {0, 0.60655763110407245886, 0.086549467449585568146, 0.96143975817822979746, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00753   {0, 0.0017838502242368942628, 0.001549072940288412966, 0.0024073931799526598375, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00754   {0, -1.5742327665558009109, 0.42138058335326011861, -2.5570410153890166249, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00755   };
00756 double CSCTFPtMethods::AB_sig53[4][15] = 
00757     {
00758   {0, 0, 0.0050716226036932833196, 0.072311934385767509537, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00759   {0, 0, 0.584416896221089055, -0.031665576103488260462, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00760   {0, 0, 0.0019163928931876126824, -0.00057867999258552171686, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00761   {0, 0, -1.1966097325097744264, 1.8999999999981582732, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00762   };
00763 double CSCTFPtMethods::AB_sig5[4][15] = 
00764     {
00765   {7.8205209077391470984, 2.9855734606682107213, 1.1825497246141358776, 19.305732840291909724, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00766   {-28.925099295750328565, -1.1590698515764885634e-05, 2.1058004914323302792e-06, -99.999999999237957127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00767   {0.49543754065341683024, 0.59927339473627028177, 0.72787082140560965815, 1.4999999999905031522, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00768   {-4.4205814548277118092, -1.731856240515097678, 0.91982931738965656443, -2.2550825501853273281, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00769   };
00770 double CSCTFPtMethods::AB_rho123F[5][15] = 
00771     {
00772   {0, 0, 0, 0.21591246799314617322, -0.0088050420313028690544, -0.088535622769352645411, 0.1006486675958642163, 0.067288821235719803449, 0.094183111621421872206, 0.11161107798998388951, 0.11398888280887224667, 0.10503939211879674553, 0.024474774056199476852, 0.046753912210887135781, 0.040088150557658401574},
00773   {0, 0, 0, -0.098239875317249245046, 0.12779984161744517568, 0.14575642641392180798, 0.00097994339623410156581, -0.017044028681701687417, -0.041821834675341319765, -0.03996460686227946979, -0.038564860655556879032, -0.033600698334453546479, 0.018439524738640494794, -0.015109111485474606418, -0.0045695887184472334247},
00774   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00775   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00776   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00777   };
00778 double CSCTFPtMethods::AB_rho123R[5][15] = 
00779     {
00780   {0, 0, 0, -0.47568140563221139594, 0.16168003252830986938, 0.25872690555461436146, 0.199495248815122872, 0.10461699853024816753, 0.096749760238894186304, 0.12110848659141376649, 0.11865295930901736954, 0.13774043814412179065, 0.084006936630821260614, 0.068568916018588138561, 0.10326984780227360661},
00781   {0, 0, 0, 0.38437441019930046471, -0.039988232827630004751, -0.11333474899807700897, -0.098018610920314108714, -0.027684275921977110485, -0.020477410702221525429, -0.039128511514004080118, -0.041694544300297106676, -0.063510349952433278742, -0.017922560128537899649, -0.016785071384088808, -0.061230529811631448367},
00782   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00783   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00784   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00785   };
00786 double CSCTFPtMethods::AB_rho124F[5][15] = 
00787     {
00788   {0, 0, 0, -0.59309777973105870519, 0.40674864730572002358, 0.025457362459962610407, 0.12390836361392933151, -0.095057602683116318443, 0.020804212882217412717, 0.0037573456395767730956, 0.051564942370207866862, 0.095392860178285313055, 0.025068145207744741559, 0.074930159107728350198, 0.083894685659705744984},
00789   {0, 0, 0, 0.43249344815524365382, -0.22620914049875265328, 0.047340519949311848924, -0.043393009608351185147, 0.089991823076996074748, 0.017785749716159038325, 0.018363489474203294888, 0.00038439875526154188012, -0.01981142588979651134, 0.029870972349476748731, -0.014713153742897349188, -0.030515833639204549554},
00790   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00791   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00792   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00793   };
00794 double CSCTFPtMethods::AB_rho124R[5][15] = 
00795     {
00796   {0, 0, 0, -0.3790214723591084911, 0.008629294656197683891, -0.18476862186063011673, -0.14382291114342518612, 0.062423042856956378888, -0.01457735302975383257, 0.054710076752791991783, 0.046163675870020424996, 0.073923291317618017304, 0.036368609033315117685, 0.13845699145909207139, 0.19089158859242033595},
00797   {0, 0, 0, 0.29446400959310820022, 0.036382668388190271547, 0.10273587571656045414, 0.098901655648261907472, -0.0024084820537273766983, 0.096524156316618106577, -0.0020090841757854135258, 0.0041754682815653386407, -0.015903678190480090987, 0.029186690106470097872, -0.057996964818734043912, -0.10902135889862836493},
00798   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00799   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00800   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00801   };
00802 double CSCTFPtMethods::AB_rho134F[5][15] = 
00803     {
00804   {0, 0, 0, -0.18540056438689667129, 0.13948900273564729391, 0.28239862898948059344, 0.18152200630689951932, 0.12019173512533826154, 0.33004964169263961704, -0.19271610018409221499, 0.010571838928394724014, -0.35782517965138482818, -0.1667933388665421568, -0.029610523966235428178, 0.14921983595489249352},
00805   {0, 0, 0, 0.14018592629407464201, -0.0058491444860705784498, -0.15000052378446995793, -0.053446371008268357683, -0.054095925229749527996, -0.25878658016296007816, 0.19159454488908850278, 0.051622440147487090589, 0.37406385695410443448, 0.20690833738895109128, 0.088602990694543637407, -0.049658965143950316301},
00806   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00807   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00808   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00809   };
00810 double CSCTFPtMethods::AB_rho134R[5][15] = 
00811     {
00812   {0, 0, 0, -0.32466278494115075048, 0.06557151645351706748, -0.49502508225505659212, -0.41235874470132255487, 0, -0.058206185496771437049, -0.11994212694833844557, -0.28765504885129739021, -0.14630986783496638393, -0.2506902435838725407, 0.077895192872688825969, 0.124491687529346029},
00813   {0, 0, 0, 0.27488604690515439088, -0.0040425703778970423219, 0.37667381909165875697, 0.41399717354299681027, 0, 0.099105082166226002305, 0.14152702361577107482, 0.29199015482789675291, 0.18481068509958351043, 0.30061000836172008244, 0.024035962765780741895, -0.039987755352911616424},
00814   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00815   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00816   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00817   };
00818 double CSCTFPtMethods::AB_rho234[5][15] = 
00819     {
00820   {0, 0, 0, -0.70172108162723456637, -0.16790171221494132325, -0.31359257756370256809, 0.52195596788366016572, 0.35469616250708335681, 0.29972961639836864789, -0.12733383185241853308, 0.023732260311915418655, -0.11620070369401960808, -0.012271043428981569592, 0.15272636020019583758, 0.22639228046259637916},
00821   {0, 0, 0, 0.5466181131903057322, 0.1896976252586676237, 0.27309056219009231192, -0.2403671552670139655, -0.24805788613689500055, -0.18366569226946502513, 0.20613233813122075477, 0.099476351393539552692, 0.23721131992179073089, 0.1662158153666866145, 0.030774565037216095043, -0.011281034689275959773},
00822   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00823   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00824   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00825   };
00826 double CSCTFPtMethods::AB_rho512[5][15] = 
00827     {
00828   {0, -0.10122374386788027256, 0.05867279399992569866, 0.022992784714161641768, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00829   {0, 0.060780405957416211438, -0.0018903031693155436521, -0.027696685591685570732, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00830   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00831   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00832   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00833   };
00834 double CSCTFPtMethods::AB_rho513[5][15] = 
00835     {
00836   {0, 0, -0.089930042979514415724, -0.093269939725297734689, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00837   {0, 0, 0.058029285354766410587, 0.03709347335623498082, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00838   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00839   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00840   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00841   };
00842 double CSCTFPtMethods::AB_rho523[5][15] = 
00843     {
00844   {0, -0.36007557586623134549, 0.36086751765228869404, -0.49597380394918910707, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00845   {0, 0.23104888116180791191, -0.21165442151467717125, 0.39616810472416036371, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00846   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00847   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00848   {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00849   };
00850 double CSCTFPtMethods::AB_rho51B[5][15] = 
00851     {
00852   {-23.317206441977930353, 0.38311096711317893515, 138.73025928148325647, -3.3895984991624619198, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00853   {39.81331931040932659, -0.58265538873024502742, -197.09814590529396128, 5.7801784630612900173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00854   {-21.692379671233720018, 0.16303933981615081894, 92.527943431966605203, -3.4630147948370328947, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00855   {3.6815612322193729256, 2.1215317965894708863e-05, -18.739157224127048096, 0.64092416582054112517, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00856   {1.4065782520225946772, 0.47918084713644876205, 3.4270868776988145932, 1.1911679883977874805, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00857   };
00858 double CSCTFPtMethods::AB_rho52B[5][15] = 
00859     {
00860   {0, -11.115614234839123142, 199.99999993867194803, -0.41345082980668335093, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00861   {0, 18.640929927342266836, 199.91384480242638233, 0.85194663719311369832, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00862   {0, -10.215935151734681696, -199.99199382783231727, -0.69886651036510760715, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00863   {0, 1.758281666952397071, -95.546949944038203739, 0.15699448924348563539, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00864   {0, 1.3487188994777750128, 5.4534491073916449011, 0.88233434422240508699, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00865   };
00866 double CSCTFPtMethods::AB_rho53B[5][15] = 
00867     {
00868   {0, 0, 199.20037694773515113, 58.711955576749318197, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00869   {0, 0, -50.001539058211825761, -162.05665958847185948, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00870   {0, 0, -75.823665036302642761, 163.90256775382573551, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00871   {0, 0, -0.56535096647798599445, -58.227592407129677099, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00872   {0, 0, 4.7457461205225630607, 4.0420077737038067056, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00873   };
00874 */
00875 
00876 // Anna's 2010 parametrization
00877 const double CSCTFPtMethods::A_mu12Front[4][15] = 
00878   {
00879     {0, 0, 0, -0.10523922235654110946, -0.10983929659374999654, -0.11452047380694262146, -0.11922097760176857129, -0.31345770385362781152, -0.29879434616186489881, -0.26915122313015271693, -0.23825592462089598134, -0.21577716540165170489, 0, 0, 0},//A_mu
00880     {0, 0, 0, 0.26520808786388666567, 0.20543788970357632073, 0.15092171845376831096, 0.10960449046799547457, 0.07249357497808966988, 0.084725241812656573726, 0.080545185052021503469, 0.063499540823294411962, 0.052274729725005748826, 0, 0, 0},//B_mu
00881     {0, 0, 0, 0.00053807554094229155788, 0.00045289727656323158257, 0.00048500971554021258918, 0.00062343043239925161666, 0.00018916793540052533398, 9.9877853046464147579e-05, 0.00011936753945903473204, -0.00013555974179713960442, -0.00018396374782998390577, 0, 0, 0},//C_mu
00882     {0, 0, 0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0, 0, 0} //D_mu
00883   };
00884 
00885 const double CSCTFPtMethods::A_sig12Front[3][15] = 
00886   {
00887     {0, 0, 0, 0.012128390128145795368, 0.0060118459615588950434, 0.0066857690437444544998, 0.016870580188088974555, 3.2471855065940857799e-17, 0.04950616849006982817, 0.047875666889731632869, 0.046434926233452016031, 0.043576561593816925955, 0, 0, 0},
00888     {0, 0, 0, 0.11205437847560090203, 0.14710111810994394577, 0.12139003108545433351, 0.05805544863709271447, 0.44230910905171338943, 0.097455948703866090987, 0.091167182629549800565, 0.08155034337565571223, 0.10115334241053108855, 0, 0, 0},
00889     {0, 0, 0, 0.00045794655246943964493, 0.00060328713936987944655, 0.00059167776206113108402, 0.00032821487645948946993, 0.0017467056059844235372, 0.00059613339189244513722, 0.00058184715339610595854, 0.00064476542748265707177, 0.00065843267283058381015, 0, 0, 0}
00890   };
00891 const double CSCTFPtMethods::A_mu13Front[4][15] = 
00892   {
00893    {0, 0, 0, -0.13778088536998894797, -0.15278054690526707282, -0.143346136779766542, -0.14969165155567873415, -0.31735124864642083597, -0.33366154127080654979, -0.32035587063652937179, -0.29063133844224109392, -0.2625110988870774098, 0, 0, 0},
00894    {0, 0, 0, 0.50472519215627242861, 0.45431218833331760143, 0.27978303792475944789, 0.21659344933388599563, 0.39042059382545513113, 0.21436973705419076763, 0.21989939737961083921, 0.17248537946455347325, 0.14545152483288878442, 0, 0, 0},
00895    {0, 0, 0, 0.00074029784977316568338, 0.00094379263107391029794, 0.00044290989468863904959, 0.00032465731761844673995, 0.00080437043173185620963, 0.00030621821048436737717, 0.00036742704696401365556, 0.00031744969589481185704, 4.3755432326479009111e-05, 0, 0, 0},
00896    {0, 0, 0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0, 0, 0}
00897   };
00898 const double CSCTFPtMethods::A_sig13Front[3][15] = 
00899   {
00900     {0, 0, 0, 0.022229486577380466045, 0.014786622332179612943, 0.022206319015528955263, 0.030956563988669690696, 0.10438632614093404372, 0.052151139493775117151, 0.061379169888241082165, 0.063070119166874993866, 0.062738437335733338029, 0, 0, 0},
00901     {0, 0, 0, 0.17561127734822717938, 0.248243347883890908, 0.15435972163154007553, 0.098222588303399416265, 0.28864281120179885454, 0.28143242857015660086, 0.16091447629058408531, 0.13483945718353784748, 0.13542102637707623125, 0, 0, 0},
00902     {0, 0, 0, 0.00050105260335033322255, 0.00060095811169912115909, 0.00049407859567527159534, 0.00062091453005704531909, 0.00046438613640785659023, 0.00074251112464886865304, 0.00070054085319381544095, 0.00064104982805283157888, 0.00060566613754535849647, 0, 0, 0}
00903   };
00904 const double CSCTFPtMethods::A_mu14Front[4][15] = 
00905   {
00906    {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.32728513383665119862, -0.30618420062024648276, -0.27554118389520276811, -0.16285631900256525295, 0, 0},
00907    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.32023477684420448286, 0.2693691108403535317, 0.22056748837118930751, 0.064251774309308562483, 0, 0},
00908    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.00042613689417415228419, 0.00055054357631906247761, 0.00015434926334609733872, -0.012950297280226659088, 0, 0},
00909    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0, 0}
00910   };
00911 const double CSCTFPtMethods::A_sig14Front[3][15] = 
00912   {
00913     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.060082258981389996544, 0.07247051398468504213, 0.069785008221314948074, 3.6424053064063738328e-12, 0, 0},
00914     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.30722806049859069377, 0.20925971382909466789, 0.21969785537300090539, 0.022179262487250456931, 0, 0},
00915     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.00094734288756094921311, 0.00069588950170735620632, 0.00069173065831375820777, 0.095265205090887594697, 0, 0}
00916   };
00917 //
00918 // Rare without CSCTF resolution 
00919 const double CSCTFPtMethods::A_mu12Rare[4][15] = 
00920   {
00921     {0, -0.10374889091836100863, -0.099788822609968519384, -0.13818657823143312702, -0.13717556879309533713, -0.14490849378394998759, -0.14408105919423722097, -0.2740736915947392105, -0.25354252758973594428, -0.22856287512160483599, -0.19978450972956338094, -0.18078462391477437277, 0, 0, 0},
00922     {0, 0.43901381552049162371, 0.33269140862921836588, 0.2867281989745522619, 0.1745740696789168378, 0.13068773408294853677, 0.090289532623200399741, 0.14511096793044100939, 0.089110172781148286325, 0.088325915559225531837, 0.058284739852102536439, 0.054838099980182117288, 0, 0, 0},
00923     {0, 0.00090427118272218449946, 0.00051285798655137816021, 0.00096712518524937637985, 0.0005533967588738022839, 0.00058699577022335697706, 0.00046096277656442602704, 0.00059775151582151515688, 0.0002982802094889720106, 0.00025087464533485412822, -1.2763501682976573746e-06, 8.7075909949317653082e-05, 0, 0, 0},
00924     {0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0, 0, 0}
00925   };
00926 const double CSCTFPtMethods::A_sig12Rare[3][15] = 
00927   {
00928     {0, 0.0038093885421048444447, 0.0065769632315039548015, 0.0055592323950014550446, 0.0093835962422483230883, 0.017396352418037726306, 0.020259861529127568686, 0.028034021369845840699, 0.039800110854239546809, 0.039980148857628114434, 0.038524308685830198351, 0.040281758067103733134, 0, 0, 0},
00929     {0, 0.23514753393254139713, 0.20840454339700395514, 0.1734554515667367236, 0.14712778893221009624, 0.068478644292554124995, 0.045578777378287992084, 0.17971688457142401263, 0.10413274328597779683, 0.096806606002943468292, 0.095972114441355463321, 0.077888109608563196873, 0, 0, 0},
00930     {0, 0.00060835884164537896556, 0.00057248928258038056342, 0.00054601310456751364283, 0.00045596139082362406765, 0.00036256195477186049098, 0.00033554189220614231851, 0.00081415383922815243514, 0.00064529700989722222747, 0.00063280618158918571729, 0.00066801533625483495039, 0.00061304601669530541484, 0, 0, 0}
00931   };
00932 const double CSCTFPtMethods::A_mu13Rare[4][15] = 
00933   {
00934    {0, 0, -0.12623127354128180211, -0.17935797490956165157, -0.18060840788964968584, -0.18696605249703140972, -0.19077279628481272344, -0.29349472537983850584, -0.28999462954606641807, -0.28042269536018021858, -0.24794997339523475177, -0.22381101094323510581, 0, 0, 0},
00935    {0, 0, 0.46581826439734036471, 0.59045368664701669559, 0.42112504758806018623, 0.31214409746624299791, 0.22991099738945788844, 0.38259688787882195626, 0.21032714197086083141, 0.23803428613207575082, 0.16848812991169570541, 0.13391107896586992854, 0, 0, 0},
00936    {0, 0, 0.0002201385928033240463, 0.00094588024264893161806, 0.0006090017795757148196, 0.00055819818498869361832, 0.00051220623767016942862, 0.0010722093641169425093, 0.00033951226487555219435, 0.00057667736469464204747, 0.00038672362687909188003, 0.00018665348905046641372, 0, 0, 0},
00937    {0, 0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0, 0, 0}
00938   };
00939 const double CSCTFPtMethods::A_sig13Rare[3][15] = 
00940   {
00941     {0, 0, 0.015046443595756202674, 0.024350274050281187077, 0.030516519859742685661, 0.034951536569288559064, 0.040872596013944946514, 0.075500038528175023034, 0.054258877880390701809, 0.057948329004836200695, 0.055684189309453437089, 0.055547652610341891055, 0, 0, 0},
00942     {0, 0, 0.72981359973468040714, 0.25552798678505961316, 0.20538399097483123201, 0.13568477284924612691, 0.087691623490571385391, 0.14380693710811331965, 0.17784552932129321645, 0.15447707796169932171, 0.15118995597952319954, 0.13106219757004208826, 0, 0, 0},
00943     {0, 0, 0.00047001852983351251119, 0.00053481400606665866967, 0.00036348184816972377081, 0.00037774161715020031574, 0.00026657604722595630358, 0.00029086094173271957383, 0.00068184877937593074432, 0.00058313040724595804811, 0.00061068422520455867882, 0.00061315948044054677767, 0, 0, 0}
00944   };
00945 const double CSCTFPtMethods::A_mu14Rare[4][15] = 
00946   {
00947    {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.2849452232390318196, -0.26600970450734234829, -0.23683395869018955548, -0.22057309433227462181, 0, 0},
00948    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.33740004932669764859, 0.27762229117854592131, 0.19628468723350062097, 0.17323896845886521678, 0, 0},
00949    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.00036794862559287675862, 0.00059266387001125628905, 0.00029802341315537321086, 0.00025629117987456756858, 0, 0},
00950    {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0, 0}
00951   };
00952 const double CSCTFPtMethods::A_sig14Rare[3][15] = 
00953   {
00954     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.057936258148966857107, 0.067831242837197713857, 0.065620840504349520206, 0.054328715544637938561, 0, 0},
00955     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.30423086251952391468, 0.20761013178198547968, 0.19093892168102474804, 0.38288685251508419727, 0, 0},
00956     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.00080261760198784384054, 0.00063696047781503656055, 0.00065139580093967995589, 0.00069639579902228165072, 0, 0}
00957   };
00958 
00959 
00960 const double CSCTFPtMethods::A_mu51[4][15] =
00961   {
00962      {-0.30205049387075266765, -0.19825408793401680385, -0.10259572704977054647, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00963      {0.39029489236430164878, -0.99999999999950184293, -0.99999999991334242999, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00964      {-0.0082240407388394932281, -0.008489109806000837144, -0.0096722775887914218262, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00965      {1.4884036315353963431, -2.8577685774096766025, -3.1123617094902709113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00966   };
00967 
00968 const double CSCTFPtMethods::A_sig51[3][15] =
00969   {
00970      {0.013883456707760059509, 0.011790507803505339071, 2.4609763012162222395e-15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00971      {0.33358000572065177325, 0.19837044850549298558, 0.21329994540971500272, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00972      {0.0026062373849642236565, 0.0026272077989507240485, 0.0025484832112267707081, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00973   };
00974 
00975 const double CSCTFPtMethods::A_mu52[4][15] = 
00976   {
00977     {0, -0.31934822512291188845, -0.24671378669106625026, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00978     {0, -0.99999999999980493381, -0.99999999999999167333, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00979     {0, -0.0073087160764979198016, -0.0070564603063957591009, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00980     {0, -5.0384103551069152616, -5.6736067150957572025, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00981   };
00982 const double CSCTFPtMethods::A_sig52[3][15] = 
00983   {
00984     {0, 0.021754484285831678786, 0.0079969520010703034479, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00985     {0, 0.31662456185786602703, 0.25320436095234394314, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00986     {0, 0.0026259453672001680305, 0.0027192866432913216992, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00987   };
00988 
00989 const double CSCTFPtMethods::A_mu53[4][15] =
00990   {
00991     {0, 0, -0.2362111548723856147, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00992     {0, 0, 0.58675988413655344456, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00993     {0, 0, -0.0074765217760223816323, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
00994     {0, 0, 1.392910355886719076, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
00995   };
00996 
00997 const double CSCTFPtMethods::A_sig53[3][15] =
00998   {
00999     {0, 0, 0.010082748878246528337, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01000     {0, 0, 0.37397019929001934502, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01001     {0, 0, 0.002686637834141298968, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
01002   };
01003 
01005 const double CSCTFPtMethods::A_rho512[5][15] =
01006   {
01007     {0, -1.3270643828972497058, -0.40947841616853780655, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01008     {0, 2.025201781399017964, 0.58089265964690128818, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01009     {0, -0.73760841017029699085, -0.060534778841327505083, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01010     {0, 0.077735281441295198124, -0.017952905037001157251, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01011     {0, 0.005510074476231469412, 0.26061236699994605459, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
01012   };
01013 const double CSCTFPtMethods::A_rho513[5][15] =
01014   {
01015     {0, 0, 0.18116780706048338234, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01016     {0, 0, -0.10826967270771679919, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01017     {0, 0, 0.033488168126484141318, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01018     {0, 0, -0.0040355575386412517735, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01019     {0, 0, -0.4934185910548575249, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
01020   };
01021 const double CSCTFPtMethods::A_rho523[5][15] =
01022   {
01023     {0, 0, -1.9080285362497979573, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01024     {0, 0, 3.2540326879755121503, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01025     {0, 0, -1.2246911037569772063, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01026     {0, 0, 0.13624286476587679773, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
01027     {0, 0, 0.24605674796105389546, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
01028   };
01029 
01030 
01031 
01032 const double CSCTFPtMethods::A_mu23[4][15] = 
01033   {
01034 
01035     {0, 0, -0.038262994788483634112, -0.038329955987871006107, -0.0374748823380766094, -0.041131685825480934771, -0.041682237062370237901, -0.043941548191289134251, -0.036858451809650610853, -0.041160145519271960912, -0.03640665951155453578, -0.037033177234847232395, -0.039730205721839016719, -0.041049544792113090708, -0.03904511674158141904},
01036     {0, 0, 0.22476203480449799543, 0.19067575131669534105, 0.15256324303025625699, 0.13801063658393192268, 0.12256502197662035025, 0.11905632873396845839, 0.10056103279215167223, 0.094455197819930808434, 0.06542931061274483151, 0.055715924150473321308, 0.053301837423971050456, 0.045890095913808617856, 0.027949821903864861122},
01037     {0, 0, 0.00069404495353071109318, 0.00065670816947569431686, 0.00050715045635956769714, 0.00051087666765004164943, 0.00050201870311558270069, 0.00025160072489320881679, 0.00026119341522217484446, 0.00027099698566654400892, 9.9011225161971808595e-05, 7.3884094779271263388e-05, 0.00025118886053809180194, 0.00035276812785148709559, 0.00023201907068018601732},
01038     {0, 0, 1.5949221750821838128, 1.7201281725872403783, 1.58953615582846286, 1.1423843849936006212, 0.97788843089194554814, 0.90488697221367975221, 1.1715145764654877336, 1.1384185105977693286, 1.1222106905033706337, 0.8870702391119174024, 0.61881410578333895245, 0.2103057782202895909, 0.20906493220451535797}
01039   };
01040 const double CSCTFPtMethods::A_sig23[3][15] = 
01041   {
01042      {0, 0, 5.1487948019707241443e-14, 1.371515748194163109e-17, 5.7867664653155070908e-15, 0.0018689633292167232882, 0.0022366390858728274135, 0.0098612407883851022766, 6.8801945206625053642e-12, 0.0032973305248131545321, 0.0054990363466139750501, 0.0092745687266331533483, 0.011501230292384876167, 0.012866555123334103353, 0.01433335748409165708},
01043      {0, 0, 0.20455300017238808863, 0.19201919320235372179, 0.17201776141542601817, 0.12441381076621171875, 0.1050096955004960475, 0.086699597450937707088, 0.12195247491883690061, 0.12325808533281308599, 0.096676601548240911899, 0.075608663356511091047, 0.063411508431177876499, 0.053299915739310803342, 0.048982690822271121589},
01044      {0, 0, 0.00067345631439024247495, 0.00071637601448934864513, 0.00073991596851847836816, 0.0007991069380909875423, 0.0008004777620410123912, 0.00089609812741991013828, 0.001505913962207979526, 0.0014477291363779595194, 0.001410515534491615236, 0.0013306603256628582281, 0.0012465454381592282456, 0.0012290059929163277448, 0.001182792281371985825}
01045   };
01046 const double CSCTFPtMethods::A_mu24[4][15] = 
01047   {
01048     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.061959407101930465134, -0.058818321370234280532, -0.068352281408454867995, -0.061460298909070447404, -0.052235918421231680719, -0.072498226107478094815},
01049     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.21211506894042392313, 0.1693324759070968244, 0.16427164509165567696, 0.12206249376578166832, 0.059425221503678751778, 0.10342818163255371178},
01050     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.00082310131655814202344, 0.00076119821363284040708, 0.0011383177083823211358, 0.00088025107979697856699, 0.00053811687741542281113, 0.0012072828551724611168},
01051     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.90513569051375386554, 0.84830498879329219175, 0.61907648481747246105, 0.62281733240515868566, 0.96959526780257299095, 0.22278747273629403991}
01052   };
01053 const double CSCTFPtMethods::A_sig24[3][15] = 
01054   {
01055      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.036897103741702109991, 0.039899187881393870236, 0.037199371928606554671, 0.044110460084859734464, 0.04574632914580819415, 0.043819228659279139959},
01056      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.12588087914450593607, 0.096275574709463407341, 0.097301378507412841778, 0.062284950968221723666, 0.040981290949611878793, 0.062080679266191686472},
01057      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.00015197851743841865125, 0.00020141684336612834154, 0.00023753469072643055345, 5.280883524679438998e-05, 5.5577569515852236366e-05, 6.1083145679098556401e-05}
01058   };
01059 const double CSCTFPtMethods::A_mu34[4][15] = 
01060   {
01061     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.0058446275511135183447, -0.0044363335612002457661, -0.0063690633680748938092, -0.0071732602982787522714, -0.0060076595959582691081, -0.0097192787716524169095},
01062     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.069899440774008433919, 0.041945454306693608082, 0.033695321175754334997, 0.02572107994967174141, 0.011966531649750349747, 0.013632158523237790024},
01063     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.00028713324507221590172, -0.00029722368993748908127, -0.00021881992359872021571, -0.00019444183718237873664, -0.00019245346134829781652, -4.7403620157884084486e-05},
01064     {0, 0, 0, 0, 0, 0, 0, 0, 0, 1.23011991602398707, 1.3460026509066507217, 1.3048596027895269511, 1.1101126497057096643, 1.3404667534791459005, 1.1961024662925265893}
01065   };
01066 const double CSCTFPtMethods::A_sig34[3][15] = 
01067   {
01068      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.014243461206981972156, 0.010278183995352333305, 0.013373297961434488582, 0.018049641090122695714, 0.018285814028279508137, 0.018004419633993375832},
01069      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.080281940189430453514, 0.097702954127336857915, 0.068717674384759980244, 0.047838267178665204449, 0.043271382660605303694, 0.034571413197575895371},
01070      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.00019610172919627981338, 0.00020181030100052541531, 9.721123551963389408e-05, 7.9515919724251022879e-05, 3.152903608551011833e-05, -1.5281155054305934032e-05}
01071   };
01072 
01073 /*
01074 const double CSCTFPtMethods::A_mu23CSCTF[4][15] = 
01075   {
01076     {0, 0, -0.05159583579882612292, -0.057495850955557127604, -0.038777381197559336601, -0.034650103854195257735, -0.035866685307932126558, -0.036520018265937925772, -0.039140048431005991514, -0.04132313862170765989, -0.036795418654570546946, -0.034712298048110004633, -0.030675971294882777712, -0.026581567107835060715, -0.027082610124683551694},
01077     {0, 0, 0.30930157379625533576, 0.30528792735566101513, 0.18101621729540517958, 0.13261043687180154582, 0.11710185518524707238, 0.1042269425450448872, 0.12842978872597279882, 0.11026714080229071957, 0.077195052828225488306, 0.052779807661988357992, 0.031907294195008026327, 0.015010793353952620391, 0.0083693744640667474405},
01078     {0, 0, 0.003303237228747075635, 0.0036877622923072827903, 0.0028778748613812418257, 0.0027697479676805046578, 0.0029722472234315878113, 0.0027557729541331493078, 0.0027439686054866367984, 0.0027429867920243330461, 0.0026205380860322580877, 0.0025684796211763527909, 0.0024501533836338673482, 0.0022886566312508992323, 0.0023109047428951515549},
01079     {0, 0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778}
01080   };
01081 const double CSCTFPtMethods::A_sig23CSCTF[3][15] = 
01082   {
01083      {0, 0, 1.9795336160186027818e-14, 1.9915059185082739646e-14, 3.1018595894952150083e-13, 3.247104191431149367e-15, 8.1315162936412832551e-20, 1.240503468176445967e-14, 5.42101086242752217e-20, 1.0611672131288774068e-13, 1.5769479363818283968e-13, 1.3950757324528162417e-13, 9.006754760412793992e-14, 6.4351600220433069488e-14, 3.422793732471562933e-14},
01084      {0, 0, 0.16247290882387102617, 0.17175130285728712476, 0.12863499593873295446, 0.087195343431809388401, 0.075178796525218818947, 0.084968005914806410406, 0.097534051101499472103, 0.10072101959821762318, 0.086515842289935293574, 0.077487068666586722543, 0.066495426545906038962, 0.05829523793723847408, 0.058469062331064518279},
01085      {0, 0, 0.0030866184008234202017, 0.0027157845892710396826, 0.0031000107472930020502, 0.0032948728256854639164, 0.0032523838944876529676, 0.0032908170044063911851, 0.0031077703733701392101, 0.003168310045777431895, 0.0031995826882447926144, 0.0033172473608836330373, 0.003481731357302361371, 0.0035885923423450909013, 0.0036197682854273677093}
01086   };
01087 const double CSCTFPtMethods::A_mu24CSCTF[4][15] = 
01088   {
01089     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.040588070215567317867, -0.037244899938720932298, -0.032557928194235655206, -0.033625486248390609734, -0.030979888871088396424, -0.034417775727303090427},
01090     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.14679164922919202274, 0.10155103197601543508, 0.05654629310554831062, 0.045376829456755543579, 0.027509877797561234358, 0.023419523710039816256},
01091     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.0020633358759647897618, 0.001896533050698436711, 0.0017858761282068486096, 0.001844050222271934221, 0.0017557139477893672803, 0.0018426777898371733428},
01092     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.8287338692316308375, 0.99774828307731855404, 1.1829866290816364316, 1.1602087549628306018, 1.2464326048294538385, 1.2759641819434877075}
01093   };
01094 const double CSCTFPtMethods::A_sig24CSCTF[3][15] = 
01095   {
01096      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.037625952557573547064, 0.01799213091317735172, 1.6125862879181815379e-11, 1.0562397310953652863e-12, 1.241077634541939978e-12, 0.0010355011396506045348},
01097      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.042427032035622765094, 0.098803329688397070751, 0.14389559700484103044, 0.13799560522998333134, 0.12970987520579105312, 0.12360506328208811788},
01098      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.0016583711392086320988, 0.0026285030865632191821, 0.0035332492384275056285, 0.0035536381484177958709, 0.0036008804486243150937, 0.003671342260090017847}
01099   };
01100 const double CSCTFPtMethods::A_mu34CSCTF[4][15] = 
01101   {
01102     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.024386862247056880632, -0.021528537191676071216, -0.02005083006670880727, -0.01336094590546606925, -0.011202986245246833105, -0.010221348552148104907},
01103     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.13932346391503466765, 0.10879329554634586952, 0.082131024131389118725, 0.049386143583177943839, 0.031626039045900805613, 0.018428910788041489438},
01104     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.002260334327917361795, 0.0022298163315863312253, 0.0022548694122104897576, 0.0018759307742583139749, 0.00177881208252465557, 0.0017313182633728260718},
01105     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778, 0.5999999999999999778}
01106   };
01107 const double CSCTFPtMethods::A_sig34CSCTF[3][15] = 
01108   {
01109      {0, 0, 0, 0, 0, 0, 0, 0, 0, 8.7898167477201694098e-15, 9.6596450456509774796e-15, 5.8301345522149272682e-15, 4.2091980942404738641e-15, 5.3458485468199645751e-15, 3.1712051604473878719e-13},
01110      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.093687563387992001118, 0.079820927326800600321, 0.066984420892720844543, 0.056708328335080805671, 0.047536365785603315604, 0.038169598629265347189},
01111      {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.0030253104511002268558, 0.0031726875548676886779, 0.0032496716988121504902, 0.0033443354915219845012, 0.0034738654347779623563, 0.0036318730482019275646}
01112 //
01113   };
01114 */
01115 
01116 /*
01117 // correlation
01118 const double CSCTFPtMethods::A_rho123FrontCSCTF[5][15] = 
01119   {
01120     {0, 0, 0, -7.1040670977031510347, -12.670315837935662628, -8.7170331637018456661, -0.67519391792989291723, -82.734134458636077625, -0.75423027516740670517, -1.5375638068488624022, -1.9436626689216969233, -3.3048393305106831264, 0, 0, 0},
01121     {0, 0, 0, 13.120105991486797237, 24.351734925387280128, 17.466447377883568493, 3.4093984643667423207, 194.02337279340923715, 2.3366398860307699969, 3.18999491763136378, 3.6653450973208929753, 5.5669645488507377706, 0, 0, 0},
01122     {0, 0, 0, -6.3122732945347292954, -12.092235620129875073, -8.964306376251860442, -2.0956518253881668556, -14.276757245102295713, -1.052341283927880955, -1.3351509494835234193, -1.4259213982588558878, -1.7115493310298179885, 0, 0, 0},
01123     {0, 0, 0, 0.88435981237335747895, 1.7435813620171676241, 1.3426959412552754713, 0.34444942151920626694, -87.449791709635917414, 0.12377690603711703765, 0.15538477196375066747, 0.15008809252689520042, 0.10296388213110005405, 0, 0, 0},
01124     {0, 0, 0, 0.6301630452598394605, 0.95776009332113687389, 0.9017528066816278276, 0.50478537372345588796, 4.2993192028223639056, 0.44617114302999638653, 0.34541691945594366064, 0.42054938381219214572, 0.7433264993299159018, 0, 0, 0}
01125   };
01126 const double CSCTFPtMethods::A_rho124FrontCSCTF[5][15] = 
01127   {
01128     {0, 0, 0, 0, 0, 0, 0, 0, -67.653257351760515803, -14.640453888061129462, -8.0061864057341729506, -6.380532066411966241, 0, 0, 0},
01129     {0, 0, 0, 0, 0, 0, 0, 0, 199.99999998356389597, 18.625354490890874359, 10.511672179624257595, 8.772341856627665635, 0, 0, 0},
01130     {0, 0, 0, 0, 0, 0, 0, 0, -190.6065599611967798, -3.7847886886961528141, -2.2651826031392530147, -1.9160721119800219192, 0, 0, 0},
01131     {0, 0, 0, 0, 0, 0, 0, 0, 58.439288729233759057, -2.3364343906401296991e-06, 3.6855623904152867709e-07, -3.0414002648998517131e-06, 0, 0, 0},
01132     {0, 0, 0, 0, 0, 0, 0, 0, 2.8796301484731765541, 1.3626067779332513563, 1.0087454870715759636, 0.90653374832410571482, 0, 0, 0}
01133   };
01134 const double CSCTFPtMethods::A_rho134FrontCSCTF[5][15] = 
01135   {
01136     {0, 0, 0, 0, 0, 0, 0, 0, 0, -5.1253686146165238213, -3.9460979852191035988, 50.876993645544430933, 0, 0, 0},
01137     {0, 0, 0, 0, 0, 0, 0, 0, 0, 8.6945510876485556651, 6.9804335263398149536, -138.23002940118752235, 0, 0, 0},
01138     {0, 0, 0, 0, 0, 0, 0, 0, 0, -3.7766962717672067917, -3.021481709800325266, 114.72054763323052384, 0, 0, 0},
01139     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.47276435137618078031, 0.37604585592516825976, -25.936589905717454485, 0, 0, 0},
01140     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.67139180168906242852, 0.65599257431238855443, 2.2983843503797514174, 0, 0, 0}
01141   };
01142 const double CSCTFPtMethods::A_rho123RareCSCTF[5][15] = 
01143   {
01144     {0, 3.693736660096563762e-07, -6.3780194230193432148, -13.770035906375994728, -5.1562051118343141809, -3.7461867441730016814, -1.2805080447177172864, 0.50294375115506961826, -1.4740723006986149457, -2.5387426474729517523, -2.1923622917088105844, -3.0911905495886267126, 0, 0, 0},
01145     {0, 1.2460479107724575787e-08, 11.270599218378388073, 22.392173152402016001, 9.3862642825355049325, 7.7578075325167734633, 4.2953294294048536273, 0.22827419724359693243, 3.4825602170197607066, 5.0470037914562615455, 4.4340011683393560915, 6.2256125281916929737, 0, 0, 0},
01146     {0, -3.4521070809865814222e-09, -5.0004899240308509079, -10.311644488849697865, -4.282123228906844048, -3.7150337817860408229, -2.2556284401727886291, -0.25683718959054824271, -1.5532530344313972837, -2.0501268102747358668, -1.6048499907132562914, -2.42639211677826383, 0, 0, 0},
01147     {0, 0.11247782203128549317, 0.65621333795917502485, 1.4508425971339706795, 0.57554752401241371373, 0.51651149712728827712, 0.32553981050209734871, 0.041454698814621479541, 0.1892053332712004543, 0.23183666635265892664, 0.14070399770166691633, 0.25037305153793043555, 0, 0, 0},
01148     {0, 5.2468060541259898405e-05, 0.59902231088968072026, 0.64691306718481345062, 0.56825725017267580963, 0.55227308775738792601, 0.52292618714173277894, 0.15015264640230108206, 0.47276305428305431811, 0.58130632102024715202, 0.66287057871639254447, 0.70571047503796380251, 0, 0, 0}
01149   };
01150 const double CSCTFPtMethods::A_rho124RareCSCTF[5][15] = 
01151   {
01152     {0, 0, 0, 0, 0, 0, 0, 0, -62.063614454439573365, -9.3911739932179134627, -6.1205175819402386495, -3.1911920231298327444, 0, 0, 0},
01153     {0, 0, 0, 0, 0, 0, 0, 0, 176.01031612404437965, 12.375741099204100593, 8.5587121090773408127, 5.7559625518179906578, 0, 0, 0},
01154     {0, 0, 0, 0, 0, 0, 0, 0, -160.26616104904954341, -2.5400842729151151822, -1.8386520927660907621, -2.1326757988726772197, 0, 0, 0},
01155     {0, 0, 0, 0, 0, 0, 0, 0, 46.856826297399912562, -4.8053174807327625473e-07, 3.6069918621373098233e-07, 0.21904388264162638622, 0, 0, 0},
01156     {0, 0, 0, 0, 0, 0, 0, 0, 2.6686667219206672286, 1.1798705662301880448, 0.9751334566408034199, 0.50657760373212734617, 0, 0, 0}
01157   };
01158 const double CSCTFPtMethods::A_rho134RareCSCTF[5][15] = 
01159   {
01160     {0, 0, 0, 0, 0, 0, 0, 0, 0, 22.63925623244709584, 33.307602374459399641, -4.7351194818759818617, 0, 0, 0},
01161     {0, 0, 0, 0, 0, 0, 0, 0, 0, -81.727537829168539929, -106.94890709205490964, 9.1466321665848884237, 0, 0, 0},
01162     {0, 0, 0, 0, 0, 0, 0, 0, 0, 81.287234092264910146, 99.769637227574477834, -3.9238059375998592948, 0, 0, 0},
01163     {0, 0, 0, 0, 0, 0, 0, 0, 0, -19.366748957614952076, -21.885672253322599801, 0.45930089549956160111, 0, 0, 0},
01164     {0, 0, 0, 0, 0, 0, 0, 0, 0, 2.3976365353544930592, 2.6613591378002552368, 0.90958735012798141994, 0, 0, 0}
01165   };
01166 const double CSCTFPtMethods::A_rho234CSCTF[5][15] = 
01167   {
01168     {0, 0, 0, 0, 0, 0, 0, 0, 0, -9.8545541776242284726, -64.883134763134137302, -2.7111481630799327824, -0.094635535725662925377, -0.24145993067693449774, -0.86334668692406080215},
01169     {0, 0, 0, 0, 0, 0, 0, 0, 0, 20.483521463583567623, 128.78793309543945611, 8.4668465066294569255, 3.2196840916959703627, 3.5062716967070435281, 4.8689870431603861078},
01170     {0, 0, 0, 0, 0, 0, 0, 0, 0, -10.072715847457928362, -81.865408753031090328, -4.2797400827660840861, -1.8900888882082564901, -2.0494364954339538976, -2.6715697235200512871},
01171     {0, 0, 0, 0, 0, 0, 0, 0, 0, 1.4368420319765635718, 44.864139609984853507, 0.57906617181020891838, 0.27668065500104588317, 0.30413204972393043102, 0.38082905421452400985},
01172     {0, 0, 0, 0, 0, 0, 0, 0, 0, 1.1952334817255199084, 3.5585102799355743386, 1.062066264100966162, 0.76269875289384825301, 0.75934194995400139394, 0.84343143505690310047}
01173   };
01174 */
01175 // correlation is calculated without CSCTF resolution
01176 const double CSCTFPtMethods::A_rho123FrontCSCTF[5][15] = 
01177   {
01178     {0, 0, 0, -1.8018355270558423786, -3.0800442413303450451, -73.019003781704810763, -71.455790570687398144, -64.380384468942153831, 2.1550121774347754666, 2.5576552488389672213, 2.449616802429892104, 2.6048654763866916362, 0, 0, 0},
01179     {0, 0, 0, -2.1007675246065984354, 5.0425956104081919307, 199.99999998505296617, 197.550283903424031, 199.99999998947504309, -3.6752175165788334432, -5.1722529027050292427, -4.3622079033393852399, -3.8822092661387657131, 0, 0, 0},
01180     {0, 0, 0, 4.7467280498208239692, -0.9954101483761357283, -174.31370635014994264, -172.76138545990900752, -195.76348611065316163, 3.4105036734574345481, 4.6147873662827647578, 3.7484788313774726198, 3.1712066148946220778, 0, 0, 0},
01181     {0, 0, 0, 0.30810891952961361184, -1.5943850767419220915e-06, 54.774256057823905053, 53.990647071858525408, 62.484493391665445472, -0.69848464296741152868, -0.91930506751317175862, -0.74283883233049896599, -0.63029551267626326982, 0, 0, 0},
01182     {0, 0, 0, 1.5832663901749726154, 0.74552216086091394054, 2.3871718840149540597, 2.3429031884405246977, 2.5923987724387411724, 0.78470036712835855575, 0.84997184658808944135, 0.77449725473134001241, 0.7103384244719952445, 0, 0, 0}
01183   };
01184 const double CSCTFPtMethods::A_rho124FrontCSCTF[5][15] = 
01185   {
01186     {0, 0, 0, 0, 0, 0, 0, 0, 0, 1.3870060999256690337, 2.9712356450806232111, 3.570810174736656073, 0, 0, 0},
01187     {0, 0, 0, 0, 0, 0, 0, 0, 0, -2.5249315692538325528, -5.0029964029336300158, -5.9723457657194050086, 0, 0, 0},
01188     {0, 0, 0, 0, 0, 0, 0, 0, 0, 2.5905258665507675531, 3.7350919226554304409, 4.4308882990573090765, 0, 0, 0},
01189     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.46509034721864128681, -0.65123509278498414865, -0.77222404956138701593, 0, 0, 0},
01190     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.80362588618902608406, 0.76388670904989408594, 0.8119443249235495097, 0, 0, 0}
01191   };
01192 const double CSCTFPtMethods::A_rho134FrontCSCTF[5][15] = 
01193   {
01194     {0, 0, 0, 0, 0, 0, 0, 0, 0, 1.9650106495811070495, 4.4682144046367060497, 3.6127345552596952238, 0, 0, 0},
01195     {0, 0, 0, 0, 0, 0, 0, 0, 0, -2.8639423697800454605, -8.5042162539937766752, -6.2743097440414938859, 0, 0, 0},
01196     {0, 0, 0, 0, 0, 0, 0, 0, 0, 2.3846745836159768395, 6.2976695885419857746, 4.8907783903396619962, 0, 0, 0},
01197     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.45508861624906205012, -1.1535577557401812676, -0.887603855749135362, 0, 0, 0},
01198     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.61133320621013831353, 0.8416666357275194299, 0.84060163399865650558, 0, 0, 0}
01199   };
01200 const double CSCTFPtMethods::A_rho123RareCSCTF[5][15] = 
01201   {
01202     {0, 3.693736660096563762e-07, 3.6624889920579235536, -1.5878130861362493853, -16.882029490672145755, -19.782998814333478066, -60.455933184308456418, 4.7409034663087075145, 1.2313698717610916944, 4.0535624038761168819, 2.839672990936767949, 1.1264072104945499486, 0, 0, 0},
01203     {0, 1.2460479107724575787e-08, -9.1322692253088106895, 2.7885945213228429118, 35.574384349975474606, 52.562872763020486389, 165.96545891988304788, -7.8572084740661054525, -2.2073725837258022509, -8.2319545861659868535, -5.2739465547973312098, -1.6641893104460985242, 0, 0, 0},
01204     {0, -3.4521070809865814222e-09, 0.304049807886722534, -1.0070939003771062215, -25.509204584815140748, -43.856338459435548316, -142.9795139802988615, 5.1120722960994200434, 2.5507720910098483635, 6.5298492011791555711, 4.4578719360600889132, 2.2487455007422072484, 0, 0, 0},
01205     {0, 0.11247782203128549317, 6.1743739480412145326, 0.11162411914689808479, 8.9528675403092599083, 15.100558849256662697, 44.430568006333729159, -0.9341261050017011236, -0.55701647459573400134, -1.2571707419142834627, -0.88779580801276813951, -0.51779245640493165581, 0, 0, 0},
01206     {0, 5.2468060541259898405e-05, 1.8940496384956984066, 0.066707207826664116634, 1.7508237418861856138, 1.8900280458873763845, 2.1844068317738409846, 0.76180412238695105476, 0.72372957011062566401, 0.89275082928758009437, 0.81250184984526685472, 0.71783981961882159517, 0, 0, 0}
01207   };
01208 const double CSCTFPtMethods::A_rho124RareCSCTF[5][15] = 
01209   {
01210     {0, 0, 0, 0, 0, 0, 0, 0, 0, 3.6863837484595949334, 2.3224336525694582178, 3.2507026803368823664, 0, 0, 0},
01211     {0, 0, 0, 0, 0, 0, 0, 0, 0, -6.9075821699787951502, -4.3426737934213210934, -6.2428017762167931082, 0, 0, 0},
01212     {0, 0, 0, 0, 0, 0, 0, 0, 0, 5.1741882361155777659, 3.6659747818805397124, 5.1137870308059385493, 0, 0, 0},
01213     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.8788429753762293517, -0.6687776952912940498, -0.89611818355296113392, 0, 0, 0},
01214     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.89064996021251574554, 0.79339716446029262542, 0.92504977817804989737, 0, 0, 0}
01215   };
01216 const double CSCTFPtMethods::A_rho134RareCSCTF[5][15] = 
01217   {
01218     {0, 0, 0, 0, 0, 0, 0, 0, 0, 3.4612440846722587473, 5.7154640478562965811, 6.1988763822017318716, 0, 0, 0},
01219     {0, 0, 0, 0, 0, 0, 0, 0, 0, -5.7252426310553330424, -10.734814097449786985, -11.773479219426080888, 0, 0, 0}, 
01220     {0, 0, 0, 0, 0, 0, 0, 0, 0, 4.1825411479975462825, 7.4929964403945605866, 8.4655628853855269256, 0, 0, 0},
01221     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.76190351147590362757, -1.349101837260204606, -1.4909015696715794963, 0, 0, 0},
01222     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.73180297067413413448, 0.85937126410475961347, 0.96408406745158758966, 0, 0, 0}
01223   };
01224 //
01225 const double CSCTFPtMethods::A_rho234CSCTF[5][15] = 
01226   {
01227     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.90545523934272553745, 0.87175008048078328482, 11.473027189906936485, 11.663806475851881572, 0.42441495626586411838, 0.32838673222117276129},
01228     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.44139458152853866535, -0.42393288245808863346, -22.394533628750806997, -23.701781706067023947, 0.3795109868989199331, 0.61276617249320963765},
01229     {0, 0, 0, 0, 0, 0, 0, 0, 0, 0.051844682585598461655, 0.049996912305763613338, 16.507523030995347568, 17.496995261382853215, -0.25771028946901503032, -0.35814371755433299649},
01230     {0, 0, 0, 0, 0, 0, 0, 0, 0, 2.7429208195040022389e-07, 9.0318461390404003453e-08, -3.1629404839892929502, -3.4008584782052286855, 0.032310851118482836197, 0.04444079467290308616},
01231     {0, 0, 0, 0, 0, 0, 0, 0, 0, -0.42794073513595692893, -0.42484700224018712156, 1.2597467573071601254, 1.2343273593218078155, -0.1335866415068663049, -0.10123375520631937297}
01232   };
01233  
01234 // Constructor
01235 CSCTFPtMethods::CSCTFPtMethods( const L1MuTriggerPtScale* ptScale )
01236   : trigger_scale( ptScale )
01237 {
01238 }
01239 
01240 // compute PT from dphi = A/Pt + B/Pt^2
01241 // this involves solving the quadratic equation and storing it as Pt
01242 // out of the two possible roots, the return value is always the larger value for Pt
01243 
01244 float CSCTFPtMethods::Pt2Stn(int type, float eta, float dphi, int fr) const 
01245 {
01246   float A = 0; 
01247   float B = 0;
01248   if (dphi == 0.0) dphi = 1.e-6;
01249   if (eta  < 0.0) eta  = static_cast<float>(fabs(static_cast<double>(eta)));
01250   if (dphi < 0.0) dphi = static_cast<float>(fabs(static_cast<double>(dphi)));
01252 #ifdef L1CSC_STANDALONE
01253   if (type == kME1andME2 && eta <= 1.25) fr = 1; 
01254 #else
01255   if (type == kME1andME2 && eta < 1.2) fr = 1; 
01256 #endif
01257   if (type >= kME1andME2 && 
01258       type <= kME2andMB2 && eta < 2.5) 
01259     {
01260       if (eta >= 0.0 && eta < 1.6)
01261         {
01262           A = AkLowEta_Fit2[type-1][0] + AkLowEta_Fit2[type-1][1]*eta 
01263             + AkLowEta_Fit2[type-1][2]*eta*eta + AkLowEta_Fit2[type-1][3]*eta*eta*eta;
01264           B = BkLowEta_Fit2[type-1][0] + BkLowEta_Fit2[type-1][1]*eta 
01265             + BkLowEta_Fit2[type-1][2]*eta*eta + BkLowEta_Fit2[type-1][3]*eta*eta*eta;
01266           if (fr >= 0 && fr <= 1) 
01267             {     
01268               A *= FRCorrLowEta[type-1][fr];
01269               B *= FRCorrLowEta[type-1][fr];
01270             } 
01271         }       
01272       
01273       if (eta >= 1.6 && eta < 2.5)
01274         {
01275           A = AkHighEta_Fit2[type-1][0] + AkHighEta_Fit2[type-1][1]*eta 
01276             + AkHighEta_Fit2[type-1][2]*eta*eta + AkHighEta_Fit2[type-1][3]*eta*eta*eta;
01277           B = BkHighEta_Fit2[type-1][0] + BkHighEta_Fit2[type-1][1]*eta 
01278             + BkHighEta_Fit2[type-1][2]*eta*eta + BkHighEta_Fit2[type-1][3]*eta*eta*eta;
01279         if (fr >= 0 && fr <= 1) 
01280           {
01281             A *= FRCorrHighEta[type-1][fr];
01282             B *= FRCorrHighEta[type-1][fr];
01283           } 
01284         }
01285       
01286       A *= kGlobalScaleFactor;
01287       B *= kGlobalScaleFactor;
01288       float Pt = (A + sqrt(A*A + 4.*dphi*B))/(2.*dphi);
01289 
01290       //      return (Pt>0.0) ? Pt : 0.0;
01291       return (Pt>trigger_scale->getPtScale()->getLowEdge(1)) ? Pt 
01292         : trigger_scale->getPtScale()->getLowEdge(1);
01293     }
01294     return 0.0;
01295 }
01296 
01297 float CSCTFPtMethods::Pt3Stn(int type, float eta, float dphi1, float dphi2, int fr ) const 
01298 {
01299     int ty1 = 0, ty2 =0;
01300 
01301     switch (type)
01302       {
01303       case 1 :
01304         ty1 = kME1andME2 -1; // subtype sets the right position for array A
01305         ty2 = kME2andME3 -1;
01306         break;
01307       case 2 :
01308         ty1 = kME1andME2 -1;
01309         ty2 = kME2andME4 -1;
01310         break;
01311       case 3 :
01312         ty1 = kME1andME3 -1;
01313         ty2 = kME3andME4 -1;
01314         break;
01315       case 4 :
01316         ty1 = kME2andME3 -1;
01317         ty2 = kME3andME4 -1;
01318         break;
01319       default:
01320         return 0.0;
01321       }
01322 
01323     // Switch to 2-Station measurement if dphi is too small
01324     // box cut around Pt of 10 GeV
01325     float Pt;
01326 //    if ( (fabs(static_cast<double>(dphi2))<0.004) &&
01327 //         (fabs(static_cast<double>(dphi1))<0.030)) {
01328     if ( fabs(static_cast<double>(dphi2))<0.004 ) 
01329       {
01330         Pt = Pt2Stn((ty1+1), eta, dphi1, fr);
01331       }
01332     else 
01333       {
01334         float c1=(-.2999 * (eta*eta*eta) + 2.030 * (eta*eta) - 4.235 * eta + 3.024) + 0.02;
01335         float c2=(-2.484 * (eta*eta*eta) + 14.43 * (eta*eta) - 27.66 * eta + 18.47)*.72;
01336         float r = 0.6; //correlation
01337         float A1 = 0; 
01338         float A2 = 0;
01339         
01340         if (dphi1 == 0.0) dphi1 = 1.e-6;
01341         if (dphi2 == 0.0) dphi2 = 1.e-6;    
01342         if (eta  < 0.0) eta  = static_cast<float>(fabs(static_cast<double>(eta)));
01343         if (eta >= 0.0 && eta < 1.6) 
01344           {
01345             A1 = AkLowEta_Fit1[ty1][0]         + AkLowEta_Fit1[ty1][1]*eta 
01346               + AkLowEta_Fit1[ty1][2]*eta*eta + AkLowEta_Fit1[ty1][3]*eta*eta*eta;
01347             A2 = AkLowEta_Fit1[ty2][0]         + AkLowEta_Fit1[ty2][1]*eta 
01348               + AkLowEta_Fit1[ty2][2]*eta*eta + AkLowEta_Fit1[ty2][3]*eta*eta*eta;
01349             if (fr >= 0 && fr <= 1) 
01350               {
01351                 A1 *= FRCorrLowEta[ty1][fr];
01352               }
01353           }
01354         
01355       if (eta >= 1.6 && eta < 2.5)
01356         {       
01357           A1 = AkHighEta_Fit1[ty1][0]         + AkHighEta_Fit1[ty1][1]*eta
01358             + AkHighEta_Fit1[ty1][2]*eta*eta + AkHighEta_Fit1[ty1][3]*eta*eta*eta;
01359           A2 = AkHighEta_Fit1[ty2][0]         + AkHighEta_Fit1[ty2][1]*eta
01360             + AkHighEta_Fit1[ty2][2]*eta*eta + AkHighEta_Fit1[ty2][3]*eta*eta*eta;
01361           if (fr >= 0 && fr <= 1) 
01362             {
01363               A1 *= FRCorrHighEta[ty1][fr];
01364             }
01365         }
01366       A1 *= kGlobalScaleFactor;
01367       A2 *= kGlobalScaleFactor;
01368       Pt = 1/((( -dphi1/c1/c1/A1+r*dphi2/c1/c2/A2+dphi1*r/c1/c2/A1-dphi2/c2/c2/A2)
01369                + sqrt( (dphi1/c1/c1/A1-r*dphi2/c1/c2/A2-dphi1*r/c1/A1/c2+dphi2/c2/c2/A2)
01370                        *(dphi1/c1/c1/A1-r*dphi2/c1/c2/A2-dphi1*r/c1/A1/c2+dphi2/c2/c2/A2)
01371                        + 8*(1-r*r)*(dphi1*dphi1/c1/c1/A1/A1-2*dphi1*dphi2*r/c1/A1/c2/A2
01372                                     +dphi2*dphi2/c2/c2/A2/A2)))/(4*(1-r*r)));
01373       
01374       } // end 2 or 3 station method
01375     //    if (Pt<0.0) Pt = 0.0;
01376     if (Pt<trigger_scale->getPtScale()->getLowEdge(1)) 
01377       Pt = trigger_scale->getPtScale()->getLowEdge(1);
01378 
01379     // switch to 2-stn Pt above 10 GeV:
01380     /*
01381       if (Pt>10.0) {
01382       switch (type)
01383       {
01384       case 1 :
01385       case 2 :
01386       Pt = Pt2Stn(1, eta, dphi1);
01387       break;
01388       case 3:
01389       Pt = Pt2Stn(2, eta, dphi1);
01390       break;
01391       case 4:
01392       Pt = Pt2Stn(3, eta, dphi1);
01393       }
01394       }
01395     */
01396     
01397     return Pt;
01398 }
01399 
01400 // Now for C.Yeh's Chisquare method
01401 
01402 /*
01403 type:
01404 sta1-2 = 0
01405 sta1-3 = 1
01406 sta2-3 = 2
01407 sta2-4 = 3
01408 sta1-2-3 = 4
01409 sta1-2-4 = 5
01410 
01411 2.0 <= pt < 140.0
01412 0.9 <= eta < 2.4
01413 
01414 Note: So far, 
01415 Pt2Stn only defined for types 0 and 1
01416 Pt3Stn only defined for types 4 and 5
01417 */
01418 
01419 //arrays for pt and eta bins
01420 
01421 const float CSCTFPtMethods::ptbins[29] = 
01422   {2.0, 2.5, 3.0, 3.5, 4.0, 4.5, 5.0, 6.0, 7.0, 8.0, 
01423    10.0, 12.0, 14.0, 16.0, 18.0, 20.0, 25.0, 30.0, 35.0, 40.0, 
01424    45.0, 50.0, 60.0, 70.0, 80.0, 90.0, 100.0, 120.0, 140.0};
01425 
01426 const float CSCTFPtMethods::etabins[16] = 
01427   {0.9, 1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 
01428    1.7, 1.8, 1.9, 2.0, 2.1, 2.2, 2.3, 2.4};
01429 
01430 double CSCTFPtMethods::Likelihood2(double *phi12, double *par_m12, double *par_sig12, double *v) const
01431    {
01432        double fitval = 0.;
01433        double Pi  = acos(-1.);
01434        double m12 = 0;
01435        if(v[0] > par_m12[3]) 
01436          m12 = par_m12[0]/(v[0]-par_m12[3]) + par_m12[1]/(v[0]-par_m12[3])/(v[0]-par_m12[3]) + par_m12[2]; //mu12
01437        double sig12 = 0.1;
01438        if(v[0] > 0.) sig12 = par_sig12[0]/v[0] + par_sig12[1]/v[0]/v[0] + par_sig12[2];//sig12  
01439 //     
01440        fitval = -(phi12[0] - m12)*(phi12[0] - m12)/2./sig12/sig12;
01441        fitval = fitval - log(sig12) - 0.5*log(2*Pi) ;
01442 
01443       return fitval;   }
01444 double CSCTFPtMethods::Likelihood2_2011(double *phi12, double *par_m12, double *par_sig12, double *v) const
01445    {
01446        double fitval = 0.;
01447        double Pi  = acos(-1.);
01448        double m12 = 0;
01449        if(v[0] > par_m12[3]) 
01450          m12 = par_m12[0]/(v[0]-par_m12[3]) + par_m12[1]/(v[0]-par_m12[3])/(v[0]-par_m12[3]) + par_m12[2]; //mu12
01451        double sig12 = 0.1;
01452        if(v[0] > par_sig12[3]) sig12 = par_sig12[0]/(v[0]-par_sig12[3]) + par_sig12[1]/(v[0]-par_sig12[3])/(v[0]-par_sig12[3]) + par_sig12[2];//sig12  
01453        if(sig12 <0.0015)sig12 = 0.0015;
01454 //     
01455        fitval = -(phi12[0] - m12)*(phi12[0] - m12)/2./sig12/sig12;
01456        fitval = fitval - log(sig12) - 0.5*log(2*Pi) ;
01457 
01458       return fitval;   }
01459 double CSCTFPtMethods::Likelihood(double *phi12, double *phi23, double *par_m12, double *par_m23, double *par_sig12, double *par_sig23, double *par_rho, double *v) const
01460    {
01461        double fitval = 0.;
01462        //double Pi  = acos(-1.);
01463        double m12 = 0.;
01464        if(v[0] > par_m12[3]) 
01465          m12 = par_m12[0]/(v[0]-par_m12[3]) + par_m12[1]/(v[0]-par_m12[3])/(v[0]-par_m12[3]) + par_m12[2]; //mu12
01466        double m23 = 0.;
01467        if(v[0] > par_m23[3]) 
01468          m23 = par_m23[0]/(v[0]-par_m23[3]) + par_m23[1]/(v[0]-par_m23[3])/(v[0]-par_m23[3]) + par_m23[2]; //mu23
01469        double sig12 = 0.1;
01470        if(v[0] > 0.) sig12 = par_sig12[0]/v[0] + par_sig12[1]/v[0]/v[0] + par_sig12[2];//sig12  
01471        double sig23 = 0.1;
01472        if(v[0] > 0.) sig23 = par_sig23[0]/v[0] + par_sig23[1]/v[0]/v[0] + par_sig23[2];//sig23  
01473 
01474        double rho = (par_rho[0] + par_rho[1]*log(v[0]) + par_rho[2]*log(v[0])*log(v[0]) + par_rho[3]*log(v[0])*log(v[0])*log(v[0]))*exp(-par_rho[4]*log(v[0])); //rho  
01475        if(rho > 0.95) rho = 0.95;
01476        if(rho < -0.95) rho = -0.95;
01477 //
01478        fitval = (phi12[0] - m12)*(phi12[0] - m12)/sig12/sig12 + (phi23[0] - m23)*(phi23[0] - m23)/sig23/sig23;
01479        fitval = fitval - 2.*rho*(phi12[0] - m12)*(phi23[0] - m23)/sig12/sig23;
01480        fitval = fitval*(-1./(2.*(1-rho*rho)));
01481        fitval = fitval - log(sig12) - log(sig23) - 0.5*log(1-rho*rho) ;
01482 
01483       return fitval;
01484    }
01485 double CSCTFPtMethods::Likelihood2011(double *phi12, double *phi23, double *par_m12, double *par_m23, double *par_sig12, double *par_sig23, double *par_rho, double *v) const
01486    {
01487        double fitval = 0.;
01488        //double Pi  = acos(-1.);
01489        double m12 = 0.;
01490        if(v[0] > par_m12[3]) 
01491          m12 = par_m12[0]/(v[0]-par_m12[3]) + par_m12[1]/(v[0]-par_m12[3])/(v[0]-par_m12[3]) + par_m12[2]; //mu12
01492        double m23 = 0.;
01493        if(v[0] > par_m23[3]) 
01494          m23 = par_m23[0]/(v[0]-par_m23[3]) + par_m23[1]/(v[0]-par_m23[3])/(v[0]-par_m23[3]) + par_m23[2]; //mu23
01495        double sig12 = 0.1;
01496        if(v[0] > par_sig12[3]) sig12 = par_sig12[0]/(v[0]-par_sig12[3]) + par_sig12[1]/(v[0]-par_sig12[3])/(v[0]-par_sig12[3]) + par_sig12[2];//sig12  
01497        double sig23 = 0.1;
01498        if(v[0] > par_sig23[3]) sig23 = par_sig23[0]/(v[0]-par_sig23[3]) + par_sig23[1]/(v[0]-par_sig23[3])/(v[0]-par_sig23[3]) + par_sig23[2];//sig12  
01499        if(sig12 <0.0015)sig12 = 0.0015;
01500        if(sig23 <0.0015)sig23 = 0.0015;
01501 
01502        double rho = (par_rho[0] + par_rho[1]*log(v[0]) + par_rho[2]*log(v[0])*log(v[0]) + par_rho[3]*log(v[0])*log(v[0])*log(v[0]))*exp(-par_rho[4]*log(v[0])); //rho  
01503        //if(rho > 0.95) rho = 0.95;
01504        //if(rho < -0.95) rho = -0.95;
01505        if(rho > 0.7) rho = 0.7;
01506        if(rho < -0.7) rho = -0.7;
01507        //rho = 0.4; 
01508 //
01509        fitval = (phi12[0] - m12)*(phi12[0] - m12)/sig12/sig12 + (phi23[0] - m23)*(phi23[0] - m23)/sig23/sig23;
01510        fitval = fitval - 2.*rho*(phi12[0] - m12)*(phi23[0] - m23)/sig12/sig23;
01511        fitval = fitval*(-1./(2.*(1-rho*rho)));
01512        fitval = fitval - log(sig12) - log(sig23) - 0.5*log(1-rho*rho) ;
01513 
01514       return fitval;
01515    }
01516 
01517 float CSCTFPtMethods::Pt2Stn2010(int type, float eta, float dphi, int fr, int method) const 
01518 {
01519     if(fabs(eta) >= 2.4) eta = 2.35;  
01520     double PTsolv = 1.; // for muon plus hypothesis
01521     double PTsolvMinus = 1.;//for muon minus hypothesis
01522     for(int iETA = 0; iETA < 15; iETA++){
01523     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
01524 
01525 // calculate curvers of mean and sigma 
01526               // calculate phi12 mean  
01527               double par1[4] = {0., 0., 0., 0.};
01528               //double phi12mean = fitf5(v, par1); //mu12 
01529               double par_sig1[3] = {0., 0., 0.};
01530         int iETA1 = iETA; 
01531         switch (type) // type = mode here
01532           {
01533           case 6 :  //1-2
01534                  if(fr == 1){
01535                    if(iETA1 < 3)iETA1 = 3;
01536                    if(iETA1 > 11)iETA1 = 11;
01537                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
01538                    par1[0] = A_mu12Front[0][iETA1];
01539                    par1[1] = A_mu12Front[1][iETA1];
01540                    par1[2] = A_mu12Front[2][iETA1];
01541                    par1[3] = A_mu12Front[3][iETA1];
01542                    par_sig1[0] = A_sig12Front[0][iETA1];
01543                    par_sig1[1] = A_sig12Front[1][iETA1];
01544                    par_sig1[2] = A_sig12Front[2][iETA1];
01545                  }
01546                  if(fr == 0){
01547                    if(iETA1 < 1)iETA1 = 1;
01548                    if(iETA1 > 11)iETA1 = 11;
01549                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
01550                    par1[0] = A_mu12Rare[0][iETA1];
01551                    par1[1] = A_mu12Rare[1][iETA1];
01552                    par1[2] = A_mu12Rare[2][iETA1];
01553                    par1[3] = A_mu12Rare[3][iETA1];
01554                    par_sig1[0] = A_sig12Rare[0][iETA1];
01555                    par_sig1[1] = A_sig12Rare[1][iETA1];
01556                    par_sig1[2] = A_sig12Rare[2][iETA1];
01557                  }
01558           break;
01559           case 7 :  //1-3
01560                  if(fr == 1){
01561                    if(iETA1 < 3)iETA1 = 3;
01562                    if(iETA1 > 11)iETA1 = 11;
01563                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
01564                    par1[0] = A_mu13Front[0][iETA1];
01565                    par1[1] = A_mu13Front[1][iETA1];
01566                    par1[2] = A_mu13Front[2][iETA1];
01567                    par1[3] = A_mu13Front[3][iETA1];
01568                    par_sig1[0] = A_sig13Front[0][iETA1];
01569                    par_sig1[1] = A_sig13Front[1][iETA1];
01570                    par_sig1[2] = A_sig13Front[2][iETA1];
01571                  }
01572                  if(fr == 0){
01573                    if(iETA1 < 2)iETA1 = 2;
01574                    if(iETA1 > 11)iETA1 = 11;
01575                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
01576                    par1[0] = A_mu13Rare[0][iETA1];
01577                    par1[1] = A_mu13Rare[1][iETA1];
01578                    par1[2] = A_mu13Rare[2][iETA1];
01579                    par1[3] = A_mu13Rare[3][iETA1];
01580                    par_sig1[0] = A_sig13Rare[0][iETA1];
01581                    par_sig1[1] = A_sig13Rare[1][iETA1];
01582                    par_sig1[2] = A_sig13Rare[2][iETA1];
01583                  }
01584           break;
01585           case 8 :  //2-3
01586                  if(iETA1 < 2)iETA1 = 2;
01587                  par1[0] = A_mu23[0][iETA1];
01588                  par1[1] = A_mu23[1][iETA1];
01589                  par1[2] = A_mu23[2][iETA1];
01590                  par1[3] = A_mu23[3][iETA1];
01591                  par_sig1[0] = A_sig23[0][iETA1];
01592                  par_sig1[1] = A_sig23[1][iETA1];
01593                  par_sig1[2] = A_sig23[2][iETA1];
01594           break;
01595           case 9 :  //2-4
01596                  if(iETA1 < 9)iETA1 = 9;
01597                  par1[0] = A_mu24[0][iETA1];
01598                  par1[1] = A_mu24[1][iETA1];
01599                  par1[2] = A_mu24[2][iETA1];
01600                  par1[3] = A_mu24[3][iETA1];
01601                  par_sig1[0] = A_sig24[0][iETA1];
01602                  par_sig1[1] = A_sig24[1][iETA1];
01603                  par_sig1[2] = A_sig24[2][iETA1];
01604           break;
01605           case 10 :  //3-4
01606                  if(iETA1 < 9)iETA1 = 9;
01607                  par1[0] = A_mu34[0][iETA1];
01608                  par1[1] = A_mu34[1][iETA1];
01609                  par1[2] = A_mu34[2][iETA1];
01610                  par1[3] = A_mu34[3][iETA1];
01611                  par_sig1[0] = A_sig34[0][iETA1];
01612                  par_sig1[1] = A_sig34[1][iETA1];
01613                  par_sig1[2] = A_sig34[2][iETA1];
01614           break;
01615           case 13 :  //1-4
01616                  if(iETA1 < 9)iETA1 = 9;
01617                  if(iETA1 > 12)iETA1 = 12;
01618                  if(fr == 1){
01619                    par1[0] = A_mu14Front[0][iETA1];
01620                    par1[1] = A_mu14Front[1][iETA1];
01621                    par1[2] = A_mu14Front[2][iETA1];
01622                    par1[3] = A_mu14Front[3][iETA1];
01623                    par_sig1[0] = A_sig14Front[0][iETA1];
01624                    par_sig1[1] = A_sig14Front[1][iETA1];
01625                    par_sig1[2] = A_sig14Front[2][iETA1];
01626                  }
01627                  if(fr == 0){
01628                    par1[0] = A_mu14Rare[0][iETA1];
01629                    par1[1] = A_mu14Rare[1][iETA1];
01630                    par1[2] = A_mu14Rare[2][iETA1];
01631                    par1[3] = A_mu14Rare[3][iETA1];
01632                    par_sig1[0] = A_sig14Rare[0][iETA1];
01633                    par_sig1[1] = A_sig14Rare[1][iETA1];
01634                    par_sig1[2] = A_sig14Rare[2][iETA1];
01635                  }
01636           break;
01637           case 11 : // b1-3
01638                  if(iETA1 != 2)iETA1 = 2;
01639                  par1[0] = A_mu53[0][iETA1];
01640                  par1[1] = A_mu53[1][iETA1];
01641                  par1[2] = A_mu53[2][iETA1];
01642                  par1[3] = A_mu53[3][iETA1];
01643                  par_sig1[0] = A_sig53[0][iETA1];
01644                  par_sig1[1] = A_sig53[1][iETA1];
01645                  par_sig1[2] = A_sig53[2][iETA1];
01646                 
01647           break;
01648           case 12 :  //1-2-b1 = 2-b1 for pt_method < 10, for pt_method > 10: b1-2
01649                  if(iETA1 < 1)iETA1 = 1;
01650                  if(iETA1 > 2)iETA1 = 2;
01651                  par1[0] = A_mu52[0][iETA1];
01652                  par1[1] = A_mu52[1][iETA1];
01653                  par1[2] = A_mu52[2][iETA1];
01654                  par1[3] = A_mu52[3][iETA1];
01655                  par_sig1[0] = A_sig52[0][iETA1];
01656                  par_sig1[1] = A_sig52[1][iETA1];
01657                  par_sig1[2] = A_sig52[2][iETA1];
01658           break;
01659           case 14 :  //2-b1 for pt_method < 10 and b1-1 for pt_method > 10
01660                  if(method < 10){
01661                     if(iETA1 < 1)iETA1 = 1;
01662                     if(iETA1 > 2)iETA1 = 2;
01663                  }
01664                  par1[0] = A_mu52[0][iETA1];
01665                  par1[1] = A_mu52[1][iETA1];
01666                  par1[2] = A_mu52[2][iETA1];
01667                  par1[3] = A_mu52[3][iETA1];
01668                  par_sig1[0] = A_sig52[0][iETA1];
01669                  par_sig1[1] = A_sig52[1][iETA1];
01670                  par_sig1[2] = A_sig52[2][iETA1];
01671                  if(method > 10){
01672                     if(iETA1 > 2)iETA1 = 2;
01673                     par1[0] = A_mu51[0][iETA1];
01674                     par1[1] = A_mu51[1][iETA1];
01675                     par1[2] = A_mu51[2][iETA1];
01676                     par1[3] = A_mu51[3][iETA1];
01677                     par_sig1[0] = A_sig51[0][iETA1];
01678                     par_sig1[1] = A_sig51[1][iETA1];
01679                     par_sig1[2] = A_sig51[2][iETA1];
01680                  }
01681           break;
01682           //default:
01683           //return 0.0;
01684           }    
01685 
01686 //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
01687           //if(fabs(dphi) >= 0.002)
01688           //if(fabs(dphi) >= 0.00)
01689           //if(fabs(dphi) >= 0.002 || (fabs(dphi) >= 0.01 && (type == 12 || type == 14)))
01690           //{
01691                   double pt = 140;
01692                   double dpt = 0.1;
01693                   double step = 5.;
01694                   while(pt > 2. ){
01695                       double par_phi12[1] = {dphi};
01696                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
01697                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.; 
01698                          v[0] = pt;
01699                          lpt1_1 = Likelihood2(par_phi12, par1, par_sig1, v);
01700                          v[0] = pt + dpt;
01701                          lpt1_2 = Likelihood2(par_phi12, par1, par_sig1, v);
01702                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
01703                          v[0] = pt - step;
01704                          lpt2_1 = Likelihood2(par_phi12, par1, par_sig1, v);
01705                          v[0] = pt - step + dpt;
01706                          lpt2_2 = Likelihood2(par_phi12, par1, par_sig1, v);
01707                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
01708                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
01709                       v[0] = pt - 0.5*step;
01710                       double fx = Likelihood2(par_phi12, par1, par_sig1, v);
01711                       v[0] = pt - 0.5*step + dpt;
01712                       double fxh = Likelihood2(par_phi12, par1, par_sig1, v);
01713                       v[0] = pt - 0.5*step + 2*dpt;
01714                       double fx2h = Likelihood2(par_phi12, par1, par_sig1, v);
01715     
01716                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
01717                       //if(lpt1*lpt2 <= 0 && lpt2nd < 0) std::cout << "lpt2nd < 0 dphi12 = " << dphi <<" PT = " << pt<< " eta =" << fabs(eta) << std::endl; 
01718                       //lpt2nd = 1.; // don't care about 2nd derivative
01719                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolv = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
01720 /*
01721                       if(pt == 140.){
01722                             v[0] = 200;
01723                             lpt2_1 = Likelihood2(par_phi12, par1, par_sig1, v);
01724                             v[0] = 200. + 5.;
01725                             lpt2_2 = Likelihood2(par_phi12, par1, par_sig1, v);
01726                             lpt2 = (lpt2_2-lpt2_1)/5.;
01727 
01728                             v[0] = 170.;
01729                             fx = Likelihood2(par_phi12, par1, par_sig1, v);
01730                             v[0] = 170.+5.;
01731                             fxh = Likelihood2(par_phi12, par1, par_sig1, v);
01732                             v[0] = 170.+2*5.;
01733                             fx2h = Likelihood2(par_phi12, par1, par_sig1, v);
01734                             lpt2nd = -(fx2h + fx - 2*fxh)/5./5.;
01735                       }
01736                       if(pt == 140. && lpt1*lpt2 <= 0 && lpt2nd > 0 && fabs(dphi) < 0.1 ){PTsolv = 137.5; break;}
01737 */
01738                       if(pt > 25) {dpt = 0.1; step = 5.;}
01739                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
01740                       pt = pt - step;
01741                   }// end while
01742 //*********** end solve equation for muon plus
01743 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
01744 // for one station method we know sing of muon: dphi > 0 for muon minus!!! => dphi = -dphi < 0
01745                   dphi = - dphi;
01746                   pt = 140;
01747                   dpt = 0.1;
01748                   step = 5.;
01749                   while(pt > 2. ){
01750                       double par_phi12[1] = {dphi};
01751                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
01752                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.;
01753                          v[0] = pt;
01754                          lpt1_1 = Likelihood2(par_phi12, par1, par_sig1, v);
01755                          v[0] = pt + dpt;
01756                          lpt1_2 = Likelihood2(par_phi12, par1, par_sig1, v);
01757                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
01758                          v[0] = pt - step;
01759                          lpt2_1 = Likelihood2(par_phi12, par1, par_sig1, v);
01760                          v[0] = pt - step + dpt;
01761                          lpt2_2 = Likelihood2(par_phi12, par1, par_sig1, v);
01762                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
01763                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
01764                       v[0] = pt - 0.5*step;
01765                       double fx = Likelihood2(par_phi12, par1, par_sig1, v);
01766                       v[0] = pt - 0.5*step + dpt;
01767                       double fxh = Likelihood2(par_phi12, par1, par_sig1, v);
01768                       v[0] = pt - 0.5*step + 2*dpt;
01769                       double fx2h = Likelihood2(par_phi12, par1, par_sig1, v);
01770     
01771                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
01772 
01773                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolvMinus = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
01774 /*
01775                       if(pt == 140.){
01776                             v[0] = 200;
01777                             lpt2_1 = Likelihood2(par_phi12, par1, par_sig1, v);
01778                             v[0] = 200. + 5.;
01779                             lpt2_2 = Likelihood2(par_phi12, par1, par_sig1, v);
01780 
01781                             lpt2 = (lpt2_2-lpt2_1)/5.;
01782 
01783                             v[0] = 170.;
01784                             fx = Likelihood2(par_phi12, par1, par_sig1, v);
01785                             v[0] = 170.+5.;
01786                             fxh = Likelihood2(par_phi12, par1, par_sig1, v);
01787                             v[0] = 170.+2*5.;
01788                             fx2h = Likelihood2(par_phi12, par1, par_sig1, v);
01789                             lpt2nd = -(fx2h + fx - 2*fxh)/5./5.;
01790                       }
01791                       if(pt == 140. && lpt1*lpt2 <= 0 && lpt2nd > 0 && fabs(dphi) < 0.1){PTsolvMinus = 137.5; break;}
01792 */
01793                       if(pt > 25) {dpt = 0.1; step = 5.;}
01794                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
01795                       pt = pt - step;
01796                   }// end while
01797 //          }// if(fabs(dphi) >= 0.002)
01798 //          else 
01799 //          {PTsolv = 137.5;} 
01800 
01801 //*********** end solve equation for muon minus 
01802           PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
01803           PTsolv = PTsolv*1.2;
01804           if(PTsolv > 137.5) PTsolv = 137.5;
01805           if(fabs(dphi) <= 0.002 && PTsolv < 120.)PTsolv = 140.;
01806           if( fabs(dphi) <= 0.01 && (type == 11 || type == 12 || type == 14) && PTsolv < 120.)PTsolv = 140.;
01807           dphi = - dphi; //return to correct sing dphi
01808 
01809     } //if(fabs(eta_TracMy) 
01810     } //end "for by iETA"
01811 
01812     float Pt = PTsolv;
01813     if(Pt > 10 && fabs(dphi) >= 0.1 ) std::cout << "iF = 0 for dphi = " << dphi <<" and Pt = " << Pt << std::endl;
01814                                                                     
01815     //if(Pt > 100 && (type == 12 || type == 14) && fabs(eta) <= 1.2 && dphi > 0.015 )std::cout << "dphi = " << dphi << " eta = " << eta << std::endl; 
01816     //if(Pt < 10 && (type == 12 || type == 14) && fabs(eta) <= 1.2 && dphi < 0.01)std::cout << "dphi = " << dphi << " eta = " << eta <<   std::endl; 
01817     //      return (Pt>0.0) ? Pt : 0.0;
01818 
01819     float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
01820     if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
01821 
01822     return (Pt > Pt_min)  ? Pt : Pt_min;
01823 }
01824 float CSCTFPtMethods::Pt2Stn2011(int type, float eta, float dphi, int fr, int method, int phiSign) const 
01825 {
01826 
01827 
01828 
01829     //if(fabs(eta) >= 2.4) eta = 2.35;  
01830     if(fabs(eta) >= 2.2) eta = 2.15;  
01831     double PTsolv = 1.; // for muon plus hypothesis
01832     double PTsolvMinus = 1.;//for muon minus hypothesis
01833     for(int iETA = 0; iETA < 15; iETA++){
01834     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
01835 
01836 // calculate curvers of mean and sigma 
01837               // calculate phi12 mean  
01838               double par1[4] = {0., 0., 0., 0.};
01839               //double phi12mean = fitf5(v, par1); //mu12 
01840               double par_sig1[4] = {0., 0., 0.,0};
01841         int iETA1 = iETA; 
01842         int iETA2 = iETA; 
01843 
01844         double (*Amean12FnoME11)[15] = AB_mu12FnoME11; 
01845         double (*Asig12FnoME11)[15] = AB_sig12FnoME11; 
01846         double (*Amean12RnoME11)[15] = AB_mu12RnoME11; 
01847         double (*Asig12RnoME11)[15] = AB_sig12RnoME11; 
01848 
01849         double (*Amean13FnoME11)[15] = AB_mu13FnoME11; 
01850         double (*Asig13FnoME11)[15] = AB_sig13FnoME11; 
01851         double (*Amean13RnoME11)[15] = AB_mu13RnoME11; 
01852         double (*Asig13RnoME11)[15] = AB_sig13RnoME11; 
01853 
01854         double (*Amean14FnoME11)[15] = AB_mu14FnoME11; 
01855         double (*Asig14FnoME11)[15] = AB_sig14FnoME11; 
01856         double (*Amean14RnoME11)[15] = AB_mu14RnoME11; 
01857         double (*Asig14RnoME11)[15] = AB_sig14RnoME11; 
01858         //
01859         double (*Amean12FME11)[15] = AB_mu12FME11; 
01860         double (*Asig12FME11)[15] = AB_sig12FME11; 
01861         double (*Amean12RME11)[15] = AB_mu12RME11; 
01862         double (*Asig12RME11)[15] = AB_sig12RME11; 
01863 
01864         double (*Amean13FME11)[15] = AB_mu13FME11; 
01865         double (*Asig13FME11)[15] = AB_sig13FME11; 
01866         double (*Amean13RME11)[15] = AB_mu13RME11; 
01867         double (*Asig13RME11)[15] = AB_sig13RME11; 
01868 
01869         double (*Amean14FME11)[15] = AB_mu14FME11; 
01870         double (*Asig14FME11)[15] = AB_sig14FME11; 
01871         double (*Amean14RME11)[15] = AB_mu14RME11; 
01872         double (*Asig14RME11)[15] = AB_sig14RME11; 
01873         //
01874         double (*Amean12F)[15] = AB_mu12F; 
01875         double (*Asig12F)[15] = AB_sig12F; 
01876         double (*Amean12R)[15] = AB_mu12R; 
01877         double (*Asig12R)[15] = AB_sig12R; 
01878 
01879         double (*Amean13F)[15] = AB_mu13F; 
01880         double (*Asig13F)[15] = AB_sig13F; 
01881         double (*Amean13R)[15] = AB_mu13R; 
01882         double (*Asig13R)[15] = AB_sig13R; 
01883 
01884         double (*Amean14F)[15] = AB_mu14F; 
01885         double (*Asig14F)[15] = AB_sig14F; 
01886         double (*Amean14R)[15] = AB_mu14R; 
01887         double (*Asig14R)[15] = AB_sig14R; 
01888 
01889         double (*Amean23)[15] = AB_mu23;
01890         double (*Asig23)[15] = AB_sig23;
01891         double (*Amean24)[15] = AB_mu24;
01892         double (*Asig24)[15] = AB_sig24;
01893         double (*Amean34)[15] = AB_mu34;
01894         double (*Asig34)[15] = AB_sig34;
01895 
01896         double (*Amean51)[15] = AB_mu51;
01897         double (*Asig51)[15] = AB_sig51;
01898         double (*Amean52)[15] = AB_mu52;
01899         double (*Asig52)[15] = AB_sig52;
01900         double (*Amean53)[15] = AB_mu53;
01901         double (*Asig53)[15] = AB_sig53;
01902 
01903         switch (type) // type = mode here
01904           {
01905           case 6 :  //1-2
01906                  if(fr == 1){
01907                    if(iETA1 < 3)iETA1 = 3;
01908                    //if(iETA1 > 11)iETA1 = 11;
01909                    par1[0] = (*(Amean12F+0))[iETA1];
01910                    par1[1] = (*(Amean12F+1))[iETA1];
01911                    par1[2] = (*(Amean12F+2))[iETA1];
01912                    par1[3] = (*(Amean12F+3))[iETA1];
01913                    par_sig1[0] = (*(Asig12F+0))[iETA1];
01914                    par_sig1[1] = (*(Asig12F+1))[iETA1];
01915                    par_sig1[2] = (*(Asig12F+2))[iETA1];
01916                    par_sig1[3] = (*(Asig12F+3))[iETA1];
01917                  }
01918                  if(fr == 0){
01919                    if(iETA1 < 1)iETA1 = 1;
01920                    //if(iETA1 > 11)iETA1 = 11;
01921                    par1[0] = (*(Amean12R+0))[iETA1];
01922                    par1[1] = (*(Amean12R+1))[iETA1];
01923                    par1[2] = (*(Amean12R+2))[iETA1];
01924                    par1[3] = (*(Amean12R+3))[iETA1];
01925                    par_sig1[0] = (*(Asig12R+0))[iETA1];
01926                    par_sig1[1] = (*(Asig12R+1))[iETA1];
01927                    par_sig1[2] = (*(Asig12R+2))[iETA1];
01928                    par_sig1[3] = (*(Asig12R+3))[iETA1];
01929                  }
01930             if(phiSign == 0){ // track belong to ME11 station
01931                  if(fr == 1){
01932                    if(iETA2 < 7)iETA2 = 7;
01933                    par1[0] = (*(Amean12FME11+0))[iETA2];
01934                    par1[1] = (*(Amean12FME11+1))[iETA2];
01935                    par1[2] = (*(Amean12FME11+2))[iETA2];
01936                    par1[3] = (*(Amean12FME11+3))[iETA2];
01937                    par_sig1[0] = (*(Asig12FME11+0))[iETA2];
01938                    par_sig1[1] = (*(Asig12FME11+1))[iETA2];
01939                    par_sig1[2] = (*(Asig12FME11+2))[iETA2];
01940                    par_sig1[3] = (*(Asig12FME11+3))[iETA2];
01941                  }
01942                  if(fr == 0){
01943                    if(iETA2 < 7)iETA2 = 7;
01944                    par1[0] = (*(Amean12RME11+0))[iETA2];
01945                    par1[1] = (*(Amean12RME11+1))[iETA2];
01946                    par1[2] = (*(Amean12RME11+2))[iETA2];
01947                    par1[3] = (*(Amean12RME11+3))[iETA2];
01948                    par_sig1[0] = (*(Asig12RME11+0))[iETA2];
01949                    par_sig1[1] = (*(Asig12RME11+1))[iETA2];
01950                    par_sig1[2] = (*(Asig12RME11+2))[iETA2];
01951                    par_sig1[3] = (*(Asig12RME11+3))[iETA2];
01952                  }
01953             }
01954             if(phiSign == 1){ // track belong to ME1/2 or ME1/3 station
01955                  if(fr == 1){
01956                    if(iETA2 < 3)iETA2 = 3;
01957                    if(iETA2 > 7)iETA2 = 7;
01958                    par1[0] = (*(Amean12FnoME11+0))[iETA2];
01959                    par1[1] = (*(Amean12FnoME11+1))[iETA2];
01960                    par1[2] = (*(Amean12FnoME11+2))[iETA2];
01961                    par1[3] = (*(Amean12FnoME11+3))[iETA2];
01962                    par_sig1[0] = (*(Asig12FnoME11+0))[iETA2];
01963                    par_sig1[1] = (*(Asig12FnoME11+1))[iETA2];
01964                    par_sig1[2] = (*(Asig12FnoME11+2))[iETA2];
01965                    par_sig1[3] = (*(Asig12FnoME11+3))[iETA2];
01966                  }
01967                  if(fr == 0){
01968                    if(iETA2 < 1)iETA2 = 1;
01969                    if(iETA2 > 6)iETA2 = 6;// rare ME1/2 only till 1.6
01970                    par1[0] = (*(Amean12RnoME11+0))[iETA2];
01971                    par1[1] = (*(Amean12RnoME11+1))[iETA2];
01972                    par1[2] = (*(Amean12RnoME11+2))[iETA2];
01973                    par1[3] = (*(Amean12RnoME11+3))[iETA2];
01974                    par_sig1[0] = (*(Asig12RnoME11+0))[iETA2];
01975                    par_sig1[1] = (*(Asig12RnoME11+1))[iETA2];
01976                    par_sig1[2] = (*(Asig12RnoME11+2))[iETA2];
01977                    par_sig1[3] = (*(Asig12RnoME11+3))[iETA2];
01978                  }
01979             }
01980 
01981           break;
01982           case 7 :  //1-3
01983                  if(fr == 1){
01984                    if(iETA1 < 3)iETA1 = 3;
01985                    //if(iETA1 > 11)iETA1 = 11;
01986                    par1[0] = (*(Amean13F+0))[iETA1];
01987                    par1[1] = (*(Amean13F+1))[iETA1];
01988                    par1[2] = (*(Amean13F+2))[iETA1];
01989                    par1[3] = (*(Amean13F+3))[iETA1];
01990                    par_sig1[0] = (*(Asig13F+0))[iETA1];
01991                    par_sig1[1] = (*(Asig13F+1))[iETA1];
01992                    par_sig1[2] = (*(Asig13F+2))[iETA1];
01993                    par_sig1[3] = (*(Asig13F+3))[iETA1];
01994                  }
01995                  if(fr == 0){
01996                    if(iETA1 < 3)iETA1 = 3;
01997                    //if(iETA1 > 11)iETA1 = 11;
01998                    par1[0] = (*(Amean13R+0))[iETA1];
01999                    par1[1] = (*(Amean13R+1))[iETA1];
02000                    par1[2] = (*(Amean13R+2))[iETA1];
02001                    par1[3] = (*(Amean13R+3))[iETA1];
02002                    par_sig1[0] = (*(Asig13R+0))[iETA1];
02003                    par_sig1[1] = (*(Asig13R+1))[iETA1];
02004                    par_sig1[2] = (*(Asig13R+2))[iETA1];
02005                    par_sig1[3] = (*(Asig13R+3))[iETA1];
02006                  }
02007             if(phiSign == 0){ // track belong to ME11 station
02008                  if(fr == 1){
02009                    if(iETA2 < 7)iETA2 = 7;
02010                    par1[0] = (*(Amean13FME11+0))[iETA2];
02011                    par1[1] = (*(Amean13FME11+1))[iETA2];
02012                    par1[2] = (*(Amean13FME11+2))[iETA2];
02013                    par1[3] = (*(Amean13FME11+3))[iETA2];
02014                    par_sig1[0] = (*(Asig13FME11+0))[iETA2];
02015                    par_sig1[1] = (*(Asig13FME11+1))[iETA2];
02016                    par_sig1[2] = (*(Asig13FME11+2))[iETA2];
02017                    par_sig1[3] = (*(Asig13FME11+3))[iETA2];
02018                  }
02019                  if(fr == 0){
02020                    if(iETA2 < 7)iETA2 = 7;
02021                    par1[0] = (*(Amean13RME11+0))[iETA2];
02022                    par1[1] = (*(Amean13RME11+1))[iETA2];
02023                    par1[2] = (*(Amean13RME11+2))[iETA2];
02024                    par1[3] = (*(Amean13RME11+3))[iETA2];
02025                    par_sig1[0] = (*(Asig13RME11+0))[iETA2];
02026                    par_sig1[1] = (*(Asig13RME11+1))[iETA2];
02027                    par_sig1[2] = (*(Asig13RME11+2))[iETA2];
02028                    par_sig1[3] = (*(Asig13RME11+3))[iETA2];
02029                  }
02030             }
02031             if(phiSign == 1){ // track belong to ME1/2 or ME1/3 station
02032                  if(fr == 1){
02033                    if(iETA2 < 3)iETA2 = 3;
02034                    if(iETA2 > 7)iETA2 = 7;
02035                    par1[0] = (*(Amean13FnoME11+0))[iETA2];
02036                    par1[1] = (*(Amean13FnoME11+1))[iETA2];
02037                    par1[2] = (*(Amean13FnoME11+2))[iETA2];
02038                    par1[3] = (*(Amean13FnoME11+3))[iETA2];
02039                    par_sig1[0] = (*(Asig13FnoME11+0))[iETA2];
02040                    par_sig1[1] = (*(Asig13FnoME11+1))[iETA2];
02041                    par_sig1[2] = (*(Asig13FnoME11+2))[iETA2];
02042                    par_sig1[3] = (*(Asig13FnoME11+3))[iETA2];
02043                  }
02044                  if(fr == 0){
02045                    if(iETA2 < 3)iETA2 = 3;
02046                    if(iETA2 > 6)iETA2 = 6;// rare ME1/2 only till 1.6
02047                    par1[0] = (*(Amean13RnoME11+0))[iETA2];
02048                    par1[1] = (*(Amean13RnoME11+1))[iETA2];
02049                    par1[2] = (*(Amean13RnoME11+2))[iETA2];
02050                    par1[3] = (*(Amean13RnoME11+3))[iETA2];
02051                    par_sig1[0] = (*(Asig13RnoME11+0))[iETA2];
02052                    par_sig1[1] = (*(Asig13RnoME11+1))[iETA2];
02053                    par_sig1[2] = (*(Asig13RnoME11+2))[iETA2];
02054                    par_sig1[3] = (*(Asig13RnoME11+3))[iETA2];
02055                  }
02056             }
02057           break;
02058           case 8 :  //2-3
02059                  if(iETA1 < 2)iETA1 = 2;
02060                    par1[0] = (*(Amean23+0))[iETA1];
02061                    par1[1] = (*(Amean23+1))[iETA1];
02062                    par1[2] = (*(Amean23+2))[iETA1];
02063                    par1[3] = (*(Amean23+3))[iETA1];
02064                    par_sig1[0] = (*(Asig23+0))[iETA1];
02065                    par_sig1[1] = (*(Asig23+1))[iETA1];
02066                    par_sig1[2] = (*(Asig23+2))[iETA1];
02067                    par_sig1[3] = (*(Asig23+3))[iETA1];
02068 
02069           break;
02070           case 9 :  //2-4
02071                  if(iETA1 < 3)iETA1 = 3;
02072                    par1[0] = (*(Amean24+0))[iETA1];
02073                    par1[1] = (*(Amean24+1))[iETA1];
02074                    par1[2] = (*(Amean24+2))[iETA1];
02075                    par1[3] = (*(Amean24+3))[iETA1];
02076                    par_sig1[0] = (*(Asig24+0))[iETA1];
02077                    par_sig1[1] = (*(Asig24+1))[iETA1];
02078                    par_sig1[2] = (*(Asig24+2))[iETA1];
02079                    par_sig1[3] = (*(Asig24+3))[iETA1];
02080           break;
02081           case 10 :  //3-4
02082                  if(iETA1 < 3)iETA1 = 3;
02083                    par1[0] = (*(Amean34+0))[iETA1];
02084                    par1[1] = (*(Amean34+1))[iETA1];
02085                    par1[2] = (*(Amean34+2))[iETA1];
02086                    par1[3] = (*(Amean34+3))[iETA1];
02087                    par_sig1[0] = (*(Asig34+0))[iETA1];
02088                    par_sig1[1] = (*(Asig34+1))[iETA1];
02089                    par_sig1[2] = (*(Asig34+2))[iETA1];
02090                    par_sig1[3] = (*(Asig34+3))[iETA1];
02091           break;
02092           case 13 :  //1-4
02093                  if(fr == 1){
02094                    if(iETA1 < 3)iETA1 = 3;
02095                    //if(iETA1 > 11)iETA1 = 11;
02096                    par1[0] = (*(Amean14F+0))[iETA1];
02097                    par1[1] = (*(Amean14F+1))[iETA1];
02098                    par1[2] = (*(Amean14F+2))[iETA1];
02099                    par1[3] = (*(Amean14F+3))[iETA1];
02100                    par_sig1[0] = (*(Asig14F+0))[iETA1];
02101                    par_sig1[1] = (*(Asig14F+1))[iETA1];
02102                    par_sig1[2] = (*(Asig14F+2))[iETA1];
02103                    par_sig1[3] = (*(Asig14F+3))[iETA1];
02104                  }
02105                  if(fr == 0){
02106                    if(iETA1 < 2)iETA1 = 2;
02107                    //if(iETA1 > 11)iETA1 = 11;
02108                    par1[0] = (*(Amean14R+0))[iETA1];
02109                    par1[1] = (*(Amean14R+1))[iETA1];
02110                    par1[2] = (*(Amean14R+2))[iETA1];
02111                    par1[3] = (*(Amean14R+3))[iETA1];
02112                    par_sig1[0] = (*(Asig14R+0))[iETA1];
02113                    par_sig1[1] = (*(Asig14R+1))[iETA1];
02114                    par_sig1[2] = (*(Asig14R+2))[iETA1];
02115                    par_sig1[3] = (*(Asig14R+3))[iETA1];
02116                  }
02117             if(phiSign == 0){ // track belong to ME11 station
02118                  if(fr == 1){
02119                    if(iETA2 < 9)iETA2 = 9;
02120                    par1[0] = (*(Amean14FME11+0))[iETA2];
02121                    par1[1] = (*(Amean14FME11+1))[iETA2];
02122                    par1[2] = (*(Amean14FME11+2))[iETA2];
02123                    par1[3] = (*(Amean14FME11+3))[iETA2];
02124                    par_sig1[0] = (*(Asig14FME11+0))[iETA2];
02125                    par_sig1[1] = (*(Asig14FME11+1))[iETA2];
02126                    par_sig1[2] = (*(Asig14FME11+2))[iETA2];
02127                    par_sig1[3] = (*(Asig14FME11+3))[iETA2];
02128                  }
02129                  if(fr == 0){
02130                    if(iETA2 < 9)iETA2 = 9;
02131                    par1[0] = (*(Amean14RME11+0))[iETA2];
02132                    par1[1] = (*(Amean14RME11+1))[iETA2];
02133                    par1[2] = (*(Amean14RME11+2))[iETA2];
02134                    par1[3] = (*(Amean14RME11+3))[iETA2];
02135                    par_sig1[0] = (*(Asig14RME11+0))[iETA2];
02136                    par_sig1[1] = (*(Asig14RME11+1))[iETA2];
02137                    par_sig1[2] = (*(Asig14RME11+2))[iETA2];
02138                    par_sig1[3] = (*(Asig14RME11+3))[iETA2];
02139                  }
02140             }
02141             if(phiSign == 1){ // track belong to ME1/2 or ME1/3 station
02142                  if(fr == 1){
02143                    if(iETA2 < 4)iETA2 = 4;
02144                    if(iETA2 > 7)iETA2 = 7;
02145                    par1[0] = (*(Amean14FnoME11+0))[iETA2];
02146                    par1[1] = (*(Amean14FnoME11+1))[iETA2];
02147                    par1[2] = (*(Amean14FnoME11+2))[iETA2];
02148                    par1[3] = (*(Amean14FnoME11+3))[iETA2];
02149                    par_sig1[0] = (*(Asig14FnoME11+0))[iETA2];
02150                    par_sig1[1] = (*(Asig14FnoME11+1))[iETA2];
02151                    par_sig1[2] = (*(Asig14FnoME11+2))[iETA2];
02152                    par_sig1[3] = (*(Asig14FnoME11+3))[iETA2];
02153                  }
02154                  if(fr == 0){
02155                    if(iETA2 < 4)iETA2 = 4;
02156                    if(iETA2 > 6)iETA2 = 6;// rare ME1/2 only till 1.6
02157                    par1[0] = (*(Amean14RnoME11+0))[iETA2];
02158                    par1[1] = (*(Amean14RnoME11+1))[iETA2];
02159                    par1[2] = (*(Amean14RnoME11+2))[iETA2];
02160                    par1[3] = (*(Amean14RnoME11+3))[iETA2];
02161                    par_sig1[0] = (*(Asig14RnoME11+0))[iETA2];
02162                    par_sig1[1] = (*(Asig14RnoME11+1))[iETA2];
02163                    par_sig1[2] = (*(Asig14RnoME11+2))[iETA2];
02164                    par_sig1[3] = (*(Asig14RnoME11+3))[iETA2];
02165                  }
02166             }
02167 
02168           break;
02169           case 11 : // b1-3 for pt_method > 10 & fr = 0, singles for pt_method < 10 
02170                  if(iETA1 != 2)iETA1 = 2;
02171                    par1[0] = (*(Amean53+0))[iETA1];
02172                    par1[1] = (*(Amean53+1))[iETA1];
02173                    par1[2] = (*(Amean53+2))[iETA1];
02174                    par1[3] = (*(Amean53+3))[iETA1];
02175                    par_sig1[0] = (*(Asig53+0))[iETA1];
02176                    par_sig1[1] = (*(Asig53+1))[iETA1];
02177                    par_sig1[2] = (*(Asig53+2))[iETA1];
02178                    par_sig1[3] = (*(Asig53+3))[iETA1];
02179           break;
02180 
02181           case 12 :  //1-2-b1 = 2-b1 for pt_method < 10, for pt_method > 10 & fr = 0: b1-2
02182                  if(iETA1 < 1)iETA1 = 1;
02183                  if(iETA1 > 2)iETA1 = 2;
02184 
02185                  par1[0] = (*(Amean52+0))[iETA1];
02186                  par1[1] = (*(Amean52+1))[iETA1];
02187                  par1[2] = (*(Amean52+2))[iETA1];
02188                  par1[3] = (*(Amean52+3))[iETA1];
02189                  par_sig1[0] = (*(Asig52+0))[iETA1];
02190                  par_sig1[1] = (*(Asig52+1))[iETA1];
02191                  par_sig1[2] = (*(Asig52+2))[iETA1];
02192                  par_sig1[3] = (*(Asig52+3))[iETA1];
02193 
02194           break;
02195           case 14 :  //2-b1 for pt_method < 10 and b1-1 for pt_method > 10 & fr = 0
02196                  if(method < 10){
02197                     if(iETA1 < 1)iETA1 = 1;
02198                     if(iETA1 > 2)iETA1 = 2;
02199                  }
02200                  par1[0] = (*(Amean52+0))[iETA1];
02201                  par1[1] = (*(Amean52+1))[iETA1];
02202                  par1[2] = (*(Amean52+2))[iETA1];
02203                  par1[3] = (*(Amean52+3))[iETA1];
02204                  par_sig1[0] = (*(Asig52+0))[iETA1];
02205                  par_sig1[1] = (*(Asig52+1))[iETA1];
02206                  par_sig1[2] = (*(Asig52+2))[iETA1];
02207                  par_sig1[3] = (*(Asig52+3))[iETA1];
02208 
02209                  if(method > 10){
02210                     if(iETA1 > 2)iETA1 = 2;
02211                     par1[0] = (*(Amean51+0))[iETA1];
02212                     par1[1] = (*(Amean51+1))[iETA1];
02213                     par1[2] = (*(Amean51+2))[iETA1];
02214                     par1[3] = (*(Amean51+3))[iETA1];
02215                     par_sig1[0] = (*(Asig51+0))[iETA1];
02216                     par_sig1[1] = (*(Asig51+1))[iETA1];
02217                     par_sig1[2] = (*(Asig51+2))[iETA1];
02218                     par_sig1[3] = (*(Asig51+3))[iETA1];
02219                  }
02220           break;
02221           //default:
02222           //return 0.0;
02223           }    
02224 
02225 //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
02226           //if(fabs(dphi) >= 0.002)
02227           //if(fabs(dphi) >= 0.00)
02228           //if(fabs(dphi) >= 0.002 || (fabs(dphi) >= 0.01 && (type == 12 || type == 14)))
02229           //{
02230                   double pt = 140;
02231                   double dpt = 0.1;
02232                   double step = 5.;
02233                   while(pt > 2. ){
02234                       double par_phi12[1] = {dphi};
02235                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
02236                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.; 
02237                          v[0] = pt;
02238                          lpt1_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02239                          v[0] = pt + dpt;
02240                          lpt1_2 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02241                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
02242                          v[0] = pt - step;
02243                          lpt2_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02244                          v[0] = pt - step + dpt;
02245                          lpt2_2 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02246                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
02247                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
02248                       v[0] = pt - 0.5*step;
02249                       double fx = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02250                       v[0] = pt - 0.5*step + dpt;
02251                       double fxh = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02252                       v[0] = pt - 0.5*step + 2*dpt;
02253                       double fx2h = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02254     
02255                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
02256                       //if(lpt1*lpt2 <= 0 && lpt2nd < 0) std::cout << "lpt2nd < 0 dphi12 = " << dphi <<" PT = " << pt<< " eta =" << fabs(eta) << std::endl; 
02257                       //lpt2nd = 1.; // don't care about 2nd derivative
02258                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolv = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
02259 /*
02260                       if(pt == 140.){
02261                             v[0] = 200;
02262                             lpt2_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02263                             v[0] = 200. + 5.;
02264                             lpt2_2 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02265                             lpt2 = (lpt2_2-lpt2_1)/5.;
02266 
02267                             v[0] = 170.;
02268                             fx = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02269                             v[0] = 170.+5.;
02270                             fxh = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02271                             v[0] = 170.+2*5.;
02272                             fx2h = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02273                             lpt2nd = -(fx2h + fx - 2*fxh)/5./5.;
02274                       }
02275                       if(pt == 140. && lpt1*lpt2 <= 0 && lpt2nd > 0 && fabs(dphi) < 0.1 ){PTsolv = 137.5; break;}
02276 */
02277                       if(pt > 25) {dpt = 0.1; step = 5.;}
02278                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
02279                       pt = pt - step;
02280                   }// end while
02281 //*********** end solve equation for muon plus
02282 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
02283 // for one station method we know sing of muon: dphi > 0 for muon minus!!! => dphi = -dphi < 0
02284                   dphi = - dphi;
02285                   pt = 140;
02286                   dpt = 0.1;
02287                   step = 5.;
02288                   while(pt > 2. ){
02289                       double par_phi12[1] = {dphi};
02290                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
02291                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.;
02292                          v[0] = pt;
02293                          lpt1_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02294                          v[0] = pt + dpt;
02295                          lpt1_2 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02296                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
02297                          v[0] = pt - step;
02298                          lpt2_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02299                          v[0] = pt - step + dpt;
02300                          lpt2_2 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02301                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
02302                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
02303                       v[0] = pt - 0.5*step;
02304                       double fx = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02305                       v[0] = pt - 0.5*step + dpt;
02306                       double fxh = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02307                       v[0] = pt - 0.5*step + 2*dpt;
02308                       double fx2h = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02309     
02310                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
02311 
02312                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolvMinus = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
02313 /*
02314                       if(pt == 140.){
02315                             v[0] = 200;
02316                             lpt2_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02317                             v[0] = 200. + 5.;
02318                             lpt2_2 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02319 
02320                             lpt2 = (lpt2_2-lpt2_1)/5.;
02321 
02322                             v[0] = 170.;
02323                             fx = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02324                             v[0] = 170.+5.;
02325                             fxh = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02326                             v[0] = 170.+2*5.;
02327                             fx2h = Likelihood2_2011(par_phi12, par1, par_sig1, v);
02328                             lpt2nd = -(fx2h + fx - 2*fxh)/5./5.;
02329                       }
02330                       if(pt == 140. && lpt1*lpt2 <= 0 && lpt2nd > 0 && fabs(dphi) < 0.1){PTsolvMinus = 137.5; break;}
02331 */
02332                       if(pt > 25) {dpt = 0.1; step = 5.;}
02333                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
02334                       pt = pt - step;
02335                   }// end while
02336 //          }// if(fabs(dphi) >= 0.002)
02337 //          else 
02338 //          {PTsolv = 137.5;} 
02339 
02340 //*********** end solve equation for muon minus 
02341           PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
02342           PTsolv = PTsolv*1.2;
02343           if(PTsolv > 137.5) PTsolv = 137.5;
02344           if(fabs(dphi) <= 0.002 && PTsolv < 120.)PTsolv = 140.;
02345           //if( fabs(dphi) <= 0.01 && (type == 11 || type == 12 || type == 14) && PTsolv < 120.)PTsolv = 140.;
02346           dphi = - dphi; //return to correct sing dphi
02347 
02348     } //if(fabs(eta_TracMy) 
02349     } //end "for by iETA"
02350 
02351     float Pt = PTsolv;
02352                                                                     
02353     //float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
02354     //if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
02355     float Pt_min = 2;// 0 GeV
02356 
02357     return (Pt > Pt_min)  ? Pt : Pt_min;
02358 }
02359 float CSCTFPtMethods::Pt3Stn2010(int type, float eta, float dphi1, float dphi2, int fr, int method) const 
02360 {
02361 
02362     if(fabs(eta) >= 2.4)eta = 2.35;
02363     float Pt = 0.;
02364     double PTsolv = 1.; // for muon plus hypothesis
02365     double PTsolvMinus = 1.;//for muon minus hypothesis
02366     for(int iETA = 0; iETA < 15; iETA++){
02367     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
02368 
02369 // calculate curvers of mean and sigma 
02370               // calculate phi12 mean  
02371               double par1[4] = {0., 0., 0., 0.};
02372               //double phi12mean = fitf5(v, par1); //mu12 
02373               double par_sig1[3] = {0., 0., 0.};
02374               // calculate phi23 mean  
02375               double par2[4] = {0., 0., 0., 0.};
02376               // calculate phi23 sig
02377               double par_sig2[3] = {0., 0., 0.};
02378               // calculate correlation rho
02379               double par_rho[5] = {0., 0., 0., 0., 0.};
02380               int iETA1 = iETA;
02381               int iETA2 = iETA;
02382         switch (type) // type = mode here
02383           {
02384           case 2 :  //1-2-3
02385                  if(fr == 1){
02386                    if(iETA1 < 3)iETA1 = 3;
02387                    if(iETA1 > 11)iETA1 = 11;
02388                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
02389                    par1[0] = A_mu12Front[0][iETA1];
02390                    par1[1] = A_mu12Front[1][iETA1];
02391                    par1[2] = A_mu12Front[2][iETA1];
02392                    par1[3] = A_mu12Front[3][iETA1];
02393                    par_sig1[0] = A_sig12Front[0][iETA1];
02394                    par_sig1[1] = A_sig12Front[1][iETA1];
02395                    par_sig1[2] = A_sig12Front[2][iETA1];
02396                    par_rho[0] = A_rho123FrontCSCTF[0][iETA1];
02397                    par_rho[1] = A_rho123FrontCSCTF[1][iETA1];
02398                    par_rho[2] = A_rho123FrontCSCTF[2][iETA1];
02399                    par_rho[3] = A_rho123FrontCSCTF[3][iETA1];
02400                    par_rho[4] = A_rho123FrontCSCTF[4][iETA1];
02401                  }
02402                  if(fr == 0){
02403                    if(iETA1 < 1)iETA1 = 1;
02404                    if(iETA1 > 11)iETA1 = 11;
02405                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
02406                    par1[0] = A_mu12Rare[0][iETA1];
02407                    par1[1] = A_mu12Rare[1][iETA1];
02408                    par1[2] = A_mu12Rare[2][iETA1];
02409                    par1[3] = A_mu12Rare[3][iETA1];
02410                    par_sig1[0] = A_sig12Rare[0][iETA1];
02411                    par_sig1[1] = A_sig12Rare[1][iETA1];
02412                    par_sig1[2] = A_sig12Rare[2][iETA1];
02413                    par_rho[0] = A_rho123RareCSCTF[0][iETA1];
02414                    par_rho[1] = A_rho123RareCSCTF[1][iETA1];
02415                    par_rho[2] = A_rho123RareCSCTF[2][iETA1];
02416                    par_rho[3] = A_rho123RareCSCTF[3][iETA1];
02417                    par_rho[4] = A_rho123RareCSCTF[4][iETA1];
02418                  }
02419                  if(iETA2 < 2)iETA2 = 2;
02420                  par2[0] = A_mu23[0][iETA2];
02421                  par2[1] = A_mu23[1][iETA2];
02422                  par2[2] = A_mu23[2][iETA2];
02423                  par2[3] = A_mu23[3][iETA2];
02424                  par_sig2[0] = A_sig23[0][iETA2];
02425                  par_sig2[1] = A_sig23[1][iETA2];
02426                  par_sig2[2] = A_sig23[2][iETA2];
02427 
02428           break;
02429           case 3 : //1-2-4
02430                  if(fr == 1){
02431                    if(iETA1 < 3)iETA1 = 3;
02432                    if(iETA1 > 11)iETA1 = 11;
02433                    par1[0] = A_mu12Front[0][iETA1];
02434                    par1[1] = A_mu12Front[1][iETA1];
02435                    par1[2] = A_mu12Front[2][iETA1];
02436                    par1[3] = A_mu12Front[3][iETA1];
02437                    par_sig1[0] = A_sig12Front[0][iETA1];
02438                    par_sig1[1] = A_sig12Front[1][iETA1];
02439                    par_sig1[2] = A_sig12Front[2][iETA1];
02440                    par_rho[0] = A_rho124FrontCSCTF[0][iETA1];
02441                    par_rho[1] = A_rho124FrontCSCTF[1][iETA1];
02442                    par_rho[2] = A_rho124FrontCSCTF[2][iETA1];
02443                    par_rho[3] = A_rho124FrontCSCTF[3][iETA1];
02444                    par_rho[4] = A_rho124FrontCSCTF[4][iETA1];
02445                  }
02446                  if(fr == 0){
02447                    if(iETA1 < 1)iETA1 = 1;
02448                    if(iETA1 > 11)iETA1 = 11;
02449                    par1[0] = A_mu12Rare[0][iETA1];
02450                    par1[1] = A_mu12Rare[1][iETA1];
02451                    par1[2] = A_mu12Rare[2][iETA1];
02452                    par1[3] = A_mu12Rare[3][iETA1];
02453                    par_sig1[0] = A_sig12Rare[0][iETA1];
02454                    par_sig1[1] = A_sig12Rare[1][iETA1];
02455                    par_sig1[2] = A_sig12Rare[2][iETA1];
02456                    par_rho[0] = A_rho124RareCSCTF[0][iETA1];
02457                    par_rho[1] = A_rho124RareCSCTF[1][iETA1];
02458                    par_rho[2] = A_rho124RareCSCTF[2][iETA1];
02459                    par_rho[3] = A_rho124RareCSCTF[3][iETA1];
02460                    par_rho[4] = A_rho124RareCSCTF[4][iETA1];
02461                  }
02462                  if(iETA2 < 9)iETA2 = 9;
02463                  par2[0] = A_mu24[0][iETA2];
02464                  par2[1] = A_mu24[1][iETA2];
02465                  par2[2] = A_mu24[2][iETA2];
02466                  par2[3] = A_mu24[3][iETA2];
02467                  par_sig2[0] = A_sig24[0][iETA2];
02468                  par_sig2[1] = A_sig24[1][iETA2];
02469                  par_sig2[2] = A_sig24[2][iETA2];
02470           break;
02471           case 4 : //1-3-4
02472                  if(fr == 1){
02473                    if(iETA1 < 3)iETA1 = 3;
02474                    if(iETA1 > 11)iETA1 = 11;
02475                    par1[0] = A_mu13Front[0][iETA1];
02476                    par1[1] = A_mu13Front[1][iETA1];
02477                    par1[2] = A_mu13Front[2][iETA1];
02478                    par1[3] = A_mu13Front[3][iETA1];
02479                    par_sig1[0] = A_sig13Front[0][iETA1];
02480                    par_sig1[1] = A_sig13Front[1][iETA1];
02481                    par_sig1[2] = A_sig13Front[2][iETA1];
02482                    par_rho[0] = A_rho134FrontCSCTF[0][iETA1];
02483                    par_rho[1] = A_rho134FrontCSCTF[1][iETA1];
02484                    par_rho[2] = A_rho134FrontCSCTF[2][iETA1];
02485                    par_rho[3] = A_rho134FrontCSCTF[3][iETA1];
02486                    par_rho[4] = A_rho134FrontCSCTF[4][iETA1];                 
02487                  }
02488                  if(fr == 0){
02489                    if(iETA1 < 2)iETA1 = 2;
02490                    if(iETA1 > 11)iETA1 = 11;
02491                    par1[0] = A_mu13Rare[0][iETA1];
02492                    par1[1] = A_mu13Rare[1][iETA1];
02493                    par1[2] = A_mu13Rare[2][iETA1];
02494                    par1[3] = A_mu13Rare[3][iETA1];
02495                    par_sig1[0] = A_sig13Rare[0][iETA1];
02496                    par_sig1[1] = A_sig13Rare[1][iETA1];
02497                    par_sig1[2] = A_sig13Rare[2][iETA1];
02498                    par_rho[0] = A_rho134RareCSCTF[0][iETA1];
02499                    par_rho[1] = A_rho134RareCSCTF[1][iETA1];
02500                    par_rho[2] = A_rho134RareCSCTF[2][iETA1];
02501                    par_rho[3] = A_rho134RareCSCTF[3][iETA1];
02502                    par_rho[4] = A_rho134RareCSCTF[4][iETA1];
02503                  }
02504                  if(iETA2 < 9)iETA2 = 9;
02505                  par2[0] = A_mu34[0][iETA2];
02506                  par2[1] = A_mu34[1][iETA2];
02507                  par2[2] = A_mu34[2][iETA2];
02508                  par2[3] = A_mu34[3][iETA2];
02509                  par_sig2[0] = A_sig34[0][iETA2];
02510                  par_sig2[1] = A_sig34[1][iETA2];
02511                  par_sig2[2] = A_sig34[2][iETA2];
02512           break;
02513           case 5 ://2-3-4
02514                  if(iETA1 < 9)iETA1 = 9;
02515                  par1[0] = A_mu23[0][iETA1];
02516                  par1[1] = A_mu23[1][iETA1];
02517                  par1[2] = A_mu23[2][iETA1];
02518                  par1[3] = A_mu23[3][iETA1];
02519                  par_sig1[0] = A_sig23[0][iETA1];
02520                  par_sig1[1] = A_sig23[1][iETA1];
02521                  par_sig1[2] = A_sig23[2][iETA1];
02522                  par_rho[0] = A_rho234CSCTF[0][iETA1];
02523                  par_rho[1] = A_rho234CSCTF[1][iETA1];
02524                  par_rho[2] = A_rho234CSCTF[2][iETA1];
02525                  par_rho[3] = A_rho234CSCTF[3][iETA1];
02526                  par_rho[4] = A_rho234CSCTF[4][iETA1];
02527 
02528                  par2[0] = A_mu34[0][iETA1];
02529                  par2[1] = A_mu34[1][iETA1];
02530                  par2[2] = A_mu34[2][iETA1];
02531                  par2[3] = A_mu34[3][iETA1];
02532                  par_sig2[0] = A_sig34[0][iETA1];
02533                  par_sig2[1] = A_sig34[1][iETA1];
02534                  par_sig2[2] = A_sig34[2][iETA1];
02535           break;
02536           case 11 : // b1-1-3
02537                  if(iETA1 != 2)iETA1 = 2;
02538                  par1[0] = A_mu51[0][iETA1];
02539                  par1[1] = A_mu51[1][iETA1];
02540                  par1[2] = A_mu51[2][iETA1];
02541                  par1[3] = A_mu51[3][iETA1];
02542                  par_sig1[0] = A_sig51[0][iETA1];
02543                  par_sig1[1] = A_sig51[1][iETA1];
02544                  par_sig1[2] = A_sig51[2][iETA1];
02545                  par_rho[0] = A_rho513[0][iETA1]; 
02546                  par_rho[1] = A_rho513[0][iETA1]; 
02547                  par_rho[2] = A_rho513[0][iETA1]; 
02548                  par_rho[3] = A_rho513[0][iETA1]; 
02549                  par_rho[4] = A_rho513[0][iETA1]; 
02550 
02551                  par2[0] = A_mu13Rare[0][iETA1];
02552                  par2[1] = A_mu13Rare[1][iETA1];
02553                  par2[2] = A_mu13Rare[2][iETA1];
02554                  par2[3] = A_mu13Rare[3][iETA1];
02555                  par_sig2[0] = A_sig13Rare[0][iETA1];
02556                  par_sig2[1] = A_sig13Rare[1][iETA1];
02557                  par_sig2[2] = A_sig13Rare[2][iETA1];
02558           break;
02559           case 12 : // b1-2-3
02560                  if(iETA1 != 2)iETA1 = 2;
02561                  par1[0] = A_mu52[0][iETA1];
02562                  par1[1] = A_mu52[1][iETA1];
02563                  par1[2] = A_mu52[2][iETA1];
02564                  par1[3] = A_mu52[3][iETA1];
02565                  par_sig1[0] = A_sig52[0][iETA1];
02566                  par_sig1[1] = A_sig52[1][iETA1];
02567                  par_sig1[2] = A_sig52[2][iETA1];
02568                  par_rho[0] = A_rho523[0][iETA1];
02569                  par_rho[1] = A_rho523[0][iETA1];
02570                  par_rho[2] = A_rho523[0][iETA1];
02571                  par_rho[3] = A_rho523[0][iETA1];
02572                  par_rho[4] = A_rho523[0][iETA1];
02573                  
02574                  par2[0] = A_mu23[0][iETA1];
02575                  par2[1] = A_mu23[1][iETA1];
02576                  par2[2] = A_mu23[2][iETA1];
02577                  par2[3] = A_mu23[3][iETA1];
02578                  par_sig2[0] = A_sig23[0][iETA1];
02579                  par_sig2[1] = A_sig23[1][iETA1];
02580                  par_sig2[2] = A_sig23[2][iETA1];
02581           break;
02582           case 14 : // b1-1-2-(3)
02583                  if(iETA1 < 1)iETA1 = 1;
02584                  if(iETA1 > 2)iETA1 = 2;
02585                  par1[0] = A_mu51[0][iETA1];
02586                  par1[1] = A_mu51[1][iETA1];
02587                  par1[2] = A_mu51[2][iETA1];
02588                  par1[3] = A_mu51[3][iETA1];
02589                  par_sig1[0] = A_sig51[0][iETA1];
02590                  par_sig1[1] = A_sig51[1][iETA1];
02591                  par_sig1[2] = A_sig51[2][iETA1];
02592                  par_rho[0] = A_rho512[0][iETA1];
02593                  par_rho[1] = A_rho512[0][iETA1];
02594                  par_rho[2] = A_rho512[0][iETA1];
02595                  par_rho[3] = A_rho512[0][iETA1];
02596                  par_rho[4] = A_rho512[0][iETA1];
02597                  
02598                  par2[0] = A_mu12Rare[0][iETA1];
02599                  par2[1] = A_mu12Rare[1][iETA1];
02600                  par2[2] = A_mu12Rare[2][iETA1];
02601                  par2[3] = A_mu12Rare[3][iETA1];
02602                  par_sig2[0] = A_sig12Rare[0][iETA1];
02603                  par_sig2[1] = A_sig12Rare[1][iETA1];
02604                  par_sig2[2] = A_sig12Rare[2][iETA1]; 
02605           break;
02606           //default:
02607           //return 0.0;
02608           }
02609 
02610         // Switch to 2-Station measurement if dphi is too small
02611         // box cut around Pt of 10 GeV
02612         if ( fabs(static_cast<double>(dphi2))<0.004 ) 
02613           {
02614             if(type == 2 || type == 3) type = 6; // 1-2-3(or 4) -> 1-2 
02615             if(type == 4) type = 7; // 1-3-4 -> 1-3
02616             if(type == 5) type = 8; // 2-3-4 -> 2-3
02617             if(type == 11) type = 14; // b1-1-3 -> b1-1 for pt_method > 10
02618             Pt = Pt2Stn2010(type, eta, dphi1, fr, method);
02619           }
02620         else 
02621           {
02622 //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
02623                   double pt = 140;
02624                   double dpt = 0.1;
02625                   double step = 5.;
02626                   while(pt > 2. ){
02627                       double par_phi12[1] = {dphi1};
02628                       double par_phi23[1] = {dphi2};
02629                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
02630                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.; 
02631                          v[0] = pt;
02632                          lpt1_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02633                          v[0] = pt + dpt;
02634                          lpt1_2 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02635                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
02636                          v[0] = pt - step;
02637                          lpt2_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02638                          v[0] = pt - step + dpt;
02639                          lpt2_2 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02640                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
02641                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
02642                       v[0] = pt - 0.5*step;
02643                       double fx = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02644                       v[0] = pt - 0.5*step + dpt;
02645                       double fxh = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02646                       v[0] = pt - 0.5*step + 2*dpt;
02647                       double fx2h = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02648     
02649                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
02650 
02651                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolv = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
02652 /*
02653                       if(pt == 140.){
02654                            v[0] = 200.;
02655                            lpt2_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02656                            v[0] = 200.+ 5.;
02657                            lpt2_2 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02658                            lpt2 = (lpt2_2-lpt2_1)/5.;
02659                             v[0] = 170.;
02660                             fx = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02661                             v[0] = 170.+5.;
02662                             fxh = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02663                             v[0] = 170.+2*5.;
02664                             fx2h = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02665                             lpt2nd = -(fx2h + fx - 2*fxh)/5./5.;
02666                       }
02667 
02668                       if(pt == 140. && lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolv = 137.5; break;}
02669 */
02670                       //double rho = fitfrho(v, par_rho); //rho 
02671                       if(pt > 25) {dpt = 0.1; step = 5.;}
02672                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
02673                       pt = pt - step;
02674                   }// end while
02675 //*********** end solve equation for muon plus
02676 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
02677 // for one station method we know sing of muon: dphi1 > 0 for muon minus!!! => dphi1 = -dphi1 < 0
02678                   dphi1 = - dphi1;
02679                   dphi2 = - dphi2;      
02680                   pt = 140;
02681                   dpt = 0.1;
02682                   step = 5.;
02683                   while(pt > 2. ){
02684                       double par_phi12[1] = {dphi1};
02685                       double par_phi23[1] = {dphi2};
02686                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
02687                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.; 
02688                          v[0] = pt;
02689                          lpt1_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02690                          v[0] = pt + dpt;
02691                          lpt1_2 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02692                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
02693                          v[0] = pt - step;
02694                          lpt2_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02695                          v[0] = pt - step + dpt;
02696                          lpt2_2 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02697                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
02698                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
02699                       v[0] = pt - 0.5*step;
02700                       double fx = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02701                       v[0] = pt - 0.5*step + dpt;
02702                       double fxh = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02703                       v[0] = pt - 0.5*step + 2*dpt;
02704                       double fx2h = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02705     
02706                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
02707 
02708                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolvMinus = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
02709                       //if(iETA == 3 && v[0] < 4 && v[0] > 3) cout << "m12 = " << fitf5(v, par1) << " sig12 = " << fitf2(v, par_sig1) << endl;
02711 /*
02712                       if(pt == 140.){
02713                            v[0] = 200.;
02714                            lpt2_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02715                            v[0] = 200.+ 5.;
02716                            lpt2_2 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02717                            lpt2 = (lpt2_2-lpt2_1)/5.;
02718                             v[0] = 170.;
02719                             fx = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02720                             v[0] = 170.+5.;
02721                             fxh = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02722                             v[0] = 170.+2*5.;
02723                             fx2h = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
02724                             lpt2nd = -(fx2h + fx - 2*fxh)/5./5.;
02725                       }
02726                       if(pt == 140. && lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolvMinus = 137.5; break;}
02727 */
02728                       //double rho = fitfrho(v, par_rho); //rho 
02729                       if(pt > 25) {dpt = 0.1; step = 5.;}
02730                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
02731                       pt = pt - step;
02732                   }// end while
02733 //*********** end solve equation for muon minus 
02734                   PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
02735                   PTsolv = PTsolv*1.2; // correction to have 90% efficiency for trigger cuts
02736                   if(PTsolv > 137.5) PTsolv = 137.5;
02737                   //if(fabs(dphi1) < 0.002 && fabs(dphi2) <= CutPhi23){PTsolv = 140;}
02738                   dphi1 = - dphi1; //return to correct sing dphi
02739                   dphi2 = - dphi2; //return to correct sing dphi
02740                   Pt = PTsolv;
02741           } // end 2 or 3 station method
02742     }}
02743            // if ( fabs(static_cast<double>(dphi2))>0.004 ) std::cout << "Pt = " << Pt << " Mode = " << type << " dphi1 = " << dphi1 << " dphi2 = " << dphi2 << std::endl;
02744 
02745     float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
02746     if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
02747 
02748     return (Pt > Pt_min)  ? Pt : Pt_min;
02749 }
02750 float CSCTFPtMethods::Pt3Stn2011(int type, float eta, float dphi1, float dphi2, int fr, int method) const 
02751 {
02752 
02753     //if(fabs(eta) >= 2.4)eta = 2.35;
02754     if(fabs(eta) >= 2.2) eta = 2.15;  
02755     float Pt = 0.;
02756     double PTsolv = 1.; // for muon plus hypothesis
02757     double PTsolvMinus = 1.;//for muon minus hypothesis
02758     for(int iETA = 0; iETA < 15; iETA++){
02759     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
02760 
02761 // calculate curvers of mean and sigma 
02762               // calculate phi12 mean  
02763               double par1[4] = {0., 0., 0., 0.};
02764               //double phi12mean = fitf5(v, par1); //mu12 
02765               double par_sig1[4] = {0., 0., 0., 0};
02766               // calculate phi23 mean  
02767               double par2[4] = {0., 0., 0., 0.};
02768               // calculate phi23 sig
02769               double par_sig2[4] = {0., 0., 0., 0.};
02770               // calculate correlation rho
02771               double par_rho[5] = {0., 0., 0., 0., 0.};
02772               int iETA1 = iETA;
02773               int iETA2 = iETA; 
02774 
02775 // defind which parameters will be use
02776         double (*Amean12F)[15] = AB_mu12F; 
02777         double (*Asig12F)[15] = AB_sig12F; 
02778         double (*Amean12R)[15] = AB_mu12R; 
02779         double (*Asig12R)[15] = AB_sig12R; 
02780 
02781         double (*Amean13F)[15] = AB_mu13F; 
02782         double (*Asig13F)[15] = AB_sig13F; 
02783         double (*Amean13R)[15] = AB_mu13R; 
02784         double (*Asig13R)[15] = AB_sig13R; 
02785 
02786         //double (*Amean14F)[15] = AB_mu14F; 
02787         //double (*Asig14F)[15] = AB_sig14F; 
02788         //double (*Amean14R)[15] = AB_mu14R; 
02789         //double (*Asig14R)[15] = AB_sig14R; 
02790 
02791         double (*Amean23)[15] = AB_mu23;
02792         double (*Asig23)[15] = AB_sig23;
02793         double (*Amean24)[15] = AB_mu24;
02794         double (*Asig24)[15] = AB_sig24;
02795         double (*Amean34)[15] = AB_mu34;
02796         double (*Asig34)[15] = AB_sig34;
02797 
02798         double (*Amean5)[15] = AB_mu5;
02799         double (*Asig5)[15] = AB_sig5;
02800         double (*Amean51)[15] = AB_mu51;
02801         double (*Asig51)[15] = AB_sig51;
02802         double (*Amean52)[15] = AB_mu52;
02803         double (*Asig52)[15] = AB_sig52;
02804         double (*Amean53)[15] = AB_mu53;
02805         double (*Asig53)[15] = AB_sig53;
02806 
02807         double (*Arho123F)[15] = AB_rho123F;
02808         double (*Arho123R)[15] = AB_rho123R;
02809         double (*Arho124F)[15] = AB_rho124F;
02810         double (*Arho124R)[15] = AB_rho124R;
02811         double (*Arho134F)[15] = AB_rho134F;
02812         double (*Arho134R)[15] = AB_rho134R;
02813         double (*Arho234)[15] = AB_rho234;
02814 
02815         double (*Arho51B)[15] = AB_rho51B;
02816         double (*Arho52B)[15] = AB_rho52B;
02817         double (*Arho53B)[15] = AB_rho53B;
02818         double (*Arho512)[15] = AB_rho512;
02819         double (*Arho513)[15] = AB_rho513;
02820         double (*Arho523)[15] = AB_rho523;
02821 
02822         //cout << "iETA = " << iETA 
02823         //     << " AB_mu51[0][iETA] = " << AB_mu51[0][iETA] << " pointer = " << (*(Amean51+0))[iETA]   
02824         //     << " AB_mu51[3][iETA] = " << AB_mu51[3][iETA] << " pointer = " << (*(Amean51+3))[iETA]   
02825         //     << endl;
02826  
02827         switch (type) // type = mode here
02828           {
02829           case 2 :  //1-2-3
02830                  if(iETA < 2)iETA2 = 2;
02831                  if(fr == 1){
02832                    if(iETA < 3)iETA1 = 3;
02833                    par1[0] = (*(Amean12F+0))[iETA1];
02834                    par1[1] = (*(Amean12F+1))[iETA1];
02835                    par1[2] = (*(Amean12F+2))[iETA1];
02836                    par1[3] = (*(Amean12F+3))[iETA1];
02837                    par_sig1[0] = (*(Asig12F+0))[iETA1];
02838                    par_sig1[1] = (*(Asig12F+1))[iETA1];
02839                    par_sig1[2] = (*(Asig12F+2))[iETA1];
02840                    par_sig1[3] = (*(Asig12F+3))[iETA1];
02841                    par_rho[0] = (*(Arho123F+0))[iETA2];
02842                    par_rho[1] = (*(Arho123F+1))[iETA2];
02843                    par_rho[2] = (*(Arho123F+2))[iETA2];
02844                    par_rho[3] = (*(Arho123F+3))[iETA2];
02845                    par_rho[4] = (*(Arho123F+4))[iETA2];
02846                  
02847                  }
02848                  if(fr == 0){
02849                    if(iETA < 1)iETA1 = 1;
02850                    par1[0] = (*(Amean12R+0))[iETA1];
02851                    par1[1] = (*(Amean12R+1))[iETA1];
02852                    par1[2] = (*(Amean12R+2))[iETA1];
02853                    par1[3] = (*(Amean12R+3))[iETA1];
02854                    par_sig1[0] = (*(Asig12R+0))[iETA1];
02855                    par_sig1[1] = (*(Asig12R+1))[iETA1];
02856                    par_sig1[2] = (*(Asig12R+2))[iETA1];
02857                    par_sig1[3] = (*(Asig12R+3))[iETA1];
02858                    par_rho[0] = (*(Arho123R+0))[iETA2];
02859                    par_rho[1] = (*(Arho123R+1))[iETA2];
02860                    par_rho[2] = (*(Arho123R+2))[iETA2];
02861                    par_rho[3] = (*(Arho123R+3))[iETA2];
02862                    par_rho[4] = (*(Arho123R+4))[iETA2];
02863                  }
02864                  par2[0] = (*(Amean23+0))[iETA2];
02865                  par2[1] = (*(Amean23+1))[iETA2];
02866                  par2[2] = (*(Amean23+2))[iETA2];
02867                  par2[3] = (*(Amean23+3))[iETA2];
02868                  par_sig2[0] = (*(Asig23+0))[iETA2];
02869                  par_sig2[1] = (*(Asig23+1))[iETA2];
02870                  par_sig2[2] = (*(Asig23+2))[iETA2]; 
02871                  par_sig2[3] = (*(Asig23+3))[iETA2]; 
02872 
02873           break;
02874           case 3 : //1-2-4
02875                  if(iETA < 3)iETA2 = 3;
02876                  if(fr == 1){
02877                    if(iETA < 3)iETA1 = 3;
02878                    par1[0] = (*(Amean12F+0))[iETA1];
02879                    par1[1] = (*(Amean12F+1))[iETA1];
02880                    par1[2] = (*(Amean12F+2))[iETA1];
02881                    par1[3] = (*(Amean12F+3))[iETA1];
02882                    par_sig1[0] = (*(Asig12F+0))[iETA1];
02883                    par_sig1[1] = (*(Asig12F+1))[iETA1];
02884                    par_sig1[2] = (*(Asig12F+2))[iETA1];
02885                    par_sig1[3] = (*(Asig12F+3))[iETA1];
02886                    par_rho[0] = (*(Arho124F+0))[iETA2];
02887                    par_rho[1] = (*(Arho124F+1))[iETA2];
02888                    par_rho[2] = (*(Arho124F+2))[iETA2];
02889                    par_rho[3] = (*(Arho124F+3))[iETA2];
02890                    par_rho[4] = (*(Arho124F+4))[iETA2];
02891                  
02892                  }
02893                  if(fr == 0){
02894                    if(iETA < 1)iETA1 = 1;
02895                    par1[0] = (*(Amean12R+0))[iETA1];
02896                    par1[1] = (*(Amean12R+1))[iETA1];
02897                    par1[2] = (*(Amean12R+2))[iETA1];
02898                    par1[3] = (*(Amean12R+3))[iETA1];
02899                    par_sig1[0] = (*(Asig12R+0))[iETA1];
02900                    par_sig1[1] = (*(Asig12R+1))[iETA1];
02901                    par_sig1[2] = (*(Asig12R+2))[iETA1];
02902                    par_sig1[3] = (*(Asig12R+3))[iETA1];
02903                    par_rho[0] = (*(Arho124R+0))[iETA2];
02904                    par_rho[1] = (*(Arho124R+1))[iETA2];
02905                    par_rho[2] = (*(Arho124R+2))[iETA2];
02906                    par_rho[3] = (*(Arho124R+3))[iETA2];
02907                    par_rho[4] = (*(Arho124R+4))[iETA2];
02908                  }
02909                  par2[0] = (*(Amean24+0))[iETA2];
02910                  par2[1] = (*(Amean24+1))[iETA2];
02911                  par2[2] = (*(Amean24+2))[iETA2];
02912                  par2[3] = (*(Amean24+3))[iETA2];
02913                  par_sig2[0] = (*(Asig24+0))[iETA2];
02914                  par_sig2[1] = (*(Asig24+1))[iETA2];
02915                  par_sig2[2] = (*(Asig24+2))[iETA2]; 
02916                  par_sig2[3] = (*(Asig24+3))[iETA2]; 
02917           break;
02918           case 4 : //1-3-4
02919                  if(iETA < 3)iETA2 = 3;
02920                  if(fr == 1){
02921                    if(iETA < 3)iETA1 = 3;
02922                    par1[0] = (*(Amean13F+0))[iETA1];
02923                    par1[1] = (*(Amean13F+1))[iETA1];
02924                    par1[2] = (*(Amean13F+2))[iETA1];
02925                    par1[3] = (*(Amean13F+3))[iETA1];
02926                    par_sig1[0] = (*(Asig13F+0))[iETA1];
02927                    par_sig1[1] = (*(Asig13F+1))[iETA1];
02928                    par_sig1[2] = (*(Asig13F+2))[iETA1];
02929                    par_sig1[3] = (*(Asig13F+3))[iETA1];
02930                    par_rho[0] = (*(Arho134F+0))[iETA2];
02931                    par_rho[1] = (*(Arho134F+1))[iETA2];
02932                    par_rho[2] = (*(Arho134F+2))[iETA2];
02933                    par_rho[3] = (*(Arho134F+3))[iETA2];
02934                    par_rho[4] = (*(Arho134F+4))[iETA2];
02935                  
02936                  }
02937                  if(fr == 0){
02938                    if(iETA < 3)iETA1 = 3;
02939                    par1[0] = (*(Amean13R+0))[iETA1];
02940                    par1[1] = (*(Amean13R+1))[iETA1];
02941                    par1[2] = (*(Amean13R+2))[iETA1];
02942                    par1[3] = (*(Amean13R+3))[iETA1];
02943                    par_sig1[0] = (*(Asig13R+0))[iETA1];
02944                    par_sig1[1] = (*(Asig13R+1))[iETA1];
02945                    par_sig1[2] = (*(Asig13R+2))[iETA1];
02946                    par_sig1[3] = (*(Asig13R+3))[iETA1];
02947                    par_rho[0] = (*(Arho134R+0))[iETA2];
02948                    par_rho[1] = (*(Arho134R+1))[iETA2];
02949                    par_rho[2] = (*(Arho134R+2))[iETA2];
02950                    par_rho[3] = (*(Arho134R+3))[iETA2];
02951                    par_rho[4] = (*(Arho134R+4))[iETA2];
02952                  }
02953                  par2[0] = (*(Amean34+0))[iETA2];
02954                  par2[1] = (*(Amean34+1))[iETA2];
02955                  par2[2] = (*(Amean34+2))[iETA2];
02956                  par2[3] = (*(Amean34+3))[iETA2];
02957                  par_sig2[0] = (*(Asig34+0))[iETA2];
02958                  par_sig2[1] = (*(Asig34+1))[iETA2];
02959                  par_sig2[2] = (*(Asig34+2))[iETA2]; 
02960                  par_sig2[3] = (*(Asig34+3))[iETA2]; 
02961           break;
02962           case 5 ://2-3-4
02963                  if(iETA < 2)iETA1 = 2;
02964                  if(iETA < 3)iETA2 = 3;
02965                  par1[0] = (*(Amean23+0))[iETA1];
02966                  par1[1] = (*(Amean23+1))[iETA1];
02967                  par1[2] = (*(Amean23+2))[iETA1];
02968                  par1[3] = (*(Amean23+3))[iETA1];
02969                  par_sig1[0] = (*(Asig23+0))[iETA1];
02970                  par_sig1[1] = (*(Asig23+1))[iETA1];
02971                  par_sig1[2] = (*(Asig23+2))[iETA1];
02972                  par_sig1[3] = (*(Asig23+3))[iETA1];
02973                  par_rho[0] = (*(Arho234+0))[iETA2];
02974                  par_rho[1] = (*(Arho234+1))[iETA2];
02975                  par_rho[2] = (*(Arho234+2))[iETA2];
02976                  par_rho[3] = (*(Arho234+3))[iETA2];
02977                  par_rho[4] = (*(Arho234+4))[iETA2];
02978                  
02979                  par2[0] = (*(Amean34+0))[iETA2];
02980                  par2[1] = (*(Amean34+1))[iETA2];
02981                  par2[2] = (*(Amean34+2))[iETA2];
02982                  par2[3] = (*(Amean34+3))[iETA2];
02983                  par_sig2[0] = (*(Asig34+0))[iETA2];
02984                  par_sig2[1] = (*(Asig34+1))[iETA2];
02985                  par_sig2[2] = (*(Asig34+2))[iETA2]; 
02986                  par_sig2[3] = (*(Asig34+3))[iETA2]; 
02987           break;
02988           case 11 : // singles for method < 10, for method > 10: fr = 1 -> b1-1-3, fr = 0 -> b1-3-phiBend
02989                  if(iETA != 2)iETA1 = 2;
02990                  par1[0] = (*(Amean53+0))[iETA1];
02991                  par1[1] = (*(Amean53+1))[iETA1];
02992                  par1[2] = (*(Amean53+2))[iETA1];
02993                  par1[3] = (*(Amean53+3))[iETA1];
02994                  par_sig1[0] = (*(Asig53+0))[iETA1];
02995                  par_sig1[1] = (*(Asig53+1))[iETA1];
02996                  par_sig1[2] = (*(Asig53+2))[iETA1];
02997                  par_sig1[3] = (*(Asig53+3))[iETA1];
02998                  par_rho[0] = (*(Arho53B+0))[iETA1];
02999                  par_rho[1] = (*(Arho53B+1))[iETA1];
03000                  par_rho[2] = (*(Arho53B+2))[iETA1];
03001                  par_rho[3] = (*(Arho53B+3))[iETA1];
03002                  par_rho[4] = (*(Arho53B+4))[iETA1];
03003                
03004                  par2[0] = (*(Amean5+0))[iETA1];
03005                  par2[1] = (*(Amean5+1))[iETA1];
03006                  par2[2] = (*(Amean5+2))[iETA1];
03007                  par2[3] = (*(Amean5+3))[iETA1];
03008                  par_sig2[0] = (*(Asig5+0))[iETA1];
03009                  par_sig2[1] = (*(Asig5+1))[iETA1];
03010                  par_sig2[2] = (*(Asig5+2))[iETA1]; 
03011                  par_sig2[3] = (*(Asig5+3))[iETA1]; 
03012 
03013                  if(fr == 1){
03014                    par1[0] = (*(Amean51+0))[iETA1];
03015                    par1[1] = (*(Amean51+1))[iETA1];
03016                    par1[2] = (*(Amean51+2))[iETA1];
03017                    par1[3] = (*(Amean51+3))[iETA1];
03018                    par_sig1[0] = (*(Asig51+0))[iETA1];
03019                    par_sig1[1] = (*(Asig51+1))[iETA1];
03020                    par_sig1[2] = (*(Asig51+2))[iETA1];
03021                    par_sig1[3] = (*(Asig51+3))[iETA1];
03022                    par_rho[0] = (*(Arho513+0))[iETA1];
03023                    par_rho[1] = (*(Arho513+1))[iETA1];
03024                    par_rho[2] = (*(Arho513+2))[iETA1];
03025                    par_rho[3] = (*(Arho513+3))[iETA1];
03026                    par_rho[4] = (*(Arho513+4))[iETA1];
03027                  
03028                    par2[0] = (*(Amean13R+0))[iETA1];
03029                    par2[1] = (*(Amean13R+1))[iETA1];
03030                    par2[2] = (*(Amean13R+2))[iETA1];
03031                    par2[3] = (*(Amean13R+3))[iETA1];
03032                    par_sig2[0] = (*(Asig13R+0))[iETA1];
03033                    par_sig2[1] = (*(Asig13R+1))[iETA1];
03034                    par_sig2[2] = (*(Asig13R+2))[iETA1]; 
03035                    par_sig2[3] = (*(Asig13R+3))[iETA1]; 
03036                  }    
03037           break;
03038           case 12 : // b1-1-2 for method < 10; for method > 10: fr = 1 -> b1-2-3, fr = 0 -> b1-2-phiBend
03039                  if(iETA < 1)iETA1 = 1;
03040                  if(iETA > 2)iETA1 = 2;
03041                  par1[0] = (*(Amean52+0))[iETA1];
03042                  par1[1] = (*(Amean52+1))[iETA1];
03043                  par1[2] = (*(Amean52+2))[iETA1];
03044                  par1[3] = (*(Amean52+3))[iETA1];
03045                  par_sig1[0] = (*(Asig52+0))[iETA1];
03046                  par_sig1[1] = (*(Asig52+1))[iETA1];
03047                  par_sig1[2] = (*(Asig52+2))[iETA1];
03048                  par_sig1[3] = (*(Asig52+3))[iETA1];
03049                  par_rho[0] = (*(Arho52B+0))[iETA1];
03050                  par_rho[1] = (*(Arho52B+1))[iETA1];
03051                  par_rho[2] = (*(Arho52B+2))[iETA1];
03052                  par_rho[3] = (*(Arho52B+3))[iETA1];
03053                  par_rho[4] = (*(Arho52B+4))[iETA1];
03054                
03055                  par2[0] = (*(Amean5+0))[iETA1];
03056                  par2[1] = (*(Amean5+1))[iETA1];
03057                  par2[2] = (*(Amean5+2))[iETA1];
03058                  par2[3] = (*(Amean5+3))[iETA1];
03059                  par_sig2[0] = (*(Asig5+0))[iETA1];
03060                  par_sig2[1] = (*(Asig5+1))[iETA1];
03061                  par_sig2[2] = (*(Asig5+2))[iETA1]; 
03062                  par_sig2[3] = (*(Asig5+3))[iETA1]; 
03063 
03064                  if(fr == 1){
03065                    if(iETA != 2)iETA1 = 2;
03066                    par1[0] = (*(Amean52+0))[iETA1];
03067                    par1[1] = (*(Amean52+1))[iETA1];
03068                    par1[2] = (*(Amean52+2))[iETA1];
03069                    par1[3] = (*(Amean52+3))[iETA1];
03070                    par_sig1[0] = (*(Asig52+0))[iETA1];
03071                    par_sig1[1] = (*(Asig52+1))[iETA1];
03072                    par_sig1[2] = (*(Asig52+2))[iETA1];
03073                    par_sig1[3] = (*(Asig52+3))[iETA1];
03074                    par_rho[0] = (*(Arho523+0))[iETA1];
03075                    par_rho[1] = (*(Arho523+1))[iETA1];
03076                    par_rho[2] = (*(Arho523+2))[iETA1];
03077                    par_rho[3] = (*(Arho523+3))[iETA1];
03078                    par_rho[4] = (*(Arho523+4))[iETA1];
03079                  
03080                    par2[0] = (*(Amean23+0))[iETA1];
03081                    par2[1] = (*(Amean23+1))[iETA1];
03082                    par2[2] = (*(Amean23+2))[iETA1];
03083                    par2[3] = (*(Amean23+3))[iETA1];
03084                    par_sig2[0] = (*(Asig23+0))[iETA1];
03085                    par_sig2[1] = (*(Asig23+1))[iETA1];
03086                    par_sig2[2] = (*(Asig23+2))[iETA1]; 
03087                    par_sig2[3] = (*(Asig23+3))[iETA1]; 
03088                  }    
03089           break;
03090           case 14 : // b1-2 for method < 10; for method > 10: fr = 1 -> b1-1-2-(3), fr = 0 -> b1-1-phiBend
03091                  if(iETA > 2)iETA1 = 2;
03092                  par1[0] = (*(Amean51+0))[iETA1];
03093                  par1[1] = (*(Amean51+1))[iETA1];
03094                  par1[2] = (*(Amean51+2))[iETA1];
03095                  par1[3] = (*(Amean51+3))[iETA1];
03096                  par_sig1[0] = (*(Asig51+0))[iETA1];
03097                  par_sig1[1] = (*(Asig51+1))[iETA1];
03098                  par_sig1[2] = (*(Asig51+2))[iETA1];
03099                  par_sig1[3] = (*(Asig51+3))[iETA1];
03100                  par_rho[0] = (*(Arho51B+0))[iETA1];
03101                  par_rho[1] = (*(Arho51B+1))[iETA1];
03102                  par_rho[2] = (*(Arho51B+2))[iETA1];
03103                  par_rho[3] = (*(Arho51B+3))[iETA1];
03104                  par_rho[4] = (*(Arho51B+4))[iETA1];
03105                
03106                  par2[0] = (*(Amean5+0))[iETA1];
03107                  par2[1] = (*(Amean5+1))[iETA1];
03108                  par2[2] = (*(Amean5+2))[iETA1];
03109                  par2[3] = (*(Amean5+3))[iETA1];
03110                  par_sig2[0] = (*(Asig5+0))[iETA1];
03111                  par_sig2[1] = (*(Asig5+1))[iETA1];
03112                  par_sig2[2] = (*(Asig5+2))[iETA1]; 
03113                  par_sig2[3] = (*(Asig5+3))[iETA1]; 
03114 
03115                  if(fr == 1){
03116                    if(iETA < 1)iETA1 = 1;
03117                    if(iETA > 2)iETA1 = 2;
03118                    par1[0] = (*(Amean51+0))[iETA1];
03119                    par1[1] = (*(Amean51+1))[iETA1];
03120                    par1[2] = (*(Amean51+2))[iETA1];
03121                    par1[3] = (*(Amean51+3))[iETA1];
03122                    par_sig1[0] = (*(Asig51+0))[iETA1];
03123                    par_sig1[1] = (*(Asig51+1))[iETA1];
03124                    par_sig1[2] = (*(Asig51+2))[iETA1];
03125                    par_sig1[3] = (*(Asig51+3))[iETA1];
03126                    par_rho[0] = (*(Arho512+0))[iETA1];
03127                    par_rho[1] = (*(Arho512+1))[iETA1];
03128                    par_rho[2] = (*(Arho512+2))[iETA1];
03129                    par_rho[3] = (*(Arho512+3))[iETA1];
03130                    par_rho[4] = (*(Arho512+4))[iETA1];
03131                  
03132                    par2[0] = (*(Amean12R+0))[iETA1];
03133                    par2[1] = (*(Amean12R+1))[iETA1];
03134                    par2[2] = (*(Amean12R+2))[iETA1];
03135                    par2[3] = (*(Amean12R+3))[iETA1];
03136                    par_sig2[0] = (*(Asig12R+0))[iETA1];
03137                    par_sig2[1] = (*(Asig12R+1))[iETA1];
03138                    par_sig2[2] = (*(Asig12R+2))[iETA1]; 
03139                    par_sig2[3] = (*(Asig12R+3))[iETA1]; 
03140                  }   
03141           break;
03142           //default:
03143           //return 0.0;
03144           }
03145 
03146         // Switch to 2-Station measurement if dphi is too small
03147         // box cut around Pt of 10 GeV
03148         if ( (fabs(static_cast<double>(dphi2))<0.004  && type != 12 && method < 25)||
03149              (fabs(static_cast<double>(dphi2))<0.004  && type != 12 && type != 14 && type != 11 && method >= 25) ) 
03150           {
03151             //if(type == 12 || type == 14 || type == 11) std::cout << "mode = " << type << " dphi23 = " << dphi2 << " method = " << method << std::endl; //test  
03152             if(type == 2 || type == 3) type = 6; // 1-2-3(or 4) -> 1-2 
03153             if(type == 4) type = 7; // 1-3-4 -> 1-3
03154             if(type == 5) type = 8; // 2-3-4 -> 2-3
03155             if(type == 11) type = 14; // b1-1-3 -> b1-1 for pt_method > 10
03156             //if(type == 14) type = 11;
03157                                                          //phiSign
03158             Pt = Pt2Stn2011(type, eta, dphi1, fr, method,int(2));//in 3 station track there is no information to which ME1/1 or ME1/2 track belong
03159           }
03160         else 
03161           {
03162 //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
03163                   double pt = 140;
03164                   double dpt = 0.1;
03165                   double step = 5.;
03166                   while(pt > 2. ){
03167                       double par_phi12[1] = {dphi1};
03168                       double par_phi23[1] = {dphi2};
03169                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
03170                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.; 
03171                          v[0] = pt;
03172                          lpt1_1 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03173                          v[0] = pt + dpt;
03174                          lpt1_2 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03175                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
03176                          v[0] = pt - step;
03177                          lpt2_1 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03178                          v[0] = pt - step + dpt;
03179                          lpt2_2 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03180                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
03181                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
03182                       v[0] = pt - 0.5*step;
03183                       double fx = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03184                       v[0] = pt - 0.5*step + dpt;
03185                       double fxh = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03186                       v[0] = pt - 0.5*step + 2*dpt;
03187                       double fx2h = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03188     
03189                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
03190 
03191                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolv = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
03192                       //double rho = fitfrho(v, par_rho); //rho 
03193                       if(pt > 25) {dpt = 0.1; step = 5.;}
03194                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
03195                       pt = pt - step;
03196                   }// end while
03197 //*********** end solve equation for muon plus
03198 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
03199 // for one station method we know sing of muon: dphi1 > 0 for muon minus!!! => dphi1 = -dphi1 < 0
03200                   dphi1 = - dphi1;
03201                   dphi2 = - dphi2;      
03202                   pt = 140;
03203                   dpt = 0.1;
03204                   step = 5.;
03205                   while(pt > 2. ){
03206                       double par_phi12[1] = {dphi1};
03207                       double par_phi23[1] = {dphi2};
03208                       double v[1], lpt1_1, lpt1_2, lpt2_1, lpt2_2;
03209                        v[0] = 0; lpt1_1 = 1.; lpt1_2 = 2.; lpt2_1 = 1.; lpt2_2 = 2.; 
03210                          v[0] = pt;
03211                          lpt1_1 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03212                          v[0] = pt + dpt;
03213                          lpt1_2 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03214                       double lpt1 = (lpt1_2-lpt1_1)/dpt; // derivative at point pt1 = pt
03215                          v[0] = pt - step;
03216                          lpt2_1 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03217                          v[0] = pt - step + dpt;
03218                          lpt2_2 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03219                       double lpt2 = (lpt2_2-lpt2_1)/dpt; // derivative at point pt1 = pt - step
03220                       // calculate 2nd derivative at point pt-0.5*step, it should be > 0 if minimum
03221                       v[0] = pt - 0.5*step;
03222                       double fx = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03223                       v[0] = pt - 0.5*step + dpt;
03224                       double fxh = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03225                       v[0] = pt - 0.5*step + 2*dpt;
03226                       double fx2h = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03227     
03228                       double lpt2nd = -(fx2h + fx - 2*fxh)/dpt/dpt;
03229 
03230                       if(lpt1*lpt2 <= 0 && lpt2nd > 0){PTsolvMinus = pt - 0.5*step; break;}// lpt = 0 between lpt1 and lpt2 => maximum pt_solv is a solution of the likelihood
03231                       //double rho = fitfrho(v, par_rho); //rho 
03232                       if(pt > 25) {dpt = 0.1; step = 5.;}
03233                       if(pt <= 25) {dpt = 0.01; step = 0.5;}
03234                       pt = pt - step;
03235                   }// end while
03236 //*********** end solve equation for muon minus 
03237                   PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
03238                   PTsolv = PTsolv*1.2; // correction to have 90% efficiency for trigger cuts
03239                   if(PTsolv > 137.5) PTsolv = 137.5;
03240                   //if(fabs(dphi1) < 0.002 && fabs(dphi2) <= CutPhi23){PTsolv = 140;}
03241                   dphi1 = - dphi1; //return to correct sing dphi
03242                   dphi2 = - dphi2; //return to correct sing dphi
03243                   Pt = PTsolv;
03244           } // end 2 or 3 station method
03245     }}
03246     // fix overlap region high pt:
03247     if(method >= 25 && (type == 12 || type == 14 || type == 11) && fabs(dphi1)<0.003 && fabs(dphi2) <2) Pt = 140.; 
03248            // if ( fabs(static_cast<double>(dphi2))>0.004 ) std::cout << "Pt = " << Pt << " Mode = " << type << " dphi1 = " << dphi1 << " dphi2 = " << dphi2 << std::endl;
03249 
03250     //float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
03251     //if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
03252     float Pt_min = 2;// 2 GeV
03253 
03254     return (Pt > Pt_min)  ? Pt : Pt_min;
03255 }
03256 
03257 
03258 
03259 float CSCTFPtMethods::Pt2Stn2012(int type, float eta, float dphi, int PtbyMLH, float &bestLH, int fr, int method) const 
03260 {
03261   int useBestMLH = PtbyMLH;
03262   int useBOXcut = false;
03263   int useDTBOXcut = true;
03264   if(type == 5) useBOXcut = true; // useBOXcut for mode 5 which come from 3 station 
03265   if(type == 5) type = 8; // 2-3-4 -> 2-3//
03266   
03267     if(fabs(eta) >= 2.4) eta = 2.35;  
03268     double PTsolv = 1.; // for muon plus hypothesis
03269     double PTsolvMinus = 1.;//for muon minus hypothesis
03270     for(int iETA = 0; iETA < 15; iETA++){
03271     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
03272 
03273 // calculate curvers of mean and sigma 
03274               // calculate phi12 mean  
03275               double par1[4] = {0., 0., 0., 0.};
03276               //double phi12mean = fitf5(v, par1); //mu12 
03277               double par_sig1[3] = {0., 0., 0.};
03278         int iETA1 = iETA; 
03279         switch (type) // type = mode here
03280           {
03281           case 6 :  //1-2
03282                  if(fr == 1){
03283                    if(iETA1 < 3)iETA1 = 3;
03284                    if(iETA1 > 11)iETA1 = 11;
03285                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
03286                    par1[0] = A_mu12Front[0][iETA1];
03287                    par1[1] = A_mu12Front[1][iETA1];
03288                    par1[2] = A_mu12Front[2][iETA1];
03289                    par1[3] = A_mu12Front[3][iETA1];
03290                    par_sig1[0] = A_sig12Front[0][iETA1];
03291                    par_sig1[1] = A_sig12Front[1][iETA1];
03292                    par_sig1[2] = A_sig12Front[2][iETA1];
03293                  }
03294                  if(fr == 0){
03295                    if(iETA1 < 1)iETA1 = 1;
03296                    if(iETA1 > 11)iETA1 = 11;
03297                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
03298                    par1[0] = A_mu12Rare[0][iETA1];
03299                    par1[1] = A_mu12Rare[1][iETA1];
03300                    par1[2] = A_mu12Rare[2][iETA1];
03301                    par1[3] = A_mu12Rare[3][iETA1];
03302                    par_sig1[0] = A_sig12Rare[0][iETA1];
03303                    par_sig1[1] = A_sig12Rare[1][iETA1];
03304                    par_sig1[2] = A_sig12Rare[2][iETA1];
03305                  }
03306           break;
03307           case 7 :  //1-3
03308                  if(fr == 1){
03309                    if(iETA1 < 3)iETA1 = 3;
03310                    if(iETA1 > 11)iETA1 = 11;
03311                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
03312                    par1[0] = A_mu13Front[0][iETA1];
03313                    par1[1] = A_mu13Front[1][iETA1];
03314                    par1[2] = A_mu13Front[2][iETA1];
03315                    par1[3] = A_mu13Front[3][iETA1];
03316                    par_sig1[0] = A_sig13Front[0][iETA1];
03317                    par_sig1[1] = A_sig13Front[1][iETA1];
03318                    par_sig1[2] = A_sig13Front[2][iETA1];
03319                  }
03320                  if(fr == 0){
03321                    if(iETA1 < 2)iETA1 = 2;
03322                    if(iETA1 > 11)iETA1 = 11;
03323                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
03324                    par1[0] = A_mu13Rare[0][iETA1];
03325                    par1[1] = A_mu13Rare[1][iETA1];
03326                    par1[2] = A_mu13Rare[2][iETA1];
03327                    par1[3] = A_mu13Rare[3][iETA1];
03328                    par_sig1[0] = A_sig13Rare[0][iETA1];
03329                    par_sig1[1] = A_sig13Rare[1][iETA1];
03330                    par_sig1[2] = A_sig13Rare[2][iETA1];
03331                  }
03332           break;
03333           case 8 :  //2-3
03334                  if(iETA1 < 2)iETA1 = 2;
03335                  par1[0] = A_mu23[0][iETA1];
03336                  par1[1] = A_mu23[1][iETA1];
03337                  par1[2] = A_mu23[2][iETA1];
03338                  par1[3] = A_mu23[3][iETA1];
03339                  par_sig1[0] = A_sig23[0][iETA1];
03340                  par_sig1[1] = A_sig23[1][iETA1];
03341                  par_sig1[2] = A_sig23[2][iETA1];
03342           break;
03343           case 9 :  //2-4
03344                  if(iETA1 < 9)iETA1 = 9;
03345                  par1[0] = A_mu24[0][iETA1];
03346                  par1[1] = A_mu24[1][iETA1];
03347                  par1[2] = A_mu24[2][iETA1];
03348                  par1[3] = A_mu24[3][iETA1];
03349                  par_sig1[0] = A_sig24[0][iETA1];
03350                  par_sig1[1] = A_sig24[1][iETA1];
03351                  par_sig1[2] = A_sig24[2][iETA1];
03352           break;
03353           case 10 :  //3-4
03354                  if(iETA1 < 9)iETA1 = 9;
03355                  par1[0] = A_mu34[0][iETA1];
03356                  par1[1] = A_mu34[1][iETA1];
03357                  par1[2] = A_mu34[2][iETA1];
03358                  par1[3] = A_mu34[3][iETA1];
03359                  par_sig1[0] = A_sig34[0][iETA1];
03360                  par_sig1[1] = A_sig34[1][iETA1];
03361                  par_sig1[2] = A_sig34[2][iETA1];
03362           break;
03363           case 13 :  //1-4
03364                  if(iETA1 < 9)iETA1 = 9;
03365                  if(iETA1 > 11)iETA1 = 11;
03366                  //if(iETA1 > 12)iETA1 = 12;
03367                  if(fr == 1){
03368                    par1[0] = A_mu14Front[0][iETA1];
03369                    par1[1] = A_mu14Front[1][iETA1];
03370                    par1[2] = A_mu14Front[2][iETA1];
03371                    par1[3] = A_mu14Front[3][iETA1];
03372                    par_sig1[0] = A_sig14Front[0][iETA1];
03373                    par_sig1[1] = A_sig14Front[1][iETA1];
03374                    par_sig1[2] = A_sig14Front[2][iETA1];
03375                  }
03376                  if(fr == 0){
03377                    par1[0] = A_mu14Rare[0][iETA1];
03378                    par1[1] = A_mu14Rare[1][iETA1];
03379                    par1[2] = A_mu14Rare[2][iETA1];
03380                    par1[3] = A_mu14Rare[3][iETA1];
03381                    par_sig1[0] = A_sig14Rare[0][iETA1];
03382                    par_sig1[1] = A_sig14Rare[1][iETA1];
03383                    par_sig1[2] = A_sig14Rare[2][iETA1];
03384                  }
03385           break;
03386           case 11 : // b1-3
03387                  if(iETA1 != 2)iETA1 = 2;
03388                  par1[0] = A_mu53[0][iETA1];
03389                  par1[1] = A_mu53[1][iETA1];
03390                  par1[2] = A_mu53[2][iETA1];
03391                  par1[3] = A_mu53[3][iETA1];
03392                  par_sig1[0] = A_sig53[0][iETA1];
03393                  par_sig1[1] = A_sig53[1][iETA1];
03394                  par_sig1[2] = A_sig53[2][iETA1];
03395                 
03396           break;
03397           case 12 :  //1-2-b1 = 2-b1 for pt_method < 10, for pt_method > 10: b1-2
03398                  if(iETA1 < 1)iETA1 = 1;
03399                  if(iETA1 > 2)iETA1 = 2;
03400                  par1[0] = A_mu52[0][iETA1];
03401                  par1[1] = A_mu52[1][iETA1];
03402                  par1[2] = A_mu52[2][iETA1];
03403                  par1[3] = A_mu52[3][iETA1];
03404                  par_sig1[0] = A_sig52[0][iETA1];
03405                  par_sig1[1] = A_sig52[1][iETA1];
03406                  par_sig1[2] = A_sig52[2][iETA1];
03407           break;
03408           case 14 :  //2-b1 for pt_method < 10 and b1-1 for pt_method > 10
03409                  if(method < 10){
03410                     if(iETA1 < 1)iETA1 = 1;
03411                     if(iETA1 > 2)iETA1 = 2;
03412                  }
03413                  par1[0] = A_mu52[0][iETA1];
03414                  par1[1] = A_mu52[1][iETA1];
03415                  par1[2] = A_mu52[2][iETA1];
03416                  par1[3] = A_mu52[3][iETA1];
03417                  par_sig1[0] = A_sig52[0][iETA1];
03418                  par_sig1[1] = A_sig52[1][iETA1];
03419                  par_sig1[2] = A_sig52[2][iETA1];
03420                  if(method > 10){
03421                     if(iETA1 > 2)iETA1 = 2;
03422                     par1[0] = A_mu51[0][iETA1];
03423                     par1[1] = A_mu51[1][iETA1];
03424                     par1[2] = A_mu51[2][iETA1];
03425                     par1[3] = A_mu51[3][iETA1];
03426                     par_sig1[0] = A_sig51[0][iETA1];
03427                     par_sig1[1] = A_sig51[1][iETA1];
03428                     par_sig1[2] = A_sig51[2][iETA1];
03429                  }
03430           break;
03431           //default:
03432           //return 0.0;
03433           }    
03434 
03435 //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
03436           //if(fabs(dphi) >= 0.002)
03437           //if(fabs(dphi) >= 0.00)
03438           //if(fabs(dphi) >= 0.002 || (fabs(dphi) >= 0.01 && (type == 12 || type == 14)))
03439           //{
03440         double muPlusMaxLH = -1e9;
03441                   double pt = 140;
03442                   double step = 5.;
03443                   double maxLH = -1e9;
03444                   
03445                   while(pt > 2. )
03446                     {
03447                       double par_phi12[1] = {dphi};
03448                       double v[1], lpt1_1;
03449                       v[0] = 0; lpt1_1 = 1.; 
03450                       v[0] = pt;
03451                       lpt1_1 = Likelihood2(par_phi12, par1, par_sig1, v);
03452                       
03453                       if (lpt1_1 > maxLH)
03454                         {
03455                           maxLH = lpt1_1;
03456                           PTsolv = pt;
03457                         }
03458                       
03459                              
03460                       if(pt <= 100) {step = 10.0/4.0;}
03461                       if(pt <= 50) {step = 5.0/4.0;}
03462                       if(pt <= 20) {step = 2.0/4.0;}
03463                       if(pt <= 10) {step = 1.0/4.0;}
03464                       if(pt <=5) {step = 0.5/4.0;}
03465                       
03466                       pt = pt - step;
03467                   }// end while
03468                   muPlusMaxLH = maxLH;
03469                   
03470 //*********** end solve equation for muon plus
03471 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
03472 // for one station method we know sing of muon: dphi > 0 for muon minus!!! => dphi = -dphi < 0
03473                   double muMinusMaxLH = -1e9;
03474                   dphi = - dphi;
03475                   pt = 140;
03476                   step = 5.;
03477                   maxLH = -1e9;
03478                   while(pt > 2. )
03479                     {
03480                       double par_phi12[1] = {dphi};
03481                       double v[1], lpt1_1;
03482                       v[0] = 0; lpt1_1 = 1.;
03483                       v[0] = pt;
03484                       lpt1_1 = Likelihood2(par_phi12, par1, par_sig1, v);
03485                       
03486                       if (lpt1_1 > maxLH)
03487                         {
03488                           maxLH = lpt1_1;
03489                           PTsolvMinus = pt;
03490                         }
03491 
03492                      
03493                       if(pt <= 100) {step = 10.0/4.0;}
03494                       if(pt <= 50) {step = 5.0/4.0;}
03495                       if(pt <= 20) {step = 2.0/4.0;}
03496                       if(pt <= 10) {step = 1.0/4.0;}
03497                       if(pt <=5) {step = 0.5/4.0;}
03498                       
03499                       pt = pt - step;
03500                     }// end while
03501                   muMinusMaxLH = maxLH;
03502                   
03503                   //          }// if(fabs(dphi) >= 0.002)
03504                   //          else 
03505 //          {PTsolv = 137.5;} 
03506                   
03507 //*********** end solve equation for muon minus 
03508                   if (useBestMLH)
03509                     PTsolv = (muPlusMaxLH > muMinusMaxLH) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
03510                   else
03511                     PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
03512                   
03513                   bestLH = (muPlusMaxLH > muMinusMaxLH) ? muPlusMaxLH : muMinusMaxLH;
03514                   
03515                   
03516                   PTsolv = PTsolv*1.2;
03517           if(PTsolv > 137.5) PTsolv = 137.5;
03518           
03519           if (useBOXcut)
03520             if(fabs(dphi) <= 0.002 && PTsolv < 120.)PTsolv = 140.;
03521           if (useDTBOXcut)
03522             if( fabs(dphi) <= 0.01 && (type == 11 || type == 12 || type == 14) && PTsolv < 120.)PTsolv = 140.;
03523 
03524           dphi = - dphi; //return to correct sing dphi
03525 
03526     } //if(fabs(eta_TracMy) 
03527     } //end "for by iETA"
03528 
03529     float Pt = PTsolv;
03530     if(Pt > 10 && fabs(dphi) >= 0.1 ) std::cout << "iF = 0 for dphi = " << dphi <<" and Pt = " << Pt << std::endl;
03531                                                                     
03532     //if(Pt > 100 && (type == 12 || type == 14) && fabs(eta) <= 1.2 && dphi > 0.015 )std::cout << "dphi = " << dphi << " eta = " << eta << std::endl; 
03533     //if(Pt < 10 && (type == 12 || type == 14) && fabs(eta) <= 1.2 && dphi < 0.01)std::cout << "dphi = " << dphi << " eta = " << eta <<   std::endl; 
03534     //      return (Pt>0.0) ? Pt : 0.0;
03535 
03536     float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
03537     if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
03538 
03539     return (Pt > Pt_min)  ? Pt : Pt_min;
03540 }
03541 
03542 
03543 
03544 
03545 float CSCTFPtMethods::Pt3Stn2012(int type, float eta, float dphi1, float dphi2,  int PtbyMLH, float &bestLH, int fr, int method) const 
03546 {
03547 
03548   int useBestMLH = PtbyMLH;
03549   int use2Stn = false;
03550   int use2StnDT = true;
03551   if(type == 5) use2Stn = true;//switch 2 station assighment for mode = 5
03552   
03553     if(fabs(eta) >= 2.4)eta = 2.35;
03554     float Pt = 0.;
03555     double PTsolv = 1.; // for muon plus hypothesis
03556     double PTsolvMinus = 1.;//for muon minus hypothesis
03557     for(int iETA = 0; iETA < 15; iETA++){
03558     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
03559 
03560 // calculate curvers of mean and sigma 
03561               // calculate phi12 mean  
03562               double par1[4] = {0., 0., 0., 0.};
03563               //double phi12mean = fitf5(v, par1); //mu12 
03564               double par_sig1[3] = {0., 0., 0.};
03565               // calculate phi23 mean  
03566               double par2[4] = {0., 0., 0., 0.};
03567               // calculate phi23 sig
03568               double par_sig2[3] = {0., 0., 0.};
03569               // calculate correlation rho
03570               double par_rho[5] = {0., 0., 0., 0., 0.};
03571               int iETA1 = iETA;
03572               int iETA2 = iETA;
03573         switch (type) // type = mode here
03574           {
03575           case 2 :  //1-2-3
03576                  if(fr == 1){
03577                    if(iETA1 < 3)iETA1 = 3;
03578                    if(iETA1 > 11)iETA1 = 11;
03579                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
03580                    par1[0] = A_mu12Front[0][iETA1];
03581                    par1[1] = A_mu12Front[1][iETA1];
03582                    par1[2] = A_mu12Front[2][iETA1];
03583                    par1[3] = A_mu12Front[3][iETA1];
03584                    par_sig1[0] = A_sig12Front[0][iETA1];
03585                    par_sig1[1] = A_sig12Front[1][iETA1];
03586                    par_sig1[2] = A_sig12Front[2][iETA1];
03587                    par_rho[0] = A_rho123FrontCSCTF[0][iETA1];
03588                    par_rho[1] = A_rho123FrontCSCTF[1][iETA1];
03589                    par_rho[2] = A_rho123FrontCSCTF[2][iETA1];
03590                    par_rho[3] = A_rho123FrontCSCTF[3][iETA1];
03591                    par_rho[4] = A_rho123FrontCSCTF[4][iETA1];
03592                  }
03593                  if(fr == 0){
03594                    if(iETA1 < 1)iETA1 = 1;
03595                    if(iETA1 > 11)iETA1 = 11;
03596                    //if(fabs(eta)>1.56 && fabs(eta) < 1.6) iETA1 = iETA +1;
03597                    par1[0] = A_mu12Rare[0][iETA1];
03598                    par1[1] = A_mu12Rare[1][iETA1];
03599                    par1[2] = A_mu12Rare[2][iETA1];
03600                    par1[3] = A_mu12Rare[3][iETA1];
03601                    par_sig1[0] = A_sig12Rare[0][iETA1];
03602                    par_sig1[1] = A_sig12Rare[1][iETA1];
03603                    par_sig1[2] = A_sig12Rare[2][iETA1];
03604                    par_rho[0] = A_rho123RareCSCTF[0][iETA1];
03605                    par_rho[1] = A_rho123RareCSCTF[1][iETA1];
03606                    par_rho[2] = A_rho123RareCSCTF[2][iETA1];
03607                    par_rho[3] = A_rho123RareCSCTF[3][iETA1];
03608                    par_rho[4] = A_rho123RareCSCTF[4][iETA1];
03609                  }
03610                  if(iETA2 < 2)iETA2 = 2;
03611                  par2[0] = A_mu23[0][iETA2];
03612                  par2[1] = A_mu23[1][iETA2];
03613                  par2[2] = A_mu23[2][iETA2];
03614                  par2[3] = A_mu23[3][iETA2];
03615                  par_sig2[0] = A_sig23[0][iETA2];
03616                  par_sig2[1] = A_sig23[1][iETA2];
03617                  par_sig2[2] = A_sig23[2][iETA2];
03618 
03619           break;
03620           case 3 : //1-2-4
03621                  if(fr == 1){
03622                    if(iETA1 < 3)iETA1 = 3;
03623                    if(iETA1 > 11)iETA1 = 11;
03624                    par1[0] = A_mu12Front[0][iETA1];
03625                    par1[1] = A_mu12Front[1][iETA1];
03626                    par1[2] = A_mu12Front[2][iETA1];
03627                    par1[3] = A_mu12Front[3][iETA1];
03628                    par_sig1[0] = A_sig12Front[0][iETA1];
03629                    par_sig1[1] = A_sig12Front[1][iETA1];
03630                    par_sig1[2] = A_sig12Front[2][iETA1];
03631                    par_rho[0] = A_rho124FrontCSCTF[0][iETA1];
03632                    par_rho[1] = A_rho124FrontCSCTF[1][iETA1];
03633                    par_rho[2] = A_rho124FrontCSCTF[2][iETA1];
03634                    par_rho[3] = A_rho124FrontCSCTF[3][iETA1];
03635                    par_rho[4] = A_rho124FrontCSCTF[4][iETA1];
03636                  }
03637                  if(fr == 0){
03638                    if(iETA1 < 1)iETA1 = 1;
03639                    if(iETA1 > 11)iETA1 = 11;
03640                    par1[0] = A_mu12Rare[0][iETA1];
03641                    par1[1] = A_mu12Rare[1][iETA1];
03642                    par1[2] = A_mu12Rare[2][iETA1];
03643                    par1[3] = A_mu12Rare[3][iETA1];
03644                    par_sig1[0] = A_sig12Rare[0][iETA1];
03645                    par_sig1[1] = A_sig12Rare[1][iETA1];
03646                    par_sig1[2] = A_sig12Rare[2][iETA1];
03647                    par_rho[0] = A_rho124RareCSCTF[0][iETA1];
03648                    par_rho[1] = A_rho124RareCSCTF[1][iETA1];
03649                    par_rho[2] = A_rho124RareCSCTF[2][iETA1];
03650                    par_rho[3] = A_rho124RareCSCTF[3][iETA1];
03651                    par_rho[4] = A_rho124RareCSCTF[4][iETA1];
03652                  }
03653                  if(iETA2 < 9)iETA2 = 9;
03654                  par2[0] = A_mu24[0][iETA2];
03655                  par2[1] = A_mu24[1][iETA2];
03656                  par2[2] = A_mu24[2][iETA2];
03657                  par2[3] = A_mu24[3][iETA2];
03658                  par_sig2[0] = A_sig24[0][iETA2];
03659                  par_sig2[1] = A_sig24[1][iETA2];
03660                  par_sig2[2] = A_sig24[2][iETA2];
03661           break;
03662           case 4 : //1-3-4
03663                  if(fr == 1){
03664                    if(iETA1 < 3)iETA1 = 3;
03665                    if(iETA1 > 11)iETA1 = 11;
03666                    par1[0] = A_mu13Front[0][iETA1];
03667                    par1[1] = A_mu13Front[1][iETA1];
03668                    par1[2] = A_mu13Front[2][iETA1];
03669                    par1[3] = A_mu13Front[3][iETA1];
03670                    par_sig1[0] = A_sig13Front[0][iETA1];
03671                    par_sig1[1] = A_sig13Front[1][iETA1];
03672                    par_sig1[2] = A_sig13Front[2][iETA1];
03673                    par_rho[0] = A_rho134FrontCSCTF[0][iETA1];
03674                    par_rho[1] = A_rho134FrontCSCTF[1][iETA1];
03675                    par_rho[2] = A_rho134FrontCSCTF[2][iETA1];
03676                    par_rho[3] = A_rho134FrontCSCTF[3][iETA1];
03677                    par_rho[4] = A_rho134FrontCSCTF[4][iETA1];                 
03678                  }
03679                  if(fr == 0){
03680                    if(iETA1 < 2)iETA1 = 2;
03681                    if(iETA1 > 11)iETA1 = 11;
03682                    par1[0] = A_mu13Rare[0][iETA1];
03683                    par1[1] = A_mu13Rare[1][iETA1];
03684                    par1[2] = A_mu13Rare[2][iETA1];
03685                    par1[3] = A_mu13Rare[3][iETA1];
03686                    par_sig1[0] = A_sig13Rare[0][iETA1];
03687                    par_sig1[1] = A_sig13Rare[1][iETA1];
03688                    par_sig1[2] = A_sig13Rare[2][iETA1];
03689                    par_rho[0] = A_rho134RareCSCTF[0][iETA1];
03690                    par_rho[1] = A_rho134RareCSCTF[1][iETA1];
03691                    par_rho[2] = A_rho134RareCSCTF[2][iETA1];
03692                    par_rho[3] = A_rho134RareCSCTF[3][iETA1];
03693                    par_rho[4] = A_rho134RareCSCTF[4][iETA1];
03694                  }
03695                  if(iETA2 < 9)iETA2 = 9;
03696                  par2[0] = A_mu34[0][iETA2];
03697                  par2[1] = A_mu34[1][iETA2];
03698                  par2[2] = A_mu34[2][iETA2];
03699                  par2[3] = A_mu34[3][iETA2];
03700                  par_sig2[0] = A_sig34[0][iETA2];
03701                  par_sig2[1] = A_sig34[1][iETA2];
03702                  par_sig2[2] = A_sig34[2][iETA2];
03703           break;
03704           case 5 ://2-3-4
03705                  if(iETA1 < 9)iETA1 = 9;
03706                  par1[0] = A_mu23[0][iETA1];
03707                  par1[1] = A_mu23[1][iETA1];
03708                  par1[2] = A_mu23[2][iETA1];
03709                  par1[3] = A_mu23[3][iETA1];
03710                  par_sig1[0] = A_sig23[0][iETA1];
03711                  par_sig1[1] = A_sig23[1][iETA1];
03712                  par_sig1[2] = A_sig23[2][iETA1];
03713                  par_rho[0] = A_rho234CSCTF[0][iETA1];
03714                  par_rho[1] = A_rho234CSCTF[1][iETA1];
03715                  par_rho[2] = A_rho234CSCTF[2][iETA1];
03716                  par_rho[3] = A_rho234CSCTF[3][iETA1];
03717                  par_rho[4] = A_rho234CSCTF[4][iETA1];
03718 
03719                  par2[0] = A_mu34[0][iETA1];
03720                  par2[1] = A_mu34[1][iETA1];
03721                  par2[2] = A_mu34[2][iETA1];
03722                  par2[3] = A_mu34[3][iETA1];
03723                  par_sig2[0] = A_sig34[0][iETA1];
03724                  par_sig2[1] = A_sig34[1][iETA1];
03725                  par_sig2[2] = A_sig34[2][iETA1];
03726           break;
03727           case 11 : // b1-1-3
03728                  if(iETA1 != 2)iETA1 = 2;
03729                  par1[0] = A_mu51[0][iETA1];
03730                  par1[1] = A_mu51[1][iETA1];
03731                  par1[2] = A_mu51[2][iETA1];
03732                  par1[3] = A_mu51[3][iETA1];
03733                  par_sig1[0] = A_sig51[0][iETA1];
03734                  par_sig1[1] = A_sig51[1][iETA1];
03735                  par_sig1[2] = A_sig51[2][iETA1];
03736                  par_rho[0] = A_rho513[0][iETA1]; 
03737                  par_rho[1] = A_rho513[0][iETA1]; 
03738                  par_rho[2] = A_rho513[0][iETA1]; 
03739                  par_rho[3] = A_rho513[0][iETA1]; 
03740                  par_rho[4] = A_rho513[0][iETA1]; 
03741 
03742                  par2[0] = A_mu13Rare[0][iETA1];
03743                  par2[1] = A_mu13Rare[1][iETA1];
03744                  par2[2] = A_mu13Rare[2][iETA1];
03745                  par2[3] = A_mu13Rare[3][iETA1];
03746                  par_sig2[0] = A_sig13Rare[0][iETA1];
03747                  par_sig2[1] = A_sig13Rare[1][iETA1];
03748                  par_sig2[2] = A_sig13Rare[2][iETA1];
03749           break;
03750           case 12 : // b1-2-3
03751                  if(iETA1 != 2)iETA1 = 2;
03752                  par1[0] = A_mu52[0][iETA1];
03753                  par1[1] = A_mu52[1][iETA1];
03754                  par1[2] = A_mu52[2][iETA1];
03755                  par1[3] = A_mu52[3][iETA1];
03756                  par_sig1[0] = A_sig52[0][iETA1];
03757                  par_sig1[1] = A_sig52[1][iETA1];
03758                  par_sig1[2] = A_sig52[2][iETA1];
03759                  par_rho[0] = A_rho523[0][iETA1];
03760                  par_rho[1] = A_rho523[0][iETA1];
03761                  par_rho[2] = A_rho523[0][iETA1];
03762                  par_rho[3] = A_rho523[0][iETA1];
03763                  par_rho[4] = A_rho523[0][iETA1];
03764                  
03765                  par2[0] = A_mu23[0][iETA1];
03766                  par2[1] = A_mu23[1][iETA1];
03767                  par2[2] = A_mu23[2][iETA1];
03768                  par2[3] = A_mu23[3][iETA1];
03769                  par_sig2[0] = A_sig23[0][iETA1];
03770                  par_sig2[1] = A_sig23[1][iETA1];
03771                  par_sig2[2] = A_sig23[2][iETA1];
03772           break;
03773           case 14 : // b1-1-2-(3)
03774                  if(iETA1 < 1)iETA1 = 1;
03775                  if(iETA1 > 2)iETA1 = 2;
03776                  par1[0] = A_mu51[0][iETA1];
03777                  par1[1] = A_mu51[1][iETA1];
03778                  par1[2] = A_mu51[2][iETA1];
03779                  par1[3] = A_mu51[3][iETA1];
03780                  par_sig1[0] = A_sig51[0][iETA1];
03781                  par_sig1[1] = A_sig51[1][iETA1];
03782                  par_sig1[2] = A_sig51[2][iETA1];
03783                  par_rho[0] = A_rho512[0][iETA1];
03784                  par_rho[1] = A_rho512[0][iETA1];
03785                  par_rho[2] = A_rho512[0][iETA1];
03786                  par_rho[3] = A_rho512[0][iETA1];
03787                  par_rho[4] = A_rho512[0][iETA1];
03788                  
03789                  par2[0] = A_mu12Rare[0][iETA1];
03790                  par2[1] = A_mu12Rare[1][iETA1];
03791                  par2[2] = A_mu12Rare[2][iETA1];
03792                  par2[3] = A_mu12Rare[3][iETA1];
03793                  par_sig2[0] = A_sig12Rare[0][iETA1];
03794                  par_sig2[1] = A_sig12Rare[1][iETA1];
03795                  par_sig2[2] = A_sig12Rare[2][iETA1]; 
03796           break;
03797           //default:
03798           //return 0.0;
03799           }
03800 
03801         // Switch to 2-Station measurement if dphi is too small 
03802         // box cut around Pt of 10 GeV
03803         if ( fabs(static_cast<double>(dphi2))<0.004  && ((type >= 11 && use2StnDT) || (type>=2 && type<=5 && use2Stn)))
03804           {
03805             if (use2Stn)
03806               {
03807                 if(type == 2 || type == 3) type = 6; // 1-2-3(or 4) -> 1-2 
03808                 if(type == 4) type = 7; // 1-3-4 -> 1-3
03809                 Pt = Pt2Stn2012(type, eta, dphi1, useBestMLH, bestLH, fr, method);
03810               }
03811             if (use2StnDT)
03812               {
03813                 if(type == 11) type = 14; // b1-1-3 -> b1-1 for pt_method > 10
03814                 Pt = Pt2Stn2012(type, eta, dphi1, useBestMLH, bestLH, fr, method);
03815               }
03816           }
03817         else 
03818           {
03819 //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
03820             double muPlusMaxLH = -1e9;
03821                   double pt = 140;
03822                   double step = 5.;
03823                   double maxLH = -1e9;
03824                   
03825                   while(pt > 2. )
03826                     {
03827                       double par_phi12[1] = {dphi1};
03828                       double par_phi23[1] = {dphi2};
03829                       double v[1], lpt1_1; 
03830                       v[0] = 0; lpt1_1 = 1.;
03831                       v[0] = pt;
03832                       lpt1_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03833                       
03834                       if (lpt1_1 > maxLH)
03835                         {
03836                           maxLH = lpt1_1;
03837                           PTsolv = pt;
03838                         }
03839 
03840                                            
03841                       if(pt <= 100) {step = 10.0/4.0;}
03842                       if(pt <= 50) {step = 5.0/4.0;}
03843                       if(pt <= 20) {step = 2.0/4.0;}
03844                       if(pt <= 10) {step = 1.0/4.0;}
03845                       if(pt <=5) {step = 0.5/4.0;}
03846 
03847                       pt = pt - step;
03848                   }// end while
03849                   muPlusMaxLH = maxLH;
03850                   
03851 //*********** end solve equation for muon plus
03852 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
03853 // for one station method we know sing of muon: dphi1 > 0 for muon minus!!! => dphi1 = -dphi1 < 0
03854                   double muMinusMaxLH = -1e9;
03855                   dphi1 = - dphi1;
03856                   dphi2 = - dphi2;      
03857                   pt = 140;
03858                   step = 5.;
03859                   maxLH = -1e9;
03860                   
03861                   while(pt > 2. )
03862                     {
03863                       double par_phi12[1] = {dphi1};
03864                       double par_phi23[1] = {dphi2};
03865                       double v[1], lpt1_1;
03866                       v[0] = 0; lpt1_1 = 1.; 
03867                       v[0] = pt;
03868                       lpt1_1 = Likelihood(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
03869                       
03870                       if (lpt1_1 > maxLH)
03871                         {
03872                           maxLH = lpt1_1;
03873                           PTsolvMinus = pt;
03874                         }
03875                       
03876                       if(pt <= 100) {step = 10.0/4.0;}
03877                       if(pt <= 50) {step = 5.0/4.0;}
03878                       if(pt <= 20) {step = 2.0/4.0;}
03879                       if(pt <= 10) {step = 1.0/4.0;}
03880                       if(pt <=5) {step = 0.5/4.0;}
03881                       
03882                       pt = pt - step;
03883                     }// end while
03884                   muMinusMaxLH = maxLH;
03885 
03886                   if (useBestMLH)
03887                     PTsolv = (muPlusMaxLH > muMinusMaxLH) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
03888                   else
03889                     PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
03890                   
03891                   bestLH = (muPlusMaxLH > muMinusMaxLH) ? muPlusMaxLH : muMinusMaxLH;
03892                   //*********** end solve equation for muon minus 
03893                   
03894                   PTsolv = PTsolv*1.2; // correction to have 90% efficiency for trigger cuts
03895                   if(PTsolv > 137.5) PTsolv = 137.5;
03896                   //if(fabs(dphi1) < 0.002 && fabs(dphi2) <= CutPhi23){PTsolv = 140;}
03897                   dphi1 = - dphi1; //return to correct sing dphi
03898                   dphi2 = - dphi2; //return to correct sing dphi
03899                   Pt = PTsolv;
03900           } // end 2 or 3 station method
03901     }
03902     }
03903            // if ( fabs(static_cast<double>(dphi2))>0.004 ) std::cout << "Pt = " << Pt << " Mode = " << type << " dphi1 = " << dphi1 << " dphi2 = " << dphi2 << std::endl;
03904 
03905     float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
03906     if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
03907 
03908     return (Pt > Pt_min)  ? Pt : Pt_min;
03909 }
03910 
03911 
03912 
03913 float CSCTFPtMethods::Pt3Stn2012_DT(int type, float eta, float dphi1, float dphi2,  int PtbyMLH, float &bestLH, int fr, int method) const 
03914 {
03915   int useBestMLH = PtbyMLH;
03916   int useBOXcutDT = true;
03917   int use2Stn = false;
03918   int use2StnDT = true;
03919   
03920     //if(fabs(eta) >= 2.4)eta = 2.35;
03921     if(fabs(eta) >= 2.2) eta = 2.15;  
03922     float Pt = 0.;
03923     double PTsolv = 1.; // for muon plus hypothesis
03924     double PTsolvMinus = 1.;//for muon minus hypothesis
03925     for(int iETA = 0; iETA < 15; iETA++){
03926     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
03927 
03928 // calculate curvers of mean and sigma 
03929               // calculate phi12 mean  
03930               double par1[4] = {0., 0., 0., 0.};
03931               //double phi12mean = fitf5(v, par1); //mu12 
03932               double par_sig1[4] = {0., 0., 0., 0};
03933               // calculate phi23 mean  
03934               double par2[4] = {0., 0., 0., 0.};
03935               // calculate phi23 sig
03936               double par_sig2[4] = {0., 0., 0., 0.};
03937               // calculate correlation rho
03938               double par_rho[5] = {0., 0., 0., 0., 0.};
03939               int iETA1 = iETA;
03940               int iETA2 = iETA;
03941 
03942 // defind which parameters will be use
03943         double (*Amean12F)[15] = AB_mu12F; 
03944         double (*Asig12F)[15] = AB_sig12F; 
03945         double (*Amean12R)[15] = AB_mu12R; 
03946         double (*Asig12R)[15] = AB_sig12R; 
03947 
03948         double (*Amean13F)[15] = AB_mu13F; 
03949         double (*Asig13F)[15] = AB_sig13F; 
03950         double (*Amean13R)[15] = AB_mu13R; 
03951         double (*Asig13R)[15] = AB_sig13R; 
03952 
03953         //double (*Amean14F)[15] = AB_mu14F; 
03954         //double (*Asig14F)[15] = AB_sig14F; 
03955         //double (*Amean14R)[15] = AB_mu14R; 
03956         //double (*Asig14R)[15] = AB_sig14R; 
03957 
03958         double (*Amean23)[15] = AB_mu23;
03959         double (*Asig23)[15] = AB_sig23;
03960         double (*Amean24)[15] = AB_mu24;
03961         double (*Asig24)[15] = AB_sig24;
03962         double (*Amean34)[15] = AB_mu34;
03963         double (*Asig34)[15] = AB_sig34;
03964 
03965         double (*Amean5)[15] = AB_mu5;
03966         double (*Asig5)[15] = AB_sig5;
03967         double (*Amean51)[15] = AB_mu51;
03968         double (*Asig51)[15] = AB_sig51;
03969         double (*Amean52)[15] = AB_mu52;
03970         double (*Asig52)[15] = AB_sig52;
03971         double (*Amean53)[15] = AB_mu53;
03972         double (*Asig53)[15] = AB_sig53;
03973 
03974         double (*Arho123F)[15] = AB_rho123F;
03975         double (*Arho123R)[15] = AB_rho123R;
03976         double (*Arho124F)[15] = AB_rho124F;
03977         double (*Arho124R)[15] = AB_rho124R;
03978         double (*Arho134F)[15] = AB_rho134F;
03979         double (*Arho134R)[15] = AB_rho134R;
03980         double (*Arho234)[15] = AB_rho234;
03981 
03982         double (*Arho51B)[15] = AB_rho51B;
03983         double (*Arho52B)[15] = AB_rho52B;
03984         double (*Arho53B)[15] = AB_rho53B;
03985         double (*Arho512)[15] = AB_rho512;
03986         double (*Arho513)[15] = AB_rho513;
03987         double (*Arho523)[15] = AB_rho523;
03988 
03989         //cout << "iETA = " << iETA 
03990         //     << " AB_mu51[0][iETA] = " << AB_mu51[0][iETA] << " pointer = " << (*(Amean51+0))[iETA]   
03991         //     << " AB_mu51[3][iETA] = " << AB_mu51[3][iETA] << " pointer = " << (*(Amean51+3))[iETA]   
03992         //     << endl;
03993  
03994         switch (type) // type = mode here
03995           {
03996           case 2 :  //1-2-3
03997                  if(iETA < 2)iETA2 = 2;
03998                  if(fr == 1){
03999                    if(iETA < 3)iETA1 = 3;
04000                    par1[0] = (*(Amean12F+0))[iETA1];
04001                    par1[1] = (*(Amean12F+1))[iETA1];
04002                    par1[2] = (*(Amean12F+2))[iETA1];
04003                    par1[3] = (*(Amean12F+3))[iETA1];
04004                    par_sig1[0] = (*(Asig12F+0))[iETA1];
04005                    par_sig1[1] = (*(Asig12F+1))[iETA1];
04006                    par_sig1[2] = (*(Asig12F+2))[iETA1];
04007                    par_sig1[3] = (*(Asig12F+3))[iETA1];
04008                    par_rho[0] = (*(Arho123F+0))[iETA2];
04009                    par_rho[1] = (*(Arho123F+1))[iETA2];
04010                    par_rho[2] = (*(Arho123F+2))[iETA2];
04011                    par_rho[3] = (*(Arho123F+3))[iETA2];
04012                    par_rho[4] = (*(Arho123F+4))[iETA2];
04013                  
04014                  }
04015                  if(fr == 0){
04016                    if(iETA < 1)iETA1 = 1;
04017                    par1[0] = (*(Amean12R+0))[iETA1];
04018                    par1[1] = (*(Amean12R+1))[iETA1];
04019                    par1[2] = (*(Amean12R+2))[iETA1];
04020                    par1[3] = (*(Amean12R+3))[iETA1];
04021                    par_sig1[0] = (*(Asig12R+0))[iETA1];
04022                    par_sig1[1] = (*(Asig12R+1))[iETA1];
04023                    par_sig1[2] = (*(Asig12R+2))[iETA1];
04024                    par_sig1[3] = (*(Asig12R+3))[iETA1];
04025                    par_rho[0] = (*(Arho123R+0))[iETA2];
04026                    par_rho[1] = (*(Arho123R+1))[iETA2];
04027                    par_rho[2] = (*(Arho123R+2))[iETA2];
04028                    par_rho[3] = (*(Arho123R+3))[iETA2];
04029                    par_rho[4] = (*(Arho123R+4))[iETA2];
04030                  }
04031                  par2[0] = (*(Amean23+0))[iETA2];
04032                  par2[1] = (*(Amean23+1))[iETA2];
04033                  par2[2] = (*(Amean23+2))[iETA2];
04034                  par2[3] = (*(Amean23+3))[iETA2];
04035                  par_sig2[0] = (*(Asig23+0))[iETA2];
04036                  par_sig2[1] = (*(Asig23+1))[iETA2];
04037                  par_sig2[2] = (*(Asig23+2))[iETA2]; 
04038                  par_sig2[3] = (*(Asig23+3))[iETA2]; 
04039 
04040           break;
04041           case 3 : //1-2-4
04042                  if(iETA < 3)iETA2 = 3;
04043                  if(fr == 1){
04044                    if(iETA < 3)iETA1 = 3;
04045                    par1[0] = (*(Amean12F+0))[iETA1];
04046                    par1[1] = (*(Amean12F+1))[iETA1];
04047                    par1[2] = (*(Amean12F+2))[iETA1];
04048                    par1[3] = (*(Amean12F+3))[iETA1];
04049                    par_sig1[0] = (*(Asig12F+0))[iETA1];
04050                    par_sig1[1] = (*(Asig12F+1))[iETA1];
04051                    par_sig1[2] = (*(Asig12F+2))[iETA1];
04052                    par_sig1[3] = (*(Asig12F+3))[iETA1];
04053                    par_rho[0] = (*(Arho124F+0))[iETA2];
04054                    par_rho[1] = (*(Arho124F+1))[iETA2];
04055                    par_rho[2] = (*(Arho124F+2))[iETA2];
04056                    par_rho[3] = (*(Arho124F+3))[iETA2];
04057                    par_rho[4] = (*(Arho124F+4))[iETA2];
04058                  
04059                  }
04060                  if(fr == 0){
04061                    if(iETA < 1)iETA1 = 1;
04062                    par1[0] = (*(Amean12R+0))[iETA1];
04063                    par1[1] = (*(Amean12R+1))[iETA1];
04064                    par1[2] = (*(Amean12R+2))[iETA1];
04065                    par1[3] = (*(Amean12R+3))[iETA1];
04066                    par_sig1[0] = (*(Asig12R+0))[iETA1];
04067                    par_sig1[1] = (*(Asig12R+1))[iETA1];
04068                    par_sig1[2] = (*(Asig12R+2))[iETA1];
04069                    par_sig1[3] = (*(Asig12R+3))[iETA1];
04070                    par_rho[0] = (*(Arho124R+0))[iETA2];
04071                    par_rho[1] = (*(Arho124R+1))[iETA2];
04072                    par_rho[2] = (*(Arho124R+2))[iETA2];
04073                    par_rho[3] = (*(Arho124R+3))[iETA2];
04074                    par_rho[4] = (*(Arho124R+4))[iETA2];
04075                  }
04076                  par2[0] = (*(Amean24+0))[iETA2];
04077                  par2[1] = (*(Amean24+1))[iETA2];
04078                  par2[2] = (*(Amean24+2))[iETA2];
04079                  par2[3] = (*(Amean24+3))[iETA2];
04080                  par_sig2[0] = (*(Asig24+0))[iETA2];
04081                  par_sig2[1] = (*(Asig24+1))[iETA2];
04082                  par_sig2[2] = (*(Asig24+2))[iETA2]; 
04083                  par_sig2[3] = (*(Asig24+3))[iETA2]; 
04084           break;
04085           case 4 : //1-3-4
04086                  if(iETA < 3)iETA2 = 3;
04087                  if(fr == 1){
04088                    if(iETA < 3)iETA1 = 3;
04089                    par1[0] = (*(Amean13F+0))[iETA1];
04090                    par1[1] = (*(Amean13F+1))[iETA1];
04091                    par1[2] = (*(Amean13F+2))[iETA1];
04092                    par1[3] = (*(Amean13F+3))[iETA1];
04093                    par_sig1[0] = (*(Asig13F+0))[iETA1];
04094                    par_sig1[1] = (*(Asig13F+1))[iETA1];
04095                    par_sig1[2] = (*(Asig13F+2))[iETA1];
04096                    par_sig1[3] = (*(Asig13F+3))[iETA1];
04097                    par_rho[0] = (*(Arho134F+0))[iETA2];
04098                    par_rho[1] = (*(Arho134F+1))[iETA2];
04099                    par_rho[2] = (*(Arho134F+2))[iETA2];
04100                    par_rho[3] = (*(Arho134F+3))[iETA2];
04101                    par_rho[4] = (*(Arho134F+4))[iETA2];
04102                  
04103                  }
04104                  if(fr == 0){
04105                    if(iETA < 3)iETA1 = 3;
04106                    par1[0] = (*(Amean13R+0))[iETA1];
04107                    par1[1] = (*(Amean13R+1))[iETA1];
04108                    par1[2] = (*(Amean13R+2))[iETA1];
04109                    par1[3] = (*(Amean13R+3))[iETA1];
04110                    par_sig1[0] = (*(Asig13R+0))[iETA1];
04111                    par_sig1[1] = (*(Asig13R+1))[iETA1];
04112                    par_sig1[2] = (*(Asig13R+2))[iETA1];
04113                    par_sig1[3] = (*(Asig13R+3))[iETA1];
04114                    par_rho[0] = (*(Arho134R+0))[iETA2];
04115                    par_rho[1] = (*(Arho134R+1))[iETA2];
04116                    par_rho[2] = (*(Arho134R+2))[iETA2];
04117                    par_rho[3] = (*(Arho134R+3))[iETA2];
04118                    par_rho[4] = (*(Arho134R+4))[iETA2];
04119                  }
04120                  par2[0] = (*(Amean34+0))[iETA2];
04121                  par2[1] = (*(Amean34+1))[iETA2];
04122                  par2[2] = (*(Amean34+2))[iETA2];
04123                  par2[3] = (*(Amean34+3))[iETA2];
04124                  par_sig2[0] = (*(Asig34+0))[iETA2];
04125                  par_sig2[1] = (*(Asig34+1))[iETA2];
04126                  par_sig2[2] = (*(Asig34+2))[iETA2]; 
04127                  par_sig2[3] = (*(Asig34+3))[iETA2]; 
04128           break;
04129           case 5 ://2-3-4
04130                  if(iETA < 2)iETA1 = 2;
04131                  if(iETA < 3)iETA2 = 3;
04132                  par1[0] = (*(Amean23+0))[iETA1];
04133                  par1[1] = (*(Amean23+1))[iETA1];
04134                  par1[2] = (*(Amean23+2))[iETA1];
04135                  par1[3] = (*(Amean23+3))[iETA1];
04136                  par_sig1[0] = (*(Asig23+0))[iETA1];
04137                  par_sig1[1] = (*(Asig23+1))[iETA1];
04138                  par_sig1[2] = (*(Asig23+2))[iETA1];
04139                  par_sig1[3] = (*(Asig23+3))[iETA1];
04140                  par_rho[0] = (*(Arho234+0))[iETA2];
04141                  par_rho[1] = (*(Arho234+1))[iETA2];
04142                  par_rho[2] = (*(Arho234+2))[iETA2];
04143                  par_rho[3] = (*(Arho234+3))[iETA2];
04144                  par_rho[4] = (*(Arho234+4))[iETA2];
04145                  
04146                  par2[0] = (*(Amean34+0))[iETA2];
04147                  par2[1] = (*(Amean34+1))[iETA2];
04148                  par2[2] = (*(Amean34+2))[iETA2];
04149                  par2[3] = (*(Amean34+3))[iETA2];
04150                  par_sig2[0] = (*(Asig34+0))[iETA2];
04151                  par_sig2[1] = (*(Asig34+1))[iETA2];
04152                  par_sig2[2] = (*(Asig34+2))[iETA2]; 
04153                  par_sig2[3] = (*(Asig34+3))[iETA2]; 
04154           break;
04155           case 11 : // singles for method < 10, for method > 10: fr = 1 -> b1-1-3, fr = 0 -> b1-3-phiBend
04156                  if(iETA != 2)iETA1 = 2;
04157                  par1[0] = (*(Amean53+0))[iETA1];
04158                  par1[1] = (*(Amean53+1))[iETA1];
04159                  par1[2] = (*(Amean53+2))[iETA1];
04160                  par1[3] = (*(Amean53+3))[iETA1];
04161                  par_sig1[0] = (*(Asig53+0))[iETA1];
04162                  par_sig1[1] = (*(Asig53+1))[iETA1];
04163                  par_sig1[2] = (*(Asig53+2))[iETA1];
04164                  par_sig1[3] = (*(Asig53+3))[iETA1];
04165                  par_rho[0] = (*(Arho53B+0))[iETA1];
04166                  par_rho[1] = (*(Arho53B+1))[iETA1];
04167                  par_rho[2] = (*(Arho53B+2))[iETA1];
04168                  par_rho[3] = (*(Arho53B+3))[iETA1];
04169                  par_rho[4] = (*(Arho53B+4))[iETA1];
04170                
04171                  par2[0] = (*(Amean5+0))[iETA1];
04172                  par2[1] = (*(Amean5+1))[iETA1];
04173                  par2[2] = (*(Amean5+2))[iETA1];
04174                  par2[3] = (*(Amean5+3))[iETA1];
04175                  par_sig2[0] = (*(Asig5+0))[iETA1];
04176                  par_sig2[1] = (*(Asig5+1))[iETA1];
04177                  par_sig2[2] = (*(Asig5+2))[iETA1]; 
04178                  par_sig2[3] = (*(Asig5+3))[iETA1]; 
04179 
04180                  if(fr == 1){
04181                    par1[0] = (*(Amean51+0))[iETA1];
04182                    par1[1] = (*(Amean51+1))[iETA1];
04183                    par1[2] = (*(Amean51+2))[iETA1];
04184                    par1[3] = (*(Amean51+3))[iETA1];
04185                    par_sig1[0] = (*(Asig51+0))[iETA1];
04186                    par_sig1[1] = (*(Asig51+1))[iETA1];
04187                    par_sig1[2] = (*(Asig51+2))[iETA1];
04188                    par_sig1[3] = (*(Asig51+3))[iETA1];
04189                    par_rho[0] = (*(Arho513+0))[iETA1];
04190                    par_rho[1] = (*(Arho513+1))[iETA1];
04191                    par_rho[2] = (*(Arho513+2))[iETA1];
04192                    par_rho[3] = (*(Arho513+3))[iETA1];
04193                    par_rho[4] = (*(Arho513+4))[iETA1];
04194                  
04195                    par2[0] = (*(Amean13R+0))[iETA1];
04196                    par2[1] = (*(Amean13R+1))[iETA1];
04197                    par2[2] = (*(Amean13R+2))[iETA1];
04198                    par2[3] = (*(Amean13R+3))[iETA1];
04199                    par_sig2[0] = (*(Asig13R+0))[iETA1];
04200                    par_sig2[1] = (*(Asig13R+1))[iETA1];
04201                    par_sig2[2] = (*(Asig13R+2))[iETA1]; 
04202                    par_sig2[3] = (*(Asig13R+3))[iETA1]; 
04203                  }    
04204           break;
04205           case 12 : // b1-1-2 for method < 10; for method > 10: fr = 1 -> b1-2-3, fr = 0 -> b1-2-phiBend
04206                  if(iETA < 1)iETA1 = 1;
04207                  if(iETA > 2)iETA1 = 2;
04208                  par1[0] = (*(Amean52+0))[iETA1];
04209                  par1[1] = (*(Amean52+1))[iETA1];
04210                  par1[2] = (*(Amean52+2))[iETA1];
04211                  par1[3] = (*(Amean52+3))[iETA1];
04212                  par_sig1[0] = (*(Asig52+0))[iETA1];
04213                  par_sig1[1] = (*(Asig52+1))[iETA1];
04214                  par_sig1[2] = (*(Asig52+2))[iETA1];
04215                  par_sig1[3] = (*(Asig52+3))[iETA1];
04216                  par_rho[0] = (*(Arho52B+0))[iETA1];
04217                  par_rho[1] = (*(Arho52B+1))[iETA1];
04218                  par_rho[2] = (*(Arho52B+2))[iETA1];
04219                  par_rho[3] = (*(Arho52B+3))[iETA1];
04220                  par_rho[4] = (*(Arho52B+4))[iETA1];
04221                
04222                  par2[0] = (*(Amean5+0))[iETA1];
04223                  par2[1] = (*(Amean5+1))[iETA1];
04224                  par2[2] = (*(Amean5+2))[iETA1];
04225                  par2[3] = (*(Amean5+3))[iETA1];
04226                  par_sig2[0] = (*(Asig5+0))[iETA1];
04227                  par_sig2[1] = (*(Asig5+1))[iETA1];
04228                  par_sig2[2] = (*(Asig5+2))[iETA1]; 
04229                  par_sig2[3] = (*(Asig5+3))[iETA1]; 
04230 
04231                  if(fr == 1){
04232                    if(iETA != 2)iETA1 = 2;
04233                    par1[0] = (*(Amean52+0))[iETA1];
04234                    par1[1] = (*(Amean52+1))[iETA1];
04235                    par1[2] = (*(Amean52+2))[iETA1];
04236                    par1[3] = (*(Amean52+3))[iETA1];
04237                    par_sig1[0] = (*(Asig52+0))[iETA1];
04238                    par_sig1[1] = (*(Asig52+1))[iETA1];
04239                    par_sig1[2] = (*(Asig52+2))[iETA1];
04240                    par_sig1[3] = (*(Asig52+3))[iETA1];
04241                    par_rho[0] = (*(Arho523+0))[iETA1];
04242                    par_rho[1] = (*(Arho523+1))[iETA1];
04243                    par_rho[2] = (*(Arho523+2))[iETA1];
04244                    par_rho[3] = (*(Arho523+3))[iETA1];
04245                    par_rho[4] = (*(Arho523+4))[iETA1];
04246                  
04247                    par2[0] = (*(Amean23+0))[iETA1];
04248                    par2[1] = (*(Amean23+1))[iETA1];
04249                    par2[2] = (*(Amean23+2))[iETA1];
04250                    par2[3] = (*(Amean23+3))[iETA1];
04251                    par_sig2[0] = (*(Asig23+0))[iETA1];
04252                    par_sig2[1] = (*(Asig23+1))[iETA1];
04253                    par_sig2[2] = (*(Asig23+2))[iETA1]; 
04254                    par_sig2[3] = (*(Asig23+3))[iETA1]; 
04255                  }    
04256           break;
04257           case 14 : // b1-2 for method < 10; for method > 10: fr = 1 -> b1-1-2-(3), fr = 0 -> b1-1-phiBend
04258                  if(iETA > 2)iETA1 = 2;
04259                  par1[0] = (*(Amean51+0))[iETA1];
04260                  par1[1] = (*(Amean51+1))[iETA1];
04261                  par1[2] = (*(Amean51+2))[iETA1];
04262                  par1[3] = (*(Amean51+3))[iETA1];
04263                  par_sig1[0] = (*(Asig51+0))[iETA1];
04264                  par_sig1[1] = (*(Asig51+1))[iETA1];
04265                  par_sig1[2] = (*(Asig51+2))[iETA1];
04266                  par_sig1[3] = (*(Asig51+3))[iETA1];
04267                  par_rho[0] = (*(Arho51B+0))[iETA1];
04268                  par_rho[1] = (*(Arho51B+1))[iETA1];
04269                  par_rho[2] = (*(Arho51B+2))[iETA1];
04270                  par_rho[3] = (*(Arho51B+3))[iETA1];
04271                  par_rho[4] = (*(Arho51B+4))[iETA1];
04272                
04273                  par2[0] = (*(Amean5+0))[iETA1];
04274                  par2[1] = (*(Amean5+1))[iETA1];
04275                  par2[2] = (*(Amean5+2))[iETA1];
04276                  par2[3] = (*(Amean5+3))[iETA1];
04277                  par_sig2[0] = (*(Asig5+0))[iETA1];
04278                  par_sig2[1] = (*(Asig5+1))[iETA1];
04279                  par_sig2[2] = (*(Asig5+2))[iETA1]; 
04280                  par_sig2[3] = (*(Asig5+3))[iETA1]; 
04281 
04282                  if(fr == 1){
04283                    if(iETA < 1)iETA1 = 1;
04284                    if(iETA > 2)iETA1 = 2;
04285                    par1[0] = (*(Amean51+0))[iETA1];
04286                    par1[1] = (*(Amean51+1))[iETA1];
04287                    par1[2] = (*(Amean51+2))[iETA1];
04288                    par1[3] = (*(Amean51+3))[iETA1];
04289                    par_sig1[0] = (*(Asig51+0))[iETA1];
04290                    par_sig1[1] = (*(Asig51+1))[iETA1];
04291                    par_sig1[2] = (*(Asig51+2))[iETA1];
04292                    par_sig1[3] = (*(Asig51+3))[iETA1];
04293                    par_rho[0] = (*(Arho512+0))[iETA1];
04294                    par_rho[1] = (*(Arho512+1))[iETA1];
04295                    par_rho[2] = (*(Arho512+2))[iETA1];
04296                    par_rho[3] = (*(Arho512+3))[iETA1];
04297                    par_rho[4] = (*(Arho512+4))[iETA1];
04298                  
04299                    par2[0] = (*(Amean12R+0))[iETA1];
04300                    par2[1] = (*(Amean12R+1))[iETA1];
04301                    par2[2] = (*(Amean12R+2))[iETA1];
04302                    par2[3] = (*(Amean12R+3))[iETA1];
04303                    par_sig2[0] = (*(Asig12R+0))[iETA1];
04304                    par_sig2[1] = (*(Asig12R+1))[iETA1];
04305                    par_sig2[2] = (*(Asig12R+2))[iETA1]; 
04306                    par_sig2[3] = (*(Asig12R+3))[iETA1]; 
04307                  }   
04308           break;
04309           //default:
04310           //return 0.0;
04311           }
04312 
04313         // Switch to 2-Station measurement if dphi is too small
04314         // box cut around Pt of 10 GeV
04315         if ( ( ( (fabs(static_cast<double>(dphi2))<0.004  && type != 12 && method < 25)||
04316                  (fabs(static_cast<double>(dphi2))<0.004  && type != 12 && type != 14 && type != 11 && method >= 25))) &&
04317              ((type>=2 && type<=5 && use2Stn) || (type >= 11 && use2StnDT)))
04318           {
04319             if (use2Stn)
04320               {
04321                 //if(type == 12 || type == 14 || type == 11) std::cout << "mode = " << type << " dphi23 = " << dphi2 << " method = " << method << std::endl; //test  
04322                 if(type == 2 || type == 3) type = 6; // 1-2-3(or 4) -> 1-2 
04323                 if(type == 4) type = 7; // 1-3-4 -> 1-3
04324                 if(type == 5) type = 8; // 2-3-4 -> 2-3
04325                 Pt = Pt2Stn2012_DT(type, eta, dphi1, useBestMLH, bestLH, fr, method,int(2));//in 3 station track there is no information to which ME1/1 or ME1/2 track belong
04326               }
04327             if (use2StnDT)
04328             {
04329               if(type == 11) type = 14; // b1-1-3 -> b1-1 for pt_method > 10
04330               //if(type == 14) type = 11;
04331               //phiSign
04332               Pt = Pt2Stn2012_DT(type, eta, dphi1,  useBestMLH, bestLH, fr, method,int(2));//in 3 station track there is no information to which ME1/1 or ME1/2 track belong
04333             }
04334           }
04335         else 
04336           {
04337             //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
04338             double muPlusMaxLH = -1e9;
04339             double pt = 140;
04340                   double step = 5.;
04341                   double maxLH = -1e9;
04342                   while(pt > 2. )
04343                     {
04344                       double par_phi12[1] = {dphi1};
04345                       double par_phi23[1] = {dphi2};
04346                       double v[1], lpt1_1;
04347                       v[0] = 0; lpt1_1 = 1.; 
04348                       v[0] = pt;
04349                       lpt1_1 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
04350                       
04351                       if (lpt1_1 > maxLH)
04352                         {
04353                           maxLH = lpt1_1;
04354                           PTsolv = pt;
04355                         }
04356                                          
04357                       if(pt <= 100) {step = 10.0/4.0;}
04358                       if(pt <= 50) {step = 5.0/4.0;}
04359                       if(pt <= 20) {step = 2.0/4.0;}
04360                       if(pt <= 10) {step = 1.0/4.0;}
04361                       if(pt <=5) {step = 0.5/4.0;}
04362                       
04363                       pt = pt - step;
04364                   }// end while
04365                   muPlusMaxLH = maxLH;
04366 //*********** end solve equation for muon plus
04367 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
04368 // for one station method we know sing of muon: dphi1 > 0 for muon minus!!! => dphi1 = -dphi1 < 0
04369                   double muMinusMaxLH = -1e9;
04370                   dphi1 = - dphi1;
04371                   dphi2 = - dphi2;      
04372                   pt = 140;
04373                   step = 5.;
04374                   maxLH = -1e9;
04375                   
04376                   while(pt > 2. )
04377                     {
04378                       double par_phi12[1] = {dphi1};
04379                       double par_phi23[1] = {dphi2};
04380                       double v[1], lpt1_1;
04381                        v[0] = 0; lpt1_1 = 1.; 
04382                        v[0] = pt;
04383                        lpt1_1 = Likelihood2011(par_phi12, par_phi23, par1, par2, par_sig1, par_sig2, par_rho, v);
04384                        
04385                        if (lpt1_1 > maxLH)
04386                          {
04387                            maxLH = lpt1_1;
04388                            PTsolvMinus = pt;
04389                          }
04390                                           
04391                        if(pt <= 100) {step = 10.0/4.0;}
04392                        if(pt <= 50) {step = 5.0/4.0;}
04393                        if(pt <= 20) {step = 2.0/4.0;}
04394                        if(pt <= 10) {step = 1.0/4.0;}
04395                        if(pt <=5) {step = 0.5/4.0;} 
04396                        pt = pt - step;
04397                     }// end while
04398                   muMinusMaxLH = maxLH;
04399 
04400                   if (useBestMLH)
04401                     PTsolv = (muPlusMaxLH > muMinusMaxLH) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
04402                   else
04403                     PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
04404                   
04405                   bestLH = (muPlusMaxLH > muMinusMaxLH) ? muPlusMaxLH : muMinusMaxLH;
04406 
04407                   PTsolv = PTsolv*1.2; // correction to have 90% efficiency for trigger cuts
04408                   if(PTsolv > 137.5) PTsolv = 137.5;
04409                   //if(fabs(dphi1) < 0.002 && fabs(dphi2) <= CutPhi23){PTsolv = 140;}
04410                   dphi1 = - dphi1; //return to correct sing dphi
04411                   dphi2 = - dphi2; //return to correct sing dphi
04412                   Pt = PTsolv;
04413           } // end 2 or 3 station method
04414     }}
04415     // fix overlap region high pt:
04416     if (useBOXcutDT)
04417       if(method >= 25 && (type == 12 || type == 14 || type == 11) && fabs(dphi1)<0.003 && fabs(dphi2) <2) Pt = 140.; 
04418            // if ( fabs(static_cast<double>(dphi2))>0.004 ) std::cout << "Pt = " << Pt << " Mode = " << type << " dphi1 = " << dphi1 << " dphi2 = " << dphi2 << std::endl;
04419 
04420     //float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
04421     //if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
04422     float Pt_min = 2;// 2 GeV
04423 
04424     return (Pt > Pt_min)  ? Pt : Pt_min;
04425 }
04426 
04427 
04428 float CSCTFPtMethods::Pt2Stn2012_DT(int type, float eta, float dphi, int PtbyMLH, float &bestLH, int fr, int method, int phiSign) const 
04429 {
04430   int useBestMLH = PtbyMLH;
04431   int useBOXcut = true;
04432  
04433     //if(fabs(eta) >= 2.4) eta = 2.35;  
04434     if(fabs(eta) >= 2.2) eta = 2.15;  
04435     double PTsolv = 1.; // for muon plus hypothesis
04436     double PTsolvMinus = 1.;//for muon minus hypothesis
04437     for(int iETA = 0; iETA < 15; iETA++){
04438     if(fabs(eta) >= etabins[iETA] && fabs(eta) < etabins[iETA+1] ){
04439 
04440 // calculate curvers of mean and sigma 
04441               // calculate phi12 mean  
04442               double par1[4] = {0., 0., 0., 0.};
04443               //double phi12mean = fitf5(v, par1); //mu12 
04444               double par_sig1[4] = {0., 0., 0.,0};
04445         int iETA1 = iETA; 
04446         int iETA2 = iETA; 
04447 
04448         double (*Amean12FnoME11)[15] = AB_mu12FnoME11; 
04449         double (*Asig12FnoME11)[15] = AB_sig12FnoME11; 
04450         double (*Amean12RnoME11)[15] = AB_mu12RnoME11; 
04451         double (*Asig12RnoME11)[15] = AB_sig12RnoME11; 
04452 
04453         double (*Amean13FnoME11)[15] = AB_mu13FnoME11; 
04454         double (*Asig13FnoME11)[15] = AB_sig13FnoME11; 
04455         double (*Amean13RnoME11)[15] = AB_mu13RnoME11; 
04456         double (*Asig13RnoME11)[15] = AB_sig13RnoME11; 
04457 
04458         double (*Amean14FnoME11)[15] = AB_mu14FnoME11; 
04459         double (*Asig14FnoME11)[15] = AB_sig14FnoME11; 
04460         double (*Amean14RnoME11)[15] = AB_mu14RnoME11; 
04461         double (*Asig14RnoME11)[15] = AB_sig14RnoME11; 
04462         //
04463         double (*Amean12FME11)[15] = AB_mu12FME11; 
04464         double (*Asig12FME11)[15] = AB_sig12FME11; 
04465         double (*Amean12RME11)[15] = AB_mu12RME11; 
04466         double (*Asig12RME11)[15] = AB_sig12RME11; 
04467 
04468         double (*Amean13FME11)[15] = AB_mu13FME11; 
04469         double (*Asig13FME11)[15] = AB_sig13FME11; 
04470         double (*Amean13RME11)[15] = AB_mu13RME11; 
04471         double (*Asig13RME11)[15] = AB_sig13RME11; 
04472 
04473         double (*Amean14FME11)[15] = AB_mu14FME11; 
04474         double (*Asig14FME11)[15] = AB_sig14FME11; 
04475         double (*Amean14RME11)[15] = AB_mu14RME11; 
04476         double (*Asig14RME11)[15] = AB_sig14RME11; 
04477         //
04478         double (*Amean12F)[15] = AB_mu12F; 
04479         double (*Asig12F)[15] = AB_sig12F; 
04480         double (*Amean12R)[15] = AB_mu12R; 
04481         double (*Asig12R)[15] = AB_sig12R; 
04482 
04483         double (*Amean13F)[15] = AB_mu13F; 
04484         double (*Asig13F)[15] = AB_sig13F; 
04485         double (*Amean13R)[15] = AB_mu13R; 
04486         double (*Asig13R)[15] = AB_sig13R; 
04487 
04488         double (*Amean14F)[15] = AB_mu14F; 
04489         double (*Asig14F)[15] = AB_sig14F; 
04490         double (*Amean14R)[15] = AB_mu14R; 
04491         double (*Asig14R)[15] = AB_sig14R; 
04492 
04493         double (*Amean23)[15] = AB_mu23;
04494         double (*Asig23)[15] = AB_sig23;
04495         double (*Amean24)[15] = AB_mu24;
04496         double (*Asig24)[15] = AB_sig24;
04497         double (*Amean34)[15] = AB_mu34;
04498         double (*Asig34)[15] = AB_sig34;
04499 
04500         double (*Amean51)[15] = AB_mu51;
04501         double (*Asig51)[15] = AB_sig51;
04502         double (*Amean52)[15] = AB_mu52;
04503         double (*Asig52)[15] = AB_sig52;
04504         double (*Amean53)[15] = AB_mu53;
04505         double (*Asig53)[15] = AB_sig53;
04506 
04507         switch (type) // type = mode here
04508           {
04509           case 6 :  //1-2
04510                  if(fr == 1){
04511                    if(iETA1 < 3)iETA1 = 3;
04512                    //if(iETA1 > 11)iETA1 = 11;
04513                    par1[0] = (*(Amean12F+0))[iETA1];
04514                    par1[1] = (*(Amean12F+1))[iETA1];
04515                    par1[2] = (*(Amean12F+2))[iETA1];
04516                    par1[3] = (*(Amean12F+3))[iETA1];
04517                    par_sig1[0] = (*(Asig12F+0))[iETA1];
04518                    par_sig1[1] = (*(Asig12F+1))[iETA1];
04519                    par_sig1[2] = (*(Asig12F+2))[iETA1];
04520                    par_sig1[3] = (*(Asig12F+3))[iETA1];
04521                  }
04522                  if(fr == 0){
04523                    if(iETA1 < 1)iETA1 = 1;
04524                    //if(iETA1 > 11)iETA1 = 11;
04525                    par1[0] = (*(Amean12R+0))[iETA1];
04526                    par1[1] = (*(Amean12R+1))[iETA1];
04527                    par1[2] = (*(Amean12R+2))[iETA1];
04528                    par1[3] = (*(Amean12R+3))[iETA1];
04529                    par_sig1[0] = (*(Asig12R+0))[iETA1];
04530                    par_sig1[1] = (*(Asig12R+1))[iETA1];
04531                    par_sig1[2] = (*(Asig12R+2))[iETA1];
04532                    par_sig1[3] = (*(Asig12R+3))[iETA1];
04533                  }
04534             if(phiSign == 0){ // track belong to ME11 station
04535                  if(fr == 1){
04536                    if(iETA2 < 7)iETA2 = 7;
04537                    par1[0] = (*(Amean12FME11+0))[iETA2];
04538                    par1[1] = (*(Amean12FME11+1))[iETA2];
04539                    par1[2] = (*(Amean12FME11+2))[iETA2];
04540                    par1[3] = (*(Amean12FME11+3))[iETA2];
04541                    par_sig1[0] = (*(Asig12FME11+0))[iETA2];
04542                    par_sig1[1] = (*(Asig12FME11+1))[iETA2];
04543                    par_sig1[2] = (*(Asig12FME11+2))[iETA2];
04544                    par_sig1[3] = (*(Asig12FME11+3))[iETA2];
04545                  }
04546                  if(fr == 0){
04547                    if(iETA2 < 7)iETA2 = 7;
04548                    par1[0] = (*(Amean12RME11+0))[iETA2];
04549                    par1[1] = (*(Amean12RME11+1))[iETA2];
04550                    par1[2] = (*(Amean12RME11+2))[iETA2];
04551                    par1[3] = (*(Amean12RME11+3))[iETA2];
04552                    par_sig1[0] = (*(Asig12RME11+0))[iETA2];
04553                    par_sig1[1] = (*(Asig12RME11+1))[iETA2];
04554                    par_sig1[2] = (*(Asig12RME11+2))[iETA2];
04555                    par_sig1[3] = (*(Asig12RME11+3))[iETA2];
04556                  }
04557             }
04558             if(phiSign == 1){ // track belong to ME1/2 or ME1/3 station
04559                  if(fr == 1){
04560                    if(iETA2 < 3)iETA2 = 3;
04561                    if(iETA2 > 7)iETA2 = 7;
04562                    par1[0] = (*(Amean12FnoME11+0))[iETA2];
04563                    par1[1] = (*(Amean12FnoME11+1))[iETA2];
04564                    par1[2] = (*(Amean12FnoME11+2))[iETA2];
04565                    par1[3] = (*(Amean12FnoME11+3))[iETA2];
04566                    par_sig1[0] = (*(Asig12FnoME11+0))[iETA2];
04567                    par_sig1[1] = (*(Asig12FnoME11+1))[iETA2];
04568                    par_sig1[2] = (*(Asig12FnoME11+2))[iETA2];
04569                    par_sig1[3] = (*(Asig12FnoME11+3))[iETA2];
04570                  }
04571                  if(fr == 0){
04572                    if(iETA2 < 1)iETA2 = 1;
04573                    if(iETA2 > 6)iETA2 = 6;// rare ME1/2 only till 1.6
04574                    par1[0] = (*(Amean12RnoME11+0))[iETA2];
04575                    par1[1] = (*(Amean12RnoME11+1))[iETA2];
04576                    par1[2] = (*(Amean12RnoME11+2))[iETA2];
04577                    par1[3] = (*(Amean12RnoME11+3))[iETA2];
04578                    par_sig1[0] = (*(Asig12RnoME11+0))[iETA2];
04579                    par_sig1[1] = (*(Asig12RnoME11+1))[iETA2];
04580                    par_sig1[2] = (*(Asig12RnoME11+2))[iETA2];
04581                    par_sig1[3] = (*(Asig12RnoME11+3))[iETA2];
04582                  }
04583             }
04584 
04585           break;
04586           case 7 :  //1-3
04587                  if(fr == 1){
04588                    if(iETA1 < 3)iETA1 = 3;
04589                    //if(iETA1 > 11)iETA1 = 11;
04590                    par1[0] = (*(Amean13F+0))[iETA1];
04591                    par1[1] = (*(Amean13F+1))[iETA1];
04592                    par1[2] = (*(Amean13F+2))[iETA1];
04593                    par1[3] = (*(Amean13F+3))[iETA1];
04594                    par_sig1[0] = (*(Asig13F+0))[iETA1];
04595                    par_sig1[1] = (*(Asig13F+1))[iETA1];
04596                    par_sig1[2] = (*(Asig13F+2))[iETA1];
04597                    par_sig1[3] = (*(Asig13F+3))[iETA1];
04598                  }
04599                  if(fr == 0){
04600                    if(iETA1 < 3)iETA1 = 3;
04601                    //if(iETA1 > 11)iETA1 = 11;
04602                    par1[0] = (*(Amean13R+0))[iETA1];
04603                    par1[1] = (*(Amean13R+1))[iETA1];
04604                    par1[2] = (*(Amean13R+2))[iETA1];
04605                    par1[3] = (*(Amean13R+3))[iETA1];
04606                    par_sig1[0] = (*(Asig13R+0))[iETA1];
04607                    par_sig1[1] = (*(Asig13R+1))[iETA1];
04608                    par_sig1[2] = (*(Asig13R+2))[iETA1];
04609                    par_sig1[3] = (*(Asig13R+3))[iETA1];
04610                  }
04611             if(phiSign == 0){ // track belong to ME11 station
04612                  if(fr == 1){
04613                    if(iETA2 < 7)iETA2 = 7;
04614                    par1[0] = (*(Amean13FME11+0))[iETA2];
04615                    par1[1] = (*(Amean13FME11+1))[iETA2];
04616                    par1[2] = (*(Amean13FME11+2))[iETA2];
04617                    par1[3] = (*(Amean13FME11+3))[iETA2];
04618                    par_sig1[0] = (*(Asig13FME11+0))[iETA2];
04619                    par_sig1[1] = (*(Asig13FME11+1))[iETA2];
04620                    par_sig1[2] = (*(Asig13FME11+2))[iETA2];
04621                    par_sig1[3] = (*(Asig13FME11+3))[iETA2];
04622                  }
04623                  if(fr == 0){
04624                    if(iETA2 < 7)iETA2 = 7;
04625                    par1[0] = (*(Amean13RME11+0))[iETA2];
04626                    par1[1] = (*(Amean13RME11+1))[iETA2];
04627                    par1[2] = (*(Amean13RME11+2))[iETA2];
04628                    par1[3] = (*(Amean13RME11+3))[iETA2];
04629                    par_sig1[0] = (*(Asig13RME11+0))[iETA2];
04630                    par_sig1[1] = (*(Asig13RME11+1))[iETA2];
04631                    par_sig1[2] = (*(Asig13RME11+2))[iETA2];
04632                    par_sig1[3] = (*(Asig13RME11+3))[iETA2];
04633                  }
04634             }
04635             if(phiSign == 1){ // track belong to ME1/2 or ME1/3 station
04636                  if(fr == 1){
04637                    if(iETA2 < 3)iETA2 = 3;
04638                    if(iETA2 > 7)iETA2 = 7;
04639                    par1[0] = (*(Amean13FnoME11+0))[iETA2];
04640                    par1[1] = (*(Amean13FnoME11+1))[iETA2];
04641                    par1[2] = (*(Amean13FnoME11+2))[iETA2];
04642                    par1[3] = (*(Amean13FnoME11+3))[iETA2];
04643                    par_sig1[0] = (*(Asig13FnoME11+0))[iETA2];
04644                    par_sig1[1] = (*(Asig13FnoME11+1))[iETA2];
04645                    par_sig1[2] = (*(Asig13FnoME11+2))[iETA2];
04646                    par_sig1[3] = (*(Asig13FnoME11+3))[iETA2];
04647                  }
04648                  if(fr == 0){
04649                    if(iETA2 < 3)iETA2 = 3;
04650                    if(iETA2 > 6)iETA2 = 6;// rare ME1/2 only till 1.6
04651                    par1[0] = (*(Amean13RnoME11+0))[iETA2];
04652                    par1[1] = (*(Amean13RnoME11+1))[iETA2];
04653                    par1[2] = (*(Amean13RnoME11+2))[iETA2];
04654                    par1[3] = (*(Amean13RnoME11+3))[iETA2];
04655                    par_sig1[0] = (*(Asig13RnoME11+0))[iETA2];
04656                    par_sig1[1] = (*(Asig13RnoME11+1))[iETA2];
04657                    par_sig1[2] = (*(Asig13RnoME11+2))[iETA2];
04658                    par_sig1[3] = (*(Asig13RnoME11+3))[iETA2];
04659                  }
04660             }
04661           break;
04662           case 8 :  //2-3
04663                  if(iETA1 < 2)iETA1 = 2;
04664                    par1[0] = (*(Amean23+0))[iETA1];
04665                    par1[1] = (*(Amean23+1))[iETA1];
04666                    par1[2] = (*(Amean23+2))[iETA1];
04667                    par1[3] = (*(Amean23+3))[iETA1];
04668                    par_sig1[0] = (*(Asig23+0))[iETA1];
04669                    par_sig1[1] = (*(Asig23+1))[iETA1];
04670                    par_sig1[2] = (*(Asig23+2))[iETA1];
04671                    par_sig1[3] = (*(Asig23+3))[iETA1];
04672 
04673           break;
04674           case 9 :  //2-4
04675                  if(iETA1 < 3)iETA1 = 3;
04676                    par1[0] = (*(Amean24+0))[iETA1];
04677                    par1[1] = (*(Amean24+1))[iETA1];
04678                    par1[2] = (*(Amean24+2))[iETA1];
04679                    par1[3] = (*(Amean24+3))[iETA1];
04680                    par_sig1[0] = (*(Asig24+0))[iETA1];
04681                    par_sig1[1] = (*(Asig24+1))[iETA1];
04682                    par_sig1[2] = (*(Asig24+2))[iETA1];
04683                    par_sig1[3] = (*(Asig24+3))[iETA1];
04684           break;
04685           case 10 :  //3-4
04686                  if(iETA1 < 3)iETA1 = 3;
04687                    par1[0] = (*(Amean34+0))[iETA1];
04688                    par1[1] = (*(Amean34+1))[iETA1];
04689                    par1[2] = (*(Amean34+2))[iETA1];
04690                    par1[3] = (*(Amean34+3))[iETA1];
04691                    par_sig1[0] = (*(Asig34+0))[iETA1];
04692                    par_sig1[1] = (*(Asig34+1))[iETA1];
04693                    par_sig1[2] = (*(Asig34+2))[iETA1];
04694                    par_sig1[3] = (*(Asig34+3))[iETA1];
04695           break;
04696           case 13 :  //1-4
04697                  if(fr == 1){
04698                    if(iETA1 < 3)iETA1 = 3;
04699                    //if(iETA1 > 11)iETA1 = 11;
04700                    par1[0] = (*(Amean14F+0))[iETA1];
04701                    par1[1] = (*(Amean14F+1))[iETA1];
04702                    par1[2] = (*(Amean14F+2))[iETA1];
04703                    par1[3] = (*(Amean14F+3))[iETA1];
04704                    par_sig1[0] = (*(Asig14F+0))[iETA1];
04705                    par_sig1[1] = (*(Asig14F+1))[iETA1];
04706                    par_sig1[2] = (*(Asig14F+2))[iETA1];
04707                    par_sig1[3] = (*(Asig14F+3))[iETA1];
04708                  }
04709                  if(fr == 0){
04710                    if(iETA1 < 2)iETA1 = 2;
04711                    //if(iETA1 > 11)iETA1 = 11;
04712                    par1[0] = (*(Amean14R+0))[iETA1];
04713                    par1[1] = (*(Amean14R+1))[iETA1];
04714                    par1[2] = (*(Amean14R+2))[iETA1];
04715                    par1[3] = (*(Amean14R+3))[iETA1];
04716                    par_sig1[0] = (*(Asig14R+0))[iETA1];
04717                    par_sig1[1] = (*(Asig14R+1))[iETA1];
04718                    par_sig1[2] = (*(Asig14R+2))[iETA1];
04719                    par_sig1[3] = (*(Asig14R+3))[iETA1];
04720                  }
04721             if(phiSign == 0){ // track belong to ME11 station
04722                  if(fr == 1){
04723                    if(iETA2 < 9)iETA2 = 9;
04724                    par1[0] = (*(Amean14FME11+0))[iETA2];
04725                    par1[1] = (*(Amean14FME11+1))[iETA2];
04726                    par1[2] = (*(Amean14FME11+2))[iETA2];
04727                    par1[3] = (*(Amean14FME11+3))[iETA2];
04728                    par_sig1[0] = (*(Asig14FME11+0))[iETA2];
04729                    par_sig1[1] = (*(Asig14FME11+1))[iETA2];
04730                    par_sig1[2] = (*(Asig14FME11+2))[iETA2];
04731                    par_sig1[3] = (*(Asig14FME11+3))[iETA2];
04732                  }
04733                  if(fr == 0){
04734                    if(iETA2 < 9)iETA2 = 9;
04735                    par1[0] = (*(Amean14RME11+0))[iETA2];
04736                    par1[1] = (*(Amean14RME11+1))[iETA2];
04737                    par1[2] = (*(Amean14RME11+2))[iETA2];
04738                    par1[3] = (*(Amean14RME11+3))[iETA2];
04739                    par_sig1[0] = (*(Asig14RME11+0))[iETA2];
04740                    par_sig1[1] = (*(Asig14RME11+1))[iETA2];
04741                    par_sig1[2] = (*(Asig14RME11+2))[iETA2];
04742                    par_sig1[3] = (*(Asig14RME11+3))[iETA2];
04743                  }
04744             }
04745             if(phiSign == 1){ // track belong to ME1/2 or ME1/3 station
04746                  if(fr == 1){
04747                    if(iETA2 < 4)iETA2 = 4;
04748                    if(iETA2 > 7)iETA2 = 7;
04749                    par1[0] = (*(Amean14FnoME11+0))[iETA2];
04750                    par1[1] = (*(Amean14FnoME11+1))[iETA2];
04751                    par1[2] = (*(Amean14FnoME11+2))[iETA2];
04752                    par1[3] = (*(Amean14FnoME11+3))[iETA2];
04753                    par_sig1[0] = (*(Asig14FnoME11+0))[iETA2];
04754                    par_sig1[1] = (*(Asig14FnoME11+1))[iETA2];
04755                    par_sig1[2] = (*(Asig14FnoME11+2))[iETA2];
04756                    par_sig1[3] = (*(Asig14FnoME11+3))[iETA2];
04757                  }
04758                  if(fr == 0){
04759                    if(iETA2 < 4)iETA2 = 4;
04760                    if(iETA2 > 6)iETA2 = 6;// rare ME1/2 only till 1.6
04761                    par1[0] = (*(Amean14RnoME11+0))[iETA2];
04762                    par1[1] = (*(Amean14RnoME11+1))[iETA2];
04763                    par1[2] = (*(Amean14RnoME11+2))[iETA2];
04764                    par1[3] = (*(Amean14RnoME11+3))[iETA2];
04765                    par_sig1[0] = (*(Asig14RnoME11+0))[iETA2];
04766                    par_sig1[1] = (*(Asig14RnoME11+1))[iETA2];
04767                    par_sig1[2] = (*(Asig14RnoME11+2))[iETA2];
04768                    par_sig1[3] = (*(Asig14RnoME11+3))[iETA2];
04769                  }
04770             }
04771 
04772           break;
04773           case 11 : // b1-3 for pt_method > 10 & fr = 0, singles for pt_method < 10 
04774                  if(iETA1 != 2)iETA1 = 2;
04775                    par1[0] = (*(Amean53+0))[iETA1];
04776                    par1[1] = (*(Amean53+1))[iETA1];
04777                    par1[2] = (*(Amean53+2))[iETA1];
04778                    par1[3] = (*(Amean53+3))[iETA1];
04779                    par_sig1[0] = (*(Asig53+0))[iETA1];
04780                    par_sig1[1] = (*(Asig53+1))[iETA1];
04781                    par_sig1[2] = (*(Asig53+2))[iETA1];
04782                    par_sig1[3] = (*(Asig53+3))[iETA1];
04783           break;
04784 
04785           case 12 :  //1-2-b1 = 2-b1 for pt_method < 10, for pt_method > 10 & fr = 0: b1-2
04786                  if(iETA1 < 1)iETA1 = 1;
04787                  if(iETA1 > 2)iETA1 = 2;
04788 
04789                  par1[0] = (*(Amean52+0))[iETA1];
04790                  par1[1] = (*(Amean52+1))[iETA1];
04791                  par1[2] = (*(Amean52+2))[iETA1];
04792                  par1[3] = (*(Amean52+3))[iETA1];
04793                  par_sig1[0] = (*(Asig52+0))[iETA1];
04794                  par_sig1[1] = (*(Asig52+1))[iETA1];
04795                  par_sig1[2] = (*(Asig52+2))[iETA1];
04796                  par_sig1[3] = (*(Asig52+3))[iETA1];
04797 
04798           break;
04799           case 14 :  //2-b1 for pt_method < 10 and b1-1 for pt_method > 10 & fr = 0
04800                  if(method < 10){
04801                     if(iETA1 < 1)iETA1 = 1;
04802                     if(iETA1 > 2)iETA1 = 2;
04803                  }
04804                  par1[0] = (*(Amean52+0))[iETA1];
04805                  par1[1] = (*(Amean52+1))[iETA1];
04806                  par1[2] = (*(Amean52+2))[iETA1];
04807                  par1[3] = (*(Amean52+3))[iETA1];
04808                  par_sig1[0] = (*(Asig52+0))[iETA1];
04809                  par_sig1[1] = (*(Asig52+1))[iETA1];
04810                  par_sig1[2] = (*(Asig52+2))[iETA1];
04811                  par_sig1[3] = (*(Asig52+3))[iETA1];
04812 
04813                  if(method > 10){
04814                     if(iETA1 > 2)iETA1 = 2;
04815                     par1[0] = (*(Amean51+0))[iETA1];
04816                     par1[1] = (*(Amean51+1))[iETA1];
04817                     par1[2] = (*(Amean51+2))[iETA1];
04818                     par1[3] = (*(Amean51+3))[iETA1];
04819                     par_sig1[0] = (*(Asig51+0))[iETA1];
04820                     par_sig1[1] = (*(Asig51+1))[iETA1];
04821                     par_sig1[2] = (*(Asig51+2))[iETA1];
04822                     par_sig1[3] = (*(Asig51+3))[iETA1];
04823                  }
04824           break;
04825           //default:
04826           //return 0.0;
04827           }    
04828 
04829 //************* solve equation dLog(Likelihood)/dpt = 0 for muon + ;
04830           //if(fabs(dphi) >= 0.002)
04831           //if(fabs(dphi) >= 0.00)
04832           //if(fabs(dphi) >= 0.002 || (fabs(dphi) >= 0.01 && (type == 12 || type == 14)))
04833           //{
04834         double muPlusMaxLH = -1e9;
04835                   double pt = 140;
04836                   double step = 5.;
04837                   double maxLH = -1e9;
04838                   while(pt > 2. )
04839                     {
04840                       double par_phi12[1] = {dphi};
04841                       double v[1], lpt1_1;
04842                       v[0] = 0; lpt1_1 = 1.;
04843                       v[0] = pt;
04844                       lpt1_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
04845                       
04846                       if (lpt1_1 > maxLH)
04847                         {
04848                           maxLH = lpt1_1;
04849                           PTsolv = pt;
04850                         }
04851                                           
04852                       if(pt <= 100) {step = 10.0/4.0;}
04853                       if(pt <= 50) {step = 5.0/4.0;}
04854                       if(pt <= 20) {step = 2.0/4.0;}
04855                       if(pt <= 10) {step = 1.0/4.0;}
04856                       if(pt <=5) {step = 0.5/4.0;}
04857 
04858                       
04859                       pt = pt - step;
04860                     }// end while
04861                     muPlusMaxLH = maxLH;
04862                   
04863 //*********** end solve equation for muon plus
04864 //************* solve equation dLog(Likelihood)/dpt = 0 for muon minus ;
04865 // for one station method we know sing of muon: dphi > 0 for muon minus!!! => dphi = -dphi < 0
04866                       double muMinusMaxLH = -1e9;
04867                     dphi = - dphi;
04868                   pt = 140;
04869                   step = 5.;
04870                   maxLH = -1e9;
04871                   while(pt > 2. )
04872                     {
04873                       double par_phi12[1] = {dphi};
04874                       double v[1], lpt1_1;
04875                       v[0] = 0; lpt1_1 = 1.; 
04876                       v[0] = pt;
04877                       lpt1_1 = Likelihood2_2011(par_phi12, par1, par_sig1, v);
04878                       
04879                       if (lpt1_1 > maxLH)
04880                         {
04881                           maxLH = lpt1_1;
04882                           PTsolvMinus = pt;
04883                         }
04884                       
04885                       if(pt <= 100) {step = 10.0/4.0;}
04886                       if(pt <= 50) {step = 5.0/4.0;}
04887                       if(pt <= 20) {step = 2.0/4.0;}
04888                       if(pt <= 10) {step = 1.0/4.0;}
04889                       if(pt <=5) {step = 0.5/4.0;}
04890                          
04891 
04892                          
04893                       pt = pt - step;
04894                   }// end while
04895                   muMinusMaxLH = maxLH;
04896                   
04897 //          }// if(fabs(dphi) >= 0.002)
04898 //          else 
04899 //          {PTsolv = 137.5;} 
04900 
04901 //*********** end solve equation for muon minus 
04902                   if (useBestMLH)
04903                     PTsolv = (muPlusMaxLH > muMinusMaxLH) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
04904                   else
04905                     PTsolv = (PTsolv > PTsolvMinus) ? PTsolv: PTsolvMinus; // select Maximum solution from muon plus and moun minus hypotesis
04906                   
04907                   bestLH = (muPlusMaxLH > muMinusMaxLH) ? muPlusMaxLH : muMinusMaxLH;
04908                   
04909 
04910                   
04911           PTsolv = PTsolv*1.2;
04912           if(PTsolv > 137.5) PTsolv = 137.5;
04913 
04914           if (useBOXcut)
04915             if(fabs(dphi) <= 0.002 && PTsolv < 120.)PTsolv = 140.;
04916           //if( fabs(dphi) <= 0.01 && (type == 11 || type == 12 || type == 14) && PTsolv < 120.)PTsolv = 140.;
04917           dphi = - dphi; //return to correct sing dphi
04918 
04919     } //if(fabs(eta_TracMy) 
04920     } //end "for by iETA"
04921 
04922     float Pt = PTsolv;
04923                                                                     
04924     //float Pt_min = trigger_scale->getPtScale()->getLowEdge(1);// 0 GeV
04925     //if(method > 10) Pt_min = trigger_scale->getPtScale()->getLowEdge(3);// 2 GeV 
04926     float Pt_min = 2;// 0 GeV
04927 
04928     return (Pt > Pt_min)  ? Pt : Pt_min;
04929 }
04930 
04931 
04932 
04933 
04934 
04935 
04936 
04937 
04938 // These arrays contain mean dphi values for each pt and eta bin.  
04939 // They are split into fr=0 and fr=1.
04940 
04941 const float CSCTFPtMethods::dphifr0[4][15][28] = 
04942   {
04943     {
04944       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04945       {-1, -1, 1253.47, -174.543, -90.845, -36.8835, -13.2793, 3.28278, 11.1568, 12.9352, 12.8576, 12.322, 11.7342, 10.5244, 10.0687, 8.32785, 7.13888, 6.20492, 5.85733, 4.75137, 4.77209, 4.02553, 3.69785, 3.28493, 2.99132, 2.55496, 2.22965, 1.98868},
04946       {-1, -1, -158.232, -135.974, -59.1458, -5.19565, 12.8464, 23.5714, 24.0722, 24.6097, 21.0736, 19.6627, 17.2412, 15.6857, 14.308, 12.6231, 10.4509, 9.9933, 8.24835, 6.92309, 6.57742, 5.69463, 4.74087, 3.78364, 4.21154, 3.27273, 3.10333, 2.60822},
04947       {-1, -1, -187.544, -42.1843, 40.6221, 54.483, 56.7803, 53.5989, 48.8252, 41.8441, 35.5835, 30.7605, 26.9772, 24.2051, 21.5163, 18.7697, 15.6471, 12.8676, 10.9852, 9.93952, 9.17785, 7.91962, 6.87614, 5.85018, 5.10393, 4.67222, 4.02645, 3.547},
04948       {-1, -93.4379, -64.9443, 70.5053, 85.4571, 85.2642, 77.1782, 67.8264, 59.6792, 50.1799, 41.1682, 35.1241, 30.6299, 27.1403, 24.6307, 20.6204, 17.277, 14.4064, 12.6264, 11.5938, 10.0659, 8.76273, 7.54754, 6.535, 5.69304, 5.44025, 4.61045, 3.87704},
04949       {-1, 65.2747, 120.239, 129.902, 115.172, 108.511, 92.9557, 77.3499, 66.5613, 56.856, 45.7164, 39.0012, 33.7201, 30.13, 26.8649, 22.9335, 18.2273, 16.5989, 13.9109, 12.3409, 10.9531, 9.90102, 8.25129, 7.1479, 6.71622, 5.77461, 5.05741, 4.38687},
04950       {1292.54, 139.196, 169.261, 134.554, 129.417, 118.125, 97.2182, 80.5974, 70.3365, 58.7809, 48.6667, 40.7918, 34.917, 30.8781, 28.1953, 23.2852, 19.1667, 14.6401, 14.0676, 12.5932, 11.4459, 9.67685, 8.55686, 7.49359, 6.3961, 6.02812, 5.26887, 4.55128},
04951       {396.903, 408.642, 331.11, 291.154, 244.6, 225.93, 191.418, 159.273, 137.156, 113.559, 92.3122, 77.8488, 67.4872, 57.885, 53.6376, 45.4894, 37.1931, 30.9091, 26.9629, 22.8523, 20.6881, 17.8588, 16.0515, 14.2847, 11.9988, 10.9918, 9.58895, 8.28621},
04952       {634.157, 376.909, 303.487, 269.928, 237.553, 221.337, 183.49, 151.95, 128.961, 108.078, 88.4642, 74.0832, 64.4987, 56.8622, 51.0964, 43.2635, 34.8376, 30.0291, 25.2508, 22.9892, 20.3061, 17.1065, 15.08, 13.1487, 11.3403, 9.8765, 8.67395, 7.70727},
04953       {370.029, 334.631, 284.161, 247.876, 220.082, 190.31, 160.042, 139.043, 119.323, 96.8377, 79.0452, 67.6644, 58.5129, 51.8932, 46.4433, 38.2747, 32.5855, 28.1408, 23.2895, 20.8651, 18.3079, 16.0197, 13.33, 10.7823, 10.5876, 9.3446, 8.18957, 7.13109},
04954       {336.807, 315.636, 263.106, 227.678, 196.301, 172.476, 144.296, 122.167, 107.034, 88.4252, 71.6369, 61.0729, 53.1695, 47.213, 42.3058, 36.058, 27.7351, 25.8168, 21.0509, 19.0587, 16.2367, 14.7198, 12.368, 10.5611, 9.43783, 8.64059, 7.30456, 6.50177},
04955       {562.84, 281.367, 231.744, 197.26, 175.838, 154, 132.991, 112.797, 97.7521, 80.0722, 66.1777, 53.8695, 47.5855, 42.4901, 36.5583, 31.8172, 24.5935, 22.6, 19.9488, 17.8189, 15.1107, 13.2519, 10.8772, 10.1643, 8.80709, 8.00448, 6.02758, 5.14123},
04956       {289.896, 258.601, 215.353, 187.786, 154.972, 143.654, 120.207, 106.698, 88.6531, 75.9, 59.003, 52.4794, 41.7089, 38.3974, 35.4884, 28.7295, 17.5001, 31.3222, 18.7727, 15.4322, 11.8692, 10.5938, 8.97935, 9.22087, 9.05559, 6.60579, 6.4547, 2.855},
04957       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04958       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1}
04959     },
04960     {
04961       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04962       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04963       {-1, -1, -1, -158, -149.043, -92.0094, -28.6132, 27.8399, 27.5444, 27.5802, 37.07, 24.0291, 24.9195, 20.9748, 18.7762, 22.7466, 14.5682, 28.4577, 11.0263, 29.5137, 7.04546, 7.38512, 7.724, 6.71233, 27.4036, 4.52113, 4.33911, 4.07762},
04964       {-1, -1, -265.6, -144.969, -56.137, -4.4, 30.8879, 44.1075, 45.163, 42.5274, 38.7436, 34.8538, 31.1479, 28.8793, 25.3394, 22.5102, 19.0281, 15.6608, 13.3702, 12.0331, 11.1189, 10.2568, 8.57414, 7.45946, 6.29798, 6.15319, 5.30089, 4.56149},
04965       {-1, -79.5241, -105.242, -29.2478, 33.9726, 60.1505, 67.6247, 67.8742, 63.3538, 55.8014, 47.6468, 41.3991, 36.6279, 32.9551, 29.9351, 25.5988, 21.3793, 17.7866, 15.8878, 14.6346, 12.5951, 11.084, 9.73607, 8.64701, 7.50803, 6.97295, 5.98046, 5.18782},
04966       {-1, -40.3713, 42.1945, 92.9089, 114.43, 113.72, 100.286, 89.219, 77.4508, 66.7699, 55.0464, 47.6297, 41.3828, 36.4328, 33.2834, 28.5722, 23.0725, 21.5406, 18.1268, 16.2328, 13.9065, 12.2744, 10.5509, 9.47753, 8.48564, 7.63124, 6.41131, 5.79205},
04967       {-34.9, 73.3963, 142.631, 145.951, 142.318, 129.656, 111.93, 94.6978, 85.5312, 71.8926, 60.7711, 50.9572, 44.9347, 39.6302, 36.0288, 30.04, 24.3307, 21.7811, 18.3903, 16.2716, 14.7719, 12.8338, 11.2943, 9.72188, 8.62582, 7.73165, 6.73526, 5.93205},
04968       {7368.83, 502.793, 291.618, 282.933, 244.114, 233.502, 201.302, 172.276, 148.921, 125.128, 102.477, 86.3142, 75.3546, 64.468, 60.2395, 50.8744, 42.101, 35.6805, 30.7703, 26.6287, 23.2273, 20.6701, 17.2109, 15.2909, 13.682, 12.3394, 11.0076, 9.19048},
04969       {82.7323, 379.23, 270.613, 264.088, 246.284, 233.18, 190.228, 162.832, 141.282, 119.001, 96.1594, 81.5045, 71.5023, 63.5261, 57.4827, 48.7483, 38.0439, 34.4778, 29.625, 25.2903, 23.1887, 20.6185, 17.7059, 14.7975, 12.9311, 11.9939, 11.016, 9.50148},
04970       {185.843, 294.953, 268.259, 250.028, 232.276, 209.138, 174.647, 153.029, 132.233, 109.333, 91.0324, 76.9822, 67.8374, 59.8954, 53.4497, 43.553, 37.6139, 32.7444, 27.023, 23.9679, 20.9309, 19.1485, 16.0294, 13.8003, 12.3176, 11.3441, 9.55937, 8.54497},
04971       {348.282, 310.699, 268.381, 243.254, 217.179, 187.212, 162.957, 136.969, 124.132, 101.48, 81.8314, 71.5882, 61.3147, 54.9158, 49.5517, 42.7537, 33.5, 29.7412, 26.1131, 23.1024, 19.7197, 17.708, 14.0364, 12.8054, 11.8375, 10.4924, 9.04095, 8.33528},
04972       {324.513, 290.628, 251.147, 216.936, 198.177, 176.297, 151.909, 129.606, 113.817, 94.3377, 76.6785, 64.382, 56.4567, 51.125, 43.4356, 37.6896, 30.338, 26.5577, 23.1858, 20.4549, 18.0182, 16.0098, 13.1211, 11.8445, 11.3616, 9.25812, 8.4992, 7.35148},
04973       {244.009, 279.89, 230.644, 231.457, 172.803, 163.804, 140.071, 126.029, 107.683, 91.6615, 72.0354, 64.4556, 50.6761, 46.5068, 41.6472, 35.4661, 21.2969, 38.4268, 19.632, 18.4574, 12.839, 14.213, 12.4018, 12.0424, 9.6145, 8.22918, 9.88007, 6.12946},
04974       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04975       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1}
04976     },
04977     {
04978       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04979       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04980       {-1, -1, -251.167, -157.188, -100.839, -70.7716, -31.9278, -14.7414, -6.46332, -1.43471, 1.10161, 1.95823, 2.6771, 2.52718, 2.67548, 2.75908, 2.87331, 2.61814, 1.92056, 2.16773, 1.70225, 1.70877, 1.55219, 1.43065, 1.53014, 1.69851, 1.40267, 1.46639},
04981       {-1, -1, -243.237, -145.933, -87.2068, -48.5578, -21.9141, -7.68402, -2.83933, 1.21596, 2.94545, 4.083, 3.97067, 4.12142, 3.78849, 3.83645, 3.07738, 2.90695, 2.53516, 2.51623, 2.31173, 2.2246, 1.85357, 1.78656, 1.65385, 1.57375, 1.40617, 1.35693},
04982       {-1, -110, -141.651, -118.596, -52.606, -23.472, -8.09735, 0.683589, 3.57165, 5.25367, 5.8348, 5.67137, 5.26599, 5.1816, 4.84428, 4.6964, 4.06178, 3.27554, 3, 2.92343, 2.56487, 2.47989, 2.32236, 1.83586, 1.84201, 1.97658, 1.64081, 1.56958},
04983       {-1, -106.053, -87.5398, -49.1882, -11.1091, -0.606904, 6.08278, 8.18373, 9.14269, 8.82061, 8.39517, 7.5095, 6.66552, 6.06293, 5.79917, 5.11953, 4.08928, 3.87, 3.71985, 3.4277, 2.925, 2.47762, 2.49134, 2.1793, 2.11341, 1.8709, 1.68674, 1.69234},
04984       {-116.854, -103.914, -48.6067, -7.80512, 4.11674, 8.14952, 11.6643, 11.178, 11.3862, 10.0188, 9.46565, 8.32955, 7.58777, 6.63929, 6.08499, 5.66225, 4.70548, 4.09773, 4.0294, 3.23529, 2.62532, 2.89612, 2.52651, 2.27649, 1.99773, 1.96176, 2.06313, 2.12814},
04985       {-146.18, -59.7282, -12.5, 3.08192, 8.34909, 11.1753, 15.2845, 14.8204, 14.3607, 12.9987, 11.1043, 9.964, 8.90504, 8.31783, 7.36251, 6.6915, 6.24035, 4.98582, 4.03066, 5.83789, 3.10856, 2.96333, 3.06171, 2.23047, 2.32792, 2.18535, 2.38165, 2.42884},
04986       {-233.643, -96.4333, -30.9536, -2.51866, 5.30801, 7.45312, 14.238, 12.5321, 12.7695, 11.741, 10.4656, 8.62541, 7.93922, 7.51216, 6.53463, 5.50929, 4.6268, 4.64697, 4.30481, 3.52426, 3.45212, 3.73824, 4.07812, 2.33724, 2.51972, 2.21704, 3.41317, 2.55682},
04987       {-211.848, -67.9261, -9.6179, 2.65525, 11.0301, 16.4831, 16.0704, 15.4027, 15.1086, 13.5929, 11.7898, 9.90025, 9.13345, 8.25683, 7.21617, 6.25572, 5.43346, 4.54866, 3.83221, 3.4237, 3.65898, 3.65808, 3.18498, 2.75829, 2.37531, 2.88444, 1.95099, 1.89066},
04988       {-143.833, -12.2832, 7.8963, 16.4622, 19.9538, 17.4053, 18.3962, 16.7577, 15.9486, 14.1232, 11.1662, 10.5826, 9.11908, 8.38156, 7.65503, 6.84281, 5.95331, 4.69263, 4.88752, 3.84843, 3.79038, 3.24503, 2.73708, 2.6645, 2.5017, 2.13435, 1.87916, 2.1749},
04989       {-37.4431, 11.3047, 18.5, 23.1562, 22.8984, 22.1124, 20.1964, 19.4342, 17.2078, 15.1252, 12.2962, 10.5784, 9.23938, 8.73254, 7.106, 6.7301, 5.53248, 4.62478, 3.82739, 3.07251, 2.79682, 2.8214, 2.92242, 2.47091, 2.63102, 1.94484, 2.30322, 2.64068},
04990       {4.24623, 23.1041, 27.5407, 28, 23.0684, 24.1685, 21.3723, 19.4634, 16.9631, 14.3876, 12.3701, 10.1272, 9.12229, 7.9875, 7.06019, 5.96169, 5.53393, 4.32105, 3.66794, 3.70074, 3.20382, 3.47729, 3.06609, 2.26191, 2.48768, 2.01323, 2.73772, 2.66561},
04991       {33.3344, 32.716, 30.0851, 30.6933, 29.2431, 25.6295, 21.674, 19.3741, 17.7184, 14.8413, 12.1543, 10.4758, 9.33113, 7.79187, 7.39106, 5.8376, 6.08377, 4.85748, 4.16908, 3.88557, 3.14086, 3.11306, 2.98297, 3.33859, 2.04182, 2.32861, 2.75164, 2.29621},
04992       {46.1357, 38.8426, 36.6976, 32.0038, 29.6956, 23.4889, 22.725, 19.779, 17.5173, 14.7043, 11.9171, 10.7871, 9.06671, 8.23658, 7.41977, 6.46988, 4.93792, 4.55465, 4.20588, 3.82236, 3.62993, 2.83949, 2.95902, 1.99063, 2.37545, 2.28563, 2.49407, 2.52411}
04993     },
04994     {
04995       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04996       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04997       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04998       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
04999       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05000       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05001       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05002       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05003       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05004       {-417.629, -218.804, -63.1122, -34.5828, -10.68, 2.75084, 8.65719, 11.6155, 13.6253, 12.1802, 12.5535, 10.8028, 9.48349, 9.38468, 7.83699, 6.99092, 5.30562, 4.20316, 4.41177, 4.52123, 3.31882, 3.91104, 3.77374, 4.04567, 2.35974, 2.35145, 2.96747, 1.98381},
05005       {-311.688, -93.8205, -32.57, -6.85071, 6.45113, 7.97528, 13.5012, 15.2368, 16.5485, 14.4764, 12.181, 11.4092, 10.3418, 9.29414, 9.04287, 7.72862, 7.46558, 5.20657, 5.19399, 5.61358, 3.9523, 3.20885, 3.29034, 2.82267, 2.91734, 2.38053, 2.44655, 2.36229},
05006       {-161.948, -37.0248, -4.60393, 8.56983, 13.4828, 19.0043, 18.3378, 20.0726, 18.3394, 16.8149, 14.4702, 12.2298, 10.8159, 10.422, 8.29546, 7.70715, 6.26524, 5.70706, 5.26374, 4.44881, 4.80797, 3.24519, 3.09801, 2.73461, 3.34774, 2.88844, 2.34626, 2.76387},
05007       {-72.1648, -12.5057, 16.9112, 23.5819, 20.6731, 21.814, 22.9407, 19.6563, 19.1021, 16.9339, 15.2842, 12.4743, 11.0013, 10.0748, 8.91402, 7.27224, 6.15542, 5.23092, 4.49629, 4.25791, 3.79059, 3.70681, 3.31756, 2.62265, 3.45895, 2.19926, 2.15639, 2.7466},
05008       {2.3118, 20.9883, 24.9015, 32.366, 32.2839, 29.3505, 24.8013, 23.3821, 21.1815, 18.3139, 15.0436, 13.3637, 11.4887, 9.84427, 9.51972, 8.22026, 6.8517, 5.85862, 4.95269, 4.5885, 3.45462, 4.03355, 3.70984, 4.04694, 2.46266, 2.50179, 3.23813, 2.46999},
05009       {30.7084, 40.046, 40.956, 39.7092, 36.4134, 28.415, 28.5543, 24.9346, 23.1865, 19.4968, 15.3536, 14.0231, 12.0163, 10.7639, 9.82125, 8.36598, 6.4058, 5.88361, 5.13249, 4.51457, 4.9171, 3.87165, 3.58904, 2.85879, 2.53645, 2.81466, 2.72057, 3.18122}
05010     }
05011   };
05012 
05013 const float CSCTFPtMethods::dphifr1[4][15][28] = 
05014   {
05015     {
05016       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05017       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05018       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05019       {-1, -1, -174.092, -53.9867, 10.2441, 27.4286, 36.9822, 37.5167, 34.3051, 31.8195, 27.8286, 24.1206, 21.161, 19.0382, 17.1718, 14.6208, 12.2432, 10.7876, 9.69835, 8.08848, 7.13485, 6.60187, 5.18874, 5.13839, 4.41612, 4.14069, 3.58335, 3.01529},
05020       {-1, 1138.05, -49.183, 2.6568, 58.5809, 57.9481, 56.8007, 51.1911, 44.5243, 37.806, 32.1175, 27.5585, 24.3955, 21.7533, 19.3667, 17.0463, 13.9365, 11.8102, 10.2398, 9.1678, 8.26393, 7.18307, 6.13392, 5.533, 4.8865, 4.11951, 3.87238, 3.48248},
05021       {-1, 9.64577, 56.9057, 81.944, 82.4872, 78.3198, 68.8015, 60.7978, 52.6542, 44.3584, 37.3611, 31.2648, 27.235, 24.5, 22.04, 18.5, 15.75, 12.9557, 11.2655, 10.2491, 9.21672, 8.30474, 6.64511, 6.13513, 5.34219, 4.95, 4.23425, 3.6963},
05022       {97.5, 87.4578, 120.684, 105.38, 98.3177, 87.4048, 75.9, 65.9142, 56.1879, 47.6314, 39.6183, 33.2005, 28.7316, 25.4495, 22.9327, 19.4612, 15.7254, 13.8618, 11.9249, 10.0859, 9.444, 8.11458, 6.95662, 6.25641, 5.44159, 5.19583, 4.35396, 3.83333},
05023       {693.205, 454.942, 655.428, 360.329, 323.261, 275.945, 234.843, 196.055, 167.247, 139.873, 113.932, 95.6506, 82.789, 72.2128, 64.9871, 53.997, 43.4461, 39.0238, 33.6322, 28.8622, 25.6006, 21.9322, 18.5028, 16.0912, 14.2918, 12.4941, 10.5138, 9.05925},
05024       {9146.66, 471.958, 387.082, 340.914, 286.893, 262.777, 224.112, 184.982, 155.447, 133.684, 107.642, 91.5521, 78.135, 69.0562, 61.4634, 52.4394, 42.1881, 36.5169, 30.0318, 27.9321, 24.4145, 21.0881, 17.9552, 14.6189, 13.2301, 12.9111, 10.8691, 8.35492},
05025       {540.281, 410.901, 354.276, 301.779, 253.803, 238.881, 199.465, 167.136, 145.674, 119.585, 97.0842, 82.3805, 70.6386, 62.154, 55.8136, 46.3101, 37.2817, 33.507, 28.8241, 25.774, 22.4889, 19.8697, 16.1007, 13.3432, 12.4647, 11.9955, 9.6895, 8.46321},
05026       {419.005, 377.428, 314.861, 270.658, 240.487, 213.074, 182.994, 151.52, 129.287, 108.487, 87.9791, 74.8889, 64.8147, 56.7597, 50.5058, 42.6958, 35.6277, 29.9064, 26.1033, 22.5358, 20.6119, 17.9656, 15.3201, 13.1018, 11.7756, 10.129, 8.86099, 7.58348},
05027       {2783.23, 334.238, 275.818, 240.947, 205.026, 186.945, 163.992, 138.569, 117.64, 100.381, 81.1057, 68.0913, 58.8849, 52.6374, 45.2179, 38.059, 32.6702, 26.3298, 23.0484, 18.3201, 18.1814, 16.0936, 12.7571, 12.2673, 9.95479, 8.37502, 7.42398, 6.72237},
05028       {-1, -1, -1, -1, -1, 143.654, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 9.23717, 9.05559, -1, -1, 338.089},
05029       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05030       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1}
05031     },
05032     {
05033       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05034       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05035       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05036       {-1, -1, -293.3, -150.312, -41.3547, -4.93182, 20.0224, 31.2313, 31.0566, 33.3205, 30.2863, 27.2634, 24.2872, 22.0512, 19.596, 17.3902, 14.2112, 12.6609, 11.407, 10.2093, 8.85659, 7.85742, 6.4135, 6.23362, 5.41945, 4.95306, 4.41755, 3.82303},
05037       {-1, -143.627, -143.826, -62.3445, 23.7381, 51.7379, 55.9747, 54.5144, 47.9348, 42.2055, 37.0868, 31.9699, 28.8453, 26.0344, 23.1051, 20.5071, 17.1946, 14.1772, 12.4708, 11.3144, 9.88063, 8.86923, 7.67165, 6.4322, 5.96624, 5.18282, 4.81762, 4.28301},
05038       {-1, -13.3855, 5.16716, 64.1898, 72.3294, 76.3905, 73.7962, 67.3364, 59.9099, 51.4343, 43.5279, 37.1873, 31.7994, 29.0358, 26.5368, 22.0615, 19.1543, 15.4385, 14.2599, 12.3375, 10.9493, 9.73496, 8.26995, 7.45197, 6.60214, 6.08206, 5.15337, 4.66445},
05039       {-42.7682, 47.3889, 103.482, 107.735, 107.75, 94.9291, 87.763, 75.9543, 65.4694, 56.7377, 47.3143, 39.9327, 34.7819, 31.2361, 27.8932, 24.1076, 19.6767, 17.1081, 15.427, 12.8984, 11.4228, 10.0318, 8.49021, 7.90816, 6.72917, 6.39571, 5.45637, 4.61281},
05040       {541.234, 465.806, 429.209, 372.183, 331.067, 285.903, 258.37, 216.269, 181.991, 154.204, 125.987, 107.564, 91.8176, 81.5452, 73.1247, 59.1412, 51, 43.3898, 37.9118, 33.2887, 28.8381, 25.3079, 21.6463, 17.6858, 16.9908, 14.841, 11.8149, 10.9434},
05041       {255.594, 371.519, 358.173, 343.459, 285.798, 262.664, 238.913, 194.777, 163.618, 142.465, 116.934, 98.3012, 84.7328, 73.9315, 66.1496, 57.1145, 45.7455, 39.2169, 33.571, 28.7347, 27.0902, 22.7753, 19.8191, 16.4045, 15.2075, 14.0935, 12.3427, 9.36143},
05042       {275.796, 423.747, 347.249, 303.803, 270.357, 254.279, 217.372, 182.151, 161.833, 132.635, 108.221, 91.6597, 79.5534, 69.683, 62.6926, 52.9109, 42.95, 36.9714, 31.6704, 28.9253, 25.7569, 22.4706, 18.5914, 16.0164, 14.43, 14.6449, 11.4458, 9.78841},
05043       {378.542, 349.351, 319.333, 285.503, 261.452, 233.428, 201.215, 165.997, 145.442, 121.289, 98.8432, 84.1681, 72.9111, 64.2952, 58.4893, 48.2012, 41.2393, 34.1303, 29.9633, 26.1572, 23.1371, 20.5019, 17.2906, 15.0458, 14.0115, 11.7586, 10.045, 9.31029},
05044       {557.927, 338.049, 301.204, 265.456, 232.807, 212.31, 185.76, 158.503, 132.332, 113.382, 91.8123, 76.8816, 67.1968, 60.2717, 52.0559, 44.363, 36.5282, 29.777, 25.6156, 22.1842, 20.2098, 18.3932, 15.1911, 14.1691, 12.6889, 10.8789, 10.4976, 7.84804},
05045       {-1, -1, -1, -1, -1, 2154.03, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 12.2722, 8.95391, -1, -1, 337.608},
05046       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05047       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1}
05048     },
05049     {
05050       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05051       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05052       {-1, -1, -251.167, -157.188, -100.839, -70.7716, -31.9278, -14.7414, -6.46332, -1.43471, 1.10161, 1.95823, 2.6771, 2.52718, 2.67548, 2.75908, 2.87331, 2.61814, 1.92056, 2.16773, 1.70225, 1.70877, 1.55219, 1.43065, 1.53014, 1.69851, 1.40267, 1.46639},
05053       {-1, -1, -243.237, -145.933, -87.2068, -48.5578, -21.9141, -7.68402, -2.83933, 1.21596, 2.94545, 4.083, 3.97067, 4.12142, 3.78849, 3.83645, 3.07738, 2.90695, 2.53516, 2.51623, 2.31173, 2.2246, 1.85357, 1.78656, 1.65385, 1.57375, 1.40617, 1.35693},
05054       {-1, -110, -141.651, -118.596, -52.606, -23.472, -8.09735, 0.683589, 3.57165, 5.25367, 5.8348, 5.67137, 5.26599, 5.1816, 4.84428, 4.6964, 4.06178, 3.27554, 3, 2.92343, 2.56487, 2.47989, 2.32236, 1.83586, 1.84201, 1.97658, 1.64081, 1.56958},
05055       {-1, -106.053, -87.5398, -49.1882, -11.1091, -0.606904, 6.08278, 8.18373, 9.14269, 8.82061, 8.39517, 7.5095, 6.66552, 6.06293, 5.79917, 5.11953, 4.08928, 3.87, 3.71985, 3.4277, 2.925, 2.47762, 2.49134, 2.1793, 2.11341, 1.8709, 1.68674, 1.69234},
05056       {-116.854, -103.914, -48.6067, -7.80512, 4.11674, 8.14952, 11.6643, 11.178, 11.3862, 10.0188, 9.46565, 8.32955, 7.58777, 6.63929, 6.08499, 5.66225, 4.70548, 4.09773, 4.0294, 3.23529, 2.62532, 2.89612, 2.52651, 2.27649, 1.99773, 1.96176, 2.06313, 2.12814},
05057       {-146.18, -59.7282, -12.5, 3.08192, 8.34909, 11.1753, 15.2845, 14.8204, 14.3607, 12.9987, 11.1043, 9.964, 8.90504, 8.31783, 7.36251, 6.6915, 6.24035, 4.98582, 4.03066, 5.83789, 3.10856, 2.96333, 3.06171, 2.23047, 2.32792, 2.18535, 2.38165, 2.42884},
05058       {-233.643, -96.4333, -30.9536, -2.51866, 5.30801, 7.45312, 14.238, 12.5321, 12.7695, 11.741, 10.4656, 8.62541, 7.93922, 7.51216, 6.53463, 5.50929, 4.6268, 4.64697, 4.30481, 3.52426, 3.45212, 3.73824, 4.07812, 2.33724, 2.51972, 2.21704, 3.41317, 2.55682},
05059       {-211.848, -67.9261, -9.6179, 2.65525, 11.0301, 16.4831, 16.0704, 15.4027, 15.1086, 13.5929, 11.7898, 9.90025, 9.13345, 8.25683, 7.21617, 6.25572, 5.43346, 4.54866, 3.83221, 3.4237, 3.65898, 3.65808, 3.18498, 2.75829, 2.37531, 2.88444, 1.95099, 1.89066},
05060       {-143.833, -12.2832, 7.8963, 16.4622, 19.9538, 17.4053, 18.3962, 16.7577, 15.9486, 14.1232, 11.1662, 10.5826, 9.11908, 8.38156, 7.65503, 6.84281, 5.95331, 4.69263, 4.88752, 3.84843, 3.79038, 3.24503, 2.73708, 2.6645, 2.5017, 2.13435, 1.87916, 2.1749},
05061       {-37.4431, 11.3047, 18.5, 23.1562, 22.8984, 22.1124, 20.1964, 19.4342, 17.2078, 15.1252, 12.2962, 10.5784, 9.23938, 8.73254, 7.106, 6.7301, 5.53248, 4.62478, 3.82739, 3.07251, 2.79682, 2.8214, 2.92242, 2.47091, 2.63102, 1.94484, 2.30322, 2.64068},
05062       {4.24623, 23.1041, 27.5407, 28, 23.0684, 24.1685, 21.3723, 19.4634, 16.9631, 14.3876, 12.3701, 10.1272, 9.12229, 7.9875, 7.06019, 5.96169, 5.53393, 4.32105, 3.66794, 3.70074, 3.20382, 3.47729, 3.06609, 2.26191, 2.48768, 2.01323, 2.73772, 2.66561},
05063       {33.3344, 32.716, 30.0851, 30.6933, 29.2431, 25.6295, 21.674, 19.3741, 17.7184, 14.8413, 12.1543, 10.4758, 9.33113, 7.79187, 7.39106, 5.8376, 6.08377, 4.85748, 4.16908, 3.88557, 3.14086, 3.11306, 2.98297, 3.33859, 2.04182, 2.32861, 2.75164, 2.29621},
05064       {46.1357, 38.8426, 36.6976, 32.0038, 29.6956, 23.4889, 22.725, 19.779, 17.5173, 14.7043, 11.9171, 10.7871, 9.06671, 8.23658, 7.41977, 6.46988, 4.93792, 4.55465, 4.20588, 3.82236, 3.62993, 2.83949, 2.95902, 1.99063, 2.37545, 2.28563, 2.49407, 2.52411}
05065     },
05066     {
05067       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05068       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05069       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05070       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05071       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05072       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05073       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05074       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05075       {-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1},
05076       {-417.629, -218.804, -63.1122, -34.5828, -10.68, 2.75084, 8.65719, 11.6155, 13.6253, 12.1802, 12.5535, 10.8028, 9.48349, 9.38468, 7.83699, 6.99092, 5.30562, 4.20316, 4.41177, 4.52123, 3.31882, 3.91104, 3.77374, 4.04567, 2.35974, 2.35145, 2.96747, 1.98381},
05077       {-311.688, -93.8205, -32.57, -6.85071, 6.45113, 7.97528, 13.5012, 15.2368, 16.5485, 14.4764, 12.181, 11.4092, 10.3418, 9.29414, 9.04287, 7.72862, 7.46558, 5.20657, 5.19399, 5.61358, 3.9523, 3.20885, 3.29034, 2.82267, 2.91734, 2.38053, 2.44655, 2.36229},
05078       {-161.948, -37.0248, -4.60393, 8.56983, 13.4828, 19.0043, 18.3378, 20.0726, 18.3394, 16.8149, 14.4702, 12.2298, 10.8159, 10.422, 8.29546, 7.70715, 6.26524, 5.70706, 5.26374, 4.44881, 4.80797, 3.24519, 3.09801, 2.73461, 3.34774, 2.88844, 2.34626, 2.76387},
05079       {-72.1648, -12.5057, 16.9112, 23.5819, 20.6731, 21.814, 22.9407, 19.6563, 19.1021, 16.9339, 15.2842, 12.4743, 11.0013, 10.0748, 8.91402, 7.27224, 6.15542, 5.23092, 4.49629, 4.25791, 3.79059, 3.70681, 3.31756, 2.62265, 3.45895, 2.19926, 2.15639, 2.7466},
05080       {2.3118, 20.9883, 24.9015, 32.366, 32.2839, 29.3505, 24.8013, 23.3821, 21.1815, 18.3139, 15.0436, 13.3637, 11.4887, 9.84427, 9.51972, 8.22026, 6.8517, 5.85862, 4.95269, 4.5885, 3.45462, 4.03355, 3.70984, 4.04694, 2.46266, 2.50179, 3.23813, 2.46999},
05081       {30.7084, 40.046, 40.956, 39.7092, 36.4134, 28.415, 28.5543, 24.9346, 23.1865, 19.4968, 15.3536, 14.0231, 12.0163, 10.7639, 9.82125, 8.36598, 6.4058, 5.88361, 5.13249, 4.51457, 4.9171, 3.87165, 3.58904, 2.85879, 2.53645, 2.81466, 2.72057, 3.18122}
05082     }
05083   };
05084 
05085 
05086 const float CSCTFPtMethods::sigmafr0[4][15][28] =
05087   {
05088     {
05089       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05090       {1, 1, 68.1251, 119.334, 71.9663, 47.2033, 34.4095, 24.1757, 16.9244, 14.21, 10.0848, 8.28308, 7.49682, 7.5252, 5.7771, 5.67435, 5.05335, 4.03134, 3.38787, 3.49897, 3.27399, 4.38102, 3.45241, 3.57641, 2.74292, 2.58754, 2.82597, 3.02336},
05091       {1, 1, 11.2171, 180.376, 95.0863, 45.7334, 36.6456, 24.597, 16.4907, 15.2826, 12.8201, 10.0379, 9.45291, 8.26339, 6.8289, 6.16693, 4.85849, 12.1669, 4.04481, 3.76596, 3.33028, 3.0602, 2.82333, 6.10153, 3.8862, 4.83151, 2.99154, 2.87868},
05092       {1, 1, 214.489, 145.179, 39.8377, 32.3612, 24.983, 17.3205, 14.5435, 11.4038, 8.99103, 7.65653, 7.03634, 6.16057, 5.35274, 6.44559, 4.63289, 3.48617, 3.32857, 3.25099, 3.28055, 3.0714, 2.58432, 2.61066, 2.99103, 2.85844, 3.29465, 3.06768},
05093       {1, 2.17804, 246.204, 73.5985, 34.3397, 27.9956, 21.2206, 15.6835, 13.173, 11.1528, 9.00959, 7.51184, 6.55643, 5.56576, 5.47, 5.43772, 4.62926, 3.37312, 3.33237, 3.59496, 2.67392, 2.79043, 3.0637, 2.60009, 3.12616, 3.22084, 3.22784, 3.62183},
05094       {1, 178.428, 54.0668, 50.639, 30.0806, 26.6723, 18.1088, 16.2946, 12.3097, 11.9197, 9.76022, 7.47657, 6.44478, 6.32831, 5.64725, 4.21032, 3.63872, 4.3096, 3.11977, 3.49313, 2.69508, 3.80622, 2.76555, 2.70835, 3.1522, 2.74832, 2.77429, 2.80946},
05095       {33.7724, 127.162, 36.813, 83.7352, 41.0058, 28.8809, 20.1964, 14.9477, 14.2195, 11.9145, 11.2838, 7.30775, 8.05355, 7.12897, 7.13998, 4.44287, 3.82913, 15.6533, 3.1924, 3.68782, 2.97145, 3.00122, 2.60565, 2.86444, 2.25535, 2.47471, 2.46453, 2.92709},
05096       {63.4126, 78.9729, 63.6832, 49.5751, 46.9535, 42.779, 36.3592, 31.1099, 23.5997, 21.204, 16.8426, 16.7998, 13.9811, 12.5411, 10.5253, 13.362, 8.63362, 6.77557, 6.6511, 14.3978, 8.47154, 10.8782, 7.15581, 5.88536, 8.01652, 12.0409, 6.80079, 9.92202},
05097       {323.587, 130.398, 76.2136, 54.71, 44.2662, 43.958, 40.2353, 30.8886, 26.9603, 24.2783, 17.5786, 15.1457, 15.3706, 13.0387, 11.2397, 11.2636, 7.87718, 10.9021, 7.53715, 8.17749, 6.93261, 17.4198, 4.87206, 5.71908, 6.3438, 9.25595, 11.7572, 6.81276},
05098       {125.501, 86.1114, 78.0846, 56.6407, 42.2517, 43.9773, 35.4223, 31.0062, 26.3755, 22.5857, 20.9842, 17.2539, 14.0029, 12.3455, 11.3132, 13.3154, 8.60381, 8.35366, 6.2164, 6.76689, 6.09496, 5.59811, 8.17196, 13.4268, 6.02764, 5.67951, 6.71677, 8.7109},
05099       {95.8611, 75.3004, 65.2466, 53.2109, 47.9975, 40.0404, 31.958, 30.4257, 27.7305, 25.0529, 17.6693, 15.6535, 14.5663, 11.3021, 11.7363, 9.1677, 11.1228, 7.84579, 6.95689, 7.39175, 8.02251, 6.36251, 6.64162, 7.60716, 5.71819, 8.15284, 6.63158, 6.81248},
05100       {274.776, 85.1791, 62.5779, 52.2624, 45.0418, 38.0133, 33.6947, 28.865, 27.5922, 23.043, 19.7818, 17.272, 15.9374, 13.4469, 11.8057, 11.5461, 10.9067, 11.0404, 8.0732, 10.2156, 10.7966, 8.75473, 8.18003, 20.2431, 14.1253, 10.6056, 14.0389, 18.7348},
05101       {81.1599, 81.4479, 69.629, 57.8942, 56.9895, 32.849, 30.7188, 31.1175, 24.4425, 21.2399, 15.3807, 20.083, 15.6961, 11.7551, 15.4998, 10.336, 95.0491, 69.3807, 9.18389, 8.17367, 17.986, 10.1523, 12.8713, 12.5117, 13.3384, 6.82039, 12.7359, 26.3342},
05102       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05103       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}
05104     },
05105     {
05106       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05107       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05108       {1, 1, 1, 0.213802, 110.043, 85.1732, 83.1862, 87.3043, 33.7737, 23.0747, 63.8276, 15.2175, 27.868, 12.6669, 17.1469, 50.731, 9.70449, 64.2886, 5.70197, 81.6955, 9.51219, 7.0649, 8.84973, 5.99795, 83.4597, 4.3645, 5.86517, 5.28726},
05109       {1, 1, 89.5159, 113.68, 91.6962, 77.6377, 52.0035, 33.9964, 28.4368, 21.664, 16.7158, 14.0169, 11.7753, 10.7078, 10.2129, 8.69455, 6.96017, 5.68121, 5.38927, 4.89401, 4.95697, 4.9322, 3.65117, 3.25201, 3.55802, 4.72346, 3.40616, 3.19724},
05110       {1, 3.65071, 167.809, 118.577, 79.2131, 62.7322, 46.6568, 31.0416, 24.7606, 20.1139, 16.3567, 13.9311, 12.4083, 10.2061, 9.70802, 8.58308, 7.39169, 5.60975, 6.81223, 4.72617, 4.29868, 4.44951, 4.15795, 3.71309, 3.85244, 3.71955, 3.6068, 4.61138},
05111       {1, 143.017, 114.974, 80.9475, 65.7978, 58.7383, 33.663, 40.7059, 22.9966, 20.6734, 16.5455, 13.8755, 12.3398, 12.2325, 10.2504, 7.705, 7.19971, 9.05019, 6.72006, 5.09801, 5.65375, 4.89251, 3.85383, 5.25096, 3.76551, 3.68784, 3.63877, 3.53497},
05112       {70.5084, 123.26, 74.5829, 51.9644, 47.7945, 42.5259, 34.1665, 27.4405, 24.5782, 19.7956, 16.2276, 12.4019, 11.9461, 10.1038, 9.26924, 8.81221, 6.45554, 6.13044, 6.01564, 5.92054, 5.00283, 3.79784, 4.43493, 3.38759, 3.06995, 3.1821, 3.37826, 3.39659},
05113       {1217.05, 201.975, 85.5261, 68.5927, 66.6012, 60.9998, 53.6427, 48.6075, 31.7341, 27.728, 24.6024, 22.4018, 15.7743, 17.3198, 13.7922, 11.3731, 10.1716, 9.0544, 8.50262, 14.2347, 6.81764, 8.60334, 9.55753, 7.02884, 6.94412, 5.80156, 7.08978, 8.2179},
05114       {236.657, 244.966, 112.373, 78.8199, 67.8974, 66.5142, 55.7426, 43.4698, 42.7562, 31.9949, 26.366, 19.1138, 19.3944, 20.4525, 14.6857, 12.3677, 10.7261, 12.6794, 8.76137, 12.16, 6.75415, 10.3045, 7.91157, 7.42901, 6.80211, 6.86062, 12.349, 10.4941},
05115       {256.896, 159.681, 100.055, 84.1373, 62.7979, 61.6566, 48.3574, 40.4226, 36.0741, 31.4883, 25.5559, 23.7784, 17.1684, 15.61, 16.1722, 15.1145, 10.1943, 10.9007, 10.3402, 7.54424, 7.313, 7.46722, 7.17864, 7.46414, 6.75702, 5.89486, 6.40948, 8.48163},
05116       {257.504, 109.282, 103.033, 75.7751, 76.7721, 58.9241, 48.3108, 41.4407, 39.4679, 33.6439, 24.8537, 21.3699, 18.0898, 16.9161, 15.6342, 14.1586, 12.3244, 9.18785, 10.0318, 9.4986, 8.91357, 11.6174, 18.6761, 9.52487, 6.88319, 13.6627, 9.81258, 14.6774},
05117       {169.185, 113.197, 93.9858, 75.5571, 65.2782, 52.2785, 48.0109, 40.0461, 36.6626, 30.353, 25.1063, 20.7361, 18.792, 16.958, 14.6701, 13.3799, 13.4912, 9.98326, 9.89502, 12.4285, 10.494, 11.2434, 8.54232, 16.3106, 14.0824, 8.59128, 9.7086, 12.0069},
05118       {101.76, 119.944, 74.5477, 78.6374, 68.0419, 54.84, 40.7916, 44.7959, 40.9335, 33.4932, 22.5979, 24.5248, 18.5872, 15.2081, 15.6492, 10.4524, 103.653, 66.9111, 17.5435, 8.81236, 15.4697, 9.49944, 13.4211, 9.33341, 11.9129, 8.46251, 14.9693, 10.4711},
05119       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05120       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}
05121     },
05122     {
05123       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05124       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05125       {1, 1, 0.0011042, 86.9352, 75.2624, 52.2464, 32.6091, 20.4476, 13.4983, 11.2587, 8.80378, 7.11921, 7.0583, 5.68815, 6.20848, 4.34774, 5.45062, 5.4936, 3.43077, 3.33174, 3.04659, 3.8793, 3.11545, 2.97137, 3.92529, 4.57437, 3.88033, 3.82278},
05126       {1, 1, 94.2962, 87.2608, 63.6413, 44.4619, 27.8601, 17.1249, 14.5496, 10.6136, 8.1779, 7.43897, 6.44223, 6.07491, 5.71576, 5.80677, 4.30508, 3.71754, 3.50651, 3.11441, 4.01509, 3.70184, 3.27363, 3.07401, 3.82936, 3.74439, 2.99869, 3.56942},
05127       {1, 0.263982, 119.77, 91.7619, 57.8566, 34.9019, 22.023, 15.941, 12.22, 10.1212, 8.34203, 7.32761, 6.13686, 5.47659, 5.31636, 4.7639, 4.16051, 3.54105, 4.07639, 3.09476, 3.04313, 3.29353, 3.70995, 2.79947, 3.94107, 3.99605, 3.96949, 4.88657},
05128       {1, 113.045, 93.6573, 70.568, 31.0566, 20.7173, 16.8019, 14.8641, 11.9429, 9.96161, 7.87523, 6.7396, 6.18326, 6.16374, 5.35523, 3.95939, 4.04783, 4.28055, 3.89598, 3.4252, 3.42753, 3.48459, 3.23155, 3.19143, 4.02432, 3.06929, 3.42948, 4.04161},
05129       {0.447397, 105.302, 76.6619, 31.9851, 22.4774, 19.276, 17.7676, 14.1965, 10.8272, 10.1416, 7.62459, 6.60822, 7.21393, 6.00029, 5.10027, 4.89418, 4.42892, 3.707, 6.06502, 3.37472, 3.49089, 3.46185, 6.33915, 3.3654, 3.30022, 3.36655, 4.87842, 8.07411},
05130       {152.08, 112.801, 47.3659, 30.5674, 29.0316, 22.3914, 19.0157, 16.3471, 15.5554, 12.4982, 10.4935, 8.23282, 7.40488, 9.06651, 6.97499, 9.66855, 8.35921, 5.45921, 5.68328, 10.6461, 4.65396, 7.5477, 7.11417, 6.02132, 6.79497, 8.21492, 10.5221, 11.7369},
05131       {177.146, 109.73, 53.3379, 32.4922, 30.5016, 25.9712, 22.9064, 19.6453, 17.4685, 14.9279, 10.9822, 10.9065, 9.22264, 9.52341, 9.23665, 6.50148, 6.20737, 8.19635, 7.38019, 9.07186, 9.22787, 11.9975, 15.4328, 12.1685, 11.2679, 11.0456, 16.8556, 15.203},
05132       {175.465, 100.985, 56.7871, 37.5513, 26.3367, 23.6775, 19.3572, 17.3464, 16.3425, 14.2809, 11.4196, 10.1502, 9.45509, 8.55837, 7.929, 7.75422, 6.25516, 6.98075, 7.95726, 5.58602, 8.52811, 8.94976, 8.61675, 7.52203, 5.86654, 9.30841, 7.95983, 9.16498},
05133       {161.557, 60.9083, 42.7418, 32.6681, 28.4483, 23.0831, 20.1852, 16.6503, 14.3982, 12.9469, 10.4914, 10.6759, 9.05724, 8.21126, 8.46837, 9.92698, 7.71569, 6.7965, 8.87549, 6.0765, 7.88892, 7.22201, 8.13346, 8.88474, 11.2008, 10.4921, 8.34342, 10.0337},
05134       {91.718, 50.2739, 37.883, 32.7472, 24.9764, 23.3509, 19.3552, 17.9669, 15.5899, 13.3535, 11.3664, 9.74592, 9.19961, 7.76436, 7.74193, 7.18929, 6.40388, 8.6005, 6.88462, 10.8404, 8.72774, 7.46032, 9.74493, 9.06091, 8.81877, 8.50823, 11.0295, 15.2753},
05135       {72.4631, 47.222, 36.2746, 28.8782, 23.553, 24.7348, 18.7544, 18.437, 15.7064, 12.729, 11.0992, 10.1026, 8.40556, 7.96116, 8.09745, 6.41375, 6.51981, 6.63771, 8.47843, 7.66306, 8.95359, 10.2608, 8.83699, 8.72077, 10.7087, 7.27377, 13.6, 14.2494},
05136       {60.2763, 42.7498, 34.6623, 26.385, 25.4651, 21.7019, 19.0647, 15.8816, 14.2646, 12.5554, 10.8672, 9.43677, 8.44181, 7.59876, 7.81844, 6.11722, 8.516, 8.94197, 6.97098, 7.17371, 6.68615, 7.24368, 6.23672, 11.2857, 8.77067, 8.43604, 11.2313, 10.0775},
05137       {57.866, 41.2832, 33.3179, 27.3557, 23.8832, 20.5696, 17.8125, 15.5961, 14.4456, 12.0961, 9.76464, 9.34033, 7.73885, 7.76005, 7.44823, 7.55132, 7.13281, 5.57387, 6.08408, 6.99443, 6.28186, 6.48654, 6.99549, 5.28173, 7.53539, 6.92374, 8.62903, 12.2492}
05138     },
05139     {
05140       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05141       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05142       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05143       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05144       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05145       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05146       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05147       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05148       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05149       {269.647, 190.711, 88.8938, 70.894, 47.3717, 44.6289, 33.3552, 28.7616, 25.0309, 21.272, 17.9555, 14.7229, 14.5419, 11.7788, 13.5958, 10.8726, 7.98782, 10.1873, 8.92189, 9.84992, 7.93519, 10.66, 9.14665, 13.8959, 8.38381, 7.987, 15.2538, 11.2857},
05150       {235.853, 115.945, 85.6699, 62.6811, 48.3218, 46.3742, 32.8133, 27.8045, 23.4159, 20.5056, 16.0387, 15.324, 13.2206, 11.3368, 10.4307, 9.27748, 11.3733, 8.87551, 8.35207, 11.7778, 8.82057, 8.90268, 8.28021, 8.06991, 12.7847, 7.80538, 8.15497, 8.97099},
05151       {181.416, 96.6442, 73.0719, 54.7106, 42.9821, 37.438, 32.203, 27.5413, 22.6414, 19.4503, 17.7779, 14.5369, 13.0979, 13.7771, 10.4079, 9.45385, 13.0227, 8.50182, 7.17865, 10.9919, 15.7864, 8.76431, 8.51823, 5.92961, 9.18247, 10.5971, 9.3721, 15.4988},
05152       {139.491, 86.7362, 64.8339, 51.7932, 40.4078, 39.1071, 30.9617, 26.4873, 25.263, 20.3243, 16.5092, 14.4393, 12.175, 11.956, 10.8174, 9.08607, 7.18855, 10.0054, 11.1779, 7.12204, 9.47445, 6.93119, 8.93181, 8.61144, 11.0501, 6.27241, 9.95825, 14.4856},
05153       {106.141, 75.9413, 58.0517, 48.534, 42.3919, 33.3155, 31.0908, 25.4912, 22.6406, 19.3109, 16.0106, 14.2606, 12.5963, 11.0191, 11.1065, 9.09784, 9.07922, 8.92264, 7.34917, 7.71939, 7.41573, 8.73107, 6.43358, 17.2136, 9.26347, 8.55656, 10.9458, 12.6821},
05154       {100.082, 76.8702, 55.0846, 48.6279, 40.6142, 34.3238, 29.3724, 26.3273, 25.1794, 19.6749, 16.3483, 14.3196, 12.3469, 11.8695, 11.738, 9.54169, 10.3128, 8.97389, 7.22238, 8.43618, 9.03957, 7.8851, 9.20503, 8.0428, 8.81155, 10.3738, 10.7343, 18.0864}
05155     }
05156   };
05157 
05158 const float CSCTFPtMethods::sigmafr1[4][15][28] = 
05159   {
05160     {
05161       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05162       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05163       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05164       {1, 1, 146.093, 91.0022, 59.1524, 33.1605, 28.0477, 17.4744, 15.5721, 11.7519, 9.35168, 7.7485, 7.04861, 6.47423, 5.73763, 5.09473, 4.08489, 3.39595, 4.04544, 2.96401, 3.63584, 3.1557, 3.00004, 3.18668, 3.41738, 2.71614, 2.82526, 3.70189},
05165       {1, 218.776, 145.244, 104.935, 64.8144, 29.6568, 23.4613, 19.0926, 14.8407, 10.6044, 9.43501, 7.74741, 6.91137, 6.22613, 5.72544, 5.2123, 4.24476, 3.74203, 3.31965, 3.40162, 3.74122, 2.96814, 3.12356, 2.69131, 3.2702, 3.08497, 3.38834, 2.81568},
05166       {1, 216.291, 89.0598, 61.8382, 26.9505, 21.5635, 19.7094, 17.3911, 12.8349, 12.6624, 9.67599, 7.38235, 6.67213, 6.85975, 5.63519, 4.96333, 5.1828, 3.76683, 3.47407, 3.5603, 4.18003, 2.75393, 3.24872, 2.69483, 3.18626, 3.0917, 2.9064, 3.49336},
05167       {74.8743, 114.685, 34.9506, 32.6917, 21.6367, 20.6803, 22.2436, 14.6578, 12.8293, 10.8414, 8.62706, 7.16602, 6.62353, 6.20931, 5.41574, 4.63619, 4.12341, 3.53772, 5.40106, 3.54274, 3.04711, 2.82168, 2.97043, 2.56215, 2.63581, 2.72855, 3.475, 2.40102},
05168       {171.647, 40.3668, 170.531, 57.8944, 49.7425, 45.0042, 40.4664, 35.8242, 31.2455, 28.1189, 21.2241, 17.9434, 14.4424, 15.5375, 14.4543, 11.4451, 11.2267, 9.18004, 8.39402, 12.0792, 5.76609, 6.72775, 8.85565, 8.75935, 6.70541, 6.8381, 9.55174, 8.56415},
05169       {1303.1, 108.27, 69.3932, 63.777, 57.8401, 52.0202, 42.5951, 33.2084, 28.6304, 27.9733, 20.1268, 18.8158, 17.0162, 13.475, 12.6629, 12.7418, 8.99252, 8.94672, 7.8758, 8.3772, 10.6977, 8.00381, 8.8381, 14.3496, 11.113, 8.4152, 9.00849, 13.7466},
05170       {160.859, 94.3386, 65.0202, 60.3475, 75.2043, 44.8816, 41.5634, 37.5275, 27.7923, 26.4016, 21.5374, 15.8813, 15.8779, 13.9959, 13.7772, 19.727, 11.742, 8.67518, 9.28799, 8.13627, 7.15515, 8.97133, 6.80429, 10.5999, 5.91254, 9.1128, 10.6201, 10.5506},
05171       {107.553, 88.8958, 66.3069, 65.4056, 48.5765, 45.1286, 40.6105, 32.3372, 26.121, 24.6533, 21.1985, 17.5026, 16.0065, 14.2815, 14.0509, 11.6923, 10.0067, 10.5004, 9.65113, 8.2566, 9.49279, 7.25941, 9.84551, 9.10625, 13.5828, 7.42791, 9.7761, 13.2592},
05172       {621.575, 81.157, 78.9902, 50.6043, 51.6995, 55.1314, 40.8115, 35.0876, 26.3547, 27.1407, 22.0774, 18.4421, 15.9584, 16.8535, 14.1161, 12.7641, 15.5263, 11.1729, 9.03555, 12.459, 19.0917, 9.49799, 18.3356, 11.5246, 14.7979, 11.849, 14.7263, 17.7757},
05173       {1, 1, 1, 1, 1, 32.849, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0.0542444, 13.3384, 1, 1, 0.248621},
05174       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05175       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}
05176     },
05177     {
05178       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05179       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05180       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05181       {1, 1, 0.296438, 118.62, 89.405, 52.2476, 45.2939, 28.7616, 25.5548, 18.0656, 13.6928, 11.9697, 10.3611, 10.2854, 7.90347, 6.39297, 5.44473, 5.61793, 5.27675, 4.76144, 3.86958, 3.78657, 3.56005, 3.94048, 3.79113, 3.08763, 3.15283, 3.15847},
05182       {1, 0.14452, 190.349, 154.279, 86.5965, 82.5413, 34.8556, 31.0941, 21.5582, 16.6576, 14.6587, 11.7976, 10.7251, 8.74257, 8.03431, 6.05178, 6.15984, 5.17494, 4.89723, 4.20602, 4.38072, 3.50678, 3.58872, 3.36111, 4.08605, 3.61866, 3.4662, 3.78235},
05183       {1, 152.929, 136.244, 73.4085, 45.9132, 36.7447, 30.241, 27.8179, 20.674, 19.6962, 14.1128, 12.5882, 9.73802, 10.7205, 7.71969, 7.51919, 7.77108, 5.55116, 5.33028, 4.40788, 4.93005, 3.668, 3.55749, 3.69614, 3.82949, 5.04436, 3.26159, 4.26046},
05184       {140.472, 85.4204, 71.8176, 59.7741, 41.1711, 31.8045, 29.5324, 23.9129, 19.9144, 18.3415, 13.8572, 10.9475, 10.3783, 8.29955, 7.48321, 7.171, 7.00912, 5.36884, 6.52747, 3.98305, 4.04028, 3.61817, 3.21717, 3.59865, 3.14602, 3.12143, 3.07281, 2.69386},
05185       {237.788, 96.2055, 102.507, 72.5626, 75.5721, 55.7517, 51.4652, 44.584, 37.268, 33.9088, 25.8814, 21.9077, 17.3586, 14.6234, 14.7653, 11.7539, 12.3716, 11.6726, 8.48135, 6.99178, 7.1455, 8.09071, 7.52601, 8.58121, 6.96213, 7.95596, 6.81041, 5.66795},
05186       {294.913, 161.347, 102.319, 90.1594, 81.3222, 70.8996, 53.4479, 45.6466, 42.2802, 37.0224, 24.8388, 24.4679, 21.1667, 17.9857, 17.5664, 18.9734, 11.9997, 12.9781, 8.93737, 8.43556, 9.32775, 10.8702, 8.67542, 7.73195, 8.2574, 8.75741, 7.36091, 13.6306},
05187       {180.057, 184.24, 82.2473, 86.6705, 77.8282, 62.6743, 52.5831, 46.0168, 37.4869, 33.5461, 26.8174, 20.3363, 20.252, 18.0727, 15.3164, 12.4784, 11.096, 9.67415, 10.3632, 9.03916, 9.16117, 10.5277, 8.66486, 7.16234, 6.57559, 10.5885, 9.67653, 10.1513},
05188       {251.671, 111.919, 94.9753, 90.3654, 68.4575, 62.0251, 55.3331, 45.2581, 34.2676, 33.7628, 26.9416, 23.3815, 19.7758, 18.5239, 19.3473, 18.9695, 12.0358, 12.3383, 10.8987, 8.83571, 10.1066, 9.69945, 10.316, 9.06576, 11.4875, 9.98941, 9.84754, 11.6985},
05189       {232.68, 109.947, 100.398, 74.9348, 66.4849, 60.1203, 51.4264, 44.3605, 37.0279, 34.0509, 27.488, 23.3947, 20.7529, 19.3877, 17.5345, 14.8416, 13.6832, 16.4535, 10.019, 13.0386, 10.8694, 9.31296, 10.1387, 9.91914, 10.8276, 8.53285, 12.0437, 13.6714},
05190       {1, 1, 1, 1, 1, 54.84, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0.0233561, 0.0280901, 1, 1, 0.226361},
05191       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05192       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}
05193     },
05194     {
05195       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05196       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05197       {1, 1, 0.0011042, 86.9352, 75.2624, 52.2464, 32.6091, 20.4476, 13.4983, 11.2587, 8.80378, 7.11921, 7.0583, 5.68815, 6.20848, 4.34774, 5.45062, 5.4936, 3.43077, 3.33174, 3.04659, 3.8793, 3.11545, 2.97137, 3.92529, 4.57437, 3.88033, 3.82278},
05198       {1, 1, 94.2962, 87.2608, 63.6413, 44.4619, 27.8601, 17.1249, 14.5496, 10.6136, 8.1779, 7.43897, 6.44223, 6.07491, 5.71576, 5.80677, 4.30508, 3.71754, 3.50651, 3.11441, 4.01509, 3.70184, 3.27363, 3.07401, 3.82936, 3.74439, 2.99869, 3.56942},
05199       {1, 0.263982, 119.77, 91.7619, 57.8566, 34.9019, 22.023, 15.941, 12.22, 10.1212, 8.34203, 7.32761, 6.13686, 5.47659, 5.31636, 4.7639, 4.16051, 3.54105, 4.07639, 3.09476, 3.04313, 3.29353, 3.70995, 2.79947, 3.94107, 3.99605, 3.96949, 4.88657},
05200       {1, 113.045, 93.6573, 70.568, 31.0566, 20.7173, 16.8019, 14.8641, 11.9429, 9.96161, 7.87523, 6.7396, 6.18326, 6.16374, 5.35523, 3.95939, 4.04783, 4.28055, 3.89598, 3.4252, 3.42753, 3.48459, 3.23155, 3.19143, 4.02432, 3.06929, 3.42948, 4.04161},
05201       {0.447397, 105.302, 76.6619, 31.9851, 22.4774, 19.276, 17.7676, 14.1965, 10.8272, 10.1416, 7.62459, 6.60822, 7.21393, 6.00029, 5.10027, 4.89418, 4.42892, 3.707, 6.06502, 3.37472, 3.49089, 3.46185, 6.33915, 3.3654, 3.30022, 3.36655, 4.87842, 8.07411},
05202       {152.08, 112.801, 47.3659, 30.5674, 29.0316, 22.3914, 19.0157, 16.3471, 15.5554, 12.4982, 10.4935, 8.23282, 7.40488, 9.06651, 6.97499, 9.66855, 8.35921, 5.45921, 5.68328, 10.6461, 4.65396, 7.5477, 7.11417, 6.02132, 6.79497, 8.21492, 10.5221, 11.7369},
05203       {177.146, 109.73, 53.3379, 32.4922, 30.5016, 25.9712, 22.9064, 19.6453, 17.4685, 14.9279, 10.9822, 10.9065, 9.22264, 9.52341, 9.23665, 6.50148, 6.20737, 8.19635, 7.38019, 9.07186, 9.22787, 11.9975, 15.4328, 12.1685, 11.2679, 11.0456, 16.8556, 15.203},
05204       {175.465, 100.985, 56.7871, 37.5513, 26.3367, 23.6775, 19.3572, 17.3464, 16.3425, 14.2809, 11.4196, 10.1502, 9.45509, 8.55837, 7.929, 7.75422, 6.25516, 6.98075, 7.95726, 5.58602, 8.52811, 8.94976, 8.61675, 7.52203, 5.86654, 9.30841, 7.95983, 9.16498},
05205       {161.557, 60.9083, 42.7418, 32.6681, 28.4483, 23.0831, 20.1852, 16.6503, 14.3982, 12.9469, 10.4914, 10.6759, 9.05724, 8.21126, 8.46837, 9.92698, 7.71569, 6.7965, 8.87549, 6.0765, 7.88892, 7.22201, 8.13346, 8.88474, 11.2008, 10.4921, 8.34342, 10.0337},
05206       {91.718, 50.2739, 37.883, 32.7472, 24.9764, 23.3509, 19.3552, 17.9669, 15.5899, 13.3535, 11.3664, 9.74592, 9.19961, 7.76436, 7.74193, 7.18929, 6.40388, 8.6005, 6.88462, 10.8404, 8.72774, 7.46032, 9.74493, 9.06091, 8.81877, 8.50823, 11.0295, 15.2753},
05207       {72.4631, 47.222, 36.2746, 28.8782, 23.553, 24.7348, 18.7544, 18.437, 15.7064, 12.729, 11.0992, 10.1026, 8.40556, 7.96116, 8.09745, 6.41375, 6.51981, 6.63771, 8.47843, 7.66306, 8.95359, 10.2608, 8.83699, 8.72077, 10.7087, 7.27377, 13.6, 14.2494},
05208       {60.2763, 42.7498, 34.6623, 26.385, 25.4651, 21.7019, 19.0647, 15.8816, 14.2646, 12.5554, 10.8672, 9.43677, 8.44181, 7.59876, 7.81844, 6.11722, 8.516, 8.94197, 6.97098, 7.17371, 6.68615, 7.24368, 6.23672, 11.2857, 8.77067, 8.43604, 11.2313, 10.0775},
05209       {57.866, 41.2832, 33.3179, 27.3557, 23.8832, 20.5696, 17.8125, 15.5961, 14.4456, 12.0961, 9.76464, 9.34033, 7.73885, 7.76005, 7.44823, 7.55132, 7.13281, 5.57387, 6.08408, 6.99443, 6.28186, 6.48654, 6.99549, 5.28173, 7.53539, 6.92374, 8.62903, 12.2492}
05210     },
05211     {
05212       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05213       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05214       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05215       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05216       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05217       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05218       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05219       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05220       {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
05221       {269.647, 190.711, 88.8938, 70.894, 47.3717, 44.6289, 33.3552, 28.7616, 25.0309, 21.272, 17.9555, 14.7229, 14.5419, 11.7788, 13.5958, 10.8726, 7.98782, 10.1873, 8.92189, 9.84992, 7.93519, 10.66, 9.14665, 13.8959, 8.38381, 7.987, 15.2538, 11.2857},
05222       {235.853, 115.945, 85.6699, 62.6811, 48.3218, 46.3742, 32.8133, 27.8045, 23.4159, 20.5056, 16.0387, 15.324, 13.2206, 11.3368, 10.4307, 9.27748, 11.3733, 8.87551, 8.35207, 11.7778, 8.82057, 8.90268, 8.28021, 8.06991, 12.7847, 7.80538, 8.15497, 8.97099},
05223       {181.416, 96.6442, 73.0719, 54.7106, 42.9821, 37.438, 32.203, 27.5413, 22.6414, 19.4503, 17.7779, 14.5369, 13.0979, 13.7771, 10.4079, 9.45385, 13.0227, 8.50182, 7.17865, 10.9919, 15.7864, 8.76431, 8.51823, 5.92961, 9.18247, 10.5971, 9.3721, 15.4988},
05224       {139.491, 86.7362, 64.8339, 51.7932, 40.4078, 39.1071, 30.9617, 26.4873, 25.263, 20.3243, 16.5092, 14.4393, 12.175, 11.956, 10.8174, 9.08607, 7.18855, 10.0054, 11.1779, 7.12204, 9.47445, 6.93119, 8.93181, 8.61144, 11.0501, 6.27241, 9.95825, 14.4856},
05225       {106.141, 75.9413, 58.0517, 48.534, 42.3919, 33.3155, 31.0908, 25.4912, 22.6406, 19.3109, 16.0106, 14.2606, 12.5963, 11.0191, 11.1065, 9.09784, 9.07922, 8.92264, 7.34917, 7.71939, 7.41573, 8.73107, 6.43358, 17.2136, 9.26347, 8.55656, 10.9458, 12.6821},
05226                 {100.082, 76.8702, 55.0846, 48.6279, 40.6142, 34.3238, 29.3724, 26.3273, 25.1794, 19.6749, 16.3483, 14.3196, 12.3469, 11.8695, 11.738, 9.54169, 10.3128, 8.97389, 7.22238, 8.43618, 9.03957, 7.8851, 9.20503, 8.0428, 8.81155, 10.3738, 10.7343, 18.0864}
05227     }
05228   };
05229 
05230 float CSCTFPtMethods::Pt2StnChiSq(int type, float eta, int dphi, int fr) const
05231 {
05232 
05233   float diff, min, ptmin, ptmax;
05234   float mypt = 0.0;
05235 
05236   int dphicopy = dphi;
05237 
05238   if (type<0 || type>3) 
05239     {
05240 //      std::cout << "CSCTFPtMethods: illegal track type for Chi-square method" << std::endl;
05241       edm::LogError("CSCTFPtMethods::Pt2StnChiSq()")<<"Illegal track type for Chi-square method";
05242       return 0.;
05243     }
05244   
05245   // flip sign
05246   //dphi = -dphi;
05247   
05248   // force positive
05249   eta = fabs(eta);
05250   
05251   //determine which eta bin muon falls into
05252   int i = 0;
05253   for(i = 0; i < 15; i++) 
05254     {
05255       if (eta >= etabins[i] && eta < etabins[i+1]) break;
05256     }
05257   if ( i == 15 ) 
05258     {
05259 //      std::cout<<" CSCTFPtMethods: muon not within any eta range"<< std::endl;
05260       edm::LogWarning("CSCTFPtMethods::Pt2StnChiSq()")<<"Muon not within any eta range";
05261       if (eta<etabins[0]) 
05262         { 
05263           eta = etabins[0];
05264           i = 0;
05265         }
05266       else if (eta>=etabins[15]) 
05267         {
05268           eta = etabins[15];
05269           i = 15;
05270         }
05271       else
05272         exit(0);
05273     }
05274 
05275   bool bCallOldMethod = false;
05276   
05277   if (fr == 0) 
05278     {
05279       //advance past bins in array w/ default values
05280       //default is: dphifr0[x][y][z] = -1, sigmafr0[x][y][z] = 1
05281       int j = 0;  //start from 1st column, j=0
05282       while (dphifr0[type][i][j] == -1 && sigmafr0[type][i][j] == 1 && j != 28) j++;
05283       if ( j == 28 ) 
05284         {
05285 //        std::cout <<" CSCTFPtMethods: every entry in row is default"<< std::endl;
05286           edm::LogInfo("CSCTFPtMethods::Pt2StnChiSq()")<<"Every entry in row is default";
05287           //      exit(0); //normal termination
05288           bCallOldMethod = true;
05289         }
05290 
05291       if (!bCallOldMethod) 
05292         {
05293           //set min, ptmin, ptmax to first bin
05294           //in row that is not default
05295           min = fabs(dphi - dphifr0[type][i][j]) / sigmafr0[type][i][j];
05296           ptmin = ptbins[j];
05297           ptmax = ptbins[j+1];
05298           
05299           //loop through all pt bins.  assign pt of bin w/ least diff
05300           //do not include default bins in calculation
05301           for ( int k = j; k < 28; k++ ) 
05302             {
05303               if(dphifr0[type][i][k] != -1 || sigmafr0[type][i][k] != 1) 
05304                 {
05305                   diff = fabs(dphi - dphifr0[type][i][k]) / sigmafr0[type][i][k];
05306                   if (diff < min) 
05307                     {
05308                       min = diff;
05309                       ptmin = ptbins[k];
05310                       ptmax = ptbins[k+1];
05311                     }
05312                 }
05313             }
05314           mypt = (ptmin + ptmax)/2;
05315         }
05316     }
05317 
05318   if (fr == 1) 
05319     {
05320       //advance past bins in array w/ default values
05321       //default is: dphifr1[x][y][z] = -1, sigmafr1[x][y][z] = 1
05322       int j = 0;  //start from 1st column, j=0
05323       
05324       while (dphifr1[type][i][j] == -1 && sigmafr1[type][i][j] == 1 && j != 28) j++;
05325       
05326       if ( j == 28 ) 
05327         {
05328 //        std::cout <<" CSCTFPtMethods: every entry in row is default"<< std::endl;
05329           edm::LogInfo("CSCTFPtMethods::Pt2StnChiSq()")<<"Every entry in row is default";
05330           //      exit(0); //normal termination
05331           bCallOldMethod = true;
05332         }
05333 
05334     if (!bCallOldMethod) 
05335       {
05336         //set min, ptmin, ptmax to first bin
05337         //in row that is not default
05338         min = fabs(dphi - dphifr1[type][i][j]) / sigmafr1[type][i][j];
05339         ptmin = ptbins[j];
05340         ptmax = ptbins[j+1];
05341         
05342         //loop through all pt bins.  assign pt of bin w/ least diff
05343         //do not include default bins in calculation
05344         for ( int k = j; k < 28; k++ ) 
05345           {
05346             if(dphifr1[type][i][k] != -1 || sigmafr1[type][i][k] != 1) 
05347               {
05348                 diff = fabs(dphi - dphifr1[type][i][k]) / sigmafr1[type][i][k];
05349                 if (diff < min) 
05350                   {
05351                     min = diff;
05352                     ptmin = ptbins[k];
05353                     ptmax = ptbins[k+1];
05354                   }
05355               }
05356           }
05357         mypt = (ptmin + ptmax)/2;
05358       }
05359     }
05360 
05361   // hybrid approach:
05362   if (bCallOldMethod)
05363     {
05364       float dphiR = static_cast<float>(dphicopy) / static_cast<float>(1<<12) * CSCTFConstants::SECTOR_RAD;
05365       // must change type definition, just add one
05366       mypt =  Pt2Stn(type+1, eta, dphiR, fr);
05367     }
05368   
05369   return mypt;
05370 }
05371 
05372 
05373 float CSCTFPtMethods::Pt3StnChiSq(int type, float eta, int dphi1, int dphi2, int fr) const
05374 {
05375 
05376   float diff, min, ptmin, ptmax;
05377   float mypt = 0.0;
05378 
05379   int dphi1copy = dphi1, dphi2copy = dphi2;
05380 
05381   if (type<4 || type>5) 
05382     {
05383 //      std::cout << "PtParams: illegal track type for Chi-square method" << std::endl;
05384       edm::LogError("CSCTFPtMethods::Pt3StnChiSq()")<<"Illegal track type for Chi-square method";
05385       return 0.;
05386     }
05387 
05388   // flip sign
05389   //dphi1 = -dphi1; 
05390   //dphi2 = -dphi2; 
05391 
05392 
05393   //determine which eta bin muon falls into
05394   int i = 0;
05395   for( i = 0; i < 15; i++ ) 
05396     {
05397       if ( eta >= etabins[i] && eta < etabins[i + 1] ) break;
05398     }
05399   if ( i == 15 ) 
05400     {
05401       //std::cout<<"muon not within any eta range";
05402       edm::LogWarning("CSCTFPtMethods::Pt3StnChiSq()")<<"Muon not within any eta range";
05403       if (eta<etabins[0]) 
05404         { 
05405           eta = etabins[0];
05406           i = 0;
05407         }
05408       else if (eta>=etabins[15]) 
05409         {
05410           eta = etabins[15];
05411           i = 15;
05412         }
05413       else
05414         exit(0);
05415     }
05416 
05417   bool bCallOldMethod = false;
05418 
05419   if(abs(dphi2) < 32) dphi2 = 0; //dphi2=dphi23 or dphi24
05420 
05421   //sta1-2-3, dphi1=dphi12, dphi2=dphi23
05422   if (type == 4) 
05423     {
05424       if (fr == 0) 
05425         {
05426           //advance past bins in array w/ default values
05427           //default is: dphifr0[x][y][z] = -1, sigmafr0[x][y][z] = 1
05428           int j = 0;  //start from 1st column, j = 0
05429           while ( ((dphifr0[0][i][j] == -1 && sigmafr0[0][i][j] == 1) || (dphifr0[2][i][j] == -1 && sigmafr0[2][i][j] == 1)) && j != 28 ) j++;
05430           if ( j == 28 ) 
05431             {
05432 //            std::cout<<" L1MuCSCPtParams: every entry in row is default"<<std::endl;  
05433               edm::LogInfo("CSCTFPtMethods::Pt3StnChiSq()")<<"Every entry in row is default";
05434               //        exit(0); //normal termination
05435               bCallOldMethod = true;
05436             }
05437           
05438           if (!bCallOldMethod) 
05439             {
05440               //set min, ptmin, ptmax to first bin
05441               //in row that is not default
05442               min = 1.5625 * ( (pow((dphi1 - dphifr0[0][i][j]),2) / pow(sigmafr0[0][i][j],2)) + (pow((dphi2 - dphifr0[2][i][j]),2) / pow(sigmafr0[2][i][j],2)) - (1.2 * (dphi1 - dphifr0[0][i][j]) * (dphi2 - dphifr0[2][i][j]) / (sigmafr0[0][i][j] * sigmafr0[2][i][j])) ); //calculate chi square
05443               ptmin = ptbins[j];
05444               ptmax = ptbins[j + 1];
05445               
05446               //loop through all pt bins.  assign pt of bin w/ least diff
05447               //do not include default bins in calculation
05448               for ( int k = j; k < 28; k++ ) 
05449                 {
05450                   if( (dphifr0[0][i][k] != -1 || sigmafr0[0][i][k] != 1) && (dphifr0[2][i][k] != -1 || sigmafr0[2][i][k] != 1) ) 
05451                     {
05452                       diff = 1.5625 * ( (pow((dphi1 - dphifr0[0][i][k]),2) / pow(sigmafr0[0][i][k],2)) + (pow((dphi2 - dphifr0[2][i][k]),2) / pow(sigmafr0[2][i][k],2)) - (1.2 * (dphi1 - dphifr0[0][i][k]) * (dphi2 - dphifr0[2][i][k]) / (sigmafr0[0][i][k] * sigmafr0[2][i][k])) );
05453                       if (diff < min) 
05454                         {
05455                           min = diff;
05456                           ptmin = ptbins[k];
05457                           ptmax = ptbins[k + 1];
05458                         }
05459                     }
05460                 }
05461               mypt = (ptmin + ptmax) / 2;
05462             }
05463         }
05464       
05465       if (fr == 1) 
05466         {
05467           //advance past bins in array w/ default values
05468           //default is: dphifr1[x][y][z] = -1, sigmafr1[x][y][z] = 1
05469           int j = 0;  //start from 1st column, j = 0
05470           while ( ((dphifr1[0][i][j] == -1 && sigmafr1[0][i][j] == 1) || (dphifr1[2][i][j] == -1 && sigmafr1[2][i][j] == 1)) && j != 28 ) j++;
05471           if ( j == 28 ) 
05472             {
05473 //            std::cout<<" L1MuCSCPtParams: every entry in row is default"<<std::endl;  
05474               edm::LogInfo("CSCTFPtMethods::Pt3StnChiSq()")<<"Every entry in row is default";
05475               //        exit(0); //normal termination
05476               bCallOldMethod = true;
05477             }
05478 
05479           if (!bCallOldMethod) 
05480             {
05481               //set min, ptmin, ptmax to first bin
05482               //in row that is not default
05483               min = 1.5625 * ( (pow((dphi1 - dphifr1[0][i][j]),2) / pow(sigmafr1[0][i][j],2)) + (pow((dphi2 - dphifr1[2][i][j]),2) / pow(sigmafr1[2][i][j],2)) - (1.2 * (dphi1 - dphifr1[0][i][j]) * (dphi2 - dphifr1[2][i][j]) / (sigmafr1[0][i][j] * sigmafr1[2][i][j])) ); //calculate chi square
05484               ptmin = ptbins[j];
05485               ptmax = ptbins[j + 1];
05486               
05487               //loop through all pt bins.  assign pt of bin w/ least diff
05488               //do not include default bins in calculation
05489               for ( int k = j; k  < 28; k++ ) 
05490                 {
05491                   if( (dphifr1[0][i][k] != -1 || sigmafr1[0][i][k] != 1) && (dphifr1[2][i][k] != -1 || sigmafr1[2][i][k] != 1) ) 
05492                     {
05493                       diff = 1.5625 * ( (pow((dphi1 - dphifr1[0][i][k]),2) / pow(sigmafr1[0][i][k],2)) + (pow((dphi2 - dphifr1[2][i][k]),2) / pow(sigmafr1[2][i][k],2)) - (1.2 * (dphi1 - dphifr1[0][i][k]) * (dphi2 - dphifr1[2][i][k]) / (sigmafr1[0][i][k] * sigmafr1[2][i][k])) );
05494                       if (diff < min) 
05495                         {
05496                           min = diff;
05497                           ptmin = ptbins[k];
05498                           ptmax = ptbins[k + 1];
05499                         }
05500                     }
05501                   mypt = (ptmin + ptmax) / 2;
05502                 }
05503             }
05504         }
05505     }
05506   
05507   //sta1-2-4, dphi1=dphi12, dphi2=dphi24
05508   if (type == 5) 
05509     {
05510       
05511       if (fr == 0) 
05512         {
05513           //advance past bins in array w/ default values
05514           //default is: dphifr0[x][y][z] = -1, sigmafr0[x][y][z] = 1
05515           int j = 0;  //start from 1st column, j = 0
05516           while ( ((dphifr0[0][i][j] == -1 && sigmafr0[0][i][j] == 1) || (dphifr0[3][i][j] == -1 && sigmafr0[3][i][j] == 1)) && j != 28 ) j++;
05517           if ( j == 28 ) 
05518             {
05519 //            std::cout<<" L1MuCSCPtParams: every entry in row is default"<<std::endl;  
05520               edm::LogInfo("CSCTFPtMethods::Pt3StnChiSq()")<<"Every entry in row is default";
05521               //        exit(0); //normal termination
05522               bCallOldMethod = true;
05523             }
05524 
05525           if (!bCallOldMethod) 
05526             {
05527               //set min, ptmin, ptmax to first bin
05528               //in row that is not default
05529               min = 1.5625 * ( (pow((dphi1 - dphifr0[0][i][j]),2) / pow(sigmafr0[0][i][j],2)) + (pow((dphi2 - dphifr0[3][i][j]),2) / pow(sigmafr0[3][i][j],2)) - (1.2 * (dphi1 - dphifr0[0][i][j]) * (dphi2 - dphifr0[3][i][j]) / (sigmafr0[0][i][j] * sigmafr0[3][i][j])) ); //calculate chi square
05530               ptmin = ptbins[j];
05531               ptmax = ptbins[j + 1];
05532               
05533               //loop through all pt bins.  assign pt of bin w/ least diff
05534       //do not include default bins in calculation
05535               for ( int k = j; k < 28; k++ ) 
05536                 {
05537                   if( (dphifr0[0][i][k] != -1 || sigmafr0[0][i][k] != 1) && (dphifr0[3][i][k] != -1 || sigmafr0[3][i][k] != 1) ) 
05538                     {
05539                       diff = 1.5625 * ( (pow((dphi1 - dphifr0[0][i][k]),2) / pow(sigmafr0[0][i][k],2)) + (pow((dphi2 - dphifr0[3][i][k]),2) / pow(sigmafr0[3][i][k],2)) - (1.2 * (dphi1 - dphifr0[0][i][k]) * (dphi2 - dphifr0[3][i][k]) / (sigmafr0[0][i][k] * sigmafr0[3][i][k])) );
05540                       if (diff < min) 
05541                         {
05542                           min = diff;
05543                           ptmin = ptbins[k];
05544                           ptmax = ptbins[k + 1];
05545                         }
05546                     }
05547                 }
05548               mypt = (ptmin + ptmax) / 2;
05549             }
05550         }
05551       
05552       if (fr == 1) 
05553         {
05554           //advance past bins in array w/ default values
05555           //default is: dphifr1[x][y][z] = -1, sigmafr1[x][y][z] = 1
05556           int j = 0;  //start from 1st column, j = 0
05557           while ( ((dphifr1[0][i][j] == -1 && sigmafr1[0][i][j] == 1) || (dphifr1[3][i][j] == -1 && sigmafr1[3][i][j] == 1)) && j != 28 ) j++;
05558           if ( j == 28 ) 
05559             {
05560 //            std::cout<<" L1MuCSCPtParams: every entry in row is default"<<std::endl;  
05561               edm::LogInfo("CSCTFPtMethods::Pt3StnChiSq()")<<"Every entry in row is default";
05562               //        exit(0); //normal termination
05563               bCallOldMethod = true;
05564             }
05565           
05566           if (!bCallOldMethod) 
05567             {
05568               //set min, ptmin, ptmax to first bin
05569               //in row that is not default
05570               min = 1.5625 * ( (pow((dphi1 - dphifr1[0][i][j]),2) / pow(sigmafr1[0][i][j],2)) + (pow((dphi2 - dphifr1[3][i][j]),2) / pow(sigmafr1[3][i][j],2)) - (1.2 * (dphi1 - dphifr1[0][i][j]) * (dphi2 - dphifr1[3][i][j]) / (sigmafr1[0][i][j] * sigmafr1[3][i][j])) ); //calculate chi square
05571               ptmin = ptbins[j];
05572               ptmax = ptbins[j + 1];
05573               
05574               //loop through all pt bins.  assign pt of bin w/ least diff
05575               //do not include default bins in calculation
05576               for ( int k = j; k < 28; k++ ) 
05577                 {
05578                   if( (dphifr1[0][i][k] != -1 || sigmafr1[0][i][k] != 1) && (dphifr1[3][i][k] != -1 || sigmafr1[3][i][k] != 1) ) 
05579                     {
05580                       diff = 1.5625 * ( (pow((dphi1 - dphifr1[0][i][k]),2) / pow(sigmafr1[0][i][k],2)) + (pow((dphi2 - dphifr1[3][i][k]),2) / pow(sigmafr1[3][i][k],2)) - (1.2 * (dphi1 - dphifr1[0][i][k]) * (dphi2 - dphifr1[3][i][k]) / (sigmafr1[0][i][k] * sigmafr1[3][i][k])) );
05581                       if (diff < min) 
05582                         {
05583                           min = diff;
05584                           ptmin = ptbins[k];
05585                           ptmax = ptbins[k + 1];
05586                         }
05587                     }
05588                 }
05589               mypt = (ptmin + ptmax) / 2;
05590             }
05591         }
05592     }
05593     
05594   if (bCallOldMethod) 
05595     {
05596       float dphi12R = (static_cast<float>(dphi1copy)) / static_cast<float>(1<<12) * CSCTFConstants::SECTOR_RAD;
05597       float dphi23R = (static_cast<float>(dphi2copy)) / static_cast<float>(1<<12) * CSCTFConstants::SECTOR_RAD;
05598       // change defintion of track type to old method
05599       mypt =  Pt3Stn(type-3, eta, dphi12R, dphi23R, fr);
05600     }
05601   return mypt;
05602 
05603 }
05604 
05605 float CSCTFPtMethods::Pt2StnHybrid(int type, float eta, int dphi, int fr) const
05606 {
05607   float mypt = 0.0;
05608 
05609   mypt = Pt2StnChiSq(type, eta, dphi, fr);
05610   if(mypt >= 8.0)
05611     {
05612       float dphiR = static_cast<float>(dphi) / static_cast<float>(1<<12) * CSCTFConstants::SECTOR_RAD;
05613       mypt = Pt2Stn(type+1, eta, dphiR, fr);
05614     }
05615 
05616   return mypt;
05617 }
05618 
05619 float CSCTFPtMethods::Pt3StnHybrid(int type, float eta, int dphi1, int dphi2, int fr) const
05620 {
05621   float mypt = 0.0;
05622 
05623   mypt = Pt3StnChiSq(type, eta, dphi1, dphi2, fr);
05624   if(mypt >= 8.0)
05625     {
05626       float dphi12R = (static_cast<float>(dphi1)) / static_cast<float>(1<<12) * CSCTFConstants::SECTOR_RAD;
05627       float dphi23R = (static_cast<float>(dphi2)) / static_cast<float>(1<<12) * CSCTFConstants::SECTOR_RAD;
05628       // change defintion of track type to old method
05629       mypt =  Pt3Stn(type-3, eta, dphi12R, dphi23R, fr);      
05630     }
05631 
05632   return mypt;
05633 }
05634 
05635 bool CSCTFPtMethods::chargeValid(unsigned pT, unsigned quality, unsigned eta, unsigned method) const
05636 {
05637   bool result = false;
05638 
05639   switch(method)
05640     {
05641     case 1:
05642       break;
05643     case 2:
05644       break;
05645     case 3:
05646       if(quality != 1)
05647         {
05648           if(pT <= 19)
05649             {
05650               if(eta >=4 && eta <=9)
05651                 result = true;         
05652             }
05653           if(pT <= 18 && pT >= 10)
05654             {
05655               if(eta > 0 && eta < 4)
05656                 result = true;
05657             }
05658         }
05659     };  
05660   
05661   return result;
05662 }
05663 
05664 float CSCTFPtMethods::PtEff90(float pt, float eta, int mode) const
05665 {
05666   // set pT resolution 
05667   float c;
05668   switch (mode) 
05669     {
05670       // 3-stn with ME1
05671     case 2:
05672     case 3:
05673     case 4:
05674       // leave as 2 Stn for now:
05675       //        if (eta < 2.0)
05676       //            c = 0.2;
05677       //        else
05678       //            c = 0.2 + (eta-2.0)*0.5;
05679       //        break;
05680       // 2-stn with ME1
05681     case 6:
05682     case 7:
05683       //        c=(-.2999 * (eta*eta*eta) + 2.030 * (eta*eta) - 4.235 * eta + 3.024)+0.02;
05684       // Try just fixed value from fits to Pt turn-on curves
05685       c=0.3;
05686       break;
05687       // 2 or 3 stn without ME1
05688     case 5:
05689     case 8:
05690     case 9:
05691       c=(-2.484 * (eta*eta*eta) + 14.43 * (eta*eta) - 27.66 * eta + 18.47)*.72;
05692       break;
05693     case 10:
05694       c=2.0;
05695       break;
05696       // MB1 tracks
05697     case 11:
05698     case 12:
05699     case 13:
05700     case 14:
05701     case 15:
05702       c=0.3;
05703       break;
05704     default:
05705       c = 0.0;
05706     };
05707   // Calculation of 90% threshold from 50% one, assuming Gaussian resolution
05708   // 90% of Gaussian area extends to 1.28*sigma
05709   if (c>0.78) c = 0.78;
05710   //    return pt/(1.0 - 1.28*c);
05711   // Let's go back to old empirical method:
05712   return pt*(1.0 + 1.28*c);
05713 }