#include <iostream>
#include <cmath>
#include <iomanip>
int main()
{
std::cout << qg << std::endl;
std::cout << "\nAccuracy test:" << std::endl;
double nQ = 20;
double Qmin = 1.1;
double Qmax = 999.;
double Step = exp( log( Qmax / Qmin ) / ( nQ - 1 ) );
double Q = Qmin;
std::cout << std::setprecision(8) << std::scientific;
std::cout << "Q \t\tDirect \t\tInterpolated\t\tRatio" << std::endl;
for (int iQ = 0; iQ < nQ; iQ++)
{
std::cout << Q << "\t\t" << as.Evaluate(Q) << "\t\t" << gas.Evaluate(Q) << "\t\t" << as.Evaluate(Q) / gas.Evaluate(Q) << std::endl;
Q *=Step;
}
std::cout << "\nPerformance test:" << std::endl;
nQ = 100000;
Step = exp( log( Qmax / Qmin ) / ( nQ - 1 ) );
std::cout << "Direct calculation of " << nQ << " points... ";
Q = Qmin;
for (int iQ = 0; iQ < nQ; iQ++)
{
as.Evaluate(Q);
Q *= Step;
}
std::cout << "Interpolated calculation of " << nQ << " points... ";
Q = Qmin;
for (int iQ = 0; iQ < nQ; iQ++)
{
gas.Evaluate(Q);
Q *= Step;
}
return 0;
}
The AlphaQCD is a specialization class of the MatchedEvolution class for the computation of the QCD c...
Definition alphaqcd.h:21
The template class QGrids is a mother class for the interpolation in Q. This class also implements me...
Definition qgrid.h:23
The template TabulateObject class is a derived of the QGrid class that tabulates on object of type T ...
Definition tabulateobject.h:26
The Timer class computes the time elapsed between start and stop.
Definition timer.h:20
void stop(bool const &ForceDisplay=false)
This function stops the timer and reports the elapsed time in seconds since the last time the timer w...
Definition timer.h:36
void start()
This function starts the timer.
Definition timer.h:30