The FLUKA Monte Carlo code - Uppsala University

38
Mattias Lantz Applied Nuclear Physics Department of Physics & Astronomy Uppsala University [email protected] The FLUKA Monte Carlo code www.fluka.org This introduction to the FLUKA MC is part of the course Modelling and simulation methods of particle transport , 5 credits, 1FA451

Transcript of The FLUKA Monte Carlo code - Uppsala University

Page 1: The FLUKA Monte Carlo code - Uppsala University

Mattias LantzApplied Nuclear Physics

Department of Physics & AstronomyUppsala University

[email protected]

The FLUKA Monte Carlo code

www.fluka.org

This introduction to the FLUKA MC is part of the course Modellingand simulation methods of particle transport, 5 credits, 1FA451

Page 2: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

OUTLINE & SCHEDULE

Part 1: What is FLUKA? (8 April 10-12)• History• Code design and features• Physics• Applications• Nice new tools

Part 2: Practical hints (10 April 13-15)

Part 3: Exercises (15 April 8-12)

Page 3: The FLUKA Monte Carlo code - Uppsala University
Page 4: The FLUKA Monte Carlo code - Uppsala University

History of

FLUKA

History of FLUKA1962: MC code(s) for high-energy proton beams

J. Ranft (Leipzig) and H. Geibel (CERN)

1970: Study of event-by-event fluctuations in calorimeters=> FLUktuierende KAskadeMainly used for radiation shielding studies

1970-1987: Development by J. Ranft and J.H. Möhring (Leipzig)with significant contributions from P. Aarnio and J. Routti (Helsinki), J.M. Zazula (Cracow) andA. Fassò and G.R. Stephenson (CERN)

1989-: A. Ferrari and P.R. Sala (INFN Milano), together with A. Fassò and J. Ranft, transforms FLUKA into a general purpose MC code

2003: CERN-INFN Collaboration Agreement 2006: Many improvements, free format input, nice tools…2011: Gfortran option available

www.fluka.org

Page 5: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

MCNP/MCNPX

EGS

PHITS

MORSE

MARS

PENELOPE

LAHETHETC

GEANT

History of FLUKA

FLUKA

SHIELD-HIT

Funny comparison between FLUKA, GEANT, and SHIELD-HIT:http://willworkforscience.blogspot.se/2010/10/monte-carlo-programs-in-particle.html

BEAM nrc

Page 6: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

MCNP/MCNPX

EGS

PHITS

MORSE

MARS

PENELOPE

LAHETHETC

GEANT

History of FLUKA

FLUKA

SHIELD-HIT

Funny comparison between FLUKA, GEANT, and SHIELD-HIT:http://willworkforscience.blogspot.se/2010/10/monte-carlo-programs-in-particle.html

BEAM nrc

Page 7: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

History of FLUKA

Comparison of number of publications between different MC codeshttp://willworkforscience.blogspot.se/2011/04/monte-carlo-race-2011.html

Page 8: The FLUKA Monte Carlo code - Uppsala University

Fluka isFLUKA is:

A stand-alone Monte Carlo code for transport andinteraction of particles and nuclei with matterHadron-hadron and hadron-nucleus interactions: 1 keV – 10000 TeVNucleus-nucleus interactions: ~10 of MeV/A – 10000 TeV/A (1)

E.m. and μ interactions: 1 keV – 10000 TeVNeutron multi-group transport and interactions: thermal – 20 MeV (2)

Photo-nuclear interactionsOptical photon generation and interactions (Cherenkov, scintillation, ...)

Neutrino generation and interactionsCharged particle transport including all relevant processes

Residual nuclei calculations, time evolution, residual dose calculations, ...

(1) Can not handle D, T, He-3, He4 yet(2): recently extended from 72 to more than 260 groups. Point-like cross sections for a few selected nuclei

Combinatorial geometry with optional voxel and lattice capabilitiesInterface to GEANT4 geometry package, AutoCAD, SimpleGeo, ... Analog calculations or with variance reduction

Precision transport in magnetic fields

www.fluka.org

Page 9: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgCode design and features

Sound and modern physics:• Based, as far as possible, on original and well-tested microscopic models• All steps should be self-consistent and with solid physical basis• Optimized by comparing with experimental data at single interaction level• No tuning on integral data such as thick target yields, etc.• Final predictions obtained with a minimum of free parameters which are fixed for all energies, targets and projectiles

