== Delphes' Configuration File == The Delphes' configuration file is based on [http://www.tcl.tk/about/language.html Tcl scripting language]. [http://www.beedub.com/book/3rd/Tclintro.pdf Tcl Fundamentals] chapter from [http://www.beedub.com/book/ Practical Programming in Tcl and Tk] describes the basic syntax rules for the Tcl scripting language. Delphes uses a safe subset of [http://www.tcl.tk/man/tcl8.0/TclCmd/contents.htm Tcl 8.0.5] with 2 additional commands: {{{module}}} and {{{add}}}. == Basic Commands == Here are the most important commands: '''{{{set ParamName value}}}''' this commands sets the value of the parameter given by {{{ParamName}}} to {{{value}}} '''{{{add ParamName value value value ...}}}''' this command treats the parameter given by {{{ParamName}}} as a list and appends each of the {{{value}}} arguments to that list as a separate element. '''{{{module ModuleClass ModuleName ModuleConfigurationBody}}}''' this command activates a module of class {{{ModuleClass}}} called {{{ModuleName}}} and evaluates module's configuration commands contained in {{{ModuleConfigurationBody}}}: {{{ module Efficiency ElectronEfficiency { set InputArray ElectronEnergySmearing/electrons set OutputArray electrons # set EfficiencyFormula {efficiency formula as a function of eta and pt} # efficiency formula for electrons set EfficiencyFormula { (pt <= 10.0) * (0.00) + \ (abs(eta) <= 1.5) * (pt > 10.0) * (0.95) + \ (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 10.0) * (0.85) + \ (abs(eta) > 2.5) * (0.00)} } }}} '''{{{set ExecutionPath ListOfModuleNames}}}''' the global parameter called '''{{{ExecutionPath}}}''' defines the order of execution of various modules: {{{ set ExecutionPath { ParticlePropagator ChargedHadronTrackingEfficiency ElectronTrackingEfficiency MuonTrackingEfficiency ChargedHadronMomentumSmearing ElectronEnergySmearing MuonMomentumSmearing TrackMerger Calorimeter EFlowMerger PhotonEfficiency PhotonIsolation ElectronEfficiency ElectronIsolation MuonEfficiency MuonIsolation MissingET FastJetFinder BTagging TauTagging UniqueObjectFinder ScalarHT TreeWriter } }}} == Comments == A Tcl comment line begins with #. == Variable Substitution == A dollar sign together with an immediately following variable name will be substituted by the value of the variable.