45
3 3 Fast Detector Simulation Using Lelaps Fast Detector Simulation Using Lelaps

3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

Embed Size (px)

Citation preview

Page 1: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

33

Fast Detector Simulation Using LelapsFast Detector Simulation Using Lelaps

Page 2: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 22

OverviewOverview

IntroductionIntroduction What does it do and what is it?What does it do and what is it?

The CEPack tool kitThe CEPack tool kit Geometry and MaterialsGeometry and Materials Tracking, Multiple Scattering and dE/dxTracking, Multiple Scattering and dE/dx Electromagnetic and Hadronic Shower ParameterizationElectromagnetic and Hadronic Shower Parameterization Decays and Gamma ConversionsDecays and Gamma Conversions

Using CEPack inside Geant4Using CEPack inside Geant4 Standalone CEPack: LelapsStandalone CEPack: Lelaps PerformancePerformance FutureFuture

Page 3: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 33

Introduction: What does it do?Introduction: What does it do?

It swims particles through detectors, taking into account magnetic It swims particles through detectors, taking into account magnetic fields, multiple scattering and dE/dx energy loss.fields, multiple scattering and dE/dx energy loss.

It produces parameterized showers in EM and hadronic It produces parameterized showers in EM and hadronic calorimeters.calorimeters.

It converts gammas.It converts gammas. It supports decays of certain short-lived particles (“V” decays).It supports decays of certain short-lived particles (“V” decays). It does all this very fast.It does all this very fast.

Page 4: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 44

Lelaps consists of a set of C++ class libraries and a main program, Lelaps consists of a set of C++ class libraries and a main program, which itself is called lelaps.which itself is called lelaps.

The main library is called CEPack, which contains the actual The main library is called CEPack, which contains the actual simulation toolkit. It uses only one utility library, “vec”.simulation toolkit. It uses only one utility library, “vec”.

Other utility libraries include: lStdHep, vlutil, plotpp, pl3.Other utility libraries include: lStdHep, vlutil, plotpp, pl3. Main programs (“lelapses”) have been written for BaBar and for LCD Main programs (“lelapses”) have been written for BaBar and for LCD

(LDMar01, SDJan03 and SDMar04 are implemented).(LDMar01, SDJan03 and SDMar04 are implemented). CEPack can also be used in conjunction with Geant4 parameterized CEPack can also be used in conjunction with Geant4 parameterized

volumes. In this way it is integrated in BaBar’s Geant4-based volumes. In this way it is integrated in BaBar’s Geant4-based simulation.simulation.

The standalone version for LCD reads StdHep generator files and The standalone version for LCD reads StdHep generator files and produces SIO or LCIO output files that can be read by JAS and produces SIO or LCIO output files that can be read by JAS and LCDWired.LCDWired.

Introduction: What is it?Introduction: What is it?

Page 5: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 55

Geometry in CEPackGeometry in CEPack

Geometries are constructed using CENodes (which may contain a Geometries are constructed using CENodes (which may contain a list of subnodes).list of subnodes).

A number of common CENodes are predefinedA number of common CENodes are predefined cylinders, cones, boxes, spheres etc.cylinders, cones, boxes, spheres etc.

Transformations may be applied to CENodes in order to position Transformations may be applied to CENodes in order to position and orient them. Arbitrary transformations are allowed.and orient them. Arbitrary transformations are allowed.

CENodes need to provide methods for tracks entering and exiting, CENodes need to provide methods for tracks entering and exiting, and for determining whether points are inside them or not.and for determining whether points are inside them or not.

CENodes may be assigned a numeric id and subid.CENodes may be assigned a numeric id and subid. CENodes may implement a method to compute a subid from a CENodes may implement a method to compute a subid from a

location.location. May be used to compute calorimeter segmentation.May be used to compute calorimeter segmentation.

CENodes do not have to be 3D objects.CENodes do not have to be 3D objects. Several predefined CENodes consist of one or more 2D surfaces.Several predefined CENodes consist of one or more 2D surfaces.

Page 6: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 66

Geometry in CEPack: LDGeometry in CEPack: LD

Most objects in the LD Most objects in the LD are cylinders.are cylinders.

There are some conical There are some conical masks (not drawn).masks (not drawn).

TPC and barrel muon TPC and barrel muon detector each contain a detector each contain a CENode with a set of CENode with a set of concentric cylinder concentric cylinder surfaces.surfaces.

Muon endcaps use a Muon endcaps use a CENode with a set of CENode with a set of cylindrical slices.cylindrical slices.

Calorimeters use subid Calorimeters use subid calculation for their calculation for their segmentation.segmentation.

Page 7: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 77

Materials in CEPackMaterials in CEPack

All elements built in with default pressure/temperature/density.All elements built in with default pressure/temperature/density. Any compound can be specified by chemical formula and density or Any compound can be specified by chemical formula and density or

(for gasses) temperature and pressure.(for gasses) temperature and pressure. Mixtures can be created by mixing elements and compounds (by Mixtures can be created by mixing elements and compounds (by

volume or by weight).volume or by weight). All needed quantities are calculated automaticallyAll needed quantities are calculated automatically

