Download presentation
Presentation is loading. Please wait.
Published byMarylou O’Connor’ Modified over 6 years ago
1
variance reduction techniques to improve efficiency of calculation B
PHITS Multi-Purpose Particle and Heavy Ion Transport code System variance reduction techniques to improve efficiency of calculation B January 2017 revised title
2
Contents of Lecture Neutron deep penetration calculation
[weight window] Weight windows [weight window generator] Function of automatically production of [weight window]
3
Concept of weight in Monte Carlo calculation
Example:track length tally Weight: Importance of the particle in Monte Carlo simulation always to be 1 for normal calculation* Artificially increase the probability of rare event occurrences. Frequency distribution per a history cannot be calculated, e.g. [t-deposit] with output = deposit, NO MORE event generator! *Not the case for low-energy neutron transport simulation
4
Difference between cell importance and weight window methods
“Cell importance method” assign a single value of weight for each cell. “Weight window method” assign allowed weight range (window) for each cell and each energy group. Efficient simulation with focusing on the important energy region, such as high-energy neutron. WU=2.5 WU=2.5 I1=1 I2=3 WU=1.25 W1=1 W=1 W1=1 Weight Weight Weight WU=0.83 WL=0.5 WL=0.5 W2=1/3 WL=0.25 W2=0.5 region1 region2 WL=0.17 region1 region2 region1 region2 Number of particle 1 → energy group1 energy group2 I2/I1=3 Number of particle 1 → 1 1→ W1/W2=2 Cell importance method Weight window method
5
Parameters Related to Weight Window
wupn: Ratio of the upper and lower limits of allowed weight (D=5.0) mxspln: Maximum number of split per event (D=5.0) mwhere: Timing for considering weight window (D=0) -1: reaction, 0: both, 1: crossing surface These parameters should be defined in [parameters] section. See manual “4.2.4 Cut off time, cut off weight, and weight window” in more detail.
6
Check the Trajectory of Single Particle
Let’s execute “weight-hist.inp”, and check the neutron trajectory Air Water (r= 10cm, Depth = 5cm×2) 5MeV neutron weight-trajectory.eps
7
Set [Weight Window] Section
Activate the 1st [weight window] section in weight-hist.inp, and execute PHITS! weight-hist.inp [weight window] part = neutron reg ww1 Lower limit of allowed weights, WL, for each cell is defined in [weight window] Upper limit of allowed weights, WU, is automatically set to WL x wupn (D=5) Set value in each region Same weight window for all energies WU=5 x WL =1.25 W1=1 Weight WL=0.25 WL=0.25 Cell 1 Cell 2 weight-trajectory.eps Weight of neutron is within the weight window range -> No split and No Russian Roulette
8
Let’s Decrease Weight Window in Cell 2
weight-hist.inp [weight window] part = neutron reg ww1 Decrease the lower limit of allowed weights in cell 2, and execute PHITS! WU=1.25 W1=1 WU=0.625 Weight WL=0.25 WL=0.125 Cell 1 Cell 2 Particle Split weight-trajectory.eps Neutron is divided into 2 because its weight (=1) is higher than the upper limit (=0.625)
9
Let’s Decrease Weight Window in Cell 2 EXTREMELY!
weight-hist.inp [weight window] part = neutron reg ww1 Decrease the lower limit of allowed weights in cell 2 EXTREMELY, and execute PHITS! WU=1.25 W1=1 Weight WL=0.25 WU=0.025 WL=0.005 Cell 1 Cell 2 weight-trajectory.eps Divided into neutrons of mxspln(D=5) by each event (crossing surface or reaction) It is better to set 2~3 for max weight window ratio between neighboring cells
10
Set different Weight Window for Each Energy Group
weight-hist.inp [weight window] part = neutron eng = 2 e5 reg ww ww2 Let’s “off” the 1st [weight window], and activate the 2nd one & execute PHITS Maximum energy for each group 2 energy groups are defined But the weight window are the same for each group WU=1.25 WU=1.25 W1=1 W1=1 WU=0.625 WU=0.625 Weight Weight WL=0.25 WL=0.25 WL=0.125 WL=0.125 Cell 1 Cell 2 Cell 1 Cell 2 Particle Split Particle Split E < 0.01 MeV 0.01 MeV < E < 105MeV weight-trajectory.eps Neutron is divided into 2 because its weight (=1) is higher than the upper limit (=0.625) (Same as 2 pages before)
11
Increase Weight Window Only for Low-Energy Neutrons
weight-hist.inp [weight window] part = neutron eng = 2 e5 reg ww ww2 * * Increase weight window for low-energy neutrons by 10 times, and execute PHITS WU=12.5 WU=6.25 WU=1.25 WL=2.5 Low-energy neutron is killed WL=1.25 W1=1 W1=1 WU=0.625 Weight Weight WL=0.25 WL=0.125 Cell 1 Cell 2 Russian Roulette Cell 1 Cell 2 Particle Split E < 0.01 MeV 0.01 MeV < E < 105MeV weight-trajectory.eps Reduce the production of low-energy neutrons, and concentrate on high-energy neutron transport simulation Get poor and better statistics at shallower and deeper locations, respectively
12
Example of calculation using [weight window]
Execute PHITS using weight.inp, and check your CPU time weight.inp Geometry, source, history are the same as imp.inp [weight window] set: c10[1.0] part = neutron eng = 2 1.0e e5 reg ww ww2 1 c10*2.5**(-1) 2.5**(-1) 2 c10*2.5**(-2) 2.5**(-2) 3 c10*2.5**(-3) 2.5**(-3) ・・・ Cylindrical Concrete (r = 50cm, depth = 1.8 m) 14MeV neutron Depth of each cell = 15 cm total cpu time = sec Decrease weight window of neighboring cells by 1/2.5 for particle split Set same weight window for all energy groups (because c10=1.0) weight-dose-xz.eps weight-dose-xz_err.eps
13
Example of calculation using [weight window]
Increase the weight window for low-energy neutrons by 10 times, and execute PHITS weight.inp [weight window] set: c10[10.0] part = neutron eng = 2 1.0e e5 reg ww ww2 1 c10*2.5**(-1) 2.5**(-1) 2 c10*2.5**(-2) 2.5**(-2) 3 c10*2.5**(-3) 2.5**(-3) ・・・ Most low-energy neutrons are immediately killed when they produced, because of Russian Roulette Low-energy neutrons have short range, so statistical uncertainties of deeper locations do not change that much total cpu time = > 14.53 sec weight-dose-xz.eps weight-dose-xz_err.eps
14
Comparison of CPU time total cpu time = 19.53 sec
Normal calculation (No [importance], No [weight window]) total cpu time = sec Use [importance] total cpu time = sec Use [weight window]; same value for all energies total cpu time = sec Use [weight window]; different values for low- and high-energy neutrons total cpu time = sec
15
Dose Reduction Rate in Concrete
90 cm 180 cm Good agreement except for deeper location doses obtained from default setting You can improve the efficiency of your calculation by appropriately setting weight window for each neutron energy group
16
Contents of Lecture Neutron deep penetration calculation
[weight window] Weight windows [weight window generator] Function of automatically production of [weight window]
17
Weight Window Generator [t-WWG]
Tally to generate appropriate weight window automatically in each cell mesh=reg only because [weight window] allows mesh=reg. 【Procedure of automatically generation】 To generate the weight window, track length of particle normalized by a volume in each cell is calculated (flux: 1/cm2). Same method with [t-track]. It is necessary to define a volume in each cell in [volume] section. [ T - WWG ] mesh = reg reg = {1-12} part = neutron e-type = 1 ne = 2 e5 axis = wwg file = WWG.out The weight window is given by a flux in each cell normalized by the maximum flux. In a cell where flux is zero, the weight window is given by the minimum flux with finite value. This procedure applies to each particle and energy bin.
18
Neutron Deep Penetration Calculation with WWG
Calculate neutron transport in thick shield and dose rate distribution to depth Execute “imp.inp” and check geometry. WWG.inp [ P a r a m e t e r s ] icntl = maxcas = maxbch = … 14MeV neutron weight-dose-xz.eps 100 cm radius x 180 cm thick cylinder
19
Check Output file of [t-WWG]
Let’s execute “WWG.inp” with icntl=0, and check “WWG.out”. WWG.out Initial value of weight window WWG.inp [ T - WWG ] mesh = reg reg = {1-12} part = neutron e-type = 1 ne = 2 $ 2 energy bin e5 axis = wwg file = WWG.out [ Weight Window ] set: c71[0.0] c72[c E-08] c73[ E-05] set: c74[0.0] c75[c E-08] c76[ E-05] part = neutron eng = 2 E E+05 reg ww ww2 1 ( E-05+c71)/c73 ( E-05+c74)/c76 2 ( E-05+c71)/c73 ( E-05+c74)/c76 3 ( E-05+c71)/c73 ( E-05+c74)/c76 4 ( E-05+c71)/c73 ( E-06+c74)/c76 5 ( E-06+c71)/c73 ( E-06+c74)/c76 6 ( E-06+c71)/c73 ( E-07+c74)/c76 7 ( E-07+c71)/c73 ( E-07+c74)/c76 8 ( E-07+c71)/c73 ( E-08+c74)/c76 9 ( E-08+c71)/c73 ( E+00+c75)/c76 10 ( E-08+c71)/c73 ( E+00+c75)/c76 11 ( E+00+c72)/c73 ( E+00+c75)/c76 12 ( E+00+c72)/c73 ( E+00+c75)/c76 Minimum flux Maximum flux weight-dose-xz_err.eps Without weight window WWG gives minimum value in the cell where flux is zero.
20
Particle Deep Penetration Calculation with WWG
Method for efficient deep penetration of particles using results of [t-WWG] In the 1st transport calculation, the initial weight window are generated by [t-WWG]. In the 2nd, the weight window are updated by initial values of weight window. After the 3rd, calculations are repeated until particles are transported to overall, and then you can obtain the appropriate weight window. After checking the weight window, you can adjust the total history.
21
Recalculation using Output Results of [t-WWG]
Activate the infl: {WWG.out} in “WWG.inp”, and execute PHITS WWG.out The weight window obtained by the 2nd calculation Total history = 1,500 [ Weight Window ] set: c71[0.0] c72[c E-09] c73[ E-05] set: c74[0.0] c75[c E-10] c76[ E-05] part = neutron eng = 2 E E+05 reg ww ww2 1 ( E-05+c71)/c73 ( E-05+c74)/c76 2 ( E-05+c71)/c73 ( E-05+c74)/c76 3 ( E-05+c71)/c73 ( E-05+c74)/c76 4 ( E-05+c71)/c73 ( E-06+c74)/c76 5 ( E-06+c71)/c73 ( E-06+c74)/c76 6 ( E-06+c71)/c73 ( E-07+c74)/c76 7 ( E-06+c71)/c73 ( E-07+c74)/c76 8 ( E-07+c71)/c73 ( E-08+c74)/c76 9 ( E-07+c71)/c73 ( E-08+c74)/c76 10 ( E-08+c71)/c73 ( E-09+c74)/c76 11 ( E-09+c71)/c73 ( E-09+c74)/c76 12 ( E-09+c71)/c73 ( E-10+c74)/c76 Use the 1st weight window “WWG.out” is updated every execution Do not change input file name “WWG.inp” weight-dose-xz_err.eps There is no region where flux is zero.
22
Execute 3rd Calculation
Let’s execute 3rd calculation and check distribution to depth and radial directions. Total history = 1,500 Use the 2nd weight window. “WWG.out” is updated every execution. weight-dose-reg.eps Dose reduction rate in concrete weight-dose-xz_err.eps *Statistic of photon dose in deeper location is not enough because WWG is not applied to photon. As the same weight window is used in a cell, the large difference among fluxes in a cell causes a region with poor statistic in a cell.
23
Divide Cell to Radial Direction
Let’s execute “WWG2.inp” with cells divided to radial direction and check geometry. Calculate the effective dose rate in cell 60 (r= cm, z= cm). WWG2.inp [ P a r a m e t e r s ] icntl = maxcas = maxbch = emin(2) = E-10 dmax(2) = file(6) = phits.out file(7) = c:/phits/data/xsdir.jnd file(14) = c:/phits/data/trxcrd.dat $ infl: {WWG2.out} … weight-dose-xz.eps Divide cell into 5 parts to radial direction R=0~20cm, 20~40cm, 40~60cm,60~80cm, 80~100 cm
24
Particle Transport Calculation in Geometry with Cell Divided to Radial Direction
Let’s execute 1st calculation using “WWG2.inp” with “icntl=0” and generate the initial weight window. Total history = 1,500 WWG2.out [ Weight Window ] set: c71[0.0] c72[c E-09] c73[ E-04] set: c74[0.0] c75[c E-08] c76[ E-03] part = neutron eng = 2 E E+05 reg ww ww2 1 ( E-04+c71)/c73 ( E-03+c74)/c76 2 ( E-04+c71)/c73 ( E-04+c74)/c76 3 ( E-04+c71)/c73 ( E-04+c74)/c76 4 ( E-04+c71)/c73 ( E-05+c74)/c76 …… weight-dose-xz_err.eps Without weight window
25
Divide cell to transport particles overall efficiently
Particle Transport Calculation in Geometry with Cell Divided to Radial Direction Let’s activate the infl: {WWG2.out} in “WWG2.inp” and execute 2nd and 3rd calculations. weight-dose-xz_err.eps weight-dose-xz_err.eps weight-dose-xz_err.eps Results of 2nd calculation Results of 3rd calculation 【reference】 Results of 3rd calculation with “WWG.inp” Divide cell to transport particles overall efficiently
26
Increase the number of history and check effective dose rate
Change maxbch=5 in WWG2.inp, increase the number of history, and execute calculation Calculate dose rate in cell 60(r= cm, z= cm) Check dose rate in “weight-dose-reg.out” weight-dose-reg.out x: Serial Num. of Region y: dose [(\muSv/h)/(source/sec)] p: xlin ylog afac(0.8) form(0.9) h: x n n y(neutron ),l3 n # num reg volume neutron r.err E E E E E E E E E E E E E E E E E E E E E E E E weight-dose-xz_err.eps *omit photon dose rate
27
Task: Deep Penetration Calculation for 14 MeV Photon
Let’s change the [source] section in “WWG2.inp” to use 14 MeV photon with isotropic direction and calculate photon dose rate in cell 60. Firstly, generate the initial weight window with [t-WWG]. Initial history number (maxcas=1500, maxbch=1) Disable “infl command” In [T-WWG], particle is photon, energy bin is 0-1MeV and 1-105MeV. WWG2.inp for this task [ P a r a m e t e r s ] icntl = maxcas = maxbch = 1 … $ infl: {WWG2.out} [ T - WWG ] mesh = reg reg = {1-60} part = photon e-type = 1 ne = 2 e5 … [ S o u r c e ] s-type = 1 proj = photon e0 = … dir = all weight-dose-xz_err.eps Without weight window
28
Task: Deep Penetration Calculation for 14 MeV Photon
Activate infl command and use the initial weight window weight-dose-xz_err.eps Warning due to many particle productions Without weight window Small values of weight window are set in a cell where photon does not come, and the number of split particle increases. It is better to increase the number of history and transportation of particles to generate the initial weight window.
29
Task: Deep Penetration Calculation for 14 MeV Photon
Change History number (maxcas=30000, maxbch=1), disable infl command and generate the initial weight window Activate infl command and calculate dose rate in cell 60 with the initial weight window weight-dose-xz_err.eps With the initial weight window weight-dose-xz_err.eps Cell60 8.27E-11(μSv/h)/(source/sec) Statistical error Without weight window
30
Summary “Weight window method” assign allowed weight range (window) for each cell and each energy group. [t-WWG] generate appropriate weight window automatically in each cell and energy. The weight window is given by a flux in each cell normalized by the maximum flux. It is necessary to define a volume in each cell in [volume] section. It is convenient for particle transport calculation to read output file of [t-WWG](= the [weight window] section) by the infl command except for the 1st calculation. Note that warning message due to many particle productions appears when statistics of the 1st calculation is very bad.
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.