Monte Carlo simulation of photon transport for radiographic devices

Dec 11, 2001 - Let us recall an elementary result. If Θ is a random variable ...... stochatic differential equations : variance reduction and numerical examples" ...
1MB taille 2 téléchargements 305 vues
Monte Carlo simulation of photon transport for radiographic devices and associated biasing techniques B. Chalmond and

Z. Ouertani

CMLA, Ecole Normale Supérieure, Cachan, France preprint 11 december 2001 Résumé This article is concerned with the simulation of photon transport in a material in order to perform a radiography of its inner structure. Photon transport is classically modelized by a Markov chain whose transition probabilities are given by the physical laws of photon-material interactions. Radiographic image is simulated using a Monte Carlo technique which estimates the probability that a photon emitted by the radiographic source escapes from the material at a given site. The first goal of this article is the variance reduction of this estimation. We describe three variance biasing techniques : first, by antithetic variables, second by importance sampling, third by constrained Markov chain. This study has been driven in the context of the development of a radiographic simulation software whose we give experimental results.

1

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

Table des matières 1 Introduction

3

2 Photon transport 2.1 Natural Markov chain . . . . . . . . . . . . . . . . . . . . . . 2.2 Physical laws . . . . . . . . . . . . . . . . . . . . . . . . . . .

4 4 5

3 Monte Carlo computing 3.1 Image simulation . . . . . . . . . . . . . . . . . . . . . . . . . 3.2 Transition kernel of the Markov chain . . . . . . . . . . . . . 3.3 Quantity to estimate . . . . . . . . . . . . . . . . . . . . . . .

6 6 7 10

4 Variance reduction by antithetic variables

11

5 Variance reduction by importance 5.1 Principle . . . . . . . . . . . . . . 5.2 Importance function estimation . 5.3 Constrained Markov chain . . . .

sampling 13 . . . . . . . . . . . . . . . . 13 . . . . . . . . . . . . . . . . 15 . . . . . . . . . . . . . . . . 16

6 Conclusion

19

7 Annexes 19 7.1 A1- Physical laws . . . . . . . . . . . . . . . . . . . . . . . . . 19 7.2 A2- Theorem proof . . . . . . . . . . . . . . . . . . . . . . . . 21

2

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

1

Introduction

This article deals with the simulation of photon transport in an object composed of a piece of material containing inclusions which are empty or filled by another materials. Photons are emitted by a gamma source with high energy (up to 1.33 MeV). The object being relatively thick (up to several centimeters), photons encounter several collisions that modify their direction and energy until they escape from the object or are absorbed by it (see Fig. 1). Photon transport is defined by its successive collisions in the object. Industrial radiography is the context of our study [2]. Here, the radiographic system is limited to photon transport in the object. So, we shall examine the simulation results with regard to "virtual images" obtained by counting, on a regular grid G placed behind the object, the repartition of photons that reach G. However, in [3], one present a software to perform the simulation of the entire radiographic system, i.e., from the source to the detector composed of a stack of metallic screens and argentic films. Our simulation is of Monte Carlo type [6, 11]. This simulation consists of estimating the probability Pε that a photon reaches the cell ε of G. By the large number law, this estimation is given by the proportion Nε /N of the number Nε of photons that reach ε among N photons emitted by the source. This paper aims to reduce the variance of this estimation in order to reduce computing times. Indeed, we have to emit several ten of millions of photons to obtain a simulated small image with sufficient quality. In that case, the estimation of {Pε , ε ∈ G} takes several hours. Variance reduction means : "to obtain a simulated image of equivalent quality with a smaller number of photons N ". Let us emphasize that to gain an advantage, we must have the assurance that the increasing in computation complexity due to the technique of reduction, does not make lost the expected advantage. Variance reduction has been widely studied for random variables, but presents more difficulties for Markov processes ([6, 13, 16, 17] among many others). In this paper, we examine three techniques : the first one is based on "antithetic" variables which correspond in our case to a duplication of the photon angular direction, the second one achieves an importance sampling for which the importance function is estimated using a maximum likelihood principle, and the third one constrains the Markov chain through a Gibbs distribution whose energy is built to favor photon trajectories reaching G.

3

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

2

Photon transport This section is a survey of photon transport modeling [4, 10, 12, 14, 15,

17].

2.1

Natural Markov chain

Classically, photon transport is described by a Markov chain which translates the physic of collisions. At the n-th collision, the photon state is characterized by its spatial position sn inside the object M ⊂ IR3 and its direction vn just before the collision : sn = sn−1 + n vn , where n = sn − sn−1  is the distance between sn−1 and sn , vn being a unit vector in IR3 . The photon state is also characterized by its energy λn just after the collision. In fact, the photon state zn = (n , vn , λn ) is the occurrence of a random vector : Zn = (Ln , Vn , Λn ) ,

(1)