Constants needed for multiple scattering and energy lossConstants needed for multiple scattering and energy loss Radiation lengths (Tsai, PDG)Radiation lengths (Tsai, PDG) Interaction lengths (from a fit to element data)Interaction lengths (from a fit to element data) Other constants needed for shower parametrizationOther constants needed for shower parametrization

Page 8: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 88

MatpropMatprop

Lelaps distribution comes with a little program called Lelaps distribution comes with a little program called matprop:matprop: matprop U # for elements (gasses at NTP)matprop U # for elements (gasses at NTP) matprop SiO2/2.32 # for solids (and liquids) specifymatprop SiO2/2.32 # for solids (and liquids) specify

# density (g/cc)# density (g/cc) matprop CO2/1/298.15 # for gasses specify pressure (atm)matprop CO2/1/298.15 # for gasses specify pressure (atm)

# and temperature (K)# and temperature (K) matprop O2/STP # for gasses at STP (0 C, 1 atm)matprop O2/STP # for gasses at STP (0 C, 1 atm) matprop Ar/NTP # for gasses at NTP (25 C, 1 atm)matprop Ar/NTP # for gasses at NTP (25 C, 1 atm) matprop H2// # for gasses at NTPmatprop H2// # for gasses at NTP

For a mixture (e.g. Air at 20 C) use (-g to indicate gas):For a mixture (e.g. Air at 20 C) use (-g to indicate gas): matprop -g O2/1/293.15 20.946 N2/1/293.15 78.084matprop -g O2/1/293.15 20.946 N2/1/293.15 78.084

Ar/1/293.15 0.934Ar/1/293.15 0.934 Just type Just type matpropmatprop to get a list of options to get a list of options Prints out lots of material propertiesPrints out lots of material properties Matprop is available onnline: Matprop is available onnline: http://http://

www.slac.stanford.edu/comp/physics/matprop.htmlwww.slac.stanford.edu/comp/physics/matprop.html

Page 9: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 99

Tracking in CEPackTracking in CEPack

Tracking is performed by taking steps along a linear trajectory with Tracking is performed by taking steps along a linear trajectory with endpoints on a helix, such that the sagitta stays below a certain endpoints on a helix, such that the sagitta stays below a certain (settable) maximum.(settable) maximum.

CENodes have bounding spheres (or bounding cylinders).CENodes have bounding spheres (or bounding cylinders). When computing distances to CENodes, only “relevant” CENodes are When computing distances to CENodes, only “relevant” CENodes are

considered.considered. After each step, the amount of material traversed is checked: if After each step, the amount of material traversed is checked: if

enough material was traversed, multiple scattering and energy loss enough material was traversed, multiple scattering and energy loss is performed and track parameters and list of relevant CENodes are is performed and track parameters and list of relevant CENodes are recalculated.recalculated.

When an intersection occurs within a step, the fractional step is When an intersection occurs within a step, the fractional step is executed, the CENode is entered, and the remaining fraction of the executed, the CENode is entered, and the remaining fraction of the step follows.step follows.

Page 10: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1010

Multiple Scattering and dE/dxMultiple Scattering and dE/dx

Multiple scattering is performed using the algorithm of Lynch and Multiple scattering is performed using the algorithm of Lynch and Dahl.Dahl. Gerald R. Lynch and Orin I. Dahl, Nucl. Instr. And Meth. B58 (1991) 6.Gerald R. Lynch and Orin I. Dahl, Nucl. Instr. And Meth. B58 (1991) 6.

Material is “saved up” along the track until there is enough.Material is “saved up” along the track until there is enough.

dE/dx is calculated using the methods by Sternheimer and Peierls.dE/dx is calculated using the methods by Sternheimer and Peierls. R.M. Sternheimer and R.F. Peierls, Phys. Rev. B3 (1971) 3681.R.M. Sternheimer and R.F. Peierls, Phys. Rev. B3 (1971) 3681.

All constants precalculated by the material classes.All constants precalculated by the material classes.

Page 11: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1111

Electromagnetic Shower ParameterizationElectromagnetic Shower Parameterization

Electromagnetic showers are parameterized using the algorithms of Electromagnetic showers are parameterized using the algorithms of Grindhammer and Peters.Grindhammer and Peters. G. Grindhammer and S. Peters, arXiv:hep-ex/0001020v1 (2000)G. Grindhammer and S. Peters, arXiv:hep-ex/0001020v1 (2000)

(Paper is a 1993 conference contribution, submitted by request to the archive in (Paper is a 1993 conference contribution, submitted by request to the archive in 2000).2000).

Calorimeters are treated as homegeneous media, with longitudinal shower Calorimeters are treated as homegeneous media, with longitudinal shower profile given by a gamma distribution (t in radiation lengths):profile given by a gamma distribution (t in radiation lengths):

Coefficients Coefficients αα and and ββ depend on the material (Z) and energy. depend on the material (Z) and energy. The profiles are fluctuated, and correlations between The profiles are fluctuated, and correlations between αα and and ββ are taken into are taken into