• Basic conservation laws are fulfilled ”a priori”• Correlations are fully preserved within interactions and among showers components

• The physical models of FLUKA are fully integrated, with full cross-talk between all components (FLUKA is NOT a toolkit! Compare with GEANT)

⇒ Results from complex cases arise naturally from the underlying physical models⇒ Suitable environment for exotic extensions (ν, N-decay…) ⇒ Predictivity where no experimental data are directly available

Page 10: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

High accuracy:• Systematic use of relativistic kinematics• All variables are double precision• Tabulated total cross sections and other integral nuclear and atomic data are used (slower, but gives better accuracy than parametrizations)

• Differential cross sections obtained by sampling reaction channels and energies by physical models• Effort to use accurate mathematical and physical algorithms in order to achieve the same level of accuracy for each component and at all energies

FORTRAN-77 code:• The code has about 500,000 lines of code (~17 MBytes)• Internal memory management, dynamical memory allocation• Available on Linux x86 (g77), Compac TrueUnix and Mac OSX (g95), ... Also KNOPPIX version (FLUPIX), bootable from any host OS

• Also used in mixed-language applications, for instance C++ with GEANT4 geometry package (FLUGG interface)

Code design and features

Page 11: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgCode design and features

No programming required for standard cases:• All scoring, cutoff settings, biasing, etc. are defined by the user without any need to write code

• This allows very optimized scoring algorithms• Difficult to convince users that are accustomed to other codes

Very powerful user routines are available for special cases where the standard scoring is not enough for the user or when complex input kinematics is necessary

Scoring: Event-by-eventCoincident/Anti-coincidentTime gatesAngle dependence w.r.t. surfacesFluctuations and correlations... (~10 more)

Many different biasing options (~10) can be activated

Page 12: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Physics

Hadronic models in FLUKA

Page 13: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgPhysics: thin target example

Angle-integrated 90Zr(p,xn) at 80.5 MeV

The various lines show contributions from:• evaporation• INC• pre-equilibrium• total

Experimental data: M. Trabandt et al., Phys. Rev. C39, 452 (1989)

Page 14: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgPhysics: thick target example

Neutron double-differential distributions from protons on stopping-length targetsExp. data: Meier et al., Nucl. Sci. Eng. 110, 299 (1992) and Meigo et al., JAERI-Conf. 95-008

Page 15: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgPhysics: modified RQMD

Double-differential neutron yield by 400 MeV/n Ar and Fe ions on thick Al targetsExperimental data points: Phys. Rev. C62, 044615 (2000)

Page 16: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Applications• Energy production, waste transmutation: Energy Amplifier• LHC: beam-machine interaction and radioprotection• LHC/ATLAS/CMS: radiation background in detectors• LHC/ATLAS: calorimetry simulation• LHC/ALICE: general detector simulation• Neutrino beams from accelerators: WANF & CNGS• Cosmic rays: calculation of secondary particles in atmosphere• ICARUS: general detector and physics simulation• BOREXINO: radioactive background studies• Dose calculations: civil aviation• Dose calculations: space missions• Medical physics: hadrotherapy

Page 17: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

ATLAS: radiation background and calorimetryE. Gschwendtner, C.W. Fabjan, N. Hessey, T. Otto, and H. Vincke,

Measuring the radiation background in the ATLAS experiment,

Nucl. Instr. Meth. A476, 222 (2002) (benchmarked up to 14 attenuation lengths)

Applications

Photon background Neutron background

Page 18: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Regions of high losses(e.g., Collimators,…)

ATLAS

Regions with low losses(e.g., due to residual gas)

The LHCLoss Regions

Point 1

Point 2

Point 3.2

Point 3.3

Point 4 Point 5

Point 6

Point 7

Point 8

ALICE

LHCb

MomentunCleaning

RF CMS

LHC Dump

BetatronCleaning

LHC: collimation, beam dump effects

Applications

Page 19: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

8 hours

1 week

4 months

Cooling time

CERN-SC-2005-092-RP-TN

Residual dose rate (mSv/h)after one year of operation

Applications

Page 20: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Warm QuadrupoleCold Dipole

LHC: Complex magnetic fields included

Applications

Page 21: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Atmosphere: 100 layersAtmosphere: 100 layers

Cone amplitudeCone amplitudeDepending on allowed toleranceDepending on allowed toleranceOn geomagnetic cut-offOn geomagnetic cut-off

