/home/bes3soft/bes3soft/Boss/7.0.2/dist/7.0.2/Generator/Mcgpj/Mcgpj-00-01-04/src/code/src/getff.C File Reference

#include "TPiFormFactor.h"
#include "TRadGlobal.h"
#include "TConstants.h"
#include <iostream>
#include <complex>
#include <stdexcept>

Go to the source code of this file.

Functions

int main (unsigned int argc, char **argv)


Function Documentation

int main ( unsigned int  argc,
char **  argv 
)

Definition at line 11 of file getff.C.

References abs, conj(), TFormFactor::Eval(), fPi, gConst, gGlobal, genRecEmupikp::i, TFormFactor::Init(), TRadGlobal::Init(), TRadGlobal::Set_dE_Abs(), TRadGlobal::Set_E(), TRadGlobal::Set_RelativeError(), TRadGlobal::Set_Theta0_Rel(), TRadGlobal::Set_ThetaInt(), TRadGlobal::Set_ThetaMin(), TRadGlobal::Set_TotalError(), and TRadGlobal::Set_Type().

00011                                         {
00012   gConst = new TConstants();
00013   gGlobal = new TRadGlobal();
00014   gGlobal->Set_Type(2);
00015   gGlobal->Set_E(800.);
00016   gGlobal->Set_ThetaMin(0.9);
00017   gGlobal->Set_dE_Abs(0.1);
00018   gGlobal->Set_Theta0_Rel(1);
00019   gGlobal->Set_ThetaInt(0.6);
00020   gGlobal->Set_TotalError(1.);
00021   gGlobal->Set_RelativeError(0.01);
00022   
00023   try{
00024     gGlobal->Init();
00025   }catch(std::logic_error lge){
00026     cout<<lge.what()<<endl;
00027     return 1;
00028   }
00029   
00030   TPiFormFactor *fPi = new TPiFormFactor();
00031   fPi->Init();
00032   for (unsigned int i = 1; i < argc; i++){
00033     double e = atof(argv[i]);
00034     complex<double> f = fPi->Eval(4*e*e);
00035     cout<<abs(f*conj(f))<<endl;
00036   }
00037   /*
00038   double En[] = {185, 195, 205, 215, 225, 235, 240, 250, 255, 260};
00039   for (unsigned int i = 0; i < 10; i++){
00040     double e = En[i];
00041     double beta = sqrt(e*e - gConst->Mpi2())/e;
00042     complex<double> f = fPi->Eval(4*e*e);
00043     double cs0 = pow(beta,3)/pow(e,2)*abs(f*conj(f));
00044 
00045     e = 1.001*En[i];
00046     beta = sqrt(e*e - gConst->Mpi2())/e;
00047     f = fPi->Eval(4*e*e);
00048     double cs1 = pow(beta,3)/pow(e,2)*abs(f*conj(f));
00049 
00050     cout<<En[i]<<" "<<(cs1-cs0)/cs0*100<<endl<<flush;
00051   }
00052   */
00053 }


Generated on Tue Nov 29 23:16:41 2016 for BOSS_7.0.2 by  doxygen 1.4.7