account.account.

Page 12: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1212

EM Shower Parameterization: Radial ProfileEM Shower Parameterization: Radial Profile

For each step of one radiation length, a radial profile is computed of the For each step of one radiation length, a radial profile is computed of the form:form:

with Rwith RCC the median radius (in units of Molière radius) of core component of the median radius (in units of Molière radius) of core component of

the shower, Rthe shower, RTT the median radius of tail component and p the fraction of the median radius of tail component and p the fraction of

“core” in the shower.“core” in the shower. RRCC, R, RTT and p are functions of Z, shower depth t and E. and p are functions of Z, shower depth t and E. Energy dE(t) is divided into spots (another gamma distribution with Energy dE(t) is divided into spots (another gamma distribution with

parameters depending on t). Spots are thrown in r according to the profile parameters depending on t). Spots are thrown in r according to the profile above, uniformly in above, uniformly in φφ and also uniformly between t and t+1. and also uniformly between t and t+1.

Roughly, about 400 spots are generated per GeV of shower energy. Roughly, about 400 spots are generated per GeV of shower energy. Spots are reported as “hits”.Spots are reported as “hits”.

222222 )(

2)1(

)(

2)(

),(

)(

1

T

T

C

C

Rr

rRp

Rr

rRprf

dr

trdE

tdE

Page 13: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1313

EM Shower Parameterization: BaBar CsIEM Shower Parameterization: BaBar CsI

CEPack simulation of CEPack simulation of BaBar EM calorimeter BaBar EM calorimeter in Moose (courtesy of in Moose (courtesy of Dominique Mangeol). Dominique Mangeol). See also the BaBar See also the BaBar web site (computing – web site (computing – simulation – fast simulation – fast simulation).simulation).

Page 14: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1414

Hadronic Shower ParameterizationHadronic Shower Parameterization

Hadronic showers are parameterized using code that is similar to Hadronic showers are parameterized using code that is similar to the code for electromagnetic showers, with some modifications:the code for electromagnetic showers, with some modifications:

The location where the shower starts is simulated using an The location where the shower starts is simulated using an exponential law with attenuation given by the interaction length.exponential law with attenuation given by the interaction length.

The longitudunal profile uses the Bock parameterization.The longitudunal profile uses the Bock parameterization. R.K. Bock, T. Hansl-Kozanecka and T.P. Shah, Nucl. Instr. And Meth. R.K. Bock, T. Hansl-Kozanecka and T.P. Shah, Nucl. Instr. And Meth.

186 (1981) 533.186 (1981) 533. A combination of two gamma distributions, one using radiation A combination of two gamma distributions, one using radiation

lengths and the other interaction lengths, is used.lengths and the other interaction lengths, is used. Bock parameterization does not specify radial profiles. For the Bock parameterization does not specify radial profiles. For the

moment we use a radial profile similar to Grindhammer & Peters (for moment we use a radial profile similar to Grindhammer & Peters (for EM showers) but with radiation lengths replaced by interaction EM showers) but with radiation lengths replaced by interaction lengths and faster spread with depth. The parameters still need to lengths and faster spread with depth. The parameters still need to be fine-tuned.be fine-tuned.

Page 15: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1515

Shower Parameterization Compared to Geant4Shower Parameterization Compared to Geant4

Parameterized shower simulation was compared to Geant4.Parameterized shower simulation was compared to Geant4. ““Parameterized Shower Simulation in Lelaps: A Comparison with Parameterized Shower Simulation in Lelaps: A Comparison with

GEANT4”, Daniel Birt, Amy Nicholson, Willy Langeveld, Dennis Wright, GEANT4”, Daniel Birt, Amy Nicholson, Willy Langeveld, Dennis Wright, SLAC-TN-03-005, Aug 2003.SLAC-TN-03-005, Aug 2003.

In general pretty good agreement for EM showers. Hadronic In general pretty good agreement for EM showers. Hadronic showers agree pretty well longitudinally, but not as well radially.showers agree pretty well longitudinally, but not as well radially.

Hadronic shower parameterization has been tweaked since then.Hadronic shower parameterization has been tweaked since then.

Page 16: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1616

EM Shower Parameterization and Geant4EM Shower Parameterization and Geant4

Comparison of Comparison of CEPack longitudinal CEPack longitudinal profile (green) of a 10 profile (green) of a 10 GeV electron in an GeV electron in an EM calorimeter with EM calorimeter with Geant4 (orange).Geant4 (orange).

Page 17: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1717

Decays and Gamma ConversionsDecays and Gamma Conversions

Decays of unstable particles and gamma conversions are performed Decays of unstable particles and gamma conversions are performed as follows:as follows:

Lelaps loops over the particles in a list, turns them into CETracks Lelaps loops over the particles in a list, turns them into CETracks and swims them through the geometryand swims them through the geometry

Tracks of decaying particles and converting gammas stop at the Tracks of decaying particles and converting gammas stop at the decay/conversion pointdecay/conversion point

For supported unstable particles, a CEPack utility function picks For supported unstable particles, a CEPack utility function picks decay mode or conversion and adds products to the listdecay mode or conversion and adds products to the list

Lelaps continues to loop over the particles in the list until there are Lelaps continues to loop over the particles in the list until there are none leftnone left

Supported unstable particles are pi0, K0-short (K0-long treated as Supported unstable particles are pi0, K0-short (K0-long treated as stable), Lambda, Sigma+/-/0, Xi-,0 and Omega- . Only decay stable), Lambda, Sigma+/-/0, Xi-,0 and Omega- . Only decay modes > 2% supported (“V” decays)modes > 2% supported (“V” decays)

Page 18: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1818

Wired picture of the Wired picture of the decay chain:decay chain:

ΩΩ → → ΞΞ00 ππ--

ΞΞ00 → → ΛΛ ππ00

Λ Λ → p → p ππ--

ππ00 → → γ γγ γ as simulated by Lelaps as simulated by Lelaps for the LCD LD model.for the LCD LD model.

History: Lelaps and CEPack 3.xHistory: Lelaps and CEPack 3.x

Page 19: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 1919

Wired picture of a Wired picture of a gamma conversion as gamma conversion as simulated by Lelaps for simulated by Lelaps for the LCD LD model.the LCD LD model.

History: Lelaps and CEPack 3.xHistory: Lelaps and CEPack 3.x

Page 20: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2020

Using CEPack inside Geant4Using CEPack inside Geant4

To use CEPack inside Geant4, create a Geant4 parameterized To use CEPack inside Geant4, create a Geant4 parameterized model, e.g.: model, e.g.: class BgsSvtParamModel : public G4VFastSimulationModelclass BgsSvtParamModel : public G4VFastSimulationModel

In its In its setup()setup(), create the CENode corresponding to the CEPack , create the CENode corresponding to the CEPack simulation with all its subnodes.simulation with all its subnodes.

In In Doit()Doit(), convert from G4FastTrack track to CETrack, and call , convert from G4FastTrack track to CETrack, and call track.swim()track.swim()

By subclassing CETrack, all hits are reported using CETRack By subclassing CETrack, all hits are reported using CETRack report_hit()report_hit() method. Convert hits to your favorite format. method. Convert hits to your favorite format.

Update Geant4’s notion of the track using Update Geant4’s notion of the track using G4FastStepG4FastStep (or call (or call KillPrimaryTrack()KillPrimaryTrack()))

Page 21: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2121

CEPack and LelapsCEPack and Lelaps

Lelaps for LCD is a standalone program which uses CEPack.Lelaps for LCD is a standalone program which uses CEPack. It sets up the CEPack geometry (supports LDMar01, SDJan03 and It sets up the CEPack geometry (supports LDMar01, SDJan03 and

SDMar04).SDMar04). It uses lStdHep (“StdHep light” – included in the distribution): a class It uses lStdHep (“StdHep light” – included in the distribution): a class

library to to read generator event files in StdHep format. StdHep library to to read generator event files in StdHep format. StdHep particles are converted to SIO or LCIO particles.particles are converted to SIO or LCIO particles.

Loops over events, creating CETracks. When hits are reported, they Loops over events, creating CETracks. When hits are reported, they are added to SIO/LCIO hit lists. For calorimeter hits, the “spots” are are added to SIO/LCIO hit lists. For calorimeter hits, the “spots” are first accumulated and turned into energy depositions in individual first accumulated and turned into energy depositions in individual calorimeter cells and then added.calorimeter cells and then added.

Finally, the SIO or LCIO event structure is written out. Finally, the SIO or LCIO event structure is written out.

Page 22: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2222

Lelaps (LDMar01)Lelaps (LDMar01)

Page 23: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2323

Lelaps (SDJan03)Lelaps (SDJan03)

Page 24: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2424

Lelaps: UsageLelaps: Usage

Most common usage: Most common usage: lelaps –o foo.sio –E bar1.stdhep bar2.stdhep …lelaps –o foo.sio –E bar1.stdhep bar2.stdhep …

reads one or more StdHep files and produces SIO output file.reads one or more StdHep files and produces SIO output file. Defaults to SDJan03. Use Defaults to SDJan03. Use –L LDMar04–L LDMar04 for LD, etc. for LD, etc.

Also has built-in simple particle “gun”:Also has built-in simple particle “gun”: lelaps –o foo.slcio –i 11 –m 10 –n 4 –N 1000lelaps –o foo.slcio –i 11 –m 10 –n 4 –N 1000

generates 1000 events with 4 electrons/event with 10 GeV eachgenerates 1000 events with 4 electrons/event with 10 GeV each

random in 4random in 4ππ and produces LCIO output file. and produces LCIO output file. Options for generation in x,y plane (2Options for generation in x,y plane (2ππ) or along x, y, z directions) or along x, y, z directions Options for turning off energy loss, multiple scattering and/or Options for turning off energy loss, multiple scattering and/or

showering in calorimetersshowering in calorimeters Options for turning off decays and/or conversions and tracking their Options for turning off decays and/or conversions and tracking their

secondaries secondaries

Page 25: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2525

Performance (LDMar01)Performance (LDMar01)

Overall timeOverall time

(at 1 GHz)(at 1 GHz)

Time/eventTime/event

(msec at 1 GHz)(msec at 1 GHz)

Time/trackTime/track

(msec at 1 GHz)(msec at 1 GHz)

Tracking only (with Tracking only (with dE/dx & MS)dE/dx & MS)

27.9 s27.9 s 279 ms279 ms 4.6 ms4.6 ms

+ EM showers+ EM showers 31.2 s31.2 s 312 ms312 ms 5.2 ms5.2 ms

+ had. showers+ had. showers 36.7 s36.7 s 367 ms367 ms 6.1 ms6.1 ms

+ decays/conversions+ decays/conversions 43.0 s43.0 s 430 ms430 ms 5.0 ms5.0 ms

+ LCIO output file + LCIO output file 62.9 s62.9 s 629 ms629 ms 7.3 ms7.3 ms

100 ee100 eeZZ events* at 500 GeV c.m. energy in the LD on a 1.4 GHz ZZ events* at 500 GeV c.m. energy in the LD on a 1.4 GHz Pentium 4 running Linux (Noric03) gives the following performance Pentium 4 running Linux (Noric03) gives the following performance (all numbers converted to 1 GHz processor speed):(all numbers converted to 1 GHz processor speed):

* panpy-ZZ-500-001001-gen-1.stdhep (5973 tracks)* panpy-ZZ-500-001001-gen-1.stdhep (5973 tracks)

Page 26: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2626

Performance (SDMar03)Performance (SDMar03)

Overall timeOverall time

(at 1 GHz)(at 1 GHz)

Time/eventTime/event

(msec at 1 GHz)(msec at 1 GHz)

Time/trackTime/track

(msec at 1 GHz)(msec at 1 GHz)

Tracking only (with Tracking only (with dE/dx & MS)dE/dx & MS)

47.7 s47.7 s 477 ms477 ms 8.4 ms8.4 ms

+ EM showers+ EM showers 56.1 s56.1 s 561 ms561 ms 9.4 ms9.4 ms

+ had. showers+ had. showers 56.3 s56.3 s 563 ms563 ms 9.5 ms9.5 ms

+ decays/conversions+ decays/conversions 69.2 s69.2 s 692 ms692 ms 9.7 ms9.7 ms

+ LCIO output file + LCIO output file 90.6 s90.6 s 906 ms906 ms 12.7 ms12.7 ms

100 ee100 eeZZ events* at 500 GeV c.m. energy in the SD on a 1.4 GHz ZZ events* at 500 GeV c.m. energy in the SD on a 1.4 GHz Pentium 4 running Linux (Noric03) gives the following performance Pentium 4 running Linux (Noric03) gives the following performance (all numbers converted to 1 GHz processor speed):(all numbers converted to 1 GHz processor speed):

* panpy-ZZ-500-001001-gen-1.stdhep (5973 tracks)* panpy-ZZ-500-001001-gen-1.stdhep (5973 tracks)

Page 27: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2727

Performance: AnalysisPerformance: Analysis

Tracking alone: 3 - 4 events/s (at 1 GHz) for LD, 2 events/s for SD.Tracking alone: 3 - 4 events/s (at 1 GHz) for LD, 2 events/s for SD. Adding parameterized showering costs 15% (SD) to 30% (LD).Adding parameterized showering costs 15% (SD) to 30% (LD). Adding decays and conversions adds 20%.Adding decays and conversions adds 20%. LCIO output file (14 MB, compressed) adds another 40%.LCIO output file (14 MB, compressed) adds another 40%.

SIO output takes much longer (factor 2 to 4 depending heavily on SIO output takes much longer (factor 2 to 4 depending heavily on calorimeter segmentation). Could be optimized.calorimeter segmentation). Could be optimized.

Platform/machine dependent. Tracking only, time per event:Platform/machine dependent. Tracking only, time per event: Noric03 (1.4 GHz, gcc 2.95.3)Noric03 (1.4 GHz, gcc 2.95.3) 0.281 sec at 1 GHz0.281 sec at 1 GHz Tersk09 (0.44 GHz, Solaris with WS 7)Tersk09 (0.44 GHz, Solaris with WS 7) 0.154 sec at 1 GHz0.154 sec at 1 GHz Windows (2 GHz, cygwin with gcc 3.2) Windows (2 GHz, cygwin with gcc 3.2) 0.384 sec at 1 GHz0.384 sec at 1 GHz

Page 28: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2828

FutureFuture

Lelaps and CEPack interfaces are not yet frozen!Lelaps and CEPack interfaces are not yet frozen! New features planned for CEPackNew features planned for CEPack

Combinatorial geometryCombinatorial geometry Shower continuation into next volumeShower continuation into next volume

New features planned for Lelaps:New features planned for Lelaps: Read in geometry from some “standard” file formatRead in geometry from some “standard” file format

Old features need to be tested more thoroughlyOld features need to be tested more thoroughly More tuning of hadronic showersMore tuning of hadronic showers

Review of code, improvements in consistencyReview of code, improvements in consistency Revisit optimizationRevisit optimization

Page 29: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 2929

About the name LelapsAbout the name Lelaps

Lelaps (“storm wind”) was a dog with such speed Lelaps (“storm wind”) was a dog with such speed that, once set upon a chase, he could not fail to that, once set upon a chase, he could not fail to catch his prey. Having forged him from bronze, catch his prey. Having forged him from bronze, Hephaestus gave him to Zeus, who in turn gave him Hephaestus gave him to Zeus, who in turn gave him to Athena, the goddess of the hunt. Athena gave to Athena, the goddess of the hunt. Athena gave Lelaps as a wedding present to Procris, daughter of Lelaps as a wedding present to Procris, daughter of Thespius, and the new bride of famous hunter Thespius, and the new bride of famous hunter Cephalus.Cephalus.

A time came when a fox created havoc for the A time came when a fox created havoc for the shepherds in Thebes. The fox had the divine shepherds in Thebes. The fox had the divine property that its speed was so great that it could not property that its speed was so great that it could not be caught. Procris sent Lelaps to catch the fox. But be caught. Procris sent Lelaps to catch the fox. But because both were divine creatures, a stalemate because both were divine creatures, a stalemate ensued, upon which Zeus turned both into stone. ensued, upon which Zeus turned both into stone. Feeling remorse, Zeus elevated Lelaps to the skies, Feeling remorse, Zeus elevated Lelaps to the skies, where he now shines as the constellation Canis where he now shines as the constellation Canis Major, with Sirius as the main star.Major, with Sirius as the main star.

Page 30: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3030

Introduction: LelapsIntroduction: Lelaps

……but clearly, Lelaps (the program) is not a dog!but clearly, Lelaps (the program) is not a dog!

Page 31: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3131

The EndThe End

Page 32: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

Geometry File FormatGeometry File Format

……and related issuesand related issues

Page 33: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3333

OverviewOverview

IntroductionIntroduction Religious wars, languages and file formats Religious wars, languages and file formats

RequirementsRequirements or at least “would be nice”sor at least “would be nice”s

A work in progressA work in progress The current planThe current plan A note about XMLA note about XML

Page 34: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3434

IntroductionIntroduction

Talking about file formats is like talking about languages or Talking about file formats is like talking about languages or standards--no matter what it is, at least 70% of the audience will be standards--no matter what it is, at least 70% of the audience will be against it:against it: ““Why not use an existing language/format, such as <fill in my favorite Why not use an existing language/format, such as <fill in my favorite

language/format>?”language/format>?” ““It’s not <fill in favorite standard> so it’s no good!”It’s not <fill in favorite standard> so it’s no good!” ““Don’t we already have enough standards?”Don’t we already have enough standards?”

Content vs. FormContent vs. Form In the following I will give an example of what could be done.In the following I will give an example of what could be done. That doesn’t mean the final product will be the same as the example.That doesn’t mean the final product will be the same as the example. XML is a specification of form, not content.XML is a specification of form, not content. The example will not look like XML, though perhaps the final version The example will not look like XML, though perhaps the final version

could be in that form.could be in that form.

Page 35: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3535

RequirementsRequirements

A Geometry file format ideally should satisfy the following:A Geometry file format ideally should satisfy the following: Should allow avoiding duplication of related numbersShould allow avoiding duplication of related numbers Should know about dimensions and enforce consistencyShould know about dimensions and enforce consistency Should know about simple mathematicsShould know about simple mathematics

cos, sin, sqrt, …cos, sin, sqrt, … Should know about levels of detailShould know about levels of detail

One wants to simulate different things in fast and full simulationsOne wants to simulate different things in fast and full simulations Should allow combinatorial geometryShould allow combinatorial geometry Simple things should be simple, difficult things should be possibleSimple things should be simple, difficult things should be possible Should be supported by Geant4, Lelaps, JAS.Should be supported by Geant4, Lelaps, JAS.

should be easily supportable by any software that would like toshould be easily supportable by any software that would like to Should be self-descriptiveShould be self-descriptive

E.g. should contain the algorithm to derive cell ids from x, y, z, rho, theta, phiE.g. should contain the algorithm to derive cell ids from x, y, z, rho, theta, phi Should allow hierarchies of volumes inside volumesShould allow hierarchies of volumes inside volumes

In the following I will not even address all of the above.In the following I will not even address all of the above.

Page 36: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3636

A Work In ProgressA Work In Progress

MaterialsMaterials Elements, compounds, mixturesElements, compounds, mixtures

Units and variablesUnits and variables Volumes and PlacementsVolumes and Placements Control structures and “arrays”Control structures and “arrays” Levels of detailLevels of detail Combinatorial geometryCombinatorial geometry

Page 37: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3737

Units and VariablesUnits and Variables

Variables are used to hold just about anything. This includes units. Variables are used to hold just about anything. This includes units. Units are declared as follows, using the built-in unit() function:Units are declared as follows, using the built-in unit() function:

##

# Comments are allowed, of course# Comments are allowed, of course

##

atm = unit("atm");atm = unit("atm");

cm = unit("cm");cm = unit("cm");

m = 100.0 * cm;m = 100.0 * cm;

T = unit("T");T = unit("T");

Page 38: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3838

MaterialsMaterials

Materials are declared using the element, material or mixture tags Materials are declared using the element, material or mixture tags (use the @ operator to pass by reference):(use the @ operator to pass by reference):Si = element("Si");Si = element("Si");vacuum = material("vacuum");vacuum = material("vacuum");O2 = material(formula("O2"),O2 = material(formula("O2"), pressure(1.0 atm),pressure(1.0 atm), temperature(293.15 K));temperature(293.15 K));Tyvek = material(name("Tyvek"),Tyvek = material(name("Tyvek"), formula("CH2CH2"),formula("CH2CH2"), density(0.935 gcc));density(0.935 gcc));Air = mixture(part(@O2, 20.946),Air = mixture(part(@O2, 20.946), part(@N2, 78.084),part(@N2, 78.084), part(@Ar, 0.934),part(@Ar, 0.934), by("volume"));by("volume"));

Page 39: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 3939

Volumes and PlacementsVolumes and Placements

First define a World Volume:First define a World Volume:World = cylinder(radius(700.0 cm), length(14.0 m), @vacuum);World = cylinder(radius(700.0 cm), length(14.0 m), @vacuum);

Define another volume:Define another volume:em_ec_irad = 21.0 cm; em_ec_orad = 125.0 cm;em_ec_irad = 21.0 cm; em_ec_orad = 125.0 cm;

em_b_irad = em_ec_orad + 2.0 cm; em_thickness = 15 cm;em_b_irad = em_ec_orad + 2.0 cm; em_thickness = 15 cm;

em_b_orad = em_b_irad + em_thickness; em_nlayers = 30;em_b_orad = em_b_irad + em_thickness; em_nlayers = 30;

em_sampfrac = 0.02664; em_b_length = 368.0 cm;em_sampfrac = 0.02664; em_b_length = 368.0 cm;

EM_Barrel = cylinder(name("EM Barrel"),EM_Barrel = cylinder(name("EM Barrel"),

innerRadius(em_b_irad),innerRadius(em_b_irad),

outerRadius(em_b_orad),outerRadius(em_b_orad),

length(em_b_length), @SiW,length(em_b_length), @SiW,

type("emcal"), nLayers(em_nlayers),type("emcal"), nLayers(em_nlayers),

samplingFraction(em_sampfrac));samplingFraction(em_sampfrac));

Add to World using placement:Add to World using placement:World += placement(@EM_Barrel, translate(0, 0, 0));World += placement(@EM_Barrel, translate(0, 0, 0));

Page 40: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 4040

Control Structures and “Arrays”Control Structures and “Arrays”

Use loops to do repetitive tasks and if statements for conditionals:Use loops to do repetitive tasks and if statements for conditionals:Vertex_Barrel = cylinder(name("Vertex Barrel"),Vertex_Barrel = cylinder(name("Vertex Barrel"),

innerRadius(v_irad), outerRadius(v_orad),innerRadius(v_irad), outerRadius(v_orad),

length(v_lenmax));length(v_lenmax));

for (i = 1; i <= v_nlayers; i += 1) {for (i = 1; i <= v_nlayers; i += 1) {

vlen = v_leninner;vlen = v_leninner;

if (i > 1) vlen = v_lenmax;if (i > 1) vlen = v_lenmax;

Vertex_Barrel.i = cylinder(name("Vertex Barrel " + i),Vertex_Barrel.i = cylinder(name("Vertex Barrel " + i),

innerRadius(v_spacing * i),innerRadius(v_spacing * i),

outerRadius(v_spacing * i + v_thickness),outerRadius(v_spacing * i + v_thickness),

length(vlen), @Si,length(vlen), @Si,

type("tracker"));type("tracker"));

Vertex_Barrel += placement(@Vertex_Barrel.i); # Notice hierarchyVertex_Barrel += placement(@Vertex_Barrel.i); # Notice hierarchy

}}

World += placement(@Vertex_Barrel);World += placement(@Vertex_Barrel);

Page 41: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 4141

Levels of DetailLevels of Detail

Specify levels of detail with “level” tag:Specify levels of detail with “level” tag:Had_Endcap = cylinder(name("Had Endcap"), level(1),Had_Endcap = cylinder(name("Had Endcap"), level(1),

innerRadius(had_ec_irad),innerRadius(had_ec_irad),

outerRadius(had_ec_orad),outerRadius(had_ec_orad),

length(had_thickness), @StainlessPoly,length(had_thickness), @StainlessPoly,

type("hadcal"), nslices(had_nlayers),type("hadcal"), nslices(had_nlayers),

samplingFraction(had_sampfrac));samplingFraction(had_sampfrac));

Had_Endcap += placement(@something, …, level(2), …);Had_Endcap += placement(@something, …, level(2), …);

Had_Endcap += placement(@something_else, …, level(3), …);Had_Endcap += placement(@something_else, …, level(3), …);

World += placement(@Had_Endcap, translate(0, 0, 0.5 * (had_b_length –World += placement(@Had_Endcap, translate(0, 0, 0.5 * (had_b_length –

had_thickness)));had_thickness)));

World += placement(@Had_Endcap, rotate_around_z(180 degrees),World += placement(@Had_Endcap, rotate_around_z(180 degrees),

translate(0, 0, -0.5 * (had_b_length – had_thickness)));translate(0, 0, -0.5 * (had_b_length – had_thickness)));

Page 42: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 4242

Combinatorial GeometryCombinatorial Geometry

Currently envisioned to be done using union() and intersection() constructs Currently envisioned to be done using union() and intersection() constructs and not():and not():Lum_Endcap = cone(name("Lum Endcap"),Lum_Endcap = cone(name("Lum Endcap"), innerTopRadius(l_e_itoprad),innerTopRadius(l_e_itoprad), outerTopRadius(l_e_otoprad),outerTopRadius(l_e_otoprad), innerBottomRadius(l_e_ibotrad),innerBottomRadius(l_e_ibotrad), outerBottomRadius(l_e_obotrad),outerBottomRadius(l_e_obotrad), length(l_e_length), @WSiG10Air);length(l_e_length), @WSiG10Air);

Beampipe1 = cylinder(name("Beampipe 1"),Beampipe1 = cylinder(name("Beampipe 1"), radius(1.0 cm), length(lb_length));radius(1.0 cm), length(lb_length));Beampipe2 = cylinder(…, radius(2.0 cm), …);Beampipe2 = cylinder(…, radius(2.0 cm), …);

Lum_Cal = intersection(placement(Lum_Endcap),Lum_Cal = intersection(placement(Lum_Endcap), placement(not(Beampipe1), …)),placement(not(Beampipe1), …)), placement(not(Beampipe2), …));placement(not(Beampipe2), …));

