Daya Bay Muon System Simulation and Analysis Debabrata Mohapatra Virginia Tech 04/07/2010
Daya Bay Muon SystemSimulation and Analysis
Debabrata Mohapatra
Virginia Tech
04/07/2010
Daya Bay Backgrounds
Purpose of Muon System
Daya Bay Muon System
Detailed Geometry
FAR
Near
Muon related Analysis topics (Wei’s List)
Daya Bay Framework: NuWaNuwa is installed at “/home/dayabay/nuwa”
externals
• CMT, Boost
• AIDA, GSL, clhep, XercesC Geant4, OpenMotif, OpenScientist
• Python, Cmake, mysql
• ROOT
Nuwa-release
• lcgcmt, ldm, relax
• Gaudi
• lhcb
• dybgaudi#!/bin/tcsh
pushd /home/dayabay/nuwa/NuWa-trunk
source setup.csh
popd
pushd /home/dayabay/nuwa/NuWa-trunk/dybgaudi/DybRelease/cmt
source setup.csh
popd
Stages of Daya Bay Simulation
Muon fluxes at the three sites are used for event generation
Pass the muon events through Geant4 detector simulation to get hits in PMTs.
Near
Far
How to write Analysis modulein Python
from DybPython.DybPythonAlg import DybPythonAlg
from GaudiPython import SUCCESS, FAILURE
from GaudiPython import gbl
from DybPython.Util import irange
# Make shortcuts to any ROOT classes you want to use
TTree = gbl.TTree
# Define the algorithm
class TreeAlg(DybPythonAlg):
"Tree-writing Python Algorithm"
def __init__(self,name):
DybPythonAlg.__init__(self,name)
return
def initialize(self)
# Initialize services
# Statistics Service: Use for histograms, graphs, trees
# Make a tree
return SUCCESS
def execute(self):
# Access current data
# Set Branch values
# Loop over hits in each detector
# Fill the tree with current branch values
return SUCCESS
def finalize(self):
return status
def configure():
from StatisticsSvc.StatisticsSvcConf import StatisticsSvc
statsSvc = StatisticsSvc()
statsSvc.Output ={"file0":"simHitStats.root"}
return
def run(app):
'''
Configure and add an algorithm to job
'''
app.ExtSvc += ["StatisticsSvc"]
example = TreeAlg("MyTreeExample")
app.addAlgorithm(example)
pass
/home/dayabay/nuwa/NuWa-trunk/tutorial/DivingIn/python/DivingIn
Writing Analysis Package in C++Example: /home/dayabay/nuwa/NuWa-trunk/tutorial/Sim15
Subdirectory
Content
cmt requirementsversion.cmt
src Sim15_entries.ccSim15_load.ccAna15.ccAna15.hValidationTree.ccValidationTree.h
python Sim15/ana.py
share Other scripts
Cmt: configuration management environment
package Sim15
use Stage * Simulation/Fifteen
use ReadoutEvent v* DataModel
use SimReadoutEvent v* DataModel
use SimTrigEvent v* DataModel
use ElecEvent v* DataModel
use SimEvent v* DataModel
use GenEvent v* DataModel
include_dirs "${SIM15ROOT}"
library Sim15 *.cc
apply_pattern component_library library=Sim15
apply_pattern install_python_modules
Requirement file> source /home/dayabay/paths.sh
Copy the tutorial directory
to your home page
Go to Sim15/cmt
> cmt config
It will produce setup scripts for
environment
source setup.sh
And then compile the package using
cmt make
Then go to python/Sim15 to run ana.py
nuwa.py -n -1 -m ana /home/dayabay/montecarlo/muon/MDCMUON_VTEC_D5990.root