CBM Simulation - PowerPoint PPT Presentation

1 / 22
About This Presentation
Title:

CBM Simulation

Description:

closer to technical drawings and analysis coordinate systems. 10.03.2005 ... fRun- AddModule(Cave); CbmModule *Target= new CbmTarget('Target' ... – PowerPoint PPT presentation

Number of Views:27
Avg rating:3.0/5.0
Slides: 23
Provided by: mohammad54
Category:

less

Transcript and Presenter's Notes

Title: CBM Simulation


1
CBM Simulation Analysis FrameworkCbmroot
  • Mohammad Al-Turany
  • Denis Bertini
  • Ilse König

2
CBM Framework Features
  • The same framework can be used for Simulation and
    Analysis
  • Fully ROOT based
  • VMC for simulation
  • Geometry Modeller (TGeoManager) Overlaps
    checking, visualization and/or navigation system
    of G3
  • IO scheme (TChain, friend TTrees, TFolders ) for
    persistency
  • TTask to organize analysis data flow
  • Completely configurable via ROOT macros
  • Easy to maintain (only ROOT standard services are
    used)
  • Reuse of HADES Geometry Interface.
  • Reuse of HADES Parameter containers.
  • Event merging before and/or after transport

3
CBM Simulation (Old)
ROOT
Geant3
Geometry Manager
Virtual MC
Geant4
Root files MCPoints, Configuration
FLUKA
Magnet
Target
IO Manager
Run Manager
GeoInterface
PIPE
Primary Generator
Cave
Module
STS
Magnetic Field
Urqmd
Detector
Tasks
EVGEN
TRD
Pluto
TOF
Particle Generator
RICH
Delta
Tracking
Field Map
ASCII
digitizers
ECAL
4
CBM Simulation
ROOT
Geant3
Root files MCPoints
Geometry Manager
Virtual MC
Magnet
Geant4
Target
FLUKA
PIPE
Run Manager
IO Manager
GeoInterface
Cave
RunTime DataBase
Module
Primary Generator
STS
Root files Configuration, Parameters, Geometry
TRD
Magnetic Field
Detector
EVGEN
Tasks
TOF
RICH
Particle Generator
Field Map
ECAL
Pluto
ASCII
Urqmd
5
CBM Analysis (Old)
ROOT
ROOT FILES Input MC Points, Configuration Output
Hits, Digits, Tracks
Geometry Manager
Virtual MC
IO Manager
Run Manager
GeoInterface
Primary Generator
Module
Magnetic Field
Detector
Tasks
EVGEN
Delta
Tracking
digitizers
6
CBM Analysis
Root files MCPoints, Hits, Digits, Tracks
IO Manager
Run Manager
GeoInterface
RunTime DataBase
Module
Primary Generator
Magnetic Field
Detector
EVGEN
Tasks
Root files Configuration, Parameters, Geometry
Delta
Tracking
digitizers
7
CBM Geometry Interface
  • Use the copy mechanism
  • reduce the size of ASCII files
  • Reduce the number of Volumes in Geant
  • Improve Geant tracking performance
  • Oracle interface
  • Hades geometry table design reusable
  • Advantage
  • more flexibility different inputs can be used.
  • closer to technical drawings and analysis
    coordinate systems

8
Material Geometry Interface
Oracle DB
TGeo Geometry/Material TGeoVolume TGeoNode TGeoMat
erial
CbmGeoInterface
ASCII
G3 Geometry/Material
RootBuilder
G3Builder
9
Simulation Macro loading Libs
// Load basic libraries gROOT-gtLoadMacro("VMC
WORKDIR/gconfig/basiclibs.C") basiclibs()
// Load Cbmroot libraries gSystem-gtLoad("lib
GeoBase") gSystem-gtLoad("libCbm")
gSystem-gtLoad("libPassive") gSystem-gtLoad("li
bGen") gSystem-gtLoad("libSts")
gSystem-gtLoad("libTrd") gSystem-gtLoad("libTof
") gSystem-gtLoad("libRich") .........
10
Simulation Macro
  • //create the Simulation Run Class
  • CbmRunSim fRun new CbmRunSim()
  • // set the MC version used
  • fRun-gtSetName("TGeant3") //for G4 use
    "TGeant4"
  • fRun-gtSetGeoModel("G3Native") //use G3
    native geometry
  • // chose an output file name
  • fRun-gtSetOutputFile("test.root")

11
Simulation Macro- Create Modules
  • CbmModule Cave new CbmCave("WORLD")
  • Cave-gtSetGeometryFileName("PASSIVE/CAVE",
    "v03a")
  • fRun-gtAddModule(Cave)
  • CbmModule Target new CbmTarget("Target")
  • Target-gtSetGeometryFileName("PASSIVE/TARGET",
    "v03a")
  • fRun-gtAddModule(Target)
  • CbmModule Pipe new CbmPIPE("PIPE")
  • Pipe-gtSetGeometryFileName("PASSIVE/PIPE",
    "v03a")
  • fRun-gtAddModule(Pipe)
  • CbmModule Magnet new CbmMagnet("MAGNET")
  • Magnet-gtSetGeometryFileName("PASSIVE/MAGNET",
    "v03a")
  • fRun-gtAddModule(Magnet)

12
Simulation Macro- Create Detectors
  • CbmDetector STS new CbmSts("STS", kTRUE)
  • STS-gtSetGeometryFileName("STS/STS", "v03c")
  • fRun-gtAddModule(STS)
  • CbmDetector TOF new CbmTof("TOF", kTRUE )
  • TOF-gtSetGeometryFileName("TOF/TOF", "v03_v10")
  • fRun-gtAddModule(TOF)
  • CbmDetector TRD new CbmTRD("TRD",kFALSE )
  • TRD-gtSetGeometryFileName("TRD/TRD", "v04b_9" )
  • fRun-gtAddModule(TRD)

13
Simulation Macro-Event Generators
  • CbmPrimaryGenerator priGen new
    CbmPrimaryGenerator()
  • fRun-gtSetGenerator(priGen)
  • CbmUrqmdGenerator fGen1 new CbmUrqmdGenerator("0
    0-03fm.100ev.f14")
  • CbmPlutoGenerator fGen2 new CbmPlutoGenerator("j
    psi.root")
  • CbmParticleGenerator fGen3 new
    CbmParticleGenerator()
  • fRun-gtAddGenerator(fGen1)
  • fRun-gtAddGenerator(fGen2)
  • fRun-gtAddGenerator(fGen3)

14
Simulation Macro-Magnetic Field
  • // setting a field map
  • CbmFieldMap fMagField new CbmFieldMap("FIELD.v03
    b.map")
  • // setting a constant field
  • CbmConstField fMagFieldnew CbmConstField()
  • fMagField-gtSetFieldXYZ(0, 30 ,0 ) // values are
    in kG
  • // MinX-75, MinY-40,MinZ-12 ,MaxX75, MaxY40
    ,MaxZ124 )
  • fMagField-gtSetFieldRegions(-74, -39 ,-22 , 74, 39
    , 160 ) // values are in cm
  • fRun-gtSetField(fMagField)

15
Simulation Macro- Run Simulation
  • fRun-gtInit() // Initialize the simulation
  • Simulation
  • 1. Initialize the VMC (Simulation)
  • 2. Initialize Tasks (if they are used in
    Simulation)
  • fRun-gtRun(NoOfEvent) //Run the Simulation

16
Saving Parameters ROOT Files
  • //Fill the Parameter containers for this run
    /
  • CbmRuntimeDb rtdbfRun-gtGetRuntimeDb()
  • rtdb-gtaddRun(1) //add run with run Id
  • CbmParRootFileIo outputnew
    CbmParRootFileIo()
  • output-gtopen("SimPar.root","RECREATE")
  • rtdb-gtsetOutput(output)
  • CbmBaseParSet par(CbmBaseParSet)(rtdb-gt
    getContainer("CbmBaseParSet"))
  • par-gtSetField(fMagField)
  • par-gtSetGen(primGen)
  • par-gtsetChanged()
  • par-gtsetInputVersion(1,1)
  • rtdb-gtsaveOutput()

17
Saving Parameters Oracle
  • gSystem-gtLoad ( "libOra" )
  • CbmRuntimeDb rtdbfRun-gtGetRuntimeDb()
  • CbmParOraIo oranew CbmParOraIo
  • ora-gtopen("cbm_sts_oper")
  • rtdb-gtsetOutput(ora)
  • CbmParTest par(CbmParTest)(rtdb-gtgetContainer
    ("CbmParTest"))
  • par-gtsetAuthor("M. Al-Turany")
  • par-gtsetDescription("Analysis interface test")
  • par-gtwrite(ora)

18
Analysis Macro
  • gROOT-gtLoadMacro("VMCWORKDIR/gconfig/basiclibs.C
    ")
  • basiclibs()
  • gSystem-gtLoad("libCbm")
  • gSystem-gtLoad("libTrack")
  • CbmRunAna fRun new CbmRunAna()
  • fRun-gtSetInputFile(/d/STS_AuAu25Gev_Urqmd.root")
  • fRun-gtSetOutputFile(trackOutput.root")

19
Analysis Macro Reading Parameters
  • CbmTrack tr new CbmTrack("Tracking
    Algorithm")
  • fRun-gtAddTask(tr)
  • CbmRuntimeDb rtdbfRun-gtGetRuntimeDb()
  • CbmParRootFileIo inputnew CbmParRootFileIo()
  • input-gtopen("test.root")
  • rtdb-gtsetFirstInput(input)
  • CbmBaseParSet par
  • (CbmBaseParSet)(rtdb-gtgetContainer
    ("CbmBaseParSet") )
  • rtdb-gtinitContainers(1) // runId 1
  • par-gtprint()
  • fRun-gtInit()
  • fRun-gtRun()

20
Reading Parameters Oracle
  • gSystem-gtLoad ( "libOra" )
  • CbmRunAna fRun new CbmRunAna()
  • CbmRuntimeDb rtdbfRun-gtGetRuntimeDb()
  • CbmParOraIo oranew CbmParOraIo()
  • ora-gtopen()
  • rtdb-gtsetFirstInput(ora)
  • CbmGenericParOraIo genio
  • (CbmGenericParOraIo)(ora-gtgetDetParIo("CbmGene
    ricParIo"))
  • CbmParTest par(CbmParTest)(rtdb-gtgetContainer(
    "CbmParTest"))
  • genio-gtreadFromLoadingTable(par,1) // runId 1
  • par-gtprint()
  • par-gtprintParams()

21
Chaining root files
  • Chaining mechanism supported in the Analysis
  • //
  • CbmRunAna fRun new CbmRunAna()
  • fRun-gtSetInputFile(myfile1.root)
  • fRun-gtAddFile(myfile2.root)
  • fRun-gtAddFile(myfile3.root)
  • // loop over all entries
  • fRun-gtRun()

22
Summary
  • The G3 Native geometry builder is implemented,
    the validation of the modified G3 is being
    performed. (TGeo as a navigation system for G3)
  • Inconsistency in the Cerenkov effect has been
    found and a report has been send to the VMC
    group.
  • Hades spectrometer has been fully integrated
  • Gives us the opportunity to tune Geant4
    (cuts/physics list ) and compare with real Data
    !
  • Validate TGeo and G3 with data
  • Realistic test of the framework.
  • HADES Parameter containers are implemented and
    ready to use
  • The Hades Oracle interface is integrated within
    the framework
Write a Comment
User Comments (0)
About PowerShow.com