{ const int n=20; // Arithmos simeiwn grafimatos double x[n], y[n]; // Pinakes dedomenwn for(int i=0; i<20; ++i){ x[i]=i*0.1; y[i]=10*sin(x[i] +0.2); } TGraph *gr = new TGraph(n,x,y); // Orismos toy grafimatos TCanvas *c1 = new TCanvas("c1", "Grafima", 700,400) ; c1->cd(); gr->Draw("A*"); // Sxediasmos grafimatos }