which is only related to those before the collision, what can be modeled by a "natural" Markov chain {Zn , n ≥ 0}. Its occurrences (n , vn , λn ) belong to E = IR+ × IR2 × IR+ . So, sn is the occurrence of a random vector Sn . {sn , n > 0} are collision positions and s0 is the position of the photon emitted by the spherical source Υ ⊂ IR3 . Let us described a photon trajectory (Fig.1). Two type of trajectories can occur : either the photon passes directly through the object and escapes from it (then it contributes to the so-called direct flux), or it collides within the object (then it contributes to the so-called diffused flux). In photon transport modeling, these two situations are simultaneously taken into account. At the n-th collision, the photon state is zn = (n , vn , λn ). If λn < λ∗ , λ∗ being a known value, then the photon is absorbed. Otherwise, before the next collision, it moves in M during a distance n+1 in direction vn+1 . At the n-th collision, three random events can occur : – photoelectric absorption (P ho), – Compton diffusion (Com), – Rayleigh diffusion (Ray). In non absorption case, the direction of diffusion is defined by a unit vector vn computed from vn−1 with a angular deviation φn and uniform direction around vn−1 described by a random variable Θn uniformly distributed on [0, 2π], independently of the other ones. Then, the random vector Vn is the function : Vn = R (Vn−1 , Φn , Θn ) . 4

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

s n -1

φn

c n -1

λn -1

vn v n+1

v n-1

ln sn

cn

λn

Fig. 1 – Photon transport.

By denoting v = (a, b, c) , R is written : ⎧ ⎪ cos(φ) v + sin(φ) (cos(θ)i + sin(θ)k ) if v = j, ⎪ ⎪ ⎞ ⎛ ⎪ ⎨ c cos(θ) + a b sin(θ) R (v, φ, θ) = ⎟ sin(φ) ⎜ ⎪  j. cos(φ) v + a2 +c2 ⎝ −(a2 + c2 )sin(θ) ⎠ if v = ⎪ ⎪ ⎪ ⎩ −a cos(θ) + b c sin(θ)

2.2

Physical laws

We recall the probability distributions which governs the random variables describing photon transport. Let Cn be the discrete random variable of collisions and c be its occurrences {P ho, Com, Ray}. Cn depends on λn−1 and is distributed according to : Γ(c | λ) = P (Cn = c | Λn−1 = λ) .

(2)

In case of Rayleigh diffusion, (Cn = Ray), photon does not loss energy and its trajectory is deviated with an angle φn+1 with respect to the incident direction vn . This deviation is represented by the conditional random variable variable (Φn+1 | Cn = Ray) which obeys to the probability distribution hRay (φ) : (Φn+1 | Cn = Ray) ∼ hRay (φ) .

(3)

In case of Compton diffusion, (Cn = Com), photon losses energy and its trajectory is deviated with an angle φn+1 function of the incident energy. 5

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

This deviation is represented by the conditional random variable variable (Φn+1 | Cn = Com, Λn = λ) which obeys to the probability distribution hCom (φ | λ) : (Φn+1 | Cn = Com, Λn = λ) ∼ hCom (φ | λ) .

(4)

The energy λ = g(λ, φ) of a deviated photon is then : λ = g(λ, φ) =

1+

λ , − cos φ)

