All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
2DoubleFuncTest.cpp
Go to the documentation of this file.
1 // ============================================================================
2 // Include files
3 // ============================================================================
4 // STD & STL
5 // ============================================================================
6 #include <math.h>
7 #include <stdio.h>
8 // ============================================================================
9 // GaudiMath
10 // ============================================================================
11 #include "GaudiMath/GaudiMath.h"
12 #include "GaudiMath/Adapters.h"
13 // ============================================================================
14 
15 // ============================================================================
23 // ============================================================================
24 
25 int main()
26 {
27  const GaudiMath::Function& mypow = GaudiMath::adapter ( pow );
28  Genfun::Argument arg(2);
29  for ( double x = 0; x < 10; ++x)
30  {
31  for (double y = 0; y < 10; ++y)
32  {
33  arg[0] = x;
34  arg[1] = y;
35  printf ("x=%6.5f y=%6.5f mypow=%+.10f pow=%+.10f pow-mypow=%+.10f \n",
36  x, y, mypow(arg), pow(x, y),
37  pow(x, y) - mypow(arg) );
38  }
39  }
40 
41  exit(0);
42 
43 }
Genfun::AbsFunction Function
Definition: GaudiMath.h:24
int main()
GAUDI_API AIDAFunction adapter(const AIDA::IFunction &function)
Definition: Adapters.cpp:27