World += placement(@Lum_Cal, translate(0, 0, l_e_zoff));World += placement(@Lum_Cal, translate(0, 0, l_e_zoff));World += placement(@Lum_Cal, rotate_around_x(180 degrees),World += placement(@Lum_Cal, rotate_around_x(180 degrees), translate(0, 0, -l_e_zoff)); translate(0, 0, -l_e_zoff));

Page 43: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 4343

The PlanThe Plan

Parser/evaluator is mostly doneParser/evaluator is mostly done 3700 lines C++, half of which came from previous projects.3700 lines C++, half of which came from previous projects. It runs and turns sample SDMar04 file into a list of volumes. It runs and turns sample SDMar04 file into a list of volumes.

Left to do (not necessarily in this order):Left to do (not necessarily in this order): Finish up some stuff in the evaluator (such as enforcing units)Finish up some stuff in the evaluator (such as enforcing units) Finalize concepts of level of detail and combinatorial geometryFinalize concepts of level of detail and combinatorial geometry Add API layer to access the volume listAdd API layer to access the volume list Add simple geometry visualizer probably using Wired and HepRepsAdd simple geometry visualizer probably using Wired and HepReps Write implementations for Geant4 and LelapsWrite implementations for Geant4 and Lelaps Translate parser/API into Java, add to JAS, WiredTranslate parser/API into Java, add to JAS, Wired Time scale depends on how fancy we want (need?) to get. Hopefully Time scale depends on how fancy we want (need?) to get. Hopefully