( 50 or 200 as options )( 50 or 200 as options )

Cosmic rays: Physics and dosimetry

First 3-D calculation of atmospheric neutrinoswas done with FLUKA. Showed unexpectedenhancement in the horizontal direction.

Applications

Page 22: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgApplicationsDosimetry: Aviation and space missions

Atmospheric neutron fluenceabove Narita Airport (Tokyo)

Ambient dose equivalent from neutronsat solar activity maximum, on commercialflights from Seattle to Hamburg and fromFrankfurt to Johannesburg

S. Roesler et al., Rad. Prot. Dos. 98 (2002) 367

Page 23: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgApplications

CNGS CNGS: Cern Neutrino beam to Gran Sasso

• FLUKA has been used for the physics and engineering design of the CNGS

• The simulation includes all details of beam transport, interaction, structure of target, horn focusing, decay, etc.

Page 24: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgApplications

CNGS: Properties of the neutrino beam

Neutrino event spectra at Gran Sasso National Laboratory

Page 25: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

ICARUS: LAr TPC• Large sensitive volume• Continuously sensitive• Self-triggering• 3D views of ionising events with particle identification

• Also acts as good homogenous calorimeter of very fine granularity

The two 300-ton ICARUSmodules inside Laboratori

Nazionali di Gran Sasso, Italy

FLUKA used for:• full detector simulation• atmospheric neutrino generation and interactions• CNGS beam simulation• Interaction of solar and supernova neutrinos• Generation and detection of proton decay• Calculation of underground muon events

Applications

Page 26: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgApplications

ICARUS: Cosmic ray events

The geometry of the mountain has beendescribed using the voxel system of FLUKA. Here: 1 voxel = 100 x 100 x 50 m3

Transport model:Transport model: FLUKA  (all processes switched on but no 

production of secondaries)GS  geometry:GS  geometry:       (as  taken  from  the  map 

used in the MACRO experiment) Input:Input:  output  event  by  event  from 

atmospheric shower generationOutput:Output:    event  by  event,  the  muons 

survived  at  the  depth  of  underground GS lab: 963 m below the surface

Page 27: The FLUKA Monte Carlo code - Uppsala University

www.fluka.orgApplications

176

cm

434 cm

Shower

Hadronic interaction

ICARUS: Cosmic ray events

FLUKA simulation

Page 28: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Medical applications12C ions (400 MeV/u) in Water

Exp. Data: Haettner et al, Rad. Prot. Dos. 122 (2006) 485Simulation: A. Mairani, PhD Thesis, Pavia, 2007

Applications

Page 29: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

K. Parodi et al, JPCS 74, 2007

Treatment Planning

Medical applicationsFLUKA can embed voxel structures within its standardcombinatorial geometry

Optimized transport through the voxelsRaw CT-scan outputs can be imported

FLUKA simulationmGy mGy

Applications

Page 30: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Tools

TITLE60.4 MeV proton on Natural Beryllium target assembly*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..DEFAULTS EET/TRANBEAM -0.0604 0.0 0.0 -0.0 -0.0 1. PROTON*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..BEAMPOS 0.0 0.0 0.0DISCARD 3.0 4.0 5.0 6.0EMFPHOTONUC 1.0 3.0 43.0 1.0*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..GEOBEGIN COMBINAT Beryllium Target* Bodies*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..**AAA*IIII_________+_________+_________+_________+_________+_________+ SPH 1 +0.0 +0.0 +0.0 +100000.0 SPH 2 +0.0 +0.0 +0.0 +1000.0* 5 infinite circular cylinders ZCC 3 +0.0 +0.0 +1.10 ZCC 4 +0.0 +0.0 +1.20 ZCC 5 +0.0 +0.0 +1.70 ZCC 6 +0.0 +0.0 +1.80 ZCC 7 +0.0 +0.0 +2.20* Infinite planes dividing the cylinders XYP 8 +0.0 XYP 9 +1.85 XYP 10 +2.45 XYP 11 +2.55 XYP 12 +2.60 XYP 13 +2.65* Planes at an angle for the copper/water cooling spiral PLA 14 .08715574 0.0 .99619470 1.7 0.0 0.05 PLA 15 .08715574 0.0 .99619470 1.7 0.0 2.05*...+....1....+....2....+....3....+....4....+....5....+....6....+....7.. SPH 16 +0.0 +0.0 +0.0 +10.0* USRBDX detector planes at 190 cm and 195 cm XYP 17 190.0 XYP 18 195.0 RPP 19 -15.0 +15.0 -11.5 +11.5 189.0 210.0 XYP 20 -1.0* Precollimator XYP 21 19.9 XYP 22 24.15 XYP 23 48.15* Cylinder to construct the upper bump in precollimator ZCC 24 0.0 0.0 7.0* Truncated cone TRC 25 0.0 0.0 50.15 0.0 0.0 -32.25 5.3168141 3.4331858

