Example program to test user class with arithmetic capabilities (based on class JMATH::JMath).  
More...
#include <string>
#include <iostream>
#include <iomanip>
#include "TRandom3.h"
#include "JLang/JException.hh"
#include "JMath/JMath.hh"
#include "JMath/JMathToolkit.hh"
#include "Jeep/JPrint.hh"
#include "Jeep/JParser.hh"
#include "Jeep/JMessage.hh"
 
Go to the source code of this file.
 | 
| int  | main (int argc, char **argv) | 
|   | 
Example program to test user class with arithmetic capabilities (based on class JMATH::JMath). 
- Author
 - mdejong 
 
Definition in file JMath.cc.
 
      
        
          | int main  | 
          ( | 
          int  | 
          argc,  | 
        
        
           | 
           | 
          char **  | 
          argv  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Definition at line 117 of file JMath.cc.
  126     JParser<> zap(
"Example program to test user class with arithmetic capabilities.");
 
  133   catch(
const exception &error) {
 
  134     FATAL(error.what() << endl);
 
  142   const Double_t xmin = -1.0;
 
  143   const Double_t xmax = +1.0;
 
  146   const JObject A(gRandom->Uniform(xmin, xmax),
 
  147                   gRandom->Uniform(xmin, xmax),
 
  148                   gRandom->Uniform(xmin, xmax));
 
  150   const JObject B(gRandom->Uniform(xmin, xmax),
 
  151                   gRandom->Uniform(xmin, xmax),
 
  152                   gRandom->Uniform(xmin, xmax));
 
  154   cout << 
"A           " << 
A << endl;
 
  155   cout << 
"B           " << B << endl;
 
  156   cout << 
"interpolate " << 
interpolate(
A, B, alpha) << endl;
 
  158   cout << 
"A + B     = " << 
A + B << endl;
 
  160   cout << 
"A * " << noshowpos << 
FIXED(5,2) << alpha << 
" = " << 
A * alpha << endl;
 
Utility class to parse command line options. 
 
T interpolate(const T &first, const T &second, const double alpha)
Interpolation between objects. 
 
Auxiliary data structure for floating point format specification. 
 
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object 
 
Auxiliary base class for inline creation of a static value or clone from a temporary object...
 
source $JPP_DIR setenv csh $JPP_DIR eval JShellParser o a A