//--------------- // MakeTSpline. Dave Lawrence wrote this for mcsmear. //--------------- TSpline* MakeTSpline(void) { // These points are taken by mapping out figure 6 // of GlueX-doc-1795 (the "5ns" rise time pulse). double t[] ={ -7.00, -4.92, -0.75, 4.24, 9.37, // 5 9.71, 10.05, 10.39, 10.73, 11.07, 12.03, 12.92, 14.08, 16.05, // 10 18.56, 21.22, 24.31, 28.44, 32.92, // 15 38.64, 42.07, //47.10, //52.59, //58.22, // 20 67.95, 71.74, 79.85, 120.0, 125.0, // 25 130.0, 160.0, 180.0, -1000.0 // flag end of data }; double mV[]={ 0, 0, 0, 0, 0-1, // 5 -1.2, -1.4, -1.6, -1.8, 0-2, -49.16039931, -159.0483507, -375.9324653, -711.3798959, // 10 -902.2379167, -988.9915625, -1020.801233, -960.0736806, -850.1857292, // 15 -694.0291667, -601.4919445, //-539.29, //-419.88, //-300.46, // 20 -142.53, -100.15, -61.63, -8.0, -4.0, // 25 -2.0, -1.0, 0.0, -1000.0 // flag end of data }; // Find number points int Npoints=0; while(true){ if(t[Npoints]==-1000.0 && mV[Npoints]==-1000.0)break; Npoints++; } TSpline *s = new TSpline3("spline", t, mV, Npoints); return s; }