test_gausTF1.cxx
Go to the documentation of this file.
1 // test_gausTF1.cxx
2 
3 // David Adams
4 // November 2018
5 //
6 // This is a test and demonstration for gausTF1.
7 
8 #undef NDEBUG
9 
11 #include <string>
12 #include <iostream>
13 #include <iomanip>
14 #include <vector>
15 #include <cassert>
16 
17 using std::string;
18 using std::cout;
19 using std::endl;
20 using std::setw;
21 using std::vector;
22 
23 using Index = unsigned int;
24 
25 //**********************************************************************
26 
27 int test_gausTF1() {
28  const string myname = "test_gausTF1: ";
29  cout << myname << "Starting test" << endl;
30 #ifdef NDEBUG
31  cout << myname << "NDEBUG must be off." << endl;
32  abort();
33 #endif
34  string line = "-----------------------------";
35  string scfg;
36 
37  cout << myname << line << endl;
38  cout << "Testing TF1." << endl;
39 
40  cout << myname << line << endl;
41  cout << "Build function." << endl;
42  TF1* pf = gausTF1(20, 50, 10, "mygaus");
43  pf->Print();
44  return 0;
45 }
46 
47 //**********************************************************************
48 
49 int main() {
50  return test_gausTF1();
51 }
52 
53 //**********************************************************************
int test_gausTF1()
std::string string
Definition: nybbler.cc:12
struct vector vector
unsigned int Index
TF1 * gausTF1(double heightIn, double meanIn, double sigmaIn, std::string fname)
Definition: gausTF1.cxx:28
Q_EXPORT QTSManip setw(int w)
Definition: qtextstream.h:331
int main()
void line(double t, double *p, double &x, double &y, double &z)
QTextStream & endl(QTextStream &s)