Notes on using the ROOT libraries in standalone C++ programs Starting with problem sheet 6 you will need to write C++ programs that use classes from the ROOT library, and you will also produce plots with the program root. To do this on linappserv1 you need to make a small modification to your set-up. On other computers the procedure should be similar. Go to your home directory and type ls -la. You will see that you have a file called .cshrc (it starts with a dot). This is a file that gets executed when you login and it sets up your environment. You will see in it lines of the form "setenv LESS -M" and other commands. Using your preferred text editor, insert in this file (e.g., below the setenv commands) the line source /usr/local/root/v5.20.00/slc4.gcc3.4/setup.csh Save the file and then enter source .cshrc You only have to do this once, as it will now automatically be done every time you log in. This defines some things needed to work with the ROOT libraries. Alternatively you can simply copy the file /usr/local/root/v5.20.00/slc4.gcc3.4/setup.csh to your local area and type source setup.csh whenever you want to use the ROOT libaraies. For people not at RHUL, the location of the setup.csh file should be similar -- it should work (I think) if you copy the setup.csh file from the web page above. Note that if you're using a shell other than C or TC, you should use the file setup.sh (not setup.csh). Once you have done the above, download the files from http://www.pp.rhul.ac.uk/~cowan/stat/root/mc/ into a convenient subdirectory and build the program simpleMC by typing gmake. More info as well as instructions on how to produce plots with the program root can be found in the file readme.txt in the web area above. More general information about root can be found at root.cern.ch. Glen Cowan 11 November, 2008