In the macro I have attached below, what I intend to do is calculate value of pi using monte-carlo simulation for various values of “n”. Currently, I have five different values of n and it will give me five different values of pi. I want to store those values of pi in an array called Pi_val and then plot nTotal against Pi_val. It does not work and gives me
Can’t call TGraph::TGraph(5,nTotal,Pi_val) in current scope montecarloforum2.C:
Could anyone help me figure this out? I honestly think that it might be just a mistake in coding than my inability to understand ROOT TGraph or maybe both. Any help would be very much appreciated.
ROOT Version: 5.34/38
Platform: Ubuntu
Compiler: Not Provided
montecarloforum2.C (863 Bytes)