//================================================================= // // Calcluate the chargino masses as function of M2, mu to get the // bounds on those parameters. // // $Id: $ // // Last change: // // Author : Alexander Wagner // Language : root // //================================================================= // Double_t Function( double x, double y) { Double_t z = x**2+y**2; return(z); } void Sample() { const Int_t xdim = 600; const Int_t ydim = 400; const Int_t xbins = 100; const Int_t ybins = 100; const Double_t xmin = 0.; const Double_t xmax = 1000.; const Double_t ymin = 0.; const Double_t ymax = 1000.; const Double_t excl = 600.0e3; Double_t z; c1 = new TCanvas("c1","",200,10,xdim,ydim); TH2F *Histo= new TH2F("histo", "", xbins, xmin, xmax, ybins, ymin, ymax); for( Double_t x = xmin; x < xmax; x += (xmax-xmin)/xbins) { for(Double_t y = ymin; y < ymax; y += (ymax-ymin)/ybins) { z = Function(x,y); Histo->SetBinContent(Histo->FindBin(x,y), z); } } Double_t contours[1]; contours[0] = excl; Histo->SetContour(1, contours); Histo->Draw("cont4Z"); }