/////////////////////////////////////////////////////////////////////////////// // /////////////////////////////////////////////////////////////////////////////// //_____________________________________________________________________________ TGraph* cteq5l_pdf(Double_t Q, Int_t IPart) { // distribution for x^(5/3)*G(x,Q) int const np = 1000; double xx, x[np], y[np]; double uv, dv, usea, dsea, str, chrm, bot, top, glue; TCteq6* cteq6 = TCteq6::Instance(); for (int i=0; iStructm(xx,Q,uv,dv,usea,dsea,str,chrm,bot,top,glue); if (IPart == 0) { y[i] = glue; } else if (IPart == 1) { y[i] = uv+usea; } else if (IPart == -1) { y[i] = usea; } else if (IPart == 2) { y[i] = dv+dsea; } else if (IPart == -2) { y[i] = dsea; } printf(" x, y = %10.6f %10.6f \n",x[i],y[i]); } TGraph* gr = new TGraph(np,x,y); return gr; } //_____________________________________________________________________________ void test2(Double_t Q, Int_t IPart) { // check CTEQ5L functions TH2F* h = new TH2F("h","CTEQ5L",1000,0,1.,1,0,1); h->GetXaxis()->SetTitle("X"); char parm[20][20]; double val[20]; strcpy(parm[0],"NPTYPE"); parm[0][6] = ' '; val [0] = 1; strcpy(parm[1],"NGROUP"); parm[1][6] = ' '; val [1] = 4; strcpy(parm[2],"NSET"); parm[2][6] = ' '; val [2] = 32; TCteq6* cteq6 = TCteq6::Instance(); cteq6->Pdfset((const char*) parm,val); TGraph* gr_glue = cteq5l_pdf(Q,IPart); h->Draw(); gr_glue->Draw(); }