* Air below water phantom 017 +27 -30* Air in neutron trap 018 +28 -27* Air above large paraffin blocks 019 OR +27 +59 -26 -62 -63 -64 -65OR +26 -23* Air on outside of large paraffin blocks 020 OR +27 -59 +58 -37OR +27 -59 +58 +38OR +27 -59 +58 -39OR +27 -59 +58 -40OR +27 -59 +58 +41OR +27 -59 +58 +42OR +27 -59 +58 -43 -35OR +27 -59 +58 -44 -36OR +27 -59 +58 +45 -36OR +27 -59 +58 +46 -35OR +27 -58 +57 -47OR +27 -58 +57 +48OR +27 -58 +57 -49OR +27 -58 +57 -50OR +27 -58 +57 +51OR +27 -58 +57 +52OR +27 -58 +57 -53 OR +27 -58 +57 -54OR +27 -58 +57 +55OR +27 -58 +57 +56OR +27 -59 +58 +43 -53 -35 +60OR +27 -59 +58 -46 +56 -35 -61OR +27 -59 +58 +44 -54 -36 +60OR +27 -59 +58 -45 +55 -36 -61*_AAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIII* Region Paraffine 021 +35 022 +36 023 OR +58 -59 -60 +37 +39 +40 +43 +44OR +57 -58 -60 +47 +49 +50 +53 +54 024 OR +58 -59 +61 -38 -41 -42 -45 -46OR +57 -58 +61 -48 -51 -52 -55 -56 025 OR +62OR +63OR +64OR +65* Air inbetween large paraffin blocks 026 OR +57 -59 +60 -61 +53 +54 -55 -56 -35 -36 END GEOEND*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..*GEOEND 100.0 100.0 200.0 -100.0 -100.0 -70.0 DEBUG*GEOEND 200.0 200.0 200.0 &BIASING 0.0 0.0 1.0 3.0BIASING 0.0 0.0 3.0 4.0BIASING 0.0 0.0 3.0 6.0*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..MATERIAL 1.0 1.0 0.0000899 3.0 HYDROGENMATERIAL 4.0 9.012182 1.85 5.0 BERYLLIUMATERIAL 6.0 12.01 2.25 6.0 CARBONMATERIAL 8.0 16.0 0.00143 8.0 OXYGENMATERIAL 12.0 24.305 1.738 9.0 MAGNESIUMATERIAL 13.0 26.982 2.7 10.0 ALUMINUMMATERIAL 26.0 55.847 7.2 11.0 IRONMATERIAL 29.0 63.546 8.96 12.0 COPPERMATERIAL 27.0 58.9332 8.9 22.0 COBALT

Page 31: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Tools: flair

TITLE60.4 MeV proton on Natural Beryllium target assembly*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..DEFAULTS EET/TRANBEAM -0.0604 0.0 0.0 -0.0 -0.0 1. PROTON*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..BEAMPOS 0.0 0.0 0.0DISCARD 3.0 4.0 5.0 6.0EMFPHOTONUC 1.0 3.0 43.0 1.0*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..GEOBEGIN COMBINAT Beryllium Target* Bodies*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..**AAA*IIII_________+_________+_________+_________+_________+_________+ SPH 1 +0.0 +0.0 +0.0 +100000.0 SPH 2 +0.0 +0.0 +0.0 +1000.0* 5 infinite circular cylinders ZCC 3 +0.0 +0.0 +1.10 ZCC 4 +0.0 +0.0 +1.20 ZCC 5 +0.0 +0.0 +1.70 ZCC 6 +0.0 +0.0 +1.80 ZCC 7 +0.0 +0.0 +2.20* Infinite planes dividing the cylinders XYP 8 +0.0 XYP 9 +1.85 XYP 10 +2.45 XYP 11 +2.55 XYP 12 +2.60 XYP 13 +2.65* Planes at an angle for the copper/water cooling spiral PLA 14 .08715574 0.0 .99619470 1.7 0.0 0.05 PLA 15 .08715574 0.0 .99619470 1.7 0.0 2.05*...+....1....+....2....+....3....+....4....+....5....+....6....+....7.. SPH 16 +0.0 +0.0 +0.0 +10.0* USRBDX detector planes at 190 cm and 195 cm XYP 17 190.0 XYP 18 195.0 RPP 19 -15.0 +15.0 -11.5 +11.5 189.0 210.0 XYP 20 -1.0* Precollimator XYP 21 19.9 XYP 22 24.15 XYP 23 48.15* Cylinder to construct the upper bump in precollimator ZCC 24 0.0 0.0 7.0* Truncated cone TRC 25 0.0 0.0 50.15 0.0 0.0 -32.25 5.3168141 3.4331858