λ λe (1

where λe is a known value. The distance n+1 between two successive collisions is a function of the energy λn . This distance is represented by the random variable (Ln+1 | Λn = λ) which obeys to the probability distribution h( | λ) of exponential type : (Ln+1 | Λn = λ) ∼ h( | λ) , h( | λ) = μλ exp(−μλ ) .

(5)

Expressions of μλ , (3), (4), (2) are given in Annex 1.

3 3.1

Monte Carlo computing Image simulation

Let us imagine that a virtual grid G is placed behind the object. This grid is regular and each of these cells is denoted ε. We assimilate G to a detector. Among N photons emitted by the source, some of them reach the grid. Let Nε be the number of photons reaching ε. The repartition {Nε /N, ε ∈ G} gives an array of numbers in [0, 1] that is seen as a virtual grey level image. In this article, we present experiments for a parallelipedic object of thickness Δ placed on an horizontal plane at (x, y, d = 0). It contains an inclusion represented by a parallelipedic vertical notch centered at (x = 0, y = 0). The spherical source of energy λ0 = 1.33 M eV is centered above this notch at (x = 0, y = 0, d = H +Δ). The source emits photons uniformly on its surface limited to the intersection with a solid cone of half angle φ∗ . The emitted photon direction is defined by two angles (φ, θ), φ being the deviation angle with respect to axis d = 0. (φ0 , θ0 ) is the occurrence of a random vector (Φ0 , Θ0 ). The probability distribution of Θ0 is uniform on [0, 2π] and those of Φ0 on [0, φ∗ ] is : h0 (φ) =

sin φ . 1 − cos φ∗

(6)

Fig.3 shows such a simulated image obtained with N = 10 millions of photons. In this experiment, G is composed of 100 × 100 cells. The presence 6

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

Fig. 2 – Some photon trajectories.

of the notch appears clearly. Let us emphasize that the probability Pε that a photon reaches ε is very small. Furthermore, many photons do not reach G (of order of 80 % in our experiments), either because of photoelectric absorption or because they escape outside G (cf. Fig.2). It implies that at least several ten of millions of photons must be emitted in order to obtain an image of good quality. Let us note that the huge amount of computing time is due to the diffusion process. When no collision is simulated then the computing time is strongly reduced. However, in many applications, it is necessary to take into account the diffusion process. Fig.2 illustrates this process.

3.2

Transition kernel of the Markov chain

Photon trajectory simulation is performed by simulating occurrences of the Markov chain {Zn , n ≥ 0}. This chain is completely defined by the law of Z0 and a transition kernel K. For every measurable function f , K allows to calculate the mathematical expectation of the conditional random variable [f (Zn ) | Zn−1 = z] with respect to the probability distribution K(z, .) K(z, dzn )f (zn ) = ˙ (Kf )(z) . (7) IE[f (Zn ) | Zn−1 = z] = For our application, it is useful to consider the particular case f (zn ) = 1zn ∈ε for which we have : (Kf )(z) = P [Zn ∈ ε | Zn−1 = z] . Let K (n) be the transition kernel in n steps : (K (n) f )(z) = IE[f (Zn ) | Z0 = z] .

(8)

7

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

10 20 30 40 50 60 70 80 90 100

10

20

30

40

50

60

70

80

90

100

Fig. 3 – A simulated radiographic image of a notch (using N = 10 millions of photons).

Fig. 4 – Raw profile of a notch image : with diffused flux (continuous line) and without diffused flux (dot line).

8

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

These kernels are defined as follows : (Kf (1) )(z) =

(Kf )(z) , K(z, du) (K (n−1) f )(u) , n > 1 . (K (n) f )(z) =

(9)

Note that (8) can be written (K

(n)

f )(z0 ) =

n

 (z1 ,...,zn)

 K(zk−1 , dzk ) f (zn ) .

k=1

Let us express (Kf )(z1 ) using the previous physical laws. First note that the random variables Cn+2 and Ln+2 are independent conditionally to Λn+1 , and that the random variables (Vn+2 , Λn+2 ) and Ln+2 are independent conditionally to Zn+1 . So, we get : (Kf )(z1 ) = IE[f (Zn+2 ) | Zn+1 = z1 ] = IE[f (2 , Vn+2 , Λn+2 ) | Zn+1 = z1 ] h(2 | λ1 ) d2   = IIRay (z1 ; 2 ) + IICom (z1 ; 2 ) + IIP ho (z1 ; 2 ) h(2 | λ1 ) d2 , (10) with IIRay (z1 ; 2 ) = P (Cn+2 = Ray | Zn+1 = z1 ) × IE[f (2 , Vn+2 , Λn+2 ) | Zn+1 = z1 , Cn+2 = Ray]  f 2 , R(v1 , φ, θ), λ1 hRay (φ) dφ dθ = Γ(Ray | λ1 ) IICom (z1 ; 2 ) = P (Cn+2 = Com | Zn+1 = z1 ) × ,Λ ) | Zn+1 = z1 , Cn+2 = Com] IE[f ( , V 2 n+2 n+2  f 2 , R(v1 , φ, θ), g(λ1 , φ) hCom (φ|λ1 )dφdθ = Γ(Com|λ1 ) IIP ho (z1 ; 2 ) = P (Cn+2 = P ho | Zn+1 = z1 ) × IE[f (2 , Vn+2 , Λn+2 ) | Zn+1 = z1 , Cn+2 = P ho] = Γ(P ho | λ1 ) f (2 , v1 , 0) .

9

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

3.3

Quantity to estimate

Our goal is to compute for every ε, the estimate Pε = Nε /N of the probability Pε that a photon emitted by the radiographic source Υ reaches ε. The photon repartition {Nε /N } on the detector defines a virtual radiographic image. Let Ωε (s) be the set of all the directions reaching ε from a point s in M, and τε the arrival time : / M} , τε = inf{n ≥ 0 , : Sn ∈ {Υ, M} , Vn+1 ∈ Ωε (Sn ) et Sn+1 ∈

(11)

/ M means that the photon escapes from M, either after n where Sn+1 ∈ collisions if n > 0, or directly from S0 ∈ Υ if n = 0. The escaping probability is : Pε = =

∞  n=0 ∞ 

P (τε = n)

 P S0 ∈ Υ, S1 ∈ M , · · · , Sn ∈ M , Vn+1 ∈ Ωε (Sn ) , Sn+1 ∈ /M

n=0

= IE

∞ 

1Υ (S0 ) 1M (S1 ) · · · 1M (Sn ) 1Ωε (Vn+1 ) 1Mc (Sn+1 )



n=0

= IE[ Tε∞ (Z0 , · · · , Zn , · · · ) ] , where : Tε∞ (Z0 , · · ·

, Zn , · · · ) =

∞ 

1Υ (S0 ) 1M (S1 ) · · · 1M (Sn ) 1Ωε (Vn+1 ) 1Mc (Sn+1 ) ,

n=0

is a random variable governed by a binomial law with parameter Pε . In practice a photon encounters a small number of collisions before it escapes from M. So, we can assume that the number of collisions is bounded by a finite number, says ν (in our experiments ν = 10). In this case we have : Pε = IE[ Tεν (Z0 , · · · , Zν ) ] with ν  ν 1Υ (S0 ) 1M (S1 ) · · · 1M (Sn ) 1Ωε (Vn+1 ) 1Mc (Sn+1 ) . Tε (Z0 , · · · , Zν ) = n=0

(12) Then, the non biased estimator of Pε is : Pε =

N 1  ν (i) Tε (Z0 , · · · , Zν(i) ) , N

(13)

i=1

(i)

where {Zn , 0 ≤ n ≤ ν}i=1,··· ,N are N independent copies of the Markov chain {Zn , 0 ≤ n ≤ ν} . 10

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

4

Variance reduction by antithetic variables

Let us recall an elementary result. If Θ is a random variable then the variance of [f (Θ) + f (−Θ)]/2 is equal or lower than the variance of f (Θ). It means that variance reduction can be performed by associating to every simulation of Θ its opposite value, this value being obtained without additional computation. We are going to consider this approach in the case of Markov chains by considering the photon angular direction Θ. For every drawn angular direction θ on [0, 2π[, we associate J − 1 another directions obtained by duplication of θ as follows : {θ + j 2π J , j = 1, · · · , J − 1}. These J − 1 directions are called antithetic variables.

proposition .— Let X and Θ be two independent random variables, the law of X being μ on Rn and those of Θ being the uniform law on [0, 2π]. Let f be a measurable function on Rn × R and 2π-periodic with respect to Θ. For every real a and for every integer J we have : 1. IE[f (X, Θ)] = IE[f (X, Θ + a)]  2π 2. IE[f (X, Θ)] = IE[ J1 J−1 j=0 f (X, Θ + j J )] 3. Let { (X (i) , Θ(i) ){i=1,··· ,N } } be N independent copies of (X, Θ). The va J−1 2π (i) (i) riance of the non biased estimator N1J N i=1 j=0 f (X , Θ +j J ) is  (i) (i) smaller than those of the standard Monte Carlo estimator N1 N i=1 f (X , Θ ). Proof .—

  2π 1. IE[f (X, Θ)] = [ 0 f (x, θ) dθ] dμ(x) since X and Θ are two independent random variables.  2π  2π It suffices to show that 0 f (x, θ) dθ = 0 f (x, θ + a) dθ. But, this is true since f is 2π-periodic with respect to θ. 2. It results directly from 1. 3. It comes from the fact that the sum variance is lower than the sum of variances. 2

Let us express the estimation of Pε . Recall (12) that is : Pε =

ν 

  IE 1Υ (S0 )1M (S1 ) · · · 1M (Sn ) 1Ωμ (Vn+1 ) 1Mc (Sn+1 ) . (14)

n=0

Sn+1 is a function of (Sn , Vn+1 , Ln+1 ) in which Vn+1 is a function of (Vn , Φn+1 , Θn+1 ). The expression 1Υ (S0 ) · · · 1M (Sn ) 1Ωμ (Vn+1 ) 1Mc (Sn+1 ) is thus a ˙ 0 , · · · , Zn−1 , Sn , Φn+1 , Ln+1 ). Consequently, function fn of Θn+1 and Xn =(Z

11

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

Fig. 5 – Simulated image with J − 1 antithetic variables : (a) J = 1. (b) J = 2. (c) J = 4. (d) J = 8.

12

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

(14) is written : Pε = =

ν  n=0 ν 

IE[ fn ((Z0 , · · · , Zn−1 , Sn , Φn+1 , Ln+1 ), Θn+1 ) ] IE[ fn (Xn , Θn+1 ) ] .

(15)

n=0

The random variables Xn and Θn+1 are independent. Following Proposition (assertion 1), for every integer J, we can rewrite (15) : ν 

ν J−1  1 2π IE[ fn (Xn , Θn+1 ) ] = IE[ fn (Xn , Θn+1 ) ] J J n=0 n=0 j=0

=

ν  n=0

1 J

J−1 

  IE 1Υ (S0 )1M (S1 ) · · · 1M (Sn ) 1Ωμ (Vn+1,j ) 1Mc (Sn+1,j ) ,

j=0

where Vn+1,j is the unit vector obtained from Vn+1 by making a rotation of j 2π J around Vn , and Sn+1,j = Sn + Ln+1 Vn+1,j . Following Proposition (assertion 3), the non biased estimator of Pε : N ν J−1   1  (i) (i) (i) (i) 1Υ (S0 )1M (S1 ) · · · 1M (Sn(i) ) 1Ωμ (Vn+1,j ) 1Mc (Sn+1,j ) NJ n=0 i=1

j=0

has a smaller variance than the standard Monte Carlo estimator : N ν  1  (i) (i) (i) (i) 1Υ (S0 )1M (S1 ) · · · 1M (Sn(i) )1Ωμ (Vn+1 ) 1Mc (Sn+1 ) . N i=1

n=0

For the same number N of copies, the new estimator is more accurate. In practice, the simulation proceeds as follows. For every i = 1, ..., N , one simulate the whole chain (Z0i , Z1i , ...). Once this simulation is accomplished, one computes for each collision the value of the J − 1 antithetic variables. (i) From each point Sn , up to J photon trajectories start, and thus for each emitted photon, several trajectories can reach the detector. Fig. 5 shows the difference between the standard simulation (J = 1) and those using antithetic variables for N = 106 emitted photons.

5 5.1

Variance reduction by importance sampling Principle

• Random variable case. Let us briefly describe this technique for a simple random variable X. The goal is the estimation of the following quantity : T (x)f (x)dx = IEf [T (X)] , η = IR

13

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

where f isa probability density. Since η = IEf [T (X)], an estimator of η is η = N1 i T (Xi ) where {Xi } are N independent random variables with density f . However, the integral expression of η is not unique. If f is another density on IR then it comes : 1 f (x)  f (x)dx = η = T (x) (T W )(x)f(x)dx = IEf[(T W )(X)] , f(x) IR IR f (x) . (16) with W (x) = f(x)  Thus, a new estimator of η is η = N1 i (T W )(Xi ) where {Xi } are N independent random variables with density f. The accuracy will be improved if V arf[(T W )(X)] < V arf [T (X)]. In this case, sampling with f is more preferable to sampling with f . • Markov chain case. As we told in §3.1, many photons do not reach G, either because of photoelectric absorption or because they escape outside. The basic idea is then to biase the physical laws in order that a large proportion of photons reach the detector. This procedure needs to redefine the estimator of Pε since with these biased laws, the estimator (13) is now a biased one. Let us recall that the natural Markov chain {Zn , n ≥ 0} is governed by the continuous laws hRay (φ), hCom (φ | λ), h( | λ), h0 (φ) introduced in (3), (4), (5), (6) and by the discrete law Γ(c | λ) introduced in (2). For every new hCom (φ | λ),  h( | λ), choice of strictly positive continuous laws  hRay (φ),    | λ), we define the Markov chain {Zn , n ≥ 0} as h0 (φ), and discrete law Γ(c we have done for {Zn , n ≥ 0}, the new laws taking the place of the old ones. In (12), Pε is the quantity to estimate. It reads : Pε = = ˙ = ˙

ν 

IE[1Υ (S0 )1M (S1 ) · · · 1M (Sn ) 1Ωε (Vn+1 ) 1Mc (Sn+1 )]

n=0 ν 

IE[f0 (Z0 )f1 (Z1 ) · · · fn (Zn )fn+1 (Zn+1 )]

n=0 ν 

IE[T (Z0 , · · · , Zn+1 )] .

(17)

n=0

But with the new chain, we have IE[T (Z0 , · · · , Zn+1 )] = IE[T (Z0 , · · · , Zn+1 )]. As in (16), we shall see that it exists a debiasing function (or weighting func0 , · · · , Zn+1 ) such that : tion) W (Z IE[T (Z0 , · · · , Zn+1 )] = IE[(T W )(Z0 , · · · , Zn+1 )] . 1

In this paper (W T )(u) = W (u)T (u).

14

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

To compute the Monte Carlo estimate of Pε , first we simulate the Markov chain {Zn } and then, we use T W . In the transport photon case, let us describe the weighting function W . As we have introduced it in (16), we set : h0 (φ0 ) ,  h0 h (2 | λ1 ) , W (z1 , z2 ) =  h h  Γ Ray (Ray | λ1 ) (φ2 )1(λ1 =λ2 ) Wφ (z1 , z2 ) =   Γ hRay h  Γ Com (φ2 | λ1 )1(λ1 =λ2 ,λ2 =0) + (Com | λ1 )   Γ hCom   Γ + (P ho | λ1 ) 1(λ2 =0) ,  Γ n  Wφ W (zk , zk+1 ) . (18) W (z0 , z1 , · · · , zn , zn+1 ) = W0 (z0 ) W0 (z0 ) =

k=0

Then we get the following theorem.

theorem .— For every real measurable function T on E n+2 , and for every

choice of {Zn , n ≥ 0} verifying the positivity constraint, we have :

0 , Z1 , · · · , Zn+1 ) ] . IE[ T (Z0 , Z1 , · · · , Zn+1 ) ] = IE[ (T W )(Z Proof of this theorem is given in Annex 2.2 Finally, recalling the definitions given in §3.3 and in particular (11) and (13), the new estimator is written : Pε =

N ν  1   (i) (i) 1(τ (i) =n) Wn(i) (Z0 , · · · , Zn+1 ) . ε N i=1

5.2

n=0

Importance function estimation

The choice of biased transition laws is a difficult problem. Many experimenters have done empirical choices by successive trials [7]. In this section, we propose a technique driven by the natural Markov chain simulation itself. The basic idea is to estimate on a limited number of trajectories, the transition laws conditionally to their arrival at the detector G. Let us consider N0 independent copies of the natural Markov chain {Zn } with N0 0 , or in an extensive form : 2  n 2  n 2  n    i sin φi cos θi + i sin φi sin θi − i cos φi tan2 φ∗ > 0 , i=1

i=1

i=1

that we rewrite more concisely : en (, φ, θ) > 0 . Then, the constraint energy is : U ∗ (, φ, θ | c) =

ν 

1cn−1 =Ray 1cn−1 =Com α1en (,φ,θ)>0 .

n=1

This energy introduces interactions between n , θn and φn . Furthermore, the chain has now a long memory which go back up to the first collision. It implies that the local conditional laws of the Gibbs distribution P (z) of  (z) = U (z) + U ∗ (z) are : constraint energy U    (z) − U  (..., z|n , ...) P(ξn | zn \ξn , {zt , t < n}) ∝ exp − U   ∝ exp − U (z) − U (..., z|n , ...) ×   (20) exp − U ∗ (z) − U ∗ (..., z|n , ...) They are different of those of P (z) for ξn = n , ξn = φn and ξn = θn . The exponential law of Ln , the Klein-Nishina law of Φn and the uniform law of Θn are biased by the presence of the second exponential in (20). The analytical expression of these laws are not accessible. However, they can be easily computed if the variables are dicretized. In this situation, one have to pay attention to the computing complexity which can make loss the expected advantage in computing time. The simulation of the Markov chain Z on I = {0, 1, ..., ν} can be achieved by a Gibbs sampler [18]. This sampler is a stochastic algorithm which sweeps periodically and sequentially I as the standard simulator (see §2) do it. For every sweep and for every n ∈ I, one draws values n , φn , θn and cn according to the local conditional laws of P, and then one computes λn = λ(cn ). 18

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

6

Conclusion

In pratice, we have implemented a method based on a combination of these biasing techniques [2] [3] (see also [7]). These techniques allow us to increase the probability of photons to scatter toward a finite detector. It increases the efficiency of Monte Carlo calculations and reduces the computing time. This method is applied to the optimization of radiographic system. In an industrial context where the goal is to detect structural flaws in material, this method is included in a simulator which allows to compute gamma-ray images for different system parameters. By this way, engineers can choose an optimal set of parameters leading to the best image of the flaws without the help of on-site experiments.

7 7.1

Annexes A1- Physical laws

Let us detail the physical laws (3), (4), (2) and μλ . The collision probability (2) is : Γ(c | λ) =

σc (λ) , σCom (λ) + σRay (λ) + σP ho (λ)

where σc are called cross-sections, and can be found in specific tables [9]. These cross-sections which depend on the incident energy and the inspected material, allows to classify the three types of collision with respect to their importance. Fig.6 depicts them for the iron (Z = 26). As it is well known, we can see on this figure that photoelectric absorption and Rayleigh diffusion are predominant at low energies, whereas Compton diffusion is predominant at the high energies used in our experiments (from 0.3 M eV to 1.33 M eV ). The attenuation coefficient μλ is defined as : μλ = ( σCom (λ) + σRay (λ) + σP ho (λ) )

ρ NA −24 10 (cm−1 ) , M

where ρ is the material density (g / cm3 ), NA is the Avogadro number (6.021023 M ole−1 ), and M is the atomic weight (g / M ole). For instance, for the iron, we get ρ = 7.86 and M = 55.847. The probability density (3) of Rayleigh diffusion is given by the Thomson law : hRay (φ) ∝ (1 + cos2 φ) , ∝ symbol meaning "up to a normalizing constant".

19

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

Fig. 6 – Iron cross-sections σRay (λ) — , σCom (λ) · · · and σP ho (λ) − −−.

Fig. 7 – Rayleigh angular deviation law.

20

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

Fig. 8 – Compton angular deviation law.

The probability density (4) of Compton diffusion is given by the KleinNishina law : hCom (φ | λ) ∝  [1 + cos2 φ] 1+

2  1 1+ λ (1 + λe (1 − cos φ)

( λλe )2 (1 − cos φ)2

λ λe (1

− cos φ))(1 + cos2 φ)

 ,

where λe is a given constant (those of the electron energy at rest). Thomson law is a particular expression of Klein-Nishina law. Note also that the large angle diffusion probability increases as the energy decreases, as it is the case of photons encountering several collisions.

7.2

A2- Theorem proof

The proof of the theorem uses the following lemma. n , n ≥ 0}) be a Markov chain with kernel lemma .— Let {Zn , n ≥ 0} (resp.{Z

 and initial law μ for Z0 (resp. μ ). K (resp.K) Assume that for every measurable function f on E, it exists : 1. a function f˙ measurable on E such that :   μ(x) (a) x∈E f (x)dμ(x) = x∈E f˙(x)d (b) ∀ g measurable on E : f g˙ = f˙g. 2. a function f measurable on E × E such that :    dy) (a) y∈E f (y)K(x; dy) = y∈E f(x, y)K(x; (b) ∀ g measurable on E : fg(x, y)=f ˙ (y) g(x, y) = f(x, y)g(y). 21

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

Then, for every sequence of measurable functions f0 , · · · , fn we have : IE[f0 (Z0 ) · · · fn (Zn )] = IE[f˙0 (Z0 )f1 (Z0 , Z1 ) · · · fn (Zn−1 , Zn )] . Proof .— This lemma is proofed by induction. Consider the property P(n) : IE[f0 (Z0 ) · · · fn (Zn )] = IE[f˙0 (Z0 )f1 (Z0 , Z1 ) · · · fn (Zn−1 , Zn )] . – P(0) is assertion 1(a). – Assume P(n) is true and let us show P(n + 1). We have successively : IE[f0 (Z0 )f1 (Z1 ) · · · fn (Zn )fn+1 (Zn+1 )] n+1  

n+1   fk (zk ) μ(z0 ) K(zk−1 , dzk ) =

(z0 ,...,zn+1)

k=0

n  

= (z0 ,...,zn)

k=1

n    fk (zk ) μ(z0 ) K(zk−1 , dzk ) ×

k=0



k=1

 K(zn , dzn+1 )fn+1 (zn+1 )

= IE[f0 (Z0 )f1 (Z1 ) · · · fn (Zn )(Kfn+1 )(Zn )] = IE[f0 (Z0 )f1 (Z1 ) · · · (fn Kfn+1 )(Zn )] Kfn+1 )(Zn−1 , Zn )] = IE[f˙0 (Z0 )f1 (Z0 , Z1 ) · · · (fn from P(n),   ˙   = IE[f0 (Z0 )f1 (Z0 , Z1 ) · · · fn (Zn−1 , Zn )(Kfn+1 )(Zn )] from l’hypothesis 2(b), = IE[f˙0 (Z0 )f1 (Z0 , Z1 ) · · · fn (Zn−1 , Zn )IE[fn+1 (Zn , Zn+1 ) | Zn ]] from l’hypothesis 2(a),   ˙   = IE[f0 (Z0 )f1 (Z0 , Z1 ) · · · fn (Zn−1 , Zn )fn+1 (Zn , Zn+1 )] . 2

Notes

– If μ is absolutely continuous with respect to μ  then hypotheses 1(a) and 1(b) are verified. – If for every x in E the probability K(x; .) is absolutely continuous with  respect to K(x; .), then hypotheses 2(a) and 2(b) are verified. Let us come to the theorem proof. Proof .— In our case, the function T which has been defined in (17), is a separable function : T (z0 , z1 , · · · , zn+1 ) = f0 (z0 ) f1 (z1 ) · · · fn+1 (zn+1 ) .

22

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

(Note that thanks to the theorem of monotonous classes, it suffices to proof the result for every separable function T , since every measurable function on E n+2 is the upper limit of a sequence of separable functions). For every measurable function f on E, we define f˙ et f : h0 f˙(z1 ) = f (z1 ) (v1 )  h0

f(z1 , z2 ) = f (z2 )Wφ (z1 , z2 )W (z1 , z2 ) .

(21)

Later, we shall proof that these functions satisfy the lemma hypotheses. Thus, this lemma implies : IE[f0 (Z0 ) · · · fn+1 (Zn+1 )] = IE[f˙0 (Z0 )f1 (Z0 , Z1 ) · · · fn+1 (Zn , Zn+1 )] = IE[ f0 (Z0 )W0 (Z0 )f1 (Z1 )(Wφ .W )(Z0 , Z1 ) · · · fn+1 (Zn+1 )(Wφ W )(Zn , Zn+1 )] n       ( Wφ .W )(Zk , Zk+1 )] = IE[ T (Z0 , Z1 , · · · , Zn , Zn+1 ) W0 (Z0 ) k=0

0 , Z1 , · · · , Zn , Zn+1 )] , = IE[T (Z0 , Z1 , · · · , Zn , Zn+1 ) W (Z this last expression being those of the theorem. It remains to proof the  (z1 , z2 )K(z  1 , dz2 ) lemma hypotheses. Let us focus on hypothesis 2(a). f  = f (z2 )K(z1 , dz2 ). By analogy with (7), we have :    1 , dz2 ) = K  f(z1 , .) (z1 ) , f(z1 , z2 )K(z and consequently, from (10) it comes :  1 , dz2 ) f(z1 , z2 )K(z   h(2 |λ1 )d2 = II Ray (z1 ; 2 ) + II Com (z1 ; 2 ) + II P ho (z1 ; 2 )      = Γ(Ray | λ1 ) f z1 , 2 , R(v1 , φ, θ), λ1  hRay (φ) dφ dθ      ) f z ,  , R(v , φ, θ), g(λ , φ) hCom (φ|λ1 ) dφ dθ + Γ(Com|λ 1 1 2 1 1    ho | λ1 ) f z1 , (2 , v1 , 0)  h(2 |λ1 ) d2 . + Γ(P Furthermore, taking account of (18), (21) and the simplification due to the

23

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

indicator variables 1λ1 = present in (18), we get :  1 , dz2 ) f(z1 , z2 )K(z     f 2 , R(v1 , φ, θ), λ1 hRay (φ) dφ dθ = Γ(Ray | λ1 )   f 2 , R(v1 , φ, θ), g(λ1 , φ) hCom (φ|λ1 ) dφ dθ + Γ(Com|λ1 )  + Γ(P ho | λ1 ) f (2 , v1 , 0) h(2 |λ1 ) d2 = f (z2 )K(z1 , dz2 ) , what proofs hypothesis 2(a). . 2 Note that if f does not depend on , then the function f1 defined by f1 (z1 , z2 ) = f (z2 )Wφ (z1 , z2 ) verifies the lemma hypothesis. Similarly, if f depends only on , then the function f2 defined by f2 (z1 , z2 ) = f (z2 )W (z1 , z2 ) verifies the lemma hypothesis.

Références [1] J. Besag, "Spatial interaction and the statistical analysis of lattice systems", Journal Royal Statis. Soc., B-36, pp. 192-236, 1974. [2] A. Bonin, B. Chalmond and B. Lavayssière, "Moderato : a Monte Carlo radiographic simulation", Review of Progress in Quantitative Non Destructive Evaluation, 19, 1999. [3] A. Bonin, B. Chalmond and B. Lavayssière, "Monte Carlo simulation of industrial radiography images and experimental designs", NDT & E International, to appear. [4] Y. Cauchois and Y. Héno, "Cheminement des particules chargés", Gauthier Villars, 1964. [5] B. Chalmond, Modeling for image analysis, Springer-Verlag, 2000 (in French). [6] G.S. Fishman, Monte Carlo, Springer-Verlag, 1995. [7] J. Ghassoun, A. Jehouani and K. Ueki, "Combination of four biasing techniques for ray shielding calculations", Progress in Nuclear Energy, 36, 1, pp. 77-89, 2000. [8] J.M. Hammersley and D.C. Handscomb, Monte Carlo methods, Methuen and Company, London, 1964. 24

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001

[9] J. H. Hubbell, "Photon cross sections, attenuation coefficients and energy absorbtion coefficients from 10 keV to 100 GeV", National bureau of standards NSRDR-NBS, 29, Washington, 1969. [10] T.M. Jenkins, Monte Carlo transport of electrons and photons, Plenum Press, 1988. [11] B. Lapeyre, E. Pardoux and R. Sentis, Monte-Carlo techniques for transport equation and diffusion, Springer-Verlag, 1998, (in French). [12] W. R. Leo, Techniques for nuclear and particle physics experiments : a how-to approach, 2nd edition, Springer-Verlag, 1994. [13] R. Rubinstein, Simulation and the Monte Carlo method, Wiley, 1981. [14] E. Segré, Nuclei and particles, 2dn edition, Advanced book program, Reading Massachussets, 1977. [15] J. Spanier and E.M. Gelbard, Monte Carlo principles and neutron transport problem Addison-Wesley, Reading, MA, 1969. [16] W. Wagner, "Monte Carlo evaluation of functionals of solutions of stochatic differential equations : variance reduction and numerical examples", Stochatic Analysis and Applications, 6, 4, pp. 447-468, 1988. [17] F.F. Williamson "Monte-Carlo simulation of photon transport phenomena : sampling techniques", In : Monte-Carlo simulation in the radiological sciences, R.L. Morin (Ed.), pp. 53-101, CRC Press, 1988. [18] Winkler G., Image Analysis, Random Fields and Dynamic Monte Carlo Methods : A Mathematical Introduction, Springer-Verlag, 1995.

25

B. Chalmond and Z.Ouertani

Monte Carlo simulation of photon transport

CMLA 2001