before Christmas.before Christmas.

Page 44: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 4444

A Note about XMLA Note about XML

Whether a file format is XML based or not is a matter of form, not contentWhether a file format is XML based or not is a matter of form, not content Most important, however, is content.Most important, however, is content. One should worry about content first, and decide upon a file format last.One should worry about content first, and decide upon a file format last. That file format could be XML, but that decision should be made after the That file format could be XML, but that decision should be made after the

content has been defined.content has been defined.<climbs on soapbox><climbs on soapbox> Commonly believed myths about XML:Commonly believed myths about XML:

Now that we’ve decided on XML, we’re almost done.Now that we’ve decided on XML, we’re almost done. Wrong! Need to define content, write .dtd.Wrong! Need to define content, write .dtd.

XML guarantees correct content.XML guarantees correct content. Wrong! Only guarantees correct syntax.Wrong! Only guarantees correct syntax.

XML is human-readable.XML is human-readable. Wrong! Just look at it sometime.Wrong! Just look at it sometime.

When you use XML you don’t need to write a parser.When you use XML you don’t need to write a parser. Wrong! You still have to write a parser, albeit at a higher level.Wrong! You still have to write a parser, albeit at a higher level.

<climbs down from soap box><climbs down from soap box>

Page 45: 3 Fast Detector Simulation Using Lelaps. 7/28/2004W.G.J. Langeveld - SLAC2 Overview Introduction Introduction What does it do and what is it? What

7/28/20047/28/2004 W.G.J. Langeveld - SLACW.G.J. Langeveld - SLAC 4545

The EndThe End