* Air below water phantom 017 +27 -30* Air in neutron trap 018 +28 -27* Air above large paraffin blocks 019 OR +27 +59 -26 -62 -63 -64 -65OR +26 -23* Air on outside of large paraffin blocks 020 OR +27 -59 +58 -37OR +27 -59 +58 +38OR +27 -59 +58 -39OR +27 -59 +58 -40OR +27 -59 +58 +41OR +27 -59 +58 +42OR +27 -59 +58 -43 -35OR +27 -59 +58 -44 -36OR +27 -59 +58 +45 -36OR +27 -59 +58 +46 -35OR +27 -58 +57 -47OR +27 -58 +57 +48OR +27 -58 +57 -49OR +27 -58 +57 -50OR +27 -58 +57 +51OR +27 -58 +57 +52OR +27 -58 +57 -53 OR +27 -58 +57 -54OR +27 -58 +57 +55OR +27 -58 +57 +56OR +27 -59 +58 +43 -53 -35 +60OR +27 -59 +58 -46 +56 -35 -61OR +27 -59 +58 +44 -54 -36 +60OR +27 -59 +58 -45 +55 -36 -61*_AAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIIIAAIIIII* Region Paraffine 021 +35 022 +36 023 OR +58 -59 -60 +37 +39 +40 +43 +44OR +57 -58 -60 +47 +49 +50 +53 +54 024 OR +58 -59 +61 -38 -41 -42 -45 -46OR +57 -58 +61 -48 -51 -52 -55 -56 025 OR +62OR +63OR +64OR +65* Air inbetween large paraffin blocks 026 OR +57 -59 +60 -61 +53 +54 -55 -56 -35 -36 END GEOEND*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..*GEOEND 100.0 100.0 200.0 -100.0 -100.0 -70.0 DEBUG*GEOEND 200.0 200.0 200.0 &BIASING 0.0 0.0 1.0 3.0BIASING 0.0 0.0 3.0 4.0BIASING 0.0 0.0 3.0 6.0*...+....1....+....2....+....3....+....4....+....5....+....6....+....7..MATERIAL 1.0 1.0 0.0000899 3.0 HYDROGENMATERIAL 4.0 9.012182 1.85 5.0 BERYLLIUMATERIAL 6.0 12.01 2.25 6.0 CARBONMATERIAL 8.0 16.0 0.00143 8.0 OXYGENMATERIAL 12.0 24.305 1.738 9.0 MAGNESIUMATERIAL 13.0 26.982 2.7 10.0 ALUMINUMMATERIAL 26.0 55.847 7.2 11.0 IRONMATERIAL 29.0 63.546 8.96 12.0 COPPERMATERIAL 27.0 58.9332 8.9 22.0 COBALT

Page 32: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Tools

Old way: 2-dimensional cutsfor debugging and visualizationof energy deposition, fluence,dose rate, etc...(still nice, but...)

File: lacassagne.inp

Page 33: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Tools: flair

File: lacassagne.inp

Page 34: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Tools: SimpleGeo

File: lacassagne.inp

Page 35: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Example with flair

Page 36: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Example with flair

Page 37: The FLUKA Monte Carlo code - Uppsala University

Part 2: Use existing course materialGo to the FLUKA web site http://www.fluka.orgClick on ”Courses” and select the 12th FLUKA Course (JLAB 2012)Click on ”Program”Also check out the Advanced Course & Workshop (Vancouver 2012)

Page 38: The FLUKA Monte Carlo code - Uppsala University

www.fluka.org

Some of the downloadable pdfs are also available on Studentportalen