Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
Introduction to the ROOT data analysis frameworkshort blurb | ||||||||
Line: 27 to 26 | ||||||||
If you do not yet have the bash shell for Windiws 10 installed and configured, follow the instructions at WindowsBashShell | ||||||||
Added: | ||||||||
> > | From here the steps are identical to installing it on Linux with only a few extra steps in the beginning. 1. Start by installing a full Ubuntu distrobution, the bash shell includes a very basic distro of ubuntu with only the most essential packages, by installing a full distro, you can ensure | |||||||
On Linux... |
Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
Introduction to the ROOT data analysis framework | ||||||||
Added: | ||||||||
> > | ||||||||
short blurb | ||||||||
Line: 8 to 10 | ||||||||
The ROOT software package is available for use on the desktop cluster as well as on the Tier3 for MSU ATLAS members. It is also available for download on the ROOT website https://root.cern.ch/.
On the desktop cluster | ||||||||
Added: | ||||||||
> > | ||||||||
On the desktop cluster the current recommended ROOT version (5.26/00 64-bit) is configured for use by default. Other versions of ROOT can be run by sourcing the setup script for the particular version located in /cern/root/vX.XX.XX/ . For example, to setup ROOT version 5.24/00: | ||||||||
Added: | ||||||||
> > | ||||||||
Changed: | ||||||||
< < | source /cern/root/v5.24.00/rootsetup.sh | |||||||
> > | source /cern/root/v5.24.00/rootsetup.sh | |||||||
Please refrain from setting up your own local ROOT version on the desktop cluster. If there is a particular version you would like to use, please contact
On a personal laptop or computer | ||||||||
Line: 19 to 24 | ||||||||
...
On Windows 10 using the bash shell | ||||||||
Changed: | ||||||||
< < | ... | |||||||
> > | If you do not yet have the bash shell for Windiws 10 installed and configured, follow the instructions at WindowsBashShell | |||||||
On Linux | ||||||||
Added: | ||||||||
> > | ||||||||
...
On the Tier3 | ||||||||
Line: 42 to 51 | ||||||||
Google is your new best friend. If you are trying to figure out how to use a TH1 and what methods are available to it, searching "ROOT TH1" on Google is a great way to start. | ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
| ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
| ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
| ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
| ||||||||
Line: 64 to 75 | ||||||||
For this part, f(x) is the following function: f(x) = - x*x + 4 (use TGraph or TF1 to draw the function). | ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
| ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
| ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
Part 2 | ||||||||
Added: | ||||||||
> > | ||||||||
For this part, g(x) is the following function: g(x) = pow(x,-3) for x between 0.1 and 10.1 | ||||||||
Line: 79 to 91 | ||||||||
For this part, g(x) is the following function: g(x) = pow(x,-3) for x between 0.1 and 10.1 | ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
-- EmilyJohnson - 20 Sep 2016 |
Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
Introduction to the ROOT data analysis frameworkshort blurbContents:
Getting ROOT | ||||||||
Changed: | ||||||||
< < |
On the HEP cluster | |||||||
> > |
The ROOT software package is available for use on the desktop cluster as well as on the Tier3 for MSU ATLAS members. It is also available for download on the ROOT website https://root.cern.ch/.
On the desktop clusterOn the desktop cluster the current recommended ROOT version (5.26/00 64-bit) is configured for use by default. Other versions of ROOT can be run by sourcing the setup script for the particular version located in/cern/root/vX.XX.XX/ . For example, to setup ROOT version 5.24/00:
source /cern/root/v5.24.00/rootsetup.shPlease refrain from setting up your own local ROOT version on the desktop cluster. If there is a particular version you would like to use, please contact | |||||||
On a personal laptop or computer | ||||||||
Added: | ||||||||
> > |
On the Tier3 | |||||||
A simple macro tutorial |
Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
Introduction to the ROOT data analysis frameworkshort blurb | ||||||||
Changed: | ||||||||
< < | ||||||||
> > | ||||||||
Getting ROOTOn the HEP clusterOn a personal laptop or computer | ||||||||
Added: | ||||||||
> > |
A simple macro tutorial | |||||||
ExercisesUse the following exercises to get acquainted with writing ROOT and C++ code. Discuss your results with mentors and other students. | ||||||||
Changed: | ||||||||
< < | Exercise 1) | |||||||
> > |
Exercise 1 | |||||||
For the following exercise you will need to look through the ROOT documentation to figure out how to: | ||||||||
Changed: | ||||||||
< < | -Create a TCanvas, draw objects on it, and save it as a pdf. -Use TRandom3 to: -Generate uniform random numbers between 0 and 10. -Generate Gaussian random numbers with (Mean = 5 and RMS = 1). -Create and fill a 1D histogram (TH1, TH1D, TH1F). -Create a TF1 and fit it to a 1D histogram. Hint: Google is your new best friend. If you are trying to figure out how to use a TH1 and what methods are available to it, searching "ROOT TH1" on google is a great way to start. Part 1 Step 1: You need two separate codes. a) In the first code, generate 10000 Uniform random numbers and fill a histogram with these numbers. b) In the second code, generate 10000 Gaussian random numbers and fill a histogram with these numbers. c) For both cases, check if the distributions are as expected. (to check, you need to fit the distributions with analytical functions, ask me if you don't know how to fit a distribution). Step 2: In a new code: a) Generate 10000 random numbers in total (Uniform and Gaussian). The generation of Uniform and Gaussian random numbers should be done randomly (without any order). b) The ratio between the Gaussian generated numbers to the Uniform generated numbers should be around 1/10. c) Create a new histogram and fill these 10000 random numbers. Step 3: Repeat step 2, but make it two separate codes: Hint: Don't overwrite your old code, make new files. a) In the first code, generate the random numbers and put them in a text file. b) In the second code, read the numbers from the text file and fill a histogram with them. Then save the histogram in a root file. Part 2 Step 4: Read the histogram from the root file created in Step 3. Then, with an analytical function, fit this histogram: a) Using the Fit method in ROOT. b) Without using the Fit method in ROOT. Exercise 2) | |||||||
> > |
| |||||||
Added: | ||||||||
> > |
Exercise 2 | |||||||
Now that you have had some practice with ROOT and searching through the ROOT documentation, see if you can figure out what you will need to do on your own. | ||||||||
Changed: | ||||||||
< < | Part 1 For the following part, f(x) is the following function: f(x) = - x*x + 4 (use TGraph or TF1 to draw the function). Step 0: Calculate analytically the integral of f(x) for x between -2 and +2. Step 1: Calculate numerically the integral of f(x) for x between -2 and +2 with Monte-Carlo method. Hint: The integral of f(x) between x=a and x=b is the surface S between f(x) and the lines x=a, x=b, and y=0. a) Define a rectangle containing the surface S. b) Generate ("Uniform") random points in the rectangle and check the fraction of points in the surface S. c) Make a plot with the function f(x) and the generated points. Step 2: Calculate the same integral numerically by filling the surface S with rectangles. a) Use a histogram with a given binning (each bin is a rectangle). b) Repeat this step with 3 different binnings. c) Make 3 different plots. One plot for each histogram. On each plot, draw f(x). Step 3: Explain/Interpret/Analyze the differences between the different results. (Where are the differences coming from? When will they be equal? Why?) Part 2 | |||||||
> > |
Part 1For this part, f(x) is the following function: f(x) = - x*x + 4 (use TGraph or TF1 to draw the function).
| |||||||
Changed: | ||||||||
< < | For the following part, g(x) is the following function: | |||||||
> > |
Part 2For this part, g(x) is the following function: | |||||||
g(x) = pow(x,-3) for x between 0.1 and 10.1 | ||||||||
Changed: | ||||||||
< < | Step 1 : On the same canvas, draw 2 plots of g(x), one on the left and one on the right. On the left keep g(x) in linear scale (default), on the right set the x and y axis to logarithmic scale. Step 2 : Calculate the integral of g(x) for x between 0.1 and 10.1 with Monte-Carlo method generating only 1000 points (as you did in the part 1). Draw the points on the plots. Step 3 : Compare the numerical integral with the analytical integral. Can you find a method to have a more precise numerical result by only generating 1000 points? | |||||||
> > |
| |||||||
-- EmilyJohnson - 20 Sep 2016 |