master’s thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable...

85
Master’s Thesis Evolution of the Grain Size Distribution in Steel Francesco Saverio Patacchini MSc in Modern Applications of Mathematics 2013

Upload: others

Post on 08-Oct-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

Master’s Thesis

Evolution of the Grain Size Distribution inSteel

Francesco Saverio PatacchiniMSc in Modern Applications of Mathematics

2013

Page 2: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

Master’s Thesis

Evolution of the Grain Size Distribution inSteel

Submitted by Francesco Saverio Patacchinifor the Degree of MSc

of the University of Bath

COPYRIGHT

Attention is drawn to the fact that copyright of this dissertation rests with its author. Thiscopy of the dissertation has been supplied on condition that anyone who consults it is

understood to recognise that its copyright rests with its author and that no quotation from thedissertation and no information derived from it may be published without the prior written

consent of the author.

Declaration

This dissertation is submitted to the University of Bath in accordance with the requirementsof the degree of Master of Science in the Department of Mathematical Sciences. No portion ofthe work in this thesis has been submitted in support of an application for any other degree orqualification of this or any other university or institution of learning. Except where specifically

acknowledged, it is the work of the author.

Page 3: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

Acknowledgements

I would like to thank Johannes Zimmer for the supervision of this thesis. His fullavailability, guidance and corrections were invaluable help to achieve the project. Iwould also like to thank Dietmar Homberg and Wolf Weiss for their kindness andwarm welcome in Berlin. The discussions we had were extremely rewarding andhelped me understand many aspects of the project. Thanks to all these people, thethesis has been highly exciting, enjoyable and gratifying. I finally thank Tony Shard-low for accepting to be the checker of my dissertation.

Abstract

We model the phase transformation of austenite into ferrite in steel, during anisothermal holding time ended by quenching. Both the two- and three-dimensionalcases are considered, where we employ an Avrami-Kolmogorov-type model in whichthe ferrite phase is supposed to grow as circular or spherical grains. We derive Fokker-Planck equations describing the evolution of the radius and area – in two dimensions– and radius and volume – in three dimensions – distributions of ferrite grains, wherethe drift velocity and the diffusion coefficient are time-dependent and linearly inter-connected. By physical arguments on the moments, we find that these equations arelocal. We use a logarithmic change of variables to find an explicit analytical solutionto the equations, which appears to be a log-normal distribution convoluted with theinitial probability density function. The connection between the radius and area caseson one hand, and between the radius and volume cases on the other hand are foundby means of changes of variables. We run numerical simulations approximating theconvolution integral present in the solution, and analyse the behaviour of the grainsize distribution. The simulations are very fast as we do not need to discretise theequations. They show infinite-time blow-up for certain diffusion coefficients and con-vergence to an asymmetric stationary state, approximately log-normally distributed,for any initial condition imposed. We finally lead a parametric study on physicalquantities and study their influence on the solution.

Page 4: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

4 CONTENTS

Contents

1 Introduction 5

2 Grain size distribution in steel 62.1 The Avrami-Kolmogorov model . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

2.1.1 General presentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62.1.2 Mathematical model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72.1.3 Extraction of data from experiment . . . . . . . . . . . . . . . . . . . . . 10

2.2 The governing equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10

3 Analysis of a general Fokker-Planck equation 143.1 An analytical solution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143.2 Decay behaviour and conservation of mass . . . . . . . . . . . . . . . . . . . . . . 203.3 Finite-time blow-up . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

4 Derivation of the governing equations 29

5 Analysis of the governing equations 315.1 Analytical solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 315.2 Relations between distributions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335.3 Finite-time blow-up . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

6 Numerical study 426.1 Numerical method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426.2 Simulations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45

6.2.1 Infinite-time blow-up . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466.2.2 Convergence to a log-normal stationary state . . . . . . . . . . . . . . . . 486.2.3 Parametric study . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 536.2.4 Comparison between two- and three-dimensional cases . . . . . . . . . . . 556.2.5 Transformations to radius . . . . . . . . . . . . . . . . . . . . . . . . . . . 566.2.6 Computation times . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57

7 Conclusion and Outlook 58

REFERENCES 60

APPENDICES 61

A Details for the relations between distributions 61

B Code 65

C Guide to the code 82

Page 5: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

5 1 INTRODUCTION

1 Introduction

When processing steel, it is desirable to predict and control mechanical properties, such ashardness and brittleness, in order to produce quality steel and thus make significant economicbenefits. An important step of steel manufacturing is temperature treatment, during which themain macroscopic characteristics of the specimen are determined. Under certain temperatureand carbon concentration conditions, steel is totally composed of austenite – an allotrope ofiron. In this situation, cooling steel initiates a phase change from the austenite into ferrite crys-tals – or grains – driven by an enrichment of carbon in the parent phase and stopping naturallywhen an equilibrium concentration of carbon is reached. Therefore, modelling and analysing thisphase transformation would provide crucial information on how to produce steel with desiredmechanical properties. When the austenite transforms into ferrite, steel organises according toa polycrystalline structure, which makes it a very complex material whose present understand-ing is remarkably poor. However, we know that as the transformation occurs, the ferrite grainsappear randomly in the austenite matrix and their size distribution essentially determines themacroscopic mechanical behaviour of the steel specimen.

In practice, steel is subject to a temperature treatment during which it is first heated up to atemperature around 900 ◦C such that it is exclusively composed of austenite. Once this situationis reached, the workpiece of steel is cooled down to a temperature which is characteristicallyaround 800 ◦C in order to initiate the phase change. After this cooling stage, its temperatureis fixed and the phase transformation from austenite to ferrite crystals happens isothermally.Finally, once it is considered that the phase change has gone far enough, the steel specimen isquenched drastically, forcing the transformation to cease and fixing the fractions of ferrite andaustenite, along with the size distribution of ferrite grains. The time during which the phasechange occurs at constant temperature is called holding time. Figure 1 shows the temperaturetreatment imposed on the steel starting at the cooling stage.

time

temp.

0

Cooling

Holding time

Quenching

Phase change stopsPhase change starts

Figure 1: Temperature treatment of steel from cooling stage. Steel is first cooled to initiate thephase transition of austenite into ferrite crystals. The temperature is then fixed for a holdingtime during which the transformation happens. Finally the steel is quenched and the phasechange ceases, fixing the ferrite and austenite fractions and the ferrite grain size distribution.

Page 6: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

6 2 GRAIN SIZE DISTRIBUTION IN STEEL

In this Master’s thesis, we formulate a mathematical model describing the phase change ofaustenite into ferrite grains during a holding time, and solve analytically and numerically theevolution equations verified by the size distribution of ferrite. The results are then evaluatedcritically and may give useful information on the growth of crystal grains in steel, helpingachieve a controlled production. In section 2, we implement the mathematical model, namely anAvrami-Kolmogorov-type model, and give the governing Fokker-Planck equations where driftand diffusion coefficients are local and time-dependent, and strongly interconnected to eachother. Through section 3, we derive an analytical solution for a very similar and more generalFokker-Planck equation by a logarithmic change of variables. We also analyse some importantproperties of the solution derived such as continuity, fast decay, conservation of mass and finite-time blow-up. Section 4 is dedicated to the derivation of the governing equations and section 5applies the results of section 3 to the case of our equations. Section 6 gives the numerical methodimplemented to obtain and plot the analytical solution, and mainly analyses the behaviour of thesolution for various diffusion coefficients, initial distributions and physical parameters. Finally,appendix A presents the details of some calculations needed in section 5, and appendices B andC give the code used for the simulations as well as a guide to it.

The work of this thesis is founded on the previous work by Johannes Zimmer (University ofBath), Dietmar Homberg and Wolf Weiss (Wasserstein Institute of Berlin) on the topic. Themain progress presented in this dissertation lies in the finding that the governing equations forthe grain size distribution are actually local (see remark 2.2 in section 2.2). This stems fromphysical considerations on the quantities appearing in the Avrami-Kolmogorov model (namelyP and N , see section 2.1.2), stating their relation to the moments of the distribution; and fromthe expression for the moments given in proposition 3.3. In addition, a novelty presented inthis thesis stands in the derivation of an analytical solution for the governing equations – viaa logarithmic change of variables – which involves a convolution. Being that the diffusion anddrift coefficients are local, this solution is explicit. Thus, we can directly obtain the numericalsolution by approximating the integral without discretisation of the equations, whereas formerwork considered finite difference schemes. The numerical method presented here is very fast asit does not require any discretisation except from the approximation of the convolution integral(see computing times in table 3, section 6.2.6). The main numerical findings given in this projectregard the convergence of the analytical solution to a stationary state if appropriate diffusioncoefficients are considered (see section 6.2.1), otherwise the solution blows up at infinite time.The stationary state appears to be approximately a log-normal distribution, even if the initialprobability density is symmetric or compactly supported. In addition, the parametric study ledin section 6.2.3 gives the influence of many physical parameters on the behaviour of the solution.

2 Grain size distribution in steel

2.1 The Avrami-Kolmogorov model

2.1.1 General presentation

In this section we implement a model describing the growth of ferrite grains in steel duringholding times. The model we wish to use is of Avrami-Kolmogorov-type and is a slight modi-

Page 7: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

7 2 GRAIN SIZE DISTRIBUTION IN STEEL

fication of the one by Dietmar Homberg and Johannes Zimmer (2012), in which the ferrite isrepresented by growing circular or spherical grains originating from the austenite matrix initiallypresent. This model assumes that the nucleation of ferrite grains happens randomly where theaustenite has not yet transformed. As in the papers by Avrami [1], [2] and [3], we distinguish thegerm nuclei – that are inherently present in the austenite matrix and that have not yet startedgrowing – from the growth nuclei – that have already initiated their growth. We call nucleationthe change from germ nuclei to growth nuclei. Figure 2 shows a two-dimensional example ofconfiguration of germ and growth nuclei.

Austenitematrix

Growth nuclei

Germ nuclei

Figure 2: Two-dimensional germ and growth nuclei configuration in austenite matrix. Germnuclei are inherently present in the austenite matrix. When the transition to ferrite grainsstarts, they randomly switch to growth nuclei which are circles in two dimensions.

The growth rate is considered to be isotropic and the growth of each grain is assumed to stopwhen impinging upon another grain or when reaching the domain boundary. Moreover, as wemodel holding times in steel processing, we only consider the isothermal situation. In prac-tice, what is observed is a only two-dimensional section of the steel, and experimental data areextracted from this section. However, what would be more accurate in order to forecast themechanical behaviour of the steel is to predict the evolution of the grain size distribution in athree-dimensional setting, where grains would grow as spheres. Therefore, we consider in thefollowing work the problem in two dimensions and three dimensions independently in order toobtain insight from both situations. Hence, we assume the nuclei to be circles growing in a two-dimensional plane or spheres growing in a three-dimensional volume. Under these hypotheses,we may derive the following model.

2.1.2 Mathematical model

Two-dimensional model Let us consider a surface S ⊂ R2 in which the transformation fromaustenite to ferrite occurs. Let us denote the surfaces occupied by the austenite and the ferrite attime t by Sa(t) and Sf (t), respectively, which satisfy Sa(t) + Sf (t) = S for all t ∈ R+ := (0,∞).Time 0 represents the beginning of the isothermal holding time. Therefore, we may define thephase fraction of ferrite by

Page 8: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

8 2 GRAIN SIZE DISTRIBUTION IN STEEL

P (t) =Sf (t)

Sfor t ∈ R+.

We also denote the number of growth nuclei per unit surface present in S at time t by N(t).We want now to find expressions determining P (t) and N(t) at any time t. We know that ifthe transformation is not stopped by an external action, it will stop naturally after a certainconcentration of carbon is reached, leading to an equilibrium phase fraction denoted by Peq. Letus consider the growth rate ρ(t), which is a length per unit time. We assume that

ρ(t) = ρ0Peq − P (t)

1− P (t)for t ∈ R+,

where ρ0 is a reference growth rate, namely the growth rate if we consider Peq = 1. Let us alsodefine the surface occupied at time t by a single ferrite grain born at time τ :

s(t, τ) = π

(∫ t

τρ(s) ds

)2

for t ∈ R+.

Our model should take into account the fact that growth nuclei cannot impinge upon each other.To do so, we first consider an extended surface Sext(t) which neglects this phenomenon. Hence,the surface Sext(t) is the overall surface occupied by every ferrite grain at time t, assuming thatthey may impinge upon each other. Therefore,

Sext(t) = αS

∫ t

0s(t, τ) dτ for t ∈ R+,

where α is the nucleation rate, i.e. the number of growth nuclei per unit time and per unitsurface. In order to now avoid grains to grow into each other, we use Avrami correction (see [1],[2], [3] for a derivation, and also the paper by Kolmogorov [8]), which is

dSf (t) = (1− P (t))dSext(t) for t ∈ R+.

Thus, knowing that limt→0 P (t) = 0 and limt→0 Sext(t) = 0, we get

log(1− P (t)) = −α∫ t

0s(t, τ) dτ for t ∈ R+,

and then

P (t) = 1− e−α∫ t0 s(t,τ) dτ for t ∈ R+. (2.1)

Since s depends on the growth rate ρ which depends on P , equation (2.1) is an implicit expressionfor P . However, we can note that if the equilibrium of the transformation is reached after thewhole surface available is filled with ferrite grains – that is Peq = 1 – then ρ(t) = ρ0 for all t andthus

P (t) = 1− e−παρ

20

3t3

for t ∈ R+.(2.2)

Independently of the value of Peq, we can now determine the number of growth nuclei per unitsurface N(t) present at time t, which is

N(t) = α

∫ t

0

(1− P (s)

Peq

)ds for t ∈ R+. (2.3)

Page 9: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

9 2 GRAIN SIZE DISTRIBUTION IN STEEL

Three-dimensional model We proceed in an analogous way to the two-dimensional case.Let us here consider a volume V ⊂ R3 in which the transformation from austenite to ferriteoccurs. The volumes occupied by the austenite and the ferrite at time t are denoted by Va(t)and Vf (t), respectively, and satisfy Va(t) + Vf (t) = V for all t ∈ R+. Therefore, we may definethe phase fraction of ferrite by

P (t) =Vf (t)

Vfor t ∈ R+.

The number of growth nuclei per unit volume present in V at time t is denoted by N(t). Again,we want to find expressions for P (t) and N(t) at any time t. As for the two-dimensional model,let us write Peq the equilibrium fraction of ferrite. We assume that the growth rate ρ(t), whichis a length per unit time, satisfies

ρ(t) = ρ0Peq − P (t)

1− P (t)for t ∈ R+,

where ρ0 is a reference growth rate. Let us also define the volume occupied at time t by a singleferrite grain born at time τ :

v(t, τ) =4π

3

(∫ t

τρ(s) ds

)3

for t ∈ R+.

Our model should take into account the fact that growth nuclei cannot impinge upon each other.Analogously to the two-dimensional case, we first consider an extended volume Vext(t), which isthe overall volume occupied by every ferrite grain at time t, assuming that they may impingeupon each other. Therefore,

Vext(t) = αV

∫ t

0v(t, τ) dτ for t ∈ R+,

where α is the nucleation rate, i.e. the number of growth nuclei per unit time and per unitvolume. In order to now avoid grains to grow into each other, we use Avrami correction (seeagain [1], [2], [3] and [8]), which is

dVf (t) = (1− P (t))dVext(t) for t ∈ R+.

Thus, knowing that limt→0 P (t) = 0 and limt→0 Vext(t) = 0, we get

log(1− P (t)) = −α∫ t

0v(t, τ) dτ for t ∈ R+,

and then

P (t) = 1− e−α∫ t0 v(t,τ) dτ for t ∈ R+. (2.4)

Since v depends on the growth rate ρ which depends on P , equation (2.4) is an implicit expressionfor P . However, as a special case, if we suppose that the equilibrium of the transformation isreached after the whole volume available is filled with ferrite grains – that is Peq = 1 – thenρ(t) = ρ0 for all t and thus

P (t) = 1− e−παρ

30

3t4

for t ∈ R+.(2.5)

Page 10: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

10 2 GRAIN SIZE DISTRIBUTION IN STEEL

Independently of the value of Peq, we can now determine the number of growth nuclei per unitvolume N(t) present at time t:

N(t) = α

∫ t

0

(1− P (s)

Peq

)ds for t ∈ R+. (2.6)

2.1.3 Extraction of data from experiment

In practice, when analysing steel, a small workpiece is cut from a larger piece. This piece issectioned transversally, and the section is then treated and polished. From this two-dimensionalsection and the Avrami-Kolmogorov-type model implemented above, one wants to deduce theevolution in time of the phase fraction P (t) and the number of nuclei per unit surface or volumeN(t) given in equations (2.1) and (2.3) in two dimensions, and in equations (2.4) and (2.6) inthree dimensions. In order to do so, one needs the values of the reference growth rate ρ0, theequilibrium fraction Peq and the nucleation rate α.

Whereas the values for the first two parameters should be found directly from the steel sec-tion, the nucleation rate can for example be found in two different ways. The first way is todirectly try to extract the value from the two-dimensional workpiece, which does not seem to beachievable easily. The second way, and more applicable one, is to deduce the nucelation rate αfrom dilatometer experiments. This is done by observing the deformation of the workpiece withtemperature. Indeed, experiments show that the deformation is a linear function of temperaturebefore reaching the holding time on one hand and after the holding time on the other hand,with slopes proportional to the austenite and ferrite fractions. From this knowledge, one candeduce the ferrite phase fraction P (t) as a function of time during the holding time. Using thenequation (2.1) or (2.4), one can solve the inverse problem for the nucleation rate α for knownparameters ρ0 and Peq. Once the nucleation rate is found, the number of nuclei per unit surfaceor volume can be obtained by equation (2.3) or (2.6), respectively.

As it is shown below, the knowledge of the ratio P (t)N(t) is of crucial importance for solving and

analysing the equations satisfied by the ferrite grain size distributions.

2.2 The governing equations

In the following we use sometimes for simplicity the terminology distribution instead of the morerigorous probability density function. We want here to give the governing equations arising fromthe Avrami-Kolmogorov model implemented in section 2.1. We consider the physical problem inboth two dimensions and three dimensions. In the former setting, we analyse the case where thedistribution is a function of the radius of the nuclei and the case where it is a function of theirarea; and in the latter setting, we analyse the case where the distribution is a function of theradius of the nuclei and the case where it is a function of their volume. We write g(t) := P (t)

N(t) > 0,

where P (t) is the surface or volume per unit surface or volume (respectively) occupied by theferrite in the austenite matrix at time t and N(t) is the number of growth nuclei per unit surfaceor volume present at time t. Also, for mathematical convenience, we assume the domain to be

Page 11: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

11 2 GRAIN SIZE DISTRIBUTION IN STEEL

infinite rather than bounded as it is in reality. This assumption is made physically acceptableby imposing some decay conditions on the distributions, as given below.

In the governing equations below, v(t) is a time-dependent drift velocity and β(t) is a time-dependent diffusion coefficient. We assume that they satisfy

β(t) = β0 + β1v(t) for t ∈ R+, (2.7)

where β0 and β1 are nonnegative diffusion parameters. Moreover, the following hypotheses hold:

1. v, β ∈ L1loc(R+),

2. β is nonnegative,

3. there exists T ∈ R+ such that for all t ∈ (0, T ), β(t) > 0.

The choice for β0 and β1 should be such that the above hypotheses be respected. These hy-potheses are justified in section 5.1, remark 5.2.

Two-dimensional case

We analyse two different distributions: the radius distribution ψ and the area distribution φ.

Radius distribution We consider that the grain size distribution ψ(r, t) : R+×R+ −→ [0,∞)is a function of the grain radius r and time t. Then ψ(r, t) is supposed to satisfy ψt = −v(t)(rψ)r + β(t)(r2ψ)rr for (r, t) ∈ R+ × R+

limt→0

ψ(r, t) = ψ0(r) for r ∈ R+,(2.8)

where β(t) is the time-dependent diffusion coefficient defined in (2.7), ψ0(r) : R+ −→ [0,∞) is aC0(R+) ∩ L∞(R+) initial distribution such that its moments satisfy (this is justified in section3.2) ∫ ∞

0rnψ0(r) dr <∞ for 0 ≤ n ≤ 2 + δ (2.9)

for some δ > 0. Furthermore, v(t) is given by

v(t) =1

2

gt(t)

g(t)− β(t) for t ∈ R+, (2.10)

or equivalently, by (2.7),

v(t) =1

1 + β1

(1

2

gt(t)

g(t)− β0

)for t ∈ R+. (2.11)

We also impose the following decay conditions on the solution (justified in section 4): limr→0

r3ψ(r, t) = limr→∞

r3ψ(r, t) = 0 for t ∈ R+

limr→0

r4ψr(r, t) = limr→∞

r4ψr(r, t) = 0 for t ∈ R+.(2.12)

An analysis of a similar Fokker-Planck equation on a bounded domain, describing the chargingand discharging of lithium batteries, can be found in the dissertation by Huth [7] and the preprintby Dreyer et al. [5].

Page 12: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

12 2 GRAIN SIZE DISTRIBUTION IN STEEL

Area distribution We now consider that the grain size distribution φ(x, t) : R+ × R+ −→[0,∞) is a function of the grain area x and time t. We assume this time that φ(x, t) satisfies φt = −v(t)(xφ)x + β(t)(x2φ)xx for (x, t) ∈ R+ × R+

limt→0

φ(x, t) = φ0(x) for x ∈ R+,(2.13)

where β(t) is the diffusion coefficient defined as in (2.7), φ0(x) : R+ −→ [0,∞) is a C0(R+) ∩L∞(R+) initial distribution such that its moments satisfy (as justified in section 3.2)∫ ∞

0xnφ0(x) dx <∞ for 0 ≤ n ≤ 1 + δ (2.14)

for some δ > 0. In addition, the drift velocity v(t) is given by

v(t) =gt(t)

g(t)for t ∈ R+. (2.15)

We now impose the following decay conditions (justified in section 4): limx→0

x2φ(x, t) = limx→∞

x2φ(x, t) = 0 for t ∈ R+

limx→0

x3φx(x, t) = limx→∞

x3φx(x, t) = 0 for t ∈ R+.(2.16)

Three-dimensional case

Analogously to the two-dimensional situation, we study two different distributions: the radiusdistribution ψ and the volume distribution φ.

Radius distribution We consider that the grain size distribution ψ(r, t) : R+×R+ −→ [0,∞)is a function of the grain radius r and time t. Then we suppose that ψ(r, t) satisfies ψt = −v(t)(rψ)r + β(t)(r2ψ)rr for (r, t) ∈ R+ × R+

limt→0

ψ(r, t) = ψ0(r) for r ∈ R+,(2.17)

where β(t) is the diffusion coefficient given in (2.7), ψ0(r) : R+ −→ [0,∞) is a C0(R+)∩L∞(R+)initial distribution such that its moments satisfy (see justification in section 3.2)∫ ∞

0rnψ0(r) dr <∞ for 0 ≤ n ≤ 3 + δ (2.18)

for some δ > 0. Furthermore, v(t) satisfies

v(t) =1

3

gt(t)

g(t)− 2β(t) for t ∈ R+, (2.19)

Page 13: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

13 2 GRAIN SIZE DISTRIBUTION IN STEEL

or equivalently by equation (2.7),

v(t) =1

1 + 2β1

(1

3

gt(t)

g(t)− 2β0

)for t ∈ R+. (2.20)

We also impose the following decay conditions on the solution (justified in section 4): limr→0

r4ψ(r, t) = limr→∞

r4ψ(r, t) = 0 for t ∈ R+

limr→0

r5ψr(r, t) = limr→∞

r5ψr(r, t) = 0 for t ∈ R+.(2.21)

Volume distribution This is perfectly analogous to the area case above. We consider thatthe grain size distribution φ(x, t) : R+ × R+ −→ [0,∞) is a function of the grain volume x andtime t. We suppose that φ(x, t) satisfies φt = −v(t)(xφ)x + β(x2φ)xx for (x, t) ∈ R+ × R+

limt→0

φ(x, t) = φ0(x) for x ∈ R+,(2.22)

where β(t) is the diffusion coefficient verifying (2.7), φ0(x) : R+ −→ [0,∞) is a C0(R+)∩L∞(R+)initial distribution such that its moments satisfy (a justification is given in section 3.2)∫ ∞

0xnφ0(x) dx <∞ for 0 ≤ n ≤ 1 + δ (2.23)

for some δ > 0. In addition, v(t) is the time-dependent drift velocity given by

v(t) =gt(t)

g(t)for t ∈ R+. (2.24)

We now impose the following decay conditions (justified in section 4): limx→0

x2φ(r, t) = limx→∞

x2φ(x, t) = 0 for t ∈ R+

limx→0

x3φx(x, t) = limx→∞

x3φx(x, t) = 0 for t ∈ R+.(2.25)

Remark 2.1 (General form of the Fokker-Planck equation). In a general fashion, the Fokker-Planck equation describes the evolution of the probability density function of a quantity char-acterising a physical system. Let us denote this density by u(x, t), where x ∈ R is the quantityof interest and t ∈ R+ is time. Then, the equation reads

ut = −(λ(x, t)u)x + (µ(x, t)u)xx for (x, t) ∈ R× R+, (2.26)

where λ(x, t) and µ(x, t) are convection - or drift - and diffusion coefficients, respectively. There-fore, equations (2.8), (2.13), (2.17) and (2.22) are special cases of the Fokker-Planck equation(2.26), with λ(x, t) = v(t)x, µ(x, t) = β(t)x2 and x-domain R+.

Page 14: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

14 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

Remark 2.2 (Locality of the equations). The structure of the governing equations implies thatthe drift velocity is a local parameter, independent of the solution, as it can be seen in equations(2.10) and (2.15) in two dimensions, and in equations (2.19) and (2.24) in three dimensions.

This directly comes from physical links between the data g(t) := P (t)N(t) and the moments of the

solution; and from the relation on the moments given in proposition 3.3. It is a strong andinteresting property which was not encountered in our first attempt to find a model, whichwas ψt = −v(t)ψr + β(t)ψrr and φt = −v(t)φx + β(t)φxx in place of (2.8) and (2.13) in twodimensions, and of (2.17) and (2.22) in three dimensions, where the same reasoning as above ledinstead to a nonlocal parameter v(t).

Remark 2.3 (Choice of the diffusion parameters). The choice of the diffusion parameters β0and β1 in (2.7) may be made numerically by tuning them so that the numerical solution forthe distribution matches the experiments as good as possible. A theoretical choice for β0 cannevertheless be made by a physical argument given in section 4, remark 4.1, and by numericsas shown in section 6.2.1.

3 Analysis of a general Fokker-Planck equation

In the following section we find an analytical solution to the Fokker-Planck equation (2.26) whenx ∈ R+ and the functions λ and µ can be written as λ(x, t) = A(t)x and µ(x, t) = B(t)x2, whereA(t) and B(t) are functions satisfying the following hypotheses:

1. A,B ∈ L1loc(R+),

2. B is nonnegative,

3. there exists T ∈ R+ such that for all t ∈ (0, T ), B(t) > 0.

3.1 An analytical solution

We want to find a probability density function u(x, t) : R+ × R+ −→ [0,∞), solution to thefollowing Cauchy problem:{

ut = −A(t)(xu)x +B(t)(x2u)xx for (x, t) ∈ R+ × R+

limt→0

u(x, t) = u0(x) for x ∈ R+,(3.1)

where A and B are time-dependent drift and diffusion coefficients satisfying the above hypothe-ses, and u0(x) : R+ −→ [0,∞) is the initial probability density function, assumed to be inC0(R+) ∩ L∞(R+). We proceed in three steps as follows (see the paper by Cordier et al. [4] fora similar derivation).

Step 1 Consider the transformation of variables{χ := log(x)

c(χ, t) := xu(x, t),(3.2)

with c(χ, t) : R× R+ −→ [0,∞). Then, by the chain rule, the following identities hold:

Page 15: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

15 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

ut =1

xct,

(xu)x = cx = χxcχ =1

xcχ,

(x2u)x = xu+ x(xu)x = c+ xcx = c+ cχ,

(x2u)xx = cx + (cx)χ =1

xcχ +

1

xcχχ.

Hence, problem (3.1) becomes{ct = (B(t)−A(t))cχ +B(t)cχχ for (χ, t) ∈ R× R+

limt→0

c(χ, t) = eχu0(eχ) for χ ∈ R. (3.3)

Note that this is now a convection-diffusion problem, where B(t) − A(t) and B(t) are time-dependent convection and diffusion coefficients, respectively.

Step 2 This step is not explicitly given in [4], although a reference to the paper by Liron andRubinstein [9] is made therein. Consider now the tranformation of variables

ξ := χ+ b(t)− a(t)

τ := b(t)

h(ξ, τ) := c(χ, t),

(3.4)

with h(ξ, τ) : R×R+ −→ [0,∞), a(t) =∫ t0 A(s) ds and b(t) =

∫ t0 B(s) ds. This transformation is

allowed by the hypotheses 1–3 on A and B, since by them τ ∈ R+ := (0,∞) and a(t) and b(t)are well-defined. Then, again using the chain rule, we get the following identities:

ct = ξthξ + τthτ = (B(t)−A(t))hξ +B(t)hτ ,

cχ = ξχhξ = hξ,

cχχ = hξξ.

Thus, problem (3.3) transforms into{hτ = hξξ for (ξ, τ) ∈ R× R+

limτ→0

h(ξ, τ) = eξu0(eξ) for ξ ∈ R, (3.5)

since t → 0 and τ → 0 are equivalent by hypothesis 3 and change of variables (3.4), andlimt→0

a(t) = limt→0

b(t) = 0. We have thus transformed equation (3.1) into the heat equation on the

real line.

Step 3 Problem (3.5) has a solution involving the fundamental solution K(ξ, τ) : R×R+ −→[0,∞) for the heat equation (see for example the book by Evans [6] for a derivation of thefundamental solution), which is

h(ξ, τ) = (K(·, τ) ∗ U0)(ξ) for (ξ, τ) ∈ R× R+, (3.6)

Page 16: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

16 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

where ∗ represents the convolution and

K(ξ, τ) =1√4πτ

e−ξ2

4τ and U0(ξ) = eξu0(eξ) for (ξ, τ) ∈ R× R+.

(3.7)

A justification of this is given in the following result:

Proposition 3.1 (Solution to the heat equation (3.5)). Let h(ξ, τ) : R× R+ −→ [0,∞) bedefined as in (3.6)–(3.7). Then,

(i) h ∈ C∞(R,R+),

(ii) hτ = hξξ for all (ξ, τ) ∈ R× R+,

(iii) h(ξ, τ)→ U0(ξ) := eξu0(eξ) as τ → 0, for all ξ ∈ R.

Proof. Let us first prove (i). We have

∫ ∞−∞

U0(ξ′) dξ′ =

∫ ∞−∞

eξ′u0(e

ξ′) dξ′

=

∫ ∞0

ηu0(η)1

ηdη (by change of variable η = exp(ξ′))

=

∫ ∞0

u0(η) dη = 1 (since u0 has unit total mass).

Therefore, U0 has unit total mass as well. U0 being nonnegative, this also proves that U0 ∈ L1(R).According to (3.6)–(3.7),

h(ξ, τ) =

∫ ∞−∞

1√4πτ

e−

(ξ − ξ′)2

4τ U0(ξ′) dξ′ for (ξ, τ) ∈ R× R+.

(3.8)

Then, the following calculation holds for all (ξ, τ) ∈ R× R+:

|h(ξ, τ)| =

∫ ∞−∞

1√4πτ

e−

(ξ − ξ′)2

4τ U0(ξ′) dξ′ (since U0 is nonnegative)

≤ 1√4πτ

∫ ∞−∞

U0(ξ′) dξ′

≤ 1√4πτ

(since U0 has unit total mass, see above).

This shows that h(ξ, τ) given in (3.8) is well-defined on R×R+. Furthermore, let H(ξ, τ, ξ′) : R×R+×R −→ [0,∞) be the integrand in (3.8). H(ξ, τ, ξ′) is clearly differentiable in ξ and τ for any

Page 17: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

17 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

ξ′ ∈ R, and its derivatives are continuous with respect to both variables. After a few calculationsfor all (ξ, τ, ξ′) ∈ R× R+ × R, we get

Hξ(ξ, τ, ξ′) = − ξ − ξ′

2τ√

4πτe−

(ξ − ξ′)2

4τ U0(ξ′) and Hτ (ξ, τ, ξ′) =

(ξ − ξ′)2 − 2τ

4τ2√

4πτe−

(ξ − ξ′)2

4τ U0(ξ′).

(3.9)Hence, for all (ξ, τ, ξ′) ∈ R× R+ × R,

|Hξ(ξ, τ, ξ′)| =

|ξ − ξ′|2τ√

4πτe−

(ξ − ξ′)2

4τ U0(ξ′) (since U0 is nonnegative)

≤ C1

2τU0(ξ

′),

where C1 := supx∈R|x|√4πτ

e−x2

4τ < ∞ is independent of ξ. Since U0 ∈ L1(R), we obtain that

|Hξ(ξ, τ, ξ′)| is bounded by an integrable function independent of ξ. This shows that for all

τ ∈ R+, h(ξ, τ) is differentiable with respect to ξ, and for all (ξ, τ) ∈ R × R+, hξ(ξ, τ) =∫∞−∞Hξ(ξ, τ, ξ

′) dξ′ (see the book by Malliavin [10] for a general result on derivatives under theintegral sign). Similarly, for all (ξ, τ, ξ′) ∈ R× R+ × R,

|Hτ (ξ, τ, ξ′)| =

∣∣(ξ − ξ′)2 − 2τ∣∣

4τ2√

4πτe−

(ξ − ξ′)2

4τ U0(ξ′) (since U0 is nonnegative)

≤ |ξ − ξ′|2

4τ2√

4πτe−

(ξ − ξ′)2

4τ U0(ξ′) +

1

2τ√

4πτe−

(ξ − ξ′)2

4τ U0(ξ′)

≤ C2

τ√τU0(ξ

′) +C0

τ√τU0(ξ

′)

≤ 1

τ√τ

(C0 + C2)U0(ξ′),

where C0 := supx∈R1

2√4π

e−x2

4τ <∞ and C2 := supx∈R|x|2

4τ√4π

e−x2

4τ <∞ are independent of τ . Let

us write for any δ > 0, Cδ := supt∈[δ,∞)1t√t

(C0 + C2) <∞, which is independent of τ . Thus, for

all (ξ, τ, ξ′) ∈ R× [δ,∞)× R,

|Hτ (ξ, τ, ξ′)| ≤ CδU0(ξ′).

Since U0 ∈ L1(R), this proves that on R× [δ,∞)× R, |Hτ (ξ, τ, ξ′)| is bounded by an integrablefunction independent of τ . Hence for all ξ ∈ R and δ > 0, the restriction of h(ξ, τ) to R× [δ,∞)is differentiable with respect to τ (see [10]). Therefore, as δ → 0, we see that h(ξ, τ) is differen-tiable with respect to τ , and for all (ξ, τ) ∈ R × R+, hτ (ξ, τ) =

∫∞−∞Hτ (ξ, τ, ξ′) dξ′ (see [10]).

We thus showed that h(ξ, τ) is differentiable on R× R+ with respect to both ξ and τ . Using avery similar reasoning, one can also prove that h(ξ, τ) is actually differentiable infinitely manytimes with respect to both its variables. Hence h ∈ C∞(R,R+).

Page 18: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

18 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

We want now to show (ii). By (3.6), and since h ∈ C∞(R,R+),

hτ (ξ, τ) = (Kτ (·, τ) ∗ U0)(ξ) and hξξ(ξ, τ) = (Kξξ(·, τ) ∗ U0)(ξ) for (ξ, τ) ∈ R× R+.

Hence,

hτ (ξ, τ)− hξξ(ξ, τ) = ((Kτ (·, τ)−Kξξ(·, τ)) ∗ U0)(ξ) = 0 for (ξ, τ) ∈ R× R+,

since K(ξ, τ) is solution to the heat equation (see [6]).

Let us now show assertion (iii). Let ξ ∈ R be fixed. Then for all τ ∈ R+,

|h(ξ, τ)− U0(ξ)| =

∣∣∣∣∫ ∞−∞

K(ξ − ξ′, τ)U0(ξ′) dξ′ − U0(ξ)

∫ ∞−∞

K(ξ′, τ) dξ′∣∣∣∣

(since K has unit mass (see [6]))

≤∫ ∞−∞

K(ξ − ξ′, τ)∣∣U0(ξ

′)− U0(ξ))∣∣ dξ′.

Let ε > 0. We know that u0 is continuous and thus U0 is continuous as well. Therefore, thereexists δ > 0 such that |U0(ξ)− U0(ξ

′)| < ε for |ξ − ξ′| < δ. Let us fix such δ > 0. Then,

|h(ξ, τ)− U0(ξ)| ≤∫|ξ−ξ′|<δ

K(ξ − ξ′, τ)∣∣U0(ξ

′)− U0(ξ)∣∣ dξ′

+

∫|ξ−ξ′|>δ

K(ξ − ξ′, τ)∣∣U0(ξ

′)− U0(ξ)∣∣ dξ′

≤ ε+

∫|ξ−ξ′|>δ

K(ξ − ξ′, τ)∣∣U0(ξ

′)− U0(ξ))∣∣ dξ′ (since K has unit mass)

≤ ε+

∫|ξ−ξ′|>δ

K(ξ − ξ′, τ)∣∣∣eξ′u0(eξ′)− eξu0(e

ξ)∣∣∣ dξ′

≤ ε+

∫|ξ−ξ′|>δ

K(ξ − ξ′, τ)emax(ξ′,ξ)∣∣∣u0(eξ′)− u0(eξ)∣∣∣ dξ′

≤ ε+ 2‖u0‖∞∫|ξ−ξ′|>δ

K(ξ − ξ′, τ)emax(ξ′,ξ) dξ′

≤ ε+ 2‖u0‖∞∫ξ−ξ′>δ

K(ξ − ξ′, τ)eξ dξ′ + 2‖u0‖∞∫ξ′−ξ>δ

K(ξ − ξ′, τ)eξ′dξ′

(since exp is an increasing function).

Then, plugging the expression of K(ξ, τ) given in equation (3.7),

|h(ξ, τ)− U0(ξ)| ≤ ε+2‖u0‖∞eξ√

4πτ

∫ ξ−δ

−∞e−

(ξ − ξ′)2

4τ dξ′ +2‖u0‖∞√

4πτ

∫ ∞δ+ξ

e−

(ξ − ξ′)2

4τ eξ′dξ′

Page 19: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

19 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

≤ ε+2‖u0‖∞eξ√

π

∫ ∞δ√4τ

e−η2

dη +2‖u0‖∞√

π

∫ ∞δ√4τ

e−ζ2eξ+√4τζ dζ

(by change of variables η =ξ − ξ′√

4τand ζ =

ξ′ − ξ√4τ

)

≤ ε+2‖u0‖∞eξ√

π

(∫ ∞δ√4τ

e−η2

dη +

∫ ∞δ√4τ

e−ζ2+√4τζ dζ

)

≤ ε+2‖u0‖∞eξ√

π

(∫ ∞δ√4τ

e−η2

dη +

∫ ∞δ√4τ

e−(ζ−√τ)

2+τ dζ

)

≤ ε+2‖u0‖∞eξ√

π

(∫ ∞δ√4τ

e−η2

dη +

∫ ∞δ√4τ−√τ

e−η2+τ dη

)

(by change of variable η = ζ −√τ)

≤ ε+2‖u0‖∞eξ√

π

(∫ ∞δ√4τ

e−η2

dη + eτ∫ ∞

δ√4τ−√τ

e−η2

)︸ ︷︷ ︸

=:Iτ

.

We clearly have Iτ → 0 as τ → 0. Thus, there exists γ > 0 such that Iτ < ε for τ < γ. Let uschoose such γ > 0. Then for τ < γ,

|h(ξ, τ)− U0(ξ)| ≤(

1 +2‖u0‖∞eξ√

π

)ε.

Therefore, given that ‖u0‖∞ <∞, |h(ξ, τ)− U0(ξ)| → 0 as τ → 0 for all ξ ∈ R.�

Then, reverting to the initial variables x and t in (3.6), we obtain the following solution toproblem (3.1):

u(x, t) =1

x(K(·, b(t)) ∗ U0)(log(x) + b(t)− a(t)) for (x, t) ∈ R+ × R+, (3.10)

where K and U0 are defined in (3.7), and a(t) :=∫ t0 A(s) ds and b(t) :=

∫ t0 B(s) ds. Equivalently

and more explicitly, we can re-write solution (3.10) as

u(x, t) =1

x√

4πb(t)

∫ ∞−∞

e−

(log(x) + b(t)− a(t)− y)2

4b(t) eyu0(ey) dy for (x, t) ∈ R+ × R+.

(3.11)Let us now state a proposition on the continuity of the solution (3.10).

Page 20: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

20 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

Proposition 3.2 (Continuity of the solution). Let u(x, t) : R+ × R+ −→ [0,∞) be thesolution to problem (3.1) defined in (3.10). Then u(·, t) ∈ C∞(R+) for all t ∈ R+, and u(x, ·) ∈C0(R+) for all x ∈ R+.

Proof. Let h(ξ, τ) be defined as in (3.6)–(3.7). Then, we know that h ∈ C∞(R,R+) by propo-sition 3.1. From transformations (3.2) and (3.4), we also know that h(ξ, τ) = xu(x, t) for all(x, t) ∈ R+ × R+, with ξ = log(x) + b(t) − a(t) and τ = b(t). Therefore, since h(·, τ) ∈ C∞(R)for all τ ∈ R+ and log ∈ C∞(R+), we have u(·, t) ∈ C∞(R+) for all t ∈ R+. Similarly, sinceh(ξ, τ) ∈ C∞(R,R+) and a, b ∈ C0(R+) (because they are the antiderivatives of A and B, re-spectively), we have u(x, ·) ∈ C0(R+).

3.2 Decay behaviour and conservation of mass

We propose in the following to find conditions on the initial distribution u0 such that the solutionu defined in (3.10) satisfies certain decay conditions and is of unit total mass. This study alsogives a justification on the assumptions (2.9) and (2.14) made for the initial grain size distri-butions in two dimensions, and on the assumptions (2.18) and (2.23) in three dimensions. Thisjustification is summarised in remark 3.2. The first result is a proposition giving an expressionfor the moments of u.

Proposition 3.3 (Relation on the moments). Let u(x, t) : R+×R+ −→ [0,∞) be a solutionto problem (3.1) and let n ∈ R+ ∪ {0}. Suppose that, for all t ∈ R+, xn+1u(x, t) → 0 andxn+2ux(x, t)→ 0 as x→ 0 and x→∞. Let us denote by Mn(u, t) the n-th moment of u takenat time t ∈ R+. Then for all t ∈ R+,

Mn(u, t) = Mn(u, 0)ena(t)+n(n−1)b(t), (3.12)

where a(t) and b(t) are defined in (3.4), and Mn(u, 0) =∫∞0 xnu0(x) dx.

Proof. We have for all t ∈ R+,

Mn(u, t) =

∫ ∞0

xnu(x, t) dx. (3.13)

Hence, by problem (3.1),

d

dtMn(u, t) =

∫ ∞0

xnut(x, t) dx

= −A(t)

∫ ∞0

xn(xu)x(x, t) dx+B(t)

∫ ∞0

xn(x2u)xx(x, t) dx

= nA(t)

∫ ∞0

xn−1xu(x, t) dx− nB(t)

∫ ∞0

xn−1(x2u)x(x, t) dx

(by integration by parts and hypotheses of proposition)

= nA(t)

∫ ∞0

xnu(x, t) dx+ n(n− 1)B(t)

∫ ∞0

xn−2x2u(x, t) dx

(by integration by parts and hypotheses of proposition)

Page 21: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

21 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

= nA(t)

∫ ∞0

xnu(x, t) dx+ n(n− 1)B(t)

∫ ∞0

xnu(x, t) dx

= nA(t)Mn(u, t) + n(n− 1)B(t)Mn(u, t)

= (nA(t) + n(n− 1)B(t))Mn(u, t).

Therefore, solving this ordinary differential equation in t, we get equation (3.12).�

Remark 3.1 (Interdependence between drift, diffusion and moments). Equation (3.12)shows that the n-th moment of the solution depends on the diffusion phenomenon only forn ≥ 2. More generally, this equation gives the strong interdependence between drift, diffusionand moments.

We also need the following lemma giving upper bounds for the solution u and its derivative ux:

Lemma 3.1 (Bounds for the solution). Let u(x, t) : R+ × R+ −→ [0,∞) be the solution toproblem (3.1) defined in (3.10). Let k ∈ R and define γ0k : R+ −→ [0,∞) by γ0k(x) = xku0(x) forall x ∈ R+. Then for all (x, t) ∈ R+ × R+,

(i) u(x, t) ≤‖γ0k‖∞xk

e(k−1)2b(t)−(k−1)(b(t)−a(t)) and u(x, t) ≤

‖γ0k‖1xk+1

Ck,0(b(t))e−k(b(t)−a(t)),

(ii) |ux(x, t)| ≤‖γ0k‖∞xk+1

(1 + |k − 1|+ 1√

πb(t)

)e(k−1)

2b(t)−(k−1)(b(t)−a(t))

and |ux(x, t)| ≤‖γ0k‖1xk+2

(Ck,0(b(t)) +

Ck,1(b(t))

2b(t)

)e−k(b(t)−a(t)),

where a(t) and b(t) are defined in (3.4), and Ck,j(t) := supx∈R|x|j√4πt

e−x2

4t+kx <∞ for j ∈ {0, 1}.

Proof. Let us first prove (i). According to (3.6)–(3.7), we have for all (ξ, τ) ∈ R× R+,

|h(ξ, τ)| =1√4πτ

∫ ∞−∞

e−

(ξ − ξ′)2

4τ− (k − 1)ξ′

ekξ′u0(e

ξ′) dξ′ (since U0 is nonnegative)

=1√4πτ

∫ ∞−∞

e−

(ξ − ξ′)2

4τ− (k − 1)ξ′

γ0k(eξ′) dξ′

≤‖γ0k‖∞√

4πτ

∫ ∞−∞

e−

(ξ − ξ′)2

4τ− (k − 1)ξ′

dξ′

≤‖γ0k‖∞√

π

∫ ∞−∞

e−η2+(k−1)

√4τη−(k−1)ξ dη (by change of variable η =

ξ − ξ′√4τ

)

≤‖γ0k‖∞√

πe−(k−1)ξ

∫ ∞−∞

e−(η−(k−1)√τ)2+(k−1)2τ dη

Page 22: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

22 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

≤‖γ0k‖∞√

πe−(k−1)ξ+(k−1)2τ

∫ ∞−∞

e−ζ2

dζ (by change of variable ζ = η − (k − 1)√τ)

≤ ‖γ0k‖∞e−(k−1)ξ+(k−1)2τ .

Therefore, reverting to the original variables (xu(x, t) = h(log(x) + b(t) − a(t), b(t)), see (3.2)and (3.4)), we get for all (x, t) ∈ R+ × R+,

xu(x, t) ≤ ‖γ0k‖∞e−(k−1)(log(x)+b(t)−a(t))+(k−1)2b(t)

≤‖γ0k‖∞xk−1

e(k−1)2b(t)−(k−1)(b(t)−a(t)).

Hence the first inequality of (i). Again by (3.6)–(3.7), we have for all (ξ, τ) ∈ R× R+,

|h(ξ, τ)| =

∫ ∞−∞

1√4πτ

e−

(ξ − ξ′)2

4τ− kξ′

e(k+1)ξ′u0(eξ′) dξ′ (since U0 is nonnegative)

=

∫ ∞−∞

e−kξ√4πτ

e−

(ξ − ξ′)2

4τ+ k(ξ − ξ′)

e(k+1)ξ′u0(eξ′) dξ′

=

∫ ∞−∞

e−kξ√4πτ

e−

(ξ − ξ′)2

4τ+ k(ξ − ξ′)

γ0k+1(eξ′) dξ′

≤ Ck,0(τ)e−kξ∫ ∞−∞

γ0k+1(eξ′) dξ′

≤ Ck,0(τ)e−kξ∫ ∞0

γ0k+1(η)1

ηdη (by change of variable η = exp(ξ′))

≤ Ck,0(τ) e−kξ∫ ∞0

γ0k(η) dη = Ck,0(τ)‖γ0k‖1e−kξ.

Then, reverting to the original variables, we obtain for all (x, t) ∈ R+ × R+,

xu(x, t) ≤ Ck,0(b(t))‖γ0k‖1e−k(log(x)+b(t)−a(t))

≤‖γ0k‖1xk

Ck,0(b(t))e−k(b(t)−a(t)).

Hence the second inequality of (i).

Let us now show (ii). By (3.9) and since we may derive in the integral sign as shown in the proofof proposition 3.1(i), we have

hξ(ξ, τ) = −∫ ∞−∞

ξ − ξ′

2τ√

4πτe−

(ξ − ξ′)2

4τ U0(ξ′) dξ′ for (ξ, τ) ∈ R× R+.

(3.14)

Page 23: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

23 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

Therefore, by (3.6)–(3.7), we have for all (ξ, τ) ∈ R× R+,

|hξ(ξ, τ)− h(ξ, τ)| ≤ 1

2τ√

4πτ

∫ ∞−∞

∣∣ξ − ξ′∣∣ e−(ξ − ξ′)2

4τ− (k − 1)ξ′

ekξ′u0(e

ξ′) dξ′

+‖γ0k‖∞e−(k−1)ξ+(k−1)2τ (by first inequality of (i))

≤ 1

2τ√

4πτ

∫ ∞−∞

∣∣ξ − ξ′∣∣ e−(ξ − ξ′)2

4τ− (k − 1)ξ′

γ0k(eξ′) dξ′

+‖γ0k‖∞e−(k−1)ξ+(k−1)2τ

≤‖γ0k‖∞

2τ√

4πτ

∫ ∞−∞

∣∣ξ − ξ′∣∣ e−(ξ − ξ′)2

4τ− (k − 1)ξ′

dξ′

+‖γ0k‖∞e−(k−1)ξ+(k−1)2τ

≤‖γ0k‖∞√πτ

∫ ∞−∞|η| e−η2+(k−1)

√4τη−(k−1)ξ dξ′ + ‖γ0k‖∞e−(k−1)ξ+(k−1)2τ

(by change of variable η =ξ − ξ′√

4τ)

≤‖γ0k‖∞√πτ

e−(k−1)ξ∫ ∞−∞|η| e−(η−(k−1)

√τ)2+(k−1)2τ dη

+‖γ0k‖∞e−(k−1)ξ+(k−1)2τ

≤‖γ0k‖∞√πτ

e−(k−1)ξ+(k−1)2τ∫ ∞−∞

∣∣ζ + (k − 1)√τ∣∣ e−ζ2 dζ

+‖γ0k‖∞e−(k−1)ξ+(k−1)2τ

(by change of variable ζ = η − (k − 1)√τ)

≤‖γ0k‖∞√πτ

e−(k−1)ξ+(k−1)2τ(∫ ∞−∞|ζ| e−ζ2 dζ + |k − 1|

√τ

∫ ∞−∞

e−ζ2

)

+‖γ0k‖∞e−(k−1)ξ+(k−1)2τ

≤‖γ0k‖∞√πτ

e−(k−1)ξ+(k−1)2τ (1 + |k − 1|√πτ) + ‖γ0k‖∞e−(k−1)ξ+(k−1)2τ

≤ ‖γ0k‖∞e−(k−1)ξ+(k−1)2τ(

1 + |k − 1|+ 1√πτ

).

Page 24: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

24 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

Then, with the original variables (x2ux(x, t) = hξ(log(x) + b(t)− a(t), b(t)))− h(log(x) + b(t)−a(t), b(t)), see (3.2) and (3.4)), we have for all (x, t) ∈ R+ × R+,

x2 |ux(x, t)| ≤ ‖γ0k‖∞e−(k−1)(log(x)+b(t)−a(t))+(k−1)2b(t)

(1 + |k − 1|+ 1√

πb(t)

)

≤‖γ0k‖∞xk−1

(1 + |k − 1|+ 1√

πb(t)

)e(k−1)

2b(t)−(k−1)(b(t)−a(t)).

Hence the first inequality of (ii). By (3.6)–(3.7) and (3.14), we have for all (ξ, τ) ∈ R× R+,

|hξ(ξ, τ)− h(ξ, τ)| ≤ 1

∫ ∞−∞

|ξ − ξ′|√4πτ

e−

(ξ − ξ′)2

4τ− kξ′

e(k+1)ξ′u0(eξ′) dξ′ + Ck,0(τ)‖γ0k‖1e−kξ

(by second inequality of (i))

≤ e−kξ

∫ ∞−∞

|ξ − ξ′|√4πτ

e−

(ξ − ξ′)2

4τ+ k(ξ − ξ′)

γ0k+1(eξ′) dξ′ + Ck,0(τ)‖γ0k‖1e−kξ

≤Ck,1(τ)e−kξ

∫ ∞−∞

γ0k+1(eξ′) dξ′ + Ck,0(τ)‖γ0k‖1e−kξ

≤Ck,1(τ)e−kξ

∫ ∞0

γ0k+1(η)1

ηdη + Ck,0(τ)‖γ0k‖1e−kξ

(by change of variable η = exp(ξ′))

≤Ck,1(τ)e−kξ

∫ ∞0

γ0k(η) dη + Ck,0(τ)‖γ0k‖1e−kξ

≤ ‖γ0k‖1e−kξ(Ck,0(τ) +

Ck,1(τ)

).

Thus, with the original variables, we get for all (x, t) ∈ R+ × R+,

x2 |ux(x, t)| ≤ ‖γ0k‖1e−k(log(x)+b(t)−a(t))(Ck,0(b(t)) +

Ck,1(b(t))

2b(t)

)

≤‖γ0k‖1xk

(Ck,0(b(t)) +

Ck,1(b(t))

2b(t)

)e−k(b(t)−a(t)).

Hence the second inequality of (ii).�

We thus have the following statements concerning sufficient conditions on the initial datum u0such that the solution u given in (3.10) satisfies certain decay conditions and has unit total mass:

Page 25: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

25 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

Proposition 3.4 (Decay of the solution). Let u(x, t) : R+×R+ −→ [0,∞) be the solution toproblem (3.1) defined in (3.10). Let n ∈ R+ ∪{0} be fixed. Then for all t ∈ R+, xn+1u(x, t)→ 0and xn+2ux(x, t)→ 0 as x→ 0. If moreover γ0n+1+δ ∈ L∞(R+) or γ0n+δ ∈ L1(R+) for some δ > 0with γ0k as defined in lemma 3.1, then for all t ∈ R+, xn+1u(x, t)→ 0 and xn+2ux(x, t)→ 0 asx→∞.

Proof. According to lemma 3.1(i), taking k = 0, we get for all (x, t) ∈ R+ × R+,

u(x, t) ≤ ‖γ00‖∞e2b(t)−a(t) = ‖u0‖∞e2b(t)−a(t).

Then, since ‖u0‖∞ <∞, xn+1u(x, t)→ 0 as x→ 0. By lemma 3.1(ii) and taking k = 0, we havefor all (x, t) ∈ R+ × R+,

|ux(x, t)| ≤ ‖γ00‖∞x

(2 +

1√πb(t)

)e2b(t)−a(t) =

‖u0‖∞x

(2 +

1√πb(t)

)e2b(t)−a(t).

Thus, since ‖u0‖∞ <∞, xn+2 |ux(x, t)| → 0 as t→ 0.

Suppose now that γ0n+1+δ ∈ L∞(R+), then by lemma 3.1(i) and taking k = n + 1 + δ, we havefor all (x, t) ∈ R+ × R+,

u(x, t) ≤‖γ0n+1+δ‖∞xn+1+δ

e(n+δ)2b(t)−(n+δ)(b(t)−a(t)).

Therefore, since ‖γ0n+1+δ‖∞ <∞, xn+1u(x, t)→ 0 as x→∞. According to lemma 3.1(ii), takingk = n+ 1 + δ, we obtain for all (x, t) ∈ R+ × R+,

|ux(x, t)| ≤‖γ0n+1+δ‖∞xn+2+δ

(1 + n+ δ +

1√πb(t)

)e(n+δ)

2b(t)−(n+δ)(b(t)−a(t)).

Hence, since ‖γ0n+1+δ‖∞ <∞, xn+2 |ux(x, t)| → 0 as x→∞.

Suppose instead that γ0n+δ ∈ L1(R+). By lemma 3.1(i) with k = n + δ, we have for all (x, t) ∈R+ × R+,

u(x, t) ≤‖γ0n+δ‖1xn+1+δ

Cn+δ,0(b(t))e−(n+δ)(b(t)−a(t)).

Then, knowing that Cn+δ,0(b(t)) < ∞ and ‖γ0n+δ‖1 < ∞, we obtain that xn+1u(x, t) → 0 asx→∞. By lemma 3.1(ii) with k = n+ δ, we get for all (x, t) ∈ R+ × R+,

|ux(x, t)| ≤‖γ0n+δ‖1xn+2+δ

(Cn+δ,0(b(t)) +

Cn+δ,1(b(t))

2b(t)

)e−(n+δ)(b(t)−a(t)).

Hence, since Cn+δ,0(b(t)) <∞, Cn+δ,1(b(t)) <∞ and ‖γ0n+δ‖1 <∞, we obtain xn+2 |ux(x, t)| →0 as x→∞.

Proposition 3.4 gives sufficient hypotheses on the initial probability density u0 in order to beable to apply proposition 3.3 on the moments.

Page 26: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

26 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

Proposition 3.5 (Conservation of mass). Let γ01+δ ∈ L∞(R+) or γ0δ ∈ L1(R+) for someδ > 0, where γ0k is defined in lemma 3.1. Then, solution u(x, t) : R+ × R+ −→ [0,∞) as givenin (3.10) is a probability density function.

Proof. From (3.10), we see that the solution we constructed satisfies u(x, t) ≥ 0 for all (x, t) ∈R+ × R+. Furthermore, by proposition 3.4, xu(x, t) → 0 and x2ux(x, t) → 0 as x → 0 andx→∞. We may thus apply proposition 3.3 with n = 0, and show that the mass of the solutionis conserved in time. Therefore, since u0 has unit total mass, u(x, t) has unit total mass at anytime t as well. Hence, u(x, t) is a probability density function.

Remark 3.2 (Justification of the initial moments hypotheses). Propositions 3.4 and 3.5justify the hypotheses (2.9) and (2.14) on the initial moments in the two-dimensional case, andthe hypotheses (2.18) and (2.23) in the three-dimensional case. Indeed, they ensure that thesolution constructed in (3.10) satisfies the assumptions on the decay (2.12) and (2.16) in twodimensions, and (2.21) and (2.25) in three dimensions. They also guarantee that solution (3.10)is a probability density function.

We may also derive the following proposition from lemma 3.1:

Proposition 3.6 (Limits of the solution). Let u(x, t) : R+ × R+ −→ [0,∞) be the solutionto problem (3.1) defined in (3.10). Then for all t ∈ R+, u(x, t) → 0 as x → ∞. If furthermorethere exists δ > 0 such that γ0−δ ∈ L∞(R+) or γ0−δ−1 ∈ L1(R+) with γ0k as defined in lemma 3.1,then for all t ∈ R+, u(x, t)→ 0 as x→ 0.

Proof. By lemma 3.1(i) with k = 0, for all (x, t) ∈ R+ × R+,

u(x, t) ≤ ‖γ00‖1x

C0,0(b(t)) =‖u0‖1x

C0,0(b(t)) =C0,0(b(t))

x

since u0 is a probability density function. Therefore, u(x, t)→ 0 as x→∞.

Suppose now that there exists δ ∈ R+ such that γ0−δ ∈ L∞(R+). Then, by lemma 3.1(i) withk = −δ, for all (x, t) ∈ R+ × R+,

u(x, t) ≤ xδ‖γ0−δ‖∞e(δ+1)2b(t)+(δ+1)(b(t)−a(t)).

Hence, since ‖γ0−δ‖∞ <∞, u(x, t)→ 0 as x→ 0.

Suppose instead that γ0−δ−1 ∈ L1(R+). According to lemma 3.1(i) with k = −δ − 1, for all(x, t) ∈ R+ × R+,

u(x, t) ≤ xδ‖γ0−δ−1‖1C−δ−1,0(b(t))e(δ+1)(b(t)−a(t)).

Thus, knowing that C−δ−1,0(b(t)) <∞ and ‖γ0−δ−1‖1 <∞, we have u(x, t)→ 0 as x→ 0.�

Page 27: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

27 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

3.3 Finite-time blow-up

We dedicate this section to finding if, and for which data and initial probability density function,a solution to (3.1) may blow up in finite time. Commonly, what is physically known is one of themoments of the solution at all time t, let us say the n-th moment for some n ∈ R+∪{0}, and let usfix such n. This knowledge comes from experimental data, which we write g(t) := cMn(u, t) > 0with limt→0 g(t) =: g(0) and c > 0 a proportion constant. The following results are based on [5],and slightly modified to correspond to our problem.

Lemma 3.2 (Sufficient conditions for blow-up). Let u(x, t) : R+×R+ −→ [0,∞) be a solutionto problem (3.1) such that xn+1u(x, t)→ 0 and xn+2ux(x, t)→ 0 as x→ 0 and x→∞. Let u0satisfy 0 < Mn(u, 0) < D for some D > 0, and suppose there exists T > 0 such that either

g(T ) ≤ g(0)− c∫ ∞0

xnu0(x) dx (3.15)

or

g(T ) ≥ g(0) + cDena(T )+n(n−1)b(T ) − c∫ ∞0

xnu0(x) dx, (3.16)

where a(t) :=∫ t0 A(s) ds and b(t) :=

∫ t0 B(s) ds. Then the solution blows up before or at time T .

Proof. By proposition 3.3, we have Mn(u, t) = Mn(u, 0)ena(t)+n(n+1)b(t) for all t ∈ R+. Thisshows that if the initial data u0 is such that 0 < Mn(u, 0) < D, then

0 < Mn(u, T ) < Dena(T )+n(n+1)b(T ). (3.17)

We have ∫ T

0

d

dtg(s) ds = g(T )− g(0) = cMn(u, T )− cMn(u, 0).

Therefore, by (3.17),

g(0)− c∫ ∞0

xnu0(x) dx < g(T ) < g(0) + cDena(T )+n(n−1)b(T ) − c∫ ∞0

xnu0(x) dx.

Hence, if either (3.15) or (3.16) holds, then inequality (3.17) is contradicted. Therefore, thesolution must have ceased to exist before or at time T , and thus must blow up.

Lemma 3.2 induces the following two results:

Proposition 3.7 (Sufficient conditions for blow-up). Let u(x, t) : R+ ×R+ −→ [0,∞) be asolution to problem (3.1) such that xn+1u(x, t)→ 0 and xn+2ux(x, t)→ 0 as x→ 0 and x→∞.Let u0 satisfy 0 < Mn(u, 0) < D for some D > 0, and suppose there exists T > 0 such thateither

g(T ) ≤ g(0)− cD (3.18)

org(T ) ≥ g(0) + cDena(T )+n(n−1)b(T ). (3.19)

Then solution u blows up before or at time T .

Page 28: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

28 3 ANALYSIS OF A GENERAL FOKKER-PLANCK EQUATION

Proof. By the hypotheses of the proposition, we have Mn(u, 0) < D, with D > 0. Hence, byinequality (3.15) we easily get that (3.18) leads to blow-up before or at time T . Similarly, since0 < Mn(u, 0), we obtain that (3.19) leads to blow-up before or at time T by inequality (3.16).

Proposition 3.8 (Existence of a blow-up solution). Suppose that gt is a nonzero functionof time. Then, there exists a probability density function u0 ∈ C∞(R+) with compact supportsuch that any solution emanating from u0 blows up in finite time.

Proof. Let G(t) :=∫ t0 gt(s) ds = g(t) − g(0) for all t ∈ R+. Since gt is a nonzero function, we

know that there exists a time T > 0 such that G(T ) 6= 0. Hence, there exist ε ∈ (0, 12) and D > 0

that satisfy either G(T ) ≤ −cDε if G(T ) < 0, or G(T ) ≥ cε+ cDena(T )+n(n−1)b(T ) if G(T ) > 0.Choose such ε and D. Let us choose a probability density function v0 ∈ C∞(R+) with compactsupport included in (1, D1/n). Assume first that G(T ) < 0. Let then take

u0(x) :=1

ε1/nv0

( x

ε1/n

)for x ∈ R+.

Then one can easily check that u0 is a probability density in C∞(R+) with compact supportcontained in (ε1/n, (Dε)1/n), and such that 0 < Mn(u, 0) :=

∫∞0 xnu0(x) dx. Moreover, let us

compute

c

∫ ∞0

xnu0(x) dx = c

∫ (Dε)1/n

ε1/nxnu0(x) dx ≤ cDε ≤ −G(T ).

Hence inequality (3.15) and finite-time blow-up of the solution with initial data u0. Assume nowthat G(T ) > 0. Let us take

u0(x) :=1

(1− ε)1/nv0

(x

(1− ε)1/n

)for x ∈ R+.

Similarly, one can easily check that u0 is a probability density in C∞(R+) with compact supportcontained in ((1− ε)1/n, (D −Dε)1/n), and such that Mn(u, 0) < D. Let us compute

c

∫ ∞0

xnu0(x) dx = c

∫ (D−Dε)1/n

(1−ε)1/nxnu0(x) dx ≥ c(1− ε) ≥ −cε ≥ cDena(T )+n(n−1)b(T ) −G(T ).

Thus we have inequality (3.16) and finite-time blow-up of the solution with initial data u0.�

Remark 3.3 (Non-physical admissibility of the finite-time blow-up conditions). Lemma(3.2) and proposition (3.7) show that any solution blows up if the initial distribution and gare taken in certain ranges. Nevertheless, it is interesting to remark that these ranges are notphysically admissible since g(0) must be equal to the n-th moment of the initial distribution andg(t) must be positive and not larger than cDena(t)+n(n−1)b(t) for all t ∈ R+.

Page 29: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

29 4 DERIVATION OF THE GOVERNING EQUATIONS

4 Derivation of the governing equations

We show in this section how to derive the governing equations and how to use the decay condi-tions (2.12) and (2.16) to find the drift velocities (2.10) and (2.15) in two dimensions, and thedecay conditions (2.21) and (2.25) to find the drift velocities (2.19) and (2.24) in three dimen-sions.

Two-dimensional case

Radius distribution We assume that the radius distribution satisfies the continuity equationwith {

ψt + Jr = 0 for (r, t) ∈ R+ × R+

J = v(t)rψ − β(t)(r2ψ)r for (r, t) ∈ R+ × R+,(4.1)

where J(r, t) is the flux. This directly gives governing equation (2.8). We now want to derive theexpression for the drift velocity given in (2.10). We physically have P (t) = N(t)

∫∞0 πr2ψ(r, t) dr =

πN(t)M2(ψ, t), where M2(ψ, t) is the second moment of ψ at time t ∈ R+. Therefore, g(t) :=P (t)N(t) = πM2(ψ, t) for all t ∈ R+. Hence, by the decay conditions given in (2.12) and proposition3.3 with n = 2, we get for all t ∈ R+,

g(t) = g(0)e2w(t)+2b(t),

where g(0) := π∫∞0 r2ψ0(r) dr 6= 0, w(t) =

∫ t0 v(s) ds, and b(t) =

∫ t0 β(s) ds = β0t + β1w(t) by

(2.7). Then,

w(t) =1

2log

(g(t)

g(0)

)− b(t). (4.2)

Therefore, differentiating equation (4.2) with respect to time t, we obtain equation (2.10).

Area distribution As for the radius distribution, we assume that the distribution satisfiesthe continuity equation with{

φt + Jx = 0 for (x, t) ∈ R+ × R+

J = v(t)xφ− β(t)(x2φ)x for (x, t) ∈ R+ × R+,(4.3)

where J(x, t) is the flux. Hence governing equation (2.13). Let us now derive the drift velocity(2.15). We know that physically P (t) = N(t)

∫∞0 xφ(r, t) dx = πN(t)M1(φ, t), where M1(φ, t) is

the first moment of φ at time t ∈ R+. Therefore, g(t) = M1(φ, t) for all t ∈ R+. Thus, using thedecay conditions (2.16) and proposition 3.3 with n = 1, we get for all t ∈ R+,

g(t) = g(0)ew(t),

where g(0) :=∫∞0 xφ0(x) dx 6= 0 and w(t) =

∫ t0 v(s) ds. Thus,

w(t) = log

(g(t)

g(0)

). (4.4)

Hence the drift velocity given in (2.15).

Page 30: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

30 4 DERIVATION OF THE GOVERNING EQUATIONS

Three-dimensional case

Radius distribution Similarly to the two-dimensional case, we assume that the radius dis-tribution satisfies the continuity equation with{

ψt + Jr = 0 for (r, t) ∈ R+ × R+

J = v(t)rψ − β(t)(r2ψ)r for (r, t) ∈ R+ × R+,(4.5)

where J(r, t) is the flux. This gives governing equation (2.17). We now want to derive theformula for the drift velocity (2.19). We have by the physics of the problem that P (t) =N(t)

∫∞0

4π3 r

3ψ(r, t) dr = 4π3 N(t)M3(ψ, t), where M3(ψ, t) is the third moment of ψ at time

t ∈ R+. Therefore, g(t) = 4π3 M3(ψ, t) for all t ∈ R+. So, by the decay conditions given in (2.21)

and proposition 3.3 with n = 3, we get for all t ∈ R+,

g(t) = g(0)e3w(t)+6b(t),

where g(0) := 4π3

∫∞0 r3ψ0(r) dr 6= 0, w(t) =

∫ t0 v(s) ds, and b(t) =

∫ t0 β(s) ds = β0 + β1w(t) by

(2.7). Then,

w(t) =1

3log

(g(t)

g(0)

)− 2b(t). (4.6)

Hence the drift velocity given in equation (2.19).

Volume distribution This case is perfectly analogous to that of the area distribution in twodimensions. Wwe assume that the volume distribution satisfies the continuity equation with{

φt + Jx = 0 for (x, t) ∈ R+ × R+

J = v(t)xφ− β(t)(x2φ)x for (x, t) ∈ R+ × R+,(4.7)

where J(x, t) is the flux. Hence governing equation (2.22). Let us now derive the drift velocity(2.24). We physically have that P (t) = N(t)

∫∞0 xφ(r, t) dx = πN(t)M1(φ, t). Then, g(t) =

M1(φ, t) for all t ∈ R+, and using the decay conditions (2.25) and again proposition 3.3 withn = 1, we get for all t ∈ R+,

g(t) = g(0)ew(t),

where g(0) :=∫∞0 xφ0(x) dx 6= 0 and w(t) =

∫ t0 v(s) ds. Thus,

w(t) = log

(g(t)

g(0)

). (4.8)

Differentiating then equation (4.8) with respect to t, we obtain the drift velocity given in (2.24).

Remark 4.1 (Choice of the diffusion parameter β0). We may now deduce important infor-mation about the parameter β0 in (2.7), that is β(t) = β0 + β1v(t), in the radius cases. Indeed,we know that after quenching, the drift velocity v(t) must be physically equal to zero for alltimes, since the transformation freezes. Therefore, we want w(t) :=

∫ t0 v(s) ds to be constant

after the quenching time. Since g(t) := P (t)N(t) is constant after quenching as well, according to

Page 31: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

31 5 ANALYSIS OF THE GOVERNING EQUATIONS

equations (4.2) and (4.6) and the expression of β(t) as dependent on v(t) given in (2.7), thiscan be fulfilled only if b(t) :=

∫ t0 β(s) ds = β0t + β1w(t) becomes a constant too, i.e., β0 = 0.

Numerical arguments in section 6.2.1 show the same conclusion concerning the area and volumecases, i.e., β0 must be zero as well.

5 Analysis of the governing equations

5.1 Analytical solutions

In the following, we apply the results found in section 3 to the grain size distribution problem.An important remark is to remember that the equations satisfied by the size distributions givenin section 2.2 are local since the drift velocities are independent of the solution (see remark2.2). Therefore, the solutions given below are explicit formulations, and can thus be directlyimplemented and plotted as done in the numerical study of section 6.2.

Two-dimensional case

Radius distribution Since ψ0, v and β respect the hypotheses given in section 3.1 on u0, Aand B respectively, we may use the result obtained in section 3.1. From remark 3.2 we knowthat the hypothesis (2.9) implies the decay conditions (2.12) in the case of the solution givenin (3.10), as well as its conservation of mass. Furthermore, by section 4, these decay conditionsyield the expression for the drift velocity (2.10). We thus deduce that the following is a solutionto problem (2.8)–(2.12):

ψ(r, t) =1

r(K(·, b(t)) ∗Ψ0)(log(r) + b(t)− w(t)) for (r, t) ∈ R+ × R+, (5.1)

where K is defined as in (3.7) and

Ψ0(ξ) = eξψ0(eξ), w(t) =

∫ t

0v(s) ds and b(t) =

∫ t

0β(s) ds for (ξ, t) ∈ R× R+, (5.2)

with v(t) given in equation (2.10) and β(t) = β0 + β1v(t).

Area distribution As for the radius case, we may use the previous results of sections 3.1 and4 to get that the following is a solution to problem (2.13)–(2.16):

φ(x, t) =1

x(K(·, b(t)) ∗ Φ0)(log(x) + b(t)− w(t)) for (x, t) ∈ R+ × R+, (5.3)

where K is defined as in (3.7) and

Φ0(ξ) = eξφ0(eξ), w(t) =

∫ t

0v(s) ds and b(t) =

∫ t

0β(s) ds for (ξ, t) ∈ R× R+, (5.4)

with v(t) given in equation (2.15) and β(t) = β0 + β1v(t).

Page 32: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

32 5 ANALYSIS OF THE GOVERNING EQUATIONS

Three-dimensional case

Radius distribution As for the problem in two dimensions, we deduce from the previousresults that the following is a solution to problem (2.17)–(2.21):

ψ(r, t) =1

r(K(·, b(t)) ∗Ψ0)(log(r) + b(t)− w(t)) for (r, t) ∈ R+ × R+, (5.5)

where K is defined as in (3.7) and

Ψ0(ξ) = eξψ0(eξ), w(t) =

∫ t

0v(s) ds b(t) =

∫ t

0β(s) ds and for (ξ, t) ∈ R× R+, (5.6)

with v(t) given in equation (2.19) and β(t) = β0 + β1v(t).

Volume distribution As for the radius case, we may use sections 3.1 and 4 to get that thefollowing is a solution to problem (2.22)–(2.25):

φ(x, t) =1

x(K(·, b(t)) ∗ Φ0)(log(x) + b(t)− w(t)) for (x, t) ∈ R+ × R+, (5.7)

where K is defined as in (3.7) and

Φ0(ξ) = eξφ0(eξ), w(t) =

∫ t

0v(s) ds and b(t) =

∫ t

0β(s) ds for (ξ, t) ∈ R× R+, (5.8)

with v(t) given in equation (2.24) and β(t) = β0 + β1v(t).

Remark 5.1 (Justification of the flux). Our first attempt for a model was to write the fluxin the simpler form J(r, t) = v(t)ψ − β(t)ψr. According to our analysis of section 3.1 (followingthe reasoning from step 2), this leads to a solution which is a normal distribution convolutedwith the initial data. This means that if we take a symmetric initial distribution, the solutionwill stay symmetric forever, which is not what is expected physically. This justifies our choicefor the flux given in (4.1), where the solution derived in (5.1)–(5.2) is a log-normal distributionconvoluted with the initial data, and it is thus an asymmetric distribution for all t > 0. Theremark clearly holds for the area distribution and three-dimensional cases as well.

Remark 5.2 (Justification of the drift velocity and diffusion coefficient hypotheses). Thehypotheses 1–3 on v(t) and β(t) given in section 2.2 allow to apply the analysis led in section3.1, as they respect the hypotheses on A and B. Thus we can find an analytical solution to ourequations for the grain size distributions, as done above.

Remark 5.3 (Restriction on the data g(t)). From the hypothesis 3 on v(t) and β(t) given in

section 2.2, we may derive necessary hypotheses on the data g(t) := P (t)N(t) > 0 in order to be

actually allowed to derive the solutions (5.1), (5.3), (5.5) and (5.7). Hypothesis 3 implies thatw(t) :=

∫∞0 v(s) ds > 0 for all t > 0. Therefore, by (4.4) and (4.8), the data g must be such

that for all t ∈ R+, g(t) > g(0) in the area- and volume-distribution cases. Similarly, in thetwo-dimensional radius case and by (4.2) and (2.7), the data g must be such that for all t ∈ R+,g(t) > g(0) exp (2(1 + β1)w(t) + 2β0t). Finally, in the three-dimensional radius case and by (4.6)and (2.7), the data g must be such that for all t ∈ R+, g(t) > g(0) exp (3(1 + 2β1)w(t) + 6β0t).

Page 33: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

33 5 ANALYSIS OF THE GOVERNING EQUATIONS

5.2 Relations between distributions

In this section, we find the relation between the radius distribution and the area distribution inthe two-dimensional problem, and between the radius distribution and the volume distributionin the three-dimensional problem. We also find the equations that each of these distributionssatisfies. As in section 2.2, let ψ(r, t) : R+ × R+ −→ [0,∞) and φ(x, t) : R+ × R+ −→ [0,∞)denote the radius distribution and the area or volume distribution, respectively.

Two-dimensional case

The quantity limdr→0 ψ(r, t)dr represents the probability that at time t, a given grain has radiusr. Similarly, limdx→0 φ(x, t)dx is the probability that at time t, a given grain has area x. Hencethe following for all t ∈ R+:

limdr→0

ψ(r, t)dr = limdx→0

φ(x, t)dx.

Therefore, writing x = x(r) = πr2,

ψ(r, t) = φ(πr2, t)limdx→0

dx

limdr→0

dr

= φ(πr2, t)dx

dr(r) = 2πrφ(πr2, t),

where ddr denotes the derivative with respect to r. Identically, writing r = r(x) =

√xπ , one finds

φ(x, t) as a function of ψ(√

xπ , t). This leads finally to the following change of variables:

ψ(r, t) = 2πrφ(πr2, t) for (r, t) ∈ R+ × R+

φ(x, t) =1

2√πxψ

(√x

π, t

)for (x, t) ∈ R+ × R+.

(5.9)

Let us now find the relation between the moments of ψ and those of φ. We have for all t ∈ R+

and n ∈ R+ ∪ {0},

Mn(ψ, t) =

∫ ∞0

rnψ(r, t) dr

=

∫ ∞0

(xπ

)n/2ψ

(√x

π, t

)1

2√πx

dx (by change of variable x = πr2)

=1

πn/2

∫ ∞0

xn/2φ(x, t) dx (by equation (5.9))

=1

πn/2Mn

2(φ, t).

Page 34: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

34 5 ANALYSIS OF THE GOVERNING EQUATIONS

Conversely, one gets Mn(φ, t) = πnM2n(ψ, t) for all t ∈ R+. Hence the following relations: Mn(ψ, t) =1

πn/2Mn

2(φ, t) for t ∈ R+

Mn(φ, t) = πnM2n(ψ, t) for t ∈ R+.

(5.10)

Equation (5.10) shows that, through transformation (5.9), the radius and area distributions stayprobability density functions as soon as their respective area and radius distributions are so.Furthermore, (5.10) respects that πM2(ψ, t) = M1(φ, t), which is what we want physically.

Let us now write the equations satisfied by both the radius and area distributions.

If radius distribution satisfies (2.8)–(2.12) Then, by (5.9), we have the following problemfor the area distribution (see appendix A for a derivation):

φt = −v∗(t)(xφ)x + β∗(t)(x2φ)xx for (x, t) ∈ R+ × R+

limt→0

φ(x, t) = φ0(x) =1

2√πxψ0

(√x

π

)for x ∈ R+,

(5.11)

where the initial distribution satisfies the following by (2.9) and (5.9):∫ ∞0

xnφ0(x) dx <∞ for 0 ≤ n ≤ 1 + δ (5.12)

for some δ > 0, and the new drift velocity v∗(t) and diffusion coefficient β∗(t) are given by{v∗(t) := 2(v(t) + β(t)) for t ∈ R+

β∗(t) := 4β(t) for t ∈ R+,(5.13)

where v(t) and β(t) are the drift and diffusion coefficients as in (2.10) and (2.7). Therefore, wecan write v∗(t) =

gt(t)

g(t)for t ∈ R+

β∗(t) = β∗0 + β∗1v∗(t) for t ∈ R+,

(5.14)

where β∗0 = 4β01+β1

≥ 0 and β∗1 = 2β11+β1

≥ 0. Also, we have the following decay conditions by (2.12): limx→0

x2φ(x, t) = limx→∞

x2φ(x, t) = 0 for t ∈ R+

limx→0

x3φx(x, t) = limx→∞

x3φx(x, t) = 0 for t ∈ R+.(5.15)

A solution to problem (5.11)–(5.15) can be obtained in two equivalent ways. One is to apply thesolution (3.10) found in section 3.1 to the new drift and diffusion coefficients v∗ and β∗, sinceby (5.13) they respect the hypotheses 1–3 on A and B given in section 3.1. Thus, a solution forthe area distribution is given by

φ(x, t) =1

x(K(·, b∗(t)) ∗ Φ0)(log(x) + b∗(t)− w∗(t)) for (x, t) ∈ R+ × R+, (5.16)

Page 35: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

35 5 ANALYSIS OF THE GOVERNING EQUATIONS

where K is defined as in (3.7) and for all (ξ, t) ∈ R× R+,

Φ0(ξ) = eξφ0(eξ) =

eξ/2

2√πψ0

(eξ/2√π

), w∗(t) =

∫ t

0v∗(s) ds and b∗(t) =

∫ t

0β∗(s) ds,

(5.17)with v∗(t) and β∗(t) given in (5.13). The second way to find the solution for the area distributionis to directly use the change of variables (5.9). We know that a solution for the radius distributionis given in equation (5.1), thus a solution for the area distribution is

φ(x, t) =1

2x(K(·, b(t)) ∗Ψ0)

(log

(√x

π

)+ b(t)− w(t)

)for (x, t) ∈ R+ × R+, (5.18)

where K is defined as in (3.7) and

Ψ0(ξ) = eξψ0(eξ), w(t) =

∫ t

0v(s) ds and b(t) =

∫ t

0β(s) ds for (ξ, t) ∈ R× R+, (5.19)

with v(t) and β(t) given in equations (2.10) and (2.7). We show in appendix A that (5.16)–(5.17)and (5.18)–(5.19) are equivalent solutions for the area distribution.

If area distribution satisfies (2.13)–(2.16) Let us proceed similarly to the radius case. Wehave by (5.9) the following problem for the radius distribution (see appendix A for a derivation): ψt = −v∗(t)(rψ)r + β∗(t)(r2ψ)rr for (r, t) ∈ R+ × R+

limt→0

ψ(r, t) = ψ0(r) = 2πrφ0(πr2) for r ∈ R+,

(5.20)

where by (2.14) and (5.9) the initial distribution satisfies∫ ∞0

xnψ0(x) dx <∞ for 0 ≤ n ≤ 2 + δ (5.21)

for some δ > 0, and the new drift and diffusion coefficients v∗(t) and β∗(t) are defined byv∗(t) :=

1

2

(v(t)− β(t)

2

)for t ∈ R+

β∗(t) :=β(t)

4for t ∈ R+,

(5.22)

where v(t) and β(t) are the drift and diffusion coefficients as in (2.15) and (2.7). If β1 < 2, wemay write v∗(t) =

1

2

gt(t)

g(t)− β∗(t) for t ∈ R+

β∗(t) = β∗0 + β∗1v∗(t) for t ∈ R+,

(5.23)

where β∗0 = β02(2−β1) ≥ 0 and β∗1 = β1

2−β1 ≥ 0. By (2.16), we also get the following decay conditions: limr→0

r3ψ(r, t) = limr→∞

r3ψ(r, t) = 0 for t ∈ R+

limr→0

r4ψr(r, t) = limr→∞

r4ψr(r, t) = 0 for t ∈ R+.(5.24)

Page 36: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

36 5 ANALYSIS OF THE GOVERNING EQUATIONS

Analogously to the radius case, we can find a solution to (5.20)-(5.24) in two ways. The firstway comes from the solution (3.10) of section 3.1, since by (5.22) the new drift velocity anddiffusion coefficient v∗ and β∗ satisfy the hypotheses on A and B given in section 3.1. Therefore,a solution for the radius distribution is

ψ(r, t) =1

r(K (·, b∗(t)) ∗Ψ0) (log(r) + b∗(t)− w∗(t)) for (r, t) ∈ R+ × R+, (5.25)

where K is defined as in (3.7) and for all for (ξ, t) ∈ R× R+,

Ψ0(ξ) = eξψ0(eξ) = 2πe2ξφ0(πe2ξ), w∗(t) =

∫ t

0v∗(s) ds and b∗(t) =

∫ t

0β∗(s) ds, (5.26)

with v∗(t) and β(t)∗ given in equation (5.22). The second way to find the solution for the radiusdistribution is to directly use the change of variables (5.9). We know that a solution for the areadistribution is given in equation (5.3), so

ψ(r, t) =2

r(K(·, b(t)) ∗ Φ0)(log(πr2) + b(t)− w(t)) for (r, t) ∈ R+ × R+, (5.27)

where K is defined as in (3.7) and

Φ0(ξ) = eξφ0(eξ), w(t) =

∫ t

0v(s) ds and b(t) =

∫ t

0β(s) ds for (ξ, t) ∈ R× R+, (5.28)

with v(t) given in (2.15) and β(t) in (2.7). Again, we prove in appendix A that solutions (5.25)–(5.26) and (5.27)–(5.28) are equivalent.

Three-dimensional case

As for the two-dimensional case, the quantity limdr→0 ψ(r, t)dr represents the probability thatat time t, a given grain has radius r, and limdx→0 φ(x, t)dx is the probability that at time t, agiven grain has volume x. Hence for all t ∈ R+:

limdr→0

ψ(r, t)dr = limdx→0

φ(x, t)dx.

Therefore, writing x = x(r) = 4π3 r

3,

ψ(r, t) = φ

(4π

3r3, t

) limdx→0

dx

limdr→0

dr

= φ

(4π

3r3, t

)dx

dr(r) = 4πr2φ

(4π

3r3, t

),

where ddr denotes the derivative with respect to r. Respectively, if one writes r = r(x) = ( 3x4π )1/3,

one finds φ(x, t) as a function of ψ(( 3x4π )1/3, t). This gives the change of variablesψ(r, t) = 4πr2φ

(4π

3r3, t

)for (r, t) ∈ R+ × R+

φ(x, t) =1

(4π)1/3(3x)2/3ψ

((3x

)1/3

, t

)for (x, t) ∈ R+ × R+.

(5.29)

Page 37: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

37 5 ANALYSIS OF THE GOVERNING EQUATIONS

Analogously to the radius case, we find the relation between the moments of ψ and those of φ.We have for all t ∈ R+ and n ∈ R+ ∪ {0},

Mn(ψ, t) =

∫ ∞0

rnψ(r, t) dr

=

∫ ∞0

(3x

)n/3ψ

((3x

)1/3

, t

)1

(4π)1/3(3x)2/3dx

(by change of variable x =4π

3r3)

=

(3

)n/3 ∫ ∞0

xn/3φ(x, t) dx (by equation (5.29))

=

(3

)n/3Mn

3(φ, t).

Conversely, one gets Mn(φ, t) = (4π3 )nM3n(ψ, t) for all t ∈ R+. Hence the following relations:Mn(ψ, t) =

(3

)n/3Mn

3(φ, t) for t ∈ R+

Mn(φ, t) =

(4π

3

)nM3n(ψ, t) for t ∈ R+.

(5.30)

As in the two-dimensional situation, equation (5.30) shows that, the radius and volume distri-butions stay probability density functions as soon as their respective volume and radius distri-butions are so. Furthermore, it respects that 4π

3 M3(ψ, t) = M1(φ, t), which is required physically.

Let us now write the equations satisfied by both the radius and volume distributions.

If radius distribution satisfies (2.17)–(2.21) Then, from (5.29), we get the following prob-lem for the area distribution (see a derivation in appendix A):

φt = −v∗(t)(xφ)x + β∗(t)(x2φ)xx for (x, t) ∈ R+ × R+

limt→0

φ(x, t) = φ0(x) =1

(4π)1/3(3x)2/3ψ0

((3x

)1/3)

for x ∈ R+,(5.31)

where the initial distribution satisfies, by (2.18) and (5.29),∫ ∞0

xnφ0(x) dx <∞ for 0 ≤ n ≤ 1 + δ (5.32)

for some δ > 0, and the new drift velocity v∗(t) and diffusion coefficient β∗(t) are defined by{v∗(t) := 3 (v(t) + 2β(t)) for t ∈ R+

β∗(t) := 9β(t) for t ∈ R+,(5.33)

Page 38: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

38 5 ANALYSIS OF THE GOVERNING EQUATIONS

where v(t) and β(t) are the drift and diffusion coefficients as in (2.19) and (2.7). We can thereforewrite v∗(t) =

gt(t)

g(t)for t ∈ R+

β∗(t) = β∗0 + β∗1v∗(t) for t ∈ R+,

(5.34)

where β∗0 = 9β01+2β1

≥ 0 and β∗1 = 3β11+2β1

≥ 0. Furthermore, we have, by (2.21), the following decayconditions: lim

x→0x2φ(x, t) = lim

x→∞x2φ(x, t) = 0 for t ∈ R+

limx→0

x3φx(x, t) = limx→∞

x3φx(x, t) = 0 for t ∈ R+.(5.35)

We can get a solution to problem (5.11)–(5.15) by two equivalent ways. The first one consistsin applying the result from section 3.1 to the new drift and diffusion coefficients v∗ and β∗,respectively, since by (5.33) they respect the hypotheses given for A and B in section 3.1. Thus,a solution for the volume distribution is given by

φ(x, t) =1

x(K(·, b∗(t)) ∗ Φ0)(log(x) + b∗(t)− w∗(t)) for (x, t) ∈ R+ × R+, (5.36)

where K is defined as in (3.7) and for all (ξ, t) ∈ R× R+,

Φ0(ξ) = eξφ0(eξ) =

eξ/3

(4π)1/332/3ψ0

((3

)1/3

eξ/3

), w∗(t) =

∫ t

0v∗(s) ds, b∗(t) =

∫ t

0β∗(s) ds,

(5.37)with v∗(t) and β∗(t) given in equation (5.33). The second way to find the solution for the volumedistribution is to directly use the change of variables (5.29). We know that a solution for theradius distribution is given in equation (5.5), thus a solution for the volume distribution is

φ(x, t) =1

3x(K(·, b(t)) ∗Ψ0)

(log

((3x

)1/3)

+ b(t)− w(t)

)for (x, t) ∈ R+ × R+, (5.38)

where K is defined as in (3.7) and

Ψ0(ξ) = eξψ0(eξ), w(t) =

∫ t

0v(s) ds and b(t) =

∫ t

0β(s) ds for (ξ, t) ∈ R× R+, (5.39)

with v(t) and β(t) given in equation (2.19). We show in appendix A that (5.36)–(5.37) and(5.38)–(5.39) are equivalent solutions for the volume distribution.

If volume distribution satisfies (2.22)–(2.25) By (5.29), we then obtain the problem forthe radius distribution (see appendix A for a derivation):

ψt = −v∗(t)(rψ)r + β∗(t)(r2ψ)rr for (r, t) ∈ R+ × R+

limt→0

ψ(r, t) = ψ0(r) = 4πr2φ0

(4π

3r3)

for r ∈ R+,(5.40)

where by the change of variable (5.29) and by (2.23), the initial distribution verifies∫ ∞0

xnψ0(x) dx <∞ for 0 ≤ n ≤ 3 + δ (5.41)

Page 39: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

39 5 ANALYSIS OF THE GOVERNING EQUATIONS

for some δ > 0, and the new drift velocity v∗(t) and diffusion coefficient β∗(t) are defined asv∗(t) :=

1

3

(v(t)− 2β(t)

3

)for t ∈ R+

β∗(t) :=β(t)

9for t ∈ R+,

(5.42)

where v(t) and β(t) are the drift and diffusion coefficients in (2.24) and (2.7). Therefore, ifβ1 <

32 , we may write v∗(t) =

1

3

gt(t)

g(t)− 2β∗(t) for t ∈ R+

β∗(t) = β∗0 + β∗1v∗(t) for t ∈ R+,

(5.43)

where β∗0 = β03(3−2β1) ≥ 0 and β∗1 = β1

3−2β1 ≥ 0. We also have the following decay conditions by

(2.25): limr→0

r4ψ(r, t) = limr→∞

r4ψ(r, t) = 0 for t ∈ R+

limr→0

r5ψr(r, t) = limr→∞

r5ψr(r, t) = 0 for t ∈ R+.(5.44)

As for the radius case, we can find a solution to problem (5.40)–(5.44) in two ways. The firstway stems from the solution (3.10) obtained in section 3.1, as by (5.42) v∗ and β∗ respect thehypotheses on A and B given in that section. Hence the solution for the radius distribution:

ψ(r, t) =1

r(K (·, b∗(t)) ∗Ψ0) (log(r) + b∗(t)− w∗(t)) for (r, t) ∈ R+ × R+, (5.45)

where K is defined as in (3.7) and for all (ξ, t) ∈ R× R+,

Ψ0(ξ) = eξψ0(eξ) = 4πe3ξφ0

(4π

3e3ξ), w∗(t) =

∫ t

0v∗(s) ds and b∗(t) =

∫ t

0β∗(s) ds,

(5.46)with v∗(t) and β∗(t) given in equation (5.42). The second way to find the solution for the radiusdistribution is to directly use the change of variables (5.29). We know that a solution for thearea distribution is given in equation (2.22), so

ψ(r, t) =3

r(K(·, b(t)) ∗ Φ0)

(log

(4π

3r3)

+ b(t)− w(t)

)for (r, t) ∈ R+ × R+, (5.47)

where K is defined as in (3.7) and

Φ0(ξ) = eξφ0(eξ), w(t) =

∫ t

0v(s) ds and b(t) =

∫ t

0β(s) ds for (ξ, t) ∈ R× R+, (5.48)

with v(t) and β(t) given in (2.24) and (2.7). We prove in appendix A that (5.45)–(5.46) and(5.47)–(5.48) are equivalent solutions for the three-dimensional radius distribution.

Remark 5.4 (Connection between distributions). Given the form of solutions (5.16) and (5.25)in two dimensions, and that of solutions (5.36) and (5.45) in three dimensions, we see that theysatisfy the same Fokker-Planck equation as their respective radius, area or volume distributions(see equations (5.1) and (5.3) in two dimensions, and (5.5) and (5.7) in three dimensions), but

Page 40: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

40 5 ANALYSIS OF THE GOVERNING EQUATIONS

with different initial data and different drift velocity and diffusion coefficient. Therefore, it doesnot matter considering in the first place that the radius or area or volume distribution satisfiesthe Fokker-Planck equations given in section 2.2, as the distributions all appear to be solutionsof the same equation, with the only difference being in the initial data and drift and diffusioncoefficients.

5.3 Finite-time blow-up

We want here to apply the results of section 3.3 to the case of the grain size distribution. In thiscase, the quantity g(t) := P (t)

N(t) > 0 represents the ratio between the surface or volume occupiedby the ferrite and the number of ferrite growth nuclei at time t.

Two-dimensional case

Radius distribution For the case of the radius distribution, we have g(t) := πM2(ψ, t) for allt ∈ R+. We may thus apply all the results from section 3.3 with n = 2 and c = π. The quantityD must be seen here as a geometric constraint, such that the second moment cannot be largerthan D at any time.

Furthermore, being that g is a positive quantity, we may use equation section 3.3 and (4.2) tofind conditions on the drift velocity v and diffusion coefficient β, such that a solution to (2.8)blows up in finite time. Suppose that ψ0 is such that 0 < M2(u, 0) < D for some D > 0. Bylemma 3.2 and equation (4.2), we know that if there exists T > 0 such that either

w(T ) + b(T ) ≤ 1

2log

(1− π

g(0)

∫ ∞0

r2ψ0(r) dr

)(5.49)

or

w(T ) + b(T ) ≥ 1

2log

(g(0)

g(0)− πD− π

g(0)− πD

∫ ∞0

r2ψ0(r) dr

), (5.50)

where w(t) =∫ t0 v(s) ds and b(t) =

∫ t0 β(s) ds for all t ∈ R+, then the solution blows-up before

or at time T . Similarly, by proposition 3.7, if there exists T > 0 such that either

w(T ) + b(T ) ≤ 1

2log

(g(0)− πD

g(0)

)(5.51)

or

w(T ) + b(T ) ≥ 1

2log

(g(0)

g(0)− πD

), (5.52)

then the solution blows-up before or at time T .

Area distribution In the area-distribution case, we have g(t) := M1(φ, t) for all t ∈ R+.Therefore, we can apply all the results from section 3.3 with n = 1 and c = 1. Again, the quan-tity D should be seen as a geometric constraint, such that the first moment is bounded aboveby D at all times.

Page 41: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

41 5 ANALYSIS OF THE GOVERNING EQUATIONS

Moreover, being that g is a positive quantity, we may use equation section 3.3 and (4.4) to findconditions on the drift velocity v and diffusion coefficient β, such that a solution to (2.13) blowsup in finite time. Suppose that φ0 is such that 0 < M1(u, 0) < D for some D > 0. By lemma 3.2and equation (4.4), we know that if there exists T > 0 such that either

w(T ) ≤ log

(1− 1

g(0)

∫ ∞0

xφ0(x) dx

)(5.53)

or

w(T ) ≥ log

(g(0)

g(0)−D− 1

g(0)−D

∫ ∞0

xφ0(x) dx

), (5.54)

then the solution blows-up before or at time T . Similarly, by proposition 3.7, if there existsT > 0 such that either

w(T ) ≤ log

(g(0)−Dg(0)

)(5.55)

or

w(T ) ≥ log

(g(0)

g(0)−D

), (5.56)

then the solution blows-up before or at time T .

Three-dimensional case

Radius distribution In three dimensions we have, for the case of the radius distribution,g(t) := 4π

3 M3(ψ, t) for all t ∈ R+. We may thus apply all the results from section 3.3 withn = 3 and c = 4π

3 . Analogously to the two-dimensional case, the quantity D must be consid-ered as a geometric constraint, such that the third moment cannot be larger than D at any time.

Being that g is a positive quantity, we may use equation section 3.3 and (4.6) to find conditionson the drift velocity v and diffusion coefficient β, such that a solution to (2.17) blows up infinite time. Suppose that ψ0 is such that 0 < M2(u, 0) < D for some D > 0. By lemma 3.2 andequation (4.2), we know that if there exists T > 0 such that either

w(T ) + 2b(T ) ≤ 1

3log

(1− 4π

3g(0)

∫ ∞0

r3ψ0(r) dr

)(5.57)

or

w(T ) + 2b(T ) ≥ 1

3log

(3g(0)

3g(0)− 4πD− 4π

3g(0)− 4πD

∫ ∞0

r3ψ0(r) dr

), (5.58)

where w(t) =∫ t0 v(s) ds and b(t) =

∫ t0 β(s) ds for all t ∈ R+, then the solution blows-up before

or at time T . Similarly, by proposition 3.7, if there exists T > 0 such that either

w(T ) + 2b(T ) ≤ 1

3log

(3g(0)− 4πD

3g(0)

)(5.59)

or

w(T ) + 2b(T ) ≥ 1

3log

(3g(0)

3g(0)− 4πD

), (5.60)

then the solution blows-up before or at time T .

Page 42: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

42 6 NUMERICAL STUDY

Volume distribution In the volume-distribution case, we have g(t) := M1(φ, t) for all t ∈ R+.This is fully analogous to the area case. We can apply all the results from section 3.3 with n = 1and c = 1.

Being that g is a positive quantity, we may use equation section 3.3 and (4.8) to find conditionson the drift velocity v and diffusion coefficient β, such that a solution to (2.22) blows up infinite time. Suppose that φ0 is such that 0 < M1(u, 0) < D for some D > 0. By lemma 3.2 andequation (4.8), we know that if there exists T > 0 such that either

w(T ) ≤ log

(1− 1

g(0)

∫ ∞0

xφ0(x) dx

)(5.61)

or

w(T ) ≥ log

(g(0)

g(0)−D− 1

g(0)−D

∫ ∞0

xφ0(x) dx

), (5.62)

then the solution blows-up before or at time T . Also, by proposition 3.7, if there exists T > 0such that either

w(T ) ≤ log

(g(0)−Dg(0)

)(5.63)

or

w(T ) ≥ log

(g(0)

g(0)−D

), (5.64)

then the solution blows-up before or at time T .

6 Numerical study

In the following section we propose to study numerically the analytical solutions found for thegrain size distributions in section 5.1. We only consider the cases where the area distributionsatisfies (2.13) in the two-dimensional case and the volume distribution satisfies (2.22) in thethree-dimensional case. Then, the solutions for the corresponding radius distributions are foundvia the transformations given in (5.9) and (5.29), i.e., once the distributions φ(x, t) are computed,the corresponding radius distributions are directly obtained using ψ(r, t) = 2πrφ(πr2, t) in thetwo-dimensional setting and ψ(r, t) = 4πr2φ(4π3 r

3, t) in the three-dimensional setting. This isonly used once in this section for testing. Considering the cases where the radius distributionssatisfy (2.8) and (2.17) would of course be possible as well, but would not give more insight onthe physical behaviour.

In order to distinguish the two-dimensional case from the three-dimensional one, subscripts 2dand 3d are used for the quantities that require this distinction, e.g. φ2d indicates the area dis-tribution and φ3d the volume distribution.

6.1 Numerical method

We managed in the previous sections to derive analytical and explicit solutions to problems(2.13)–(2.16) and (2.22)–(2.25) in the two-dimensional and three-dimensional cases, respectively,

Page 43: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

43 6 NUMERICAL STUDY

that are for all (x, t) ∈ R+ × R+ (see section 5.1),

φ2d(x, t) =1

x√

4πb2d(t)

∫ ∞−∞

e−

(log(x) + b2d(t)− w2d(t)− y)2

4b2d(t) eyφ0,2d (ey) dy, (6.1)

where w2d(t) =∫ t0 v2d(s) ds and b2d(t) =

∫ t0 β2d(s) ds, with β2d(t) = β0 + β1v2d(t); and

φ3d(x, t) =1

x√

4πb3d(t)

∫ ∞−∞

e−

(log(x) + b3d(t)− w3d(t)− y)2

4b3d(t) eyφ0,3d (ey) dy,(6.2)

where w3d(t) =∫ t0 v3d(s) ds and b3d(t) =

∫ t0 β3d(s) ds, with β3d(t) = β0 + β1v3d(t). These solu-

tions are explicit since the drift velocity v is a local parameter (see remark 2.2), and thus so areits antiderivative w and the antiderivative b of the diffusion coefficient β = β0 + β1v. Therefore,we can directly implement and plot the solutions by following the numerical method below.

The numerical method that we use in the following consists in:

Step 1 determining the antiderivatives w2d and w3d, and b2d and b3d,

Step 2 approximating the integrals in (6.1) and (6.2).

Step 1 Let us write g(t) := P (t)N(t) > 0, where P (t) is the total surface or volume occupied by

ferrite grains per unit surface or volume at time t, and N(t) is the number of ferrite grains perunit surface or volume present at time t. Then, by equations (4.4) and (4.8), we know that forall t ∈ R+ := (0,∞),

w2d(t) = log

(g2d(t)

g2d(0)

)w3d(t) = log

(g3d(t)

g3d(0)

),

(6.3)

where g2d(t) and g3d(t) are found by the Avrami-Kolmogorov model presented in section 2.1.By equations (2.1) and (2.3), we have for all t ∈ R+,

P2d(t) = 1− exp

(−πα

∫ t

0

(∫ t

τρ2d(s) ds

)2

)

P3d(t) = 1− exp

(−4π

∫ t

0

(∫ t

τρ3d(s) ds

)3

),

(6.4)

with ρ2d(t) = ρ0

Peq − P2d(t)

1− P2d(t)

ρ3d(t) = ρ0Peq − P3d(t)

1− P3d(t),

(6.5)

Page 44: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

44 6 NUMERICAL STUDY

and N2d(t) = α

∫ t

0

(1− P2d(s)

Peq

)ds

N3d(t) = α

∫ t

0

(1− P3d(s)

Peq

)ds.

(6.6)

In order to get g2d and g3d, and thus w2d and w3d, we need to solve (6.4)–(6.6) for P2d and N2d,and for P3d and N3d. Equations in (6.4) can be differentiated with respect to time t, and we getthe following integro-differential equations for all t ∈ R+:

P ′2d(t) = 2παρ2d(t) (1− P2d(t))

∫ t

0

∫ t

τρ2d(s) ds dτ

P ′3d(t) = 4παρ3d(t) (1− P3d(t))

∫ t

0

(∫ t

τρ3d(s) ds

)2

dτ,

(6.7)

where ′ indicates the derivative with respect to time t. We also have the physical initial conditionslimt→0 P2d(t) = limt→0 P3d(t) = 0. We now want to solve (6.7) numerically, considering that weknow the data (ρ0, Peq, α). One way to do this is to see that these integro-differential equationscan be written as follows in the two-dimensional case: y′(t)

z′(t)P ′2d(t)

=

αρ2d(t)y

2πρ2d(t) (1− P2d(t)) z

with limt→0

y(t)z(t)P2d(t)

=

000

, (6.8)

and as follows in the three-dimensional case:x′(t)y′(t)z′(t)P ′3d(t)

=

α

ρ3d(t)x2ρ3d(t)y

4πρ3d(t) (1− P3d(t)) z

with limt→0

x(t)y(t)z(t)P3d(t)

=

0000

, (6.9)

where ρ2d(t) and ρ3d(t) are as in (6.5). These differential systems are then easily solved witha MATLAB solver, for instance ode45. This numerical method gives P2d(tdis) and P3d(tdis) atdiscrete times represented by the vector tdis. Then, P2d and P3d are interpolated between thesediscrete times tdis with the MATLAB function interp1, using for example splines. This allowsto approximate the integrals in (6.6) by means of the MATLAB function integral, and thus

determine N2d(tdis) and N3d(tdis). Once this is done, the simple ratios P2d(tdis)N2d(tdis)

and P3d(tdis)N3d(tdis)

give

g2d(tdis) and g3d(tdis), respectively. Then, by (6.3), we obtain w2d(tdis) and w3d(tdis) as wanted.Furthermore, we may now exploit w2d and w3d to get b2d and b3d. Since β2d(t) = β0 + β1v2d(t),we have b2d(t) = β0t+ β1w2d(t). Similarly, we get b3d(t) = β0t+ β1w3d(t). Therefore, assumingthat we know the data (β0, β1), we have b2d(tdis) and b3d(tdis) at the discrete times tdis as well.

Step 2 Now that w2d and b2d, and w3d and b3d are known at given discrete times tdis, we mayuse them to get the analytical solutions (6.1) and (6.2). For this, we need to approximate the in-tegrals coming from the convolution product present in these solutions. This is performed by thecomposite Simpson’s rule or, equivalently, the mid-point rule. The bounds of the integrals canbe chosen depending on the intial distributions φ0,2d and φ0,3d. Generally, these initial densitiesdecay very fast as x becomes large or as x approaches 0, and their values are thus not relevant

Page 45: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

45 6 NUMERICAL STUDY

out of a given range. Therefore, as bounds for the integrals, we may take the range of y suchthat ey is where the initial distributions have relevant values (see (6.1) and (6.2)). The numberof subintervals used in the composite Simpson’s rule is chosen so that the solution obtaineddoes not seem to vary anymore if more subintervals are considered. This is a way which is onlymanual and can of course be improved in the future.

6.2 Simulations

In this section we perform numerical simulations (see the MATLAB codes used in appendixB) following the method explained in section 6.1. We first run a study on the influence of thefirst diffusion coefficient β0 in β(t) = β0 + β1v(t) and show infinite-time blow-up. This givesa justificiation of the reason we can consider β0 = 0. Secondly, we want to capture the be-haviour when several different initial distributions are considered. As mentioned in remark 5.1,experiments indicate that the profile of the distribution should become asymmetric, and thisis analysed in these simulations, showing convergence to an approximate log-normal stationarystate. Thirdly, we run a parametric study on the parameters ρ0, Peq, α and β1, that are thereference growth rate, the equilibrium ferrite fraction, the nucleation rate and the first diffusioncoefficient, respectively. We use a selection of ranges for (ρ0, Peq, α) and use them to generateg(tdis) at discrete times tdis, via system (6.4)–(6.6). Then, the solutions (6.1) and (6.2) are plot-ted at tdis, and the influence of each parameter is analysed. Fourthly, we compare the solutionsfor the two-dimensional case and the three-dimensional case. Finally, we test the direct trans-formations (5.9) and (5.29), and we analyse computing times.

All the plots are represented with spacings in the x-direction of either 0.001 or 0.01. Further-more, the number of subintervals used for the Simpson’s rule are N = 300 and the bounds forthe integrals present in the solutions (6.1) and (6.2) are [−3, 2], and are so that the importantranges of the initial distributions always lie in this interval. Also, the initial time is taken tobe t0 ' 1.64536, and since the whole analysis in the previous sections is made with the initialtime t = 0, the numerics have been translated in time by t0. However, the various plots forg(t) and v(t) are still plotted from t = 0, as they can still be calculated for times earlier thant0. Moreover, the quenching time is considered to be tq = 150. All the results are given in thetwo-dimensional case, except when the contrary is mentioned. If not specified, the default valuesused for the parameters are (ρ0, Peq, α, β0, β1) = (1, 0.45, 0.001, 0, 0.01).

Remark 6.1 (Choice of the initial distribution). The initial distributions are always carefullychosen so that their first moments – which are used to directly define g(t0) – are slightly smallerthan g(t1), where t1 is the first discrete time in the vector tdis greater than t0. This allows to becoherent with the physical equalities g2d(t) =

∫∞0 xφ2d(x, t) dx and g3d(t) =

∫∞0 xφ3d(x, t) dx. It

also ensures that the restriction on the data g2d and g3d given in remark 5.3 – that is g(ti) > g(t0)for all ti in tdis with i ≥ 1 – is respected, at least at time t1. Of course, when data g are generated,it also has to be checked that they respect this restriction for all ti in tdis.

Page 46: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

46 6 NUMERICAL STUDY

6.2.1 Infinite-time blow-up

We want to capture the effect of the first diffusion coefficient β0 on the behaviour of the solution(6.1). It is theoretically noticed in remark 4.1 that this coefficient must be zero in the radiuscases if one wants to respect the fact that the solution must freeze when the quenching timeis reached. We show numerically the influence of β0 in the area case (the volume case beingfully analogous). Figure 3a gives the evolution of g(t) plotted with the default values of theparameters (ρ0, Peq, α) and by solving the differential system (6.8) as explained in section 6.1.Figure 3b shows the initial distribution used for this study (which is unimodal log-normal, seetables 1 and 2), and figure 3c shows how the solution evolves up to a time t = 500.

Very close to equilibrium(t ' 30)

(a) Evolution of g(t) := P (t)N(t)

(b) Initial distribution

t = 11

t = 18

t = 23

30 ≤ t ≤ 500

(c) Solution up to t = 500

Figure 3: Behaviour of the solution for large times with β0 = 0. After g(t) := P (t)N(t) reaches a state

very close to the equilibrium (a), the solution does not seem to evolve anymore. It definitely stopsafter the quenching time tq = 150 (c), from when g(t) is considered to be rigorously constant.

From figure 3a, we see that g(t) becomes nearly constant from time t ' 30, meaning that theferrite transformation reaches a state very close to the equilibrium at this time. The functiong(t) actually continues increasing after that time, even if very slowly, until the quenching timetq = 150 after which g(t) is taken as rigorously constant. Figure 3c directly reflects this behaviourof g, as the solution seems to stop evolving after time t = 30. It actually goes on evolving very

Page 47: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

47 6 NUMERICAL STUDY

slighty up to the quenching time where it definitely stops. There is thus exactly no evolutionbetween the quenching time tq = 150 and t = 500. This is the behaviour we actually want,that is to reach a stationary state once the ferrite phase change ceases due to quenching. Thischaracteristic can be expected theoretically since we assume β(t) = β0 + β1v(t), and thereforewhen the transformation is quenched, g(t) becoming constant, v(t) becomes zero by (2.15), andso does β(t) with β0 = 0. Thus, the solution in (6.1) becomes constant. This wanted characteristicdoes not hold when the diffusion coefficient β0 is not zero, as shown in figure 4 below.

t = 11

time arrow

(a) β0 = 0.001

t = 11tim

earrow

(b) β0 = 0.01

t = 11

time

arrow

(c) β0 = 0.03

time

arrow

(d) Zoom for β0 = 0.01

Figure 4: Behaviour of the solution with various nonzero diffusion coefficients β0 up to t = 500.The solution drifts to the right in the first place, until the diffusion takes over and makes thesolution drift to the left (a) and (b). The larger β0 is, the quicker the profile moves to the left.When β0 = 0.03, the drift to the right does not occur anymore (c). Infinite-time blow-up happensas soon as β0 6= 0 (d).

We see in figure 4 that the solution does not converge to a stationary state, even though the steelis quenched. It rather reaches a distribution with a minimal mode and then starts growing andapproaching x = 0. This happens all the faster as β0 increases, and the solution seems to growand accumulate indefinitely towards x = 0, tending to an infinite-time blow-up. This behaviouris obviously unphysical, since it does not take the quenching phenomenon into account nor thefact that the transformation should in any case naturally reach an equilibrium after some time,

Page 48: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

48 6 NUMERICAL STUDY

characterised by Peq. We thus justify the choice β0 = 0 for the following simulations. We can alsosee in figures 3c, 4a and 4b that the solution gets drifted to the right up to a certain time andthen, when the diffusion effect beats the drift effect (which is the case if β0 6= 0 after quenching,since the drift velocity goes to zero at that moment), the profile drifts to the left indefinitelyuntils it blows up. When the diffusion is too strong, the profile does not even have the time todrift to the right and directly drifts to the left (see figure 4c).

6.2.2 Convergence to a log-normal stationary state

In this section we analyse the response of the Fokker-Planck equation (2.13) to various initialdistributions, plotted in figure 5. These distributions, given in figure 5 below, cover a good rangeof possible initial data: asymmetric, symmetric, bimodal and compactly supported.

Page 49: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

49 6 NUMERICAL STUDY

(a) Log-normal (b) Bimodal log-normal

(c) Normal (d) Elliptic with compact support

(e) Exponential with compact support

Figure 5: Initial distributions tested. Unimodal log-normal (a), bimodal log-normal (b), nor-mal (c), compactly supported with discontinuous slope at support boundary (d), compactlysupported with C∞ support boundary (e).

The difference between the last two examples (figures 5d and 5e) stays in the fact that the formershows a discontinuity in the derivative at the boundary of its support, which is not the case forthe latter. The equations for the initial distributions used in figure 5 are summarised in tables 1and 2 below. They give both the equations for the two-dimensional and three-dimensional cases.The initial distributions for the three-dimensional case are used in sections 6.2.4, 6.2.5 and 6.2.6,

Page 50: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

50 6 NUMERICAL STUDY

and for now only the two-dimensional equations should be looked at.

Initial distribution For all x ∈ R+, φ0,2d/3d(x) =

Unimodal log-normal1

x√

2πσexp

(−(log(x)− µ)2

2σ2

)

Bimodal log-normal

1

x√

2πσexp

(−(log(x)− µ)2

2σ2

)for x ≤ l

1

(x− l)√

2πσexp

(−(log(x− l)− µ)2

2σ2

)for x > l

Normal1√2πσ

exp

(−(x− µ)2

2σ2

)

Elliptic compactly supported

b

√1−

(x− x0a

)2

for x0 − a ≤ x ≤ x0 + a

0 elsewhere

Exponential compactly supported

c exp

(− h

k − (x− x0)2

)for x0 −

√k ≤ x ≤ x0 +

√k

0 elsewhere

Table 1: Equations for the various initial distributions tested (see figure 5)

Parameters

Initial distribution Two dimensions Three dimensions

Unimodal log-normal σ = 0.1, µ = log(0.6) + σ2 σ = 0.1, µ = log(0.45) + σ2

Bimodal log-normalσ = 0.1, l = 0.6,

µ = log(0.3) + σ2σ = 0.1, l = 0.6,

µ = log(0.15) + σ2

Normal σ = 0.1, µ = 0.6 σ = 0.1, µ = 0.45

Elliptic compactly supporteda = 0.2, b =

2

πa,

x0 = 0.6

a = 0.15, b =2

πa,

x0 = 0.45

Exponential compactly supportedc =

1

0.0160702, h = 1,

k = 0.3, x0 =√k + 0.1

c =1

0.000307953, h = 1,

k = 0.15, x0 =√k + 0.1

Table 2: Parameters for the various initial distributions tested (see figure 5 and table 1)

The values in table 2 are chosen so that the initial distributions have all unit total mass – atleast as close as possible for the three last cases – and respect remark 6.1. Figure 6 below givesthe evolution of these initial data at t = 150.

Page 51: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

51 6 NUMERICAL STUDY

(a) Log-normal initial data (b) Bimodal log-normal initial data

(c) Normal initial data (d) Elliptic compactly supported initial data

(e) Exponential compactly supported initial data

Figure 6: Solutions with various initial data at the quenching time tq = 150 (blue). The greenprofiles represent the solution in (a), for comparison to a log-normal profile. Solutions look asif they tend to very similar stationary states (a), (c), (d) and (e). The solution with bimodallog-normal initial distribution seems to converge to a similar stationary profile, however it wouldrequire more time to fully reach it.

We should first mention that when considering the unimodal log-normal case, the solution in(6.1) stays a log-normal distribution at all times since it is then the convolution between twolog-normal profiles (see figures 5a and 6a). Figures 6a, 6c, 6d and 6e show very similar profiles

Page 52: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

52 6 NUMERICAL STUDY

at the quenching time tq = 150. These profiles represent stationary states as they are taken atthe quenching time and thus do not change if further time is waited (since β0 = 0, see section6.2.1). They are asymmetric stationary states and may be considered as log-normal probabilitydensities (see profiles in green for comparison with a log-normal distribution), even when theinitial data are not log-normal, but are normal or compactly supported. This is a very strongpeculiarity of the Fokker-Planck equation we are analysing: the profile of the solution becomesasymmetric and very close to a log-normal distribution even if the initial datum is symmetric(as it is the case for the normal and compactly supported initial distributions). In addition, thediscontinuity in the derivative at the boundary of the support of the elliptic initial distribitionin 5d does not have an important influence on this behaviour, as it behaves very closely to theexponential initial data with compact support given in 5e, which has C∞ support boundary.Concerning the bimodal initial case, as it is shown in figure 6b at t = 150, the second peakflattens much faster than the first one even if at the initial time both peaks have same height.The profile has not converged to a unimodal log-normal distribution, but seems to tend to itif a longer time is waited. In order to see if this is actually the case, we look in figure 7 at thesolution with the same bimodal initial distribution, but rather at time t = 230. However, wehave to consider a nonzero diffusion coefficient β0, as otherwise the solution freezes at tq = 150as demonstrated in the previous section. This affects the exact shape of the solution, but givesits behaviour at large times.

Figure 7: Solution with bimodal log-normal initial distribution with β0 = 0.001 at t = 220(blue). The green profile is the distribution given in figure 5a, for comparison to a log-normaldistribution. In order to see the behaviour of the solution for larger times than tq = 150, β0 istaken to be nonzero. The profile would otherwise stay as in figure 6b, since the quenching timeis reached. The solution converges to an asymmetric unimodal profile, as it is the case for therest of the initial data tested (see figures 6a and 6c to 6e).

Figure 7 confirms what said above: the second peak still present at t = 150 (see figure 6b), fullyflattens after large times and seem to have disappeared at t = 230. The solution is a that timean asymmetric profile whose shape is very similar to a log-normal distribution. We thus have anumerical proof of the convergence of solution (6.1) to an asymmetric stationary state, likely tobe log-normal whatever initial distribution is imposed.

Page 53: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

53 6 NUMERICAL STUDY

6.2.3 Parametric study

We propose now to study the influence of the set of parameters (ρ0, Peq, α, β1) on the solution(6.1). The default values of these parameters are (ρ0, Peq, α, β1) = (1, 0.45, 0.001, 0.01), meaningthat each time we take these values for three of them while varying the fourth one. The followingfigure shows how the first three parameters influence function g(t) := P (t)

N(t) .

ρ0

(a) Variation of ρ0

Peq

(b) Variation of Peq

α

(c) Variation of α

Figure 8: Evolution of g(t) := P (t)N(t) when varying parameters. The influence on g(t) of the

reference growth rate ρ0 and the equilibrium ferrite fraction Peq is the same: increasing theequilibrium value of g and shifting the equilibrium time to an earlier time (a) and (b). Thenucleation rate α has the opposite effect on the equilibrium value of g, but the same effect onthe equilibrium time (c). The arrows indicate the growth direction of the parameters.

The plots in figure 8 are computed by calculating g(t) for each of the parameters via the methodoutlined in step 1 of section 6.1. A first remark that may be done on these plots is that g seemsto reach a state very close to the equilibrium before the quenching time tq = 150, at a timebetween t ' 30 and t ' 40. Before analysing these graphs into more detail, let us first zoomthem in:

Page 54: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

54 6 NUMERICAL STUDY

(a) Variation of ρ0 (b) Variation of Peq

(c) Variation of α

Figure 9: Zoomed figures of the evolution of g(t) := P (t)N(t) for varying parameters (see figure 8).

We can see from figures 8a and 9a on one hand, and 8b and 9b on the other hand, that thereference growth rate ρ0 and the equilibrium phase fraction Peq have the same influence on g(t),that is to increase the equilibrium value of g and to make the system reach the equilibrium statefaster. This is expected since if the reference growth rate is higher, then the growth rate ρ(t) ishigher by (6.5) and thus the transformation reaches the equilibrium quantity of ferrite quickerand also tends to push the average area of the grains – which is exactly g(t)) – to larger values,as the growth is faster. Concerning the equilibrium fraction, this behaviour can be interpretedby the fact that if the equilibrium fraction is higher, the system physically tends to it faster asit starts from a state which is farther from the equilibrium state. This makes the ferrite phasechange quicker and thus push the average area to larger values as well. The plots in figures 8cand 9c show that the nucleation rate α has the contrary influence about the equilibrium valueof g. This may be explained by the fact that if more nuclei are born at each time, then theratio g(t) = P (t)

N(t) will diminish. However, concerning when the equilibrium state is reached, thenucleation rate has the same influence: the system reaches the equilibrium faster as α increases.This is because the reaction proceeds faster as α grows, since the nucleation is quicker. Figure10 below gives the influence of the previous parameters on solution (6.1).

Page 55: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

55 6 NUMERICAL STUDY

ρ0

(a) Variation of ρ0

Peq

(b) Variation of Peq

α

(c) Variation of α

β1

(d) Variation of β1

Figure 10: Solutions for t = 150 for each parameter variation. The influence of the referencegrowth rate ρ0 and the equilibrium phase fraction Peq is to make the profile flatten and drift tothe right more quickly, while the effect of the nucleation rate α is the opposite. The effect of thediffusion coefficient β1 is to make the solution flatten and move to the left faster. The arrowsindicate the growth direction of the parameters.

The influence of the parameters on the solution reflects what said about their effect on g. In-creasing the reference growth rate ρ0 or the equilibrium fraction of ferrite Peq makes the profileflatten and drift to the right faster (figures 10a and 10b), while increasing the nucleation rate αmakes it flatten and drift to the right less quickly (figure 10c). From figure 10d, we can noticethat the effect of the diffusion coefficient β1 in β(t) = β0+β1v(t) = β1v(t) is to make the solutionflatten faster and drift more quickly to the left. The first effect is expected as the influence ofthe diffusion is to spread the solution on the whole space.

6.2.4 Comparison between two- and three-dimensional cases

We show in the following a comparison between the behaviour of solution (6.1) in the two-dimensional case and that of (6.2) in the three-dimensional case. Figure 11 gives a comparisonof g, the drift velocity v and the solutions at time t = 150 for the initial unimodal log-normaldistribution as given in tables 1 and 2.

Page 56: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

56 6 NUMERICAL STUDY

(a) Ratios g2d(t) := P2d(t)N2d(t)

and g3d(t) := P3d(t)N3d(t)

(b) Drift velocities v2d(t) and v3d(t)

(c) Solutions φ2d and φ3d at t = 150

Figure 11: Comparison of g, v and solutions in two dimensions and three dimensions. The three-dimensional case makes the equilibrium value of g increase and the equilibrium reached earlier(a), which is reflected in the solutions (c). The drift velocities decay very fast in the beginning,becoming lower than 1 at about t = 3 (b).

In figure 11b, the velocities are calculated by finite differences directly from the expressions(2.15) and (2.24) with the discrete times tdis generated when solving the differential systems(6.8) and (6.9) for P2d(t) and P2d(t), respectively. We see in figure 11a that in three dimensionsthe equilibrium value of g is larger than in two dimensions, and that the equilibrium of thephase change is reached faster in three dimensions as well. This is reflected in the shape of thesolutions given in figure 11c, where in three dimensions the profile flattens and drifts to the rightmore quickly. From figure 11b, we can extract information on the behaviour of the drift velocityv(t), which decays very fast (even more in three dimensions) in small times and becomes lessthan 1 from t ' 3, before reaching 0 at the quenching time (from equations (2.15) and (2.24),since g(t) becomes constant after tq).

6.2.5 Transformations to radius

We want here to compare the area distribution to the radius distribution in two dimensionsand the volume distribution to the radius distribution in three dimensions, in order to test the

Page 57: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

57 6 NUMERICAL STUDY

relations given in section 5.2. This is direclty done by transformations (5.9) and (5.29) once thearea and volume distributions (6.1) and (6.2) are already known, with no need of calling theSimpson’s rule a second time. Figure 12 shows the transformations for the initial log-normaldistributions given in tables 1 and 2 at time t = 150.

(a) Area distributon (b) Two-dimensional radius distribution

(c) Volume distribution (d) Three-dimensional radius distribution

Figure 12: Transformation from area to radius and from volume to radius at t = 150. Thetransformations are done by means of (5.9) and (5.29), respectively, and make the profiles shrink(b) and (d).

By figure 12, we see that, as expected by the changes of variables (5.9) and 5.29), the radiusdistributions are tighter and thus less asymmetric than the corresponding area or volume dis-tributions. Furthermore, again from the changes of variables, the radius distribution in threedimensions case is even tighter than the one in two dimensions.

6.2.6 Computation times

We give in this section some computation times for the Simpson’s rule used to approach theintegral in the analytical solution for the area distribution (6.1) on one hand and that for thevolume distribution (6.2) on the other hand, at time t = 150. The simulations are all run withMATLAB 2012b (see appendix B for the codes), on a 1.8 GHz Intel Core i5 processor. Table 3

Page 58: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

58 7 CONCLUSION AND OUTLOOK

below summarises these times for the initial data given in tables 1 and 2. All the times are givenin seconds and the solutions are calculated up to x = 150 for the area and volume distributions,with x-spacings of 0.01.

Initial distribution Area Volume

Unimodal log-normal 0.63 0.58

Bimodal log-normal 0.67 0.67

Normal 0.60 0.57

Elliptic compactly supported 0.58 0.62

Exponential compactly supported 0.60 0.62

Table 3: Computing times in seconds for the Simpson’s rule used to approximate the convolutionintegral present in solutions (6.1) and (6.2) and for different initial data, on a 1.8 GHz Intel Corei5 processor.

These times actually represent the only times of computation which are necessary to obtain an-alytical solutions once the data g(t) = P (t)

N(t) are already known. This makes our code particularlyfast, as it does not need any discretisation apart from the Simpson’s rule. We can see that theinitial distributions do not have a significant importance on the simulation times. We may alsoremark that the dimension of the problem does not affect the computing times either. This isexpected as the time needed for the generation of the data g(t) from systems (6.8) and (6.9) –which differs between the two-dimensional and the three-dimensional cases – is not taken intoaccount here. The time needed to obtain the two-dimensional radius and the three-dimensionalradius distributions from the area and volume distributions, respectively from (5.9) and (5.29),is quasi-instantaneous as the code only computes them directly from the area and volume solu-tions without using the Simpson’s rule a second time (see script 21 in appendix B).

7 Conclusion and Outlook

We have modelled the evolution of the size distribution of ferrite crystals due to a change of phasein steel, occurring during an isothermal holding time ended by quenching. The model we haveused is of Avrami-Kolmogorov-type, which considers the grain growth as circular and sphericalin the two- and three-dimensional settings, respectively. We have extracted the ferrite phasefraction P (t) and the relative number of ferrite grains N(t) by solving an integro-differentialequation for P (t). We have derived Fokker-Planck equations satisfied by the radius and areadistributions in the two-dimensional case, and by the radius and volume distributions in thethree-dimensional case. Each of these equations has linearly interconnected and time-dependentdrift velocity and diffusion coefficient (β(t) = β0 + β1v(t)), which appear to be local by thephysical model and considerations on the moments. We have found an analytical solution tothese equations by means of a logarithmic change of variables, which is a convolution productbetween a log-normal distribution and the initial probability density function. We have alsodetermined the relations between all the distributions that have been considered, that are thetwo-dimensional radius, area, three-dimensional radius and volume distributions. These relationshave shown that the distributions all satisfy the same Fokker-Planck equation but with different

Page 59: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

59 7 CONCLUSION AND OUTLOOK

drift and diffusion coefficients. We have found finite-time blow-up conditions on the data pro-vided by the Avrami-Kolmogorov model and the initial distribution. These conditions all appearto correspond to non-physical situations and should thus not be encountered if correct data isplugged in the analytical solution. We have run numerical simulations where the first term of thediffusion coefficient β0 has shown to provoke infinite-time blow-up if taken as nonzero. This firstdiffusion term has thus to be neglected as the blow-up scenario is unphysical, since we expectto reach a stationary state corresponding to the quenching of the steel. Under this assumption,the profiles of the distributions seem to tend to a stationary state, whichever initial condition isimposed. The stationary state is an asymmetric profile, approximately log-normally distributed,even if the initial conditions are symmetric or with compact support. This characteristic isstrongly coherent with the experiments, which show a convergence to a log-normal stationarystate. We have led a parametric study on the model parameters, namely the reference growthrate, the equilibrium phase fraction, the nucleation rate and the second diffusion coefficient β1.This has not shown an influence on the shape of the solution, but rather on its translation orits flattening rates.

The mathematical model and equations that we have derived are promising for the descriptionof the complex behaviour of phase change in steel. They have shown coherence with experimentsregarding the convergence to a stationary state and the asymmetrisation towards a log-normalprofile of the grain size distribution. As already mentioned, we have shown theoretical finite-timeblow-up for unphysical data, but no numerical evidence of this has been found, and this mayconstitute a potential further study. Another interesting research could be led in analyticallyshowing the convergence to an asymmetric log-normal stationary state, independently from theinitial distribution, supporting in this way the numerical results. Further studies could takeinto consideration other diffusion coefficients, as the more general polynomial relation with thedrift velocity β(t) =

∑N0 βkv(t)k. The parametric study presented in this thesis should also be

used in order to tune the physical parameters and make the solution profiles fit the experimen-tal profiles as good as possible. A study on the relation between the two-dimensional and thethree-dimensional cases would be interesting to be led. We have compared both in one of thenumerical simulations of this thesis, but an analytical relation would bring a very strong insighton the problem, as in reality we only have access to two-dimensional sections of the steel; andexperiments can thus only provide the two-dimensional radius and area distributions.

Page 60: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

60 REFERENCES

References

[1] M. Avrami. Kinetics of Phase Change. I General Theory. Journal of Chemical Physics,7:1103–1112, 1939.

[2] M. Avrami. Kinetics of Phase Change. II Transformation-Time Relations for RandomDistribution of Nuclei. Journal of Chemical Physics, 8:212–224, 1940.

[3] M. Avrami. Kinetics of Phase Change. III Granulation, Phase Change, and MicrostructureKinetics of Phase Change. Journal of Chemical Physics, 9:177–184, 1941.

[4] S. Cordier, L. Pareschi, and C. Piatecki. Mesoscopic Modelling of Financial Markets. Jour-nal of Statistical Physics, 134:161–184, 2009.

[5] W. Dreyer, R. Huth, A. Mielke, J. Rehberg, and M. Winkler. Blow-up versus Boundednessin a Nonlocal and Nonlinear Fokker-Planck Equation. Weierstrass-Institut fur AngewandteAnalysis und Stochastik. Preprint 1604, 2011.

[6] L. C. Evans. Partial Differential Equations. Providence, R.I.: American MathematicalSociety, 2nd edition, 1998.

[7] R. Huth. On a Fokker-Planck Equation Coupled with a Constraint. PhD thesis,Mathematisch-Naturwissenschaftlichen Fakultat II Humboldt-Universitat zu Berlin, 2012.

[8] A. N. Kolmogorov. On the Statistical Theory of Metal Crystallization. Izvestia AkademiaNauk SSSR Serie Mathematica, 3:355–360, 1937.

[9] N. Liron and J. Rubinstein. Calculating the fundamental solution to linear convection-diffusion problems. SIAM Journal of Applied Mathematics, 44:493–511, 1984.

[10] P. Malliavin. Integration and Probability. New York: Springer-Verlag, 2nd edition, 1995.

Page 61: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

61 A DETAILS FOR THE RELATIONS BETWEEN DISTRIBUTIONS

A Details for the relations between distributions

In this appendix we give the details of some calculations needed in section 5.2, concerning therelations between the various distributions used.

Two-dimensional case

If radius distribution satisfies (2.8)–(2.12) We give here the derivation of problem (5.11)using the transformation (5.9). We have the following identities:

ψt = 2πrφt = 2√πxφt,

(rψ)r = 2π(r2φ)r = 4πrφ+ 2πr2xrφx = 4√πx(φ+ xφx) = 4

√πx(xφ)x,

(r2ψ)r = 2π(r3φ)r = 6πr2φ+ 2πr3xrφx = 6xφ+ 4x2φx,

(r2ψ)rr = 6xrφ+ 6xxrφx + 8xxrφx + 2x2xrφxx = 4√πx(3φ+ 7xφx + 2x2φxx)

= 4√πx(2(x2φ)xx − (xφ)x).

This directly gives problem (5.11) since ψ(r, t) satisfies (2.8).

Let us now show that (5.16)–(5.17) and (5.18)–(5.19) are equivalent. When writing (5.18) ex-plicitly, we get for all (x, t) ∈ R+ × R+,

φ(x, t) =1

2x√

4πb(t)

∫ ∞−∞

e−

(log

(√x

π

)+ b(t)− w(t)− y

)2

4b(t) eyψ0(ey) dy

=1

x√

16πb(t)

∫ ∞−∞

e−

(log(x) + 2b(t)− 2w(t)− z)2

16b(t) ez/2

2√πψ0

(ez/2√π

)dz

(by change of variable z = 2y + log(π))

=1

x√

16πb(t)

∫ ∞−∞

e−

(log(x) + 2b(t)− 2w(t)− z)2

16b(t) Φ0(z) dz (by (5.17))

=1

x(K(·, 4b(t)) ∗ Φ0)(log(x) + 2b(t)− 2w(t))

=1

x(K(·, b∗(t)) ∗ Φ0)(log(x) + b∗(t)− w∗(t)) (by (5.13)),

as wanted.

Page 62: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

62 A DETAILS FOR THE RELATIONS BETWEEN DISTRIBUTIONS

If area distribution satisfies (2.13)–(2.16) Similarly, we want to give the derivation ofproblem (5.20). By the change of variable (5.9), we have the following identities:

φt =1

2√πxψt =

1

2πrψt,

(xφ)x =1

2√π

(√xψ)x =

1

4√πxψ +

√x

2√πrxψr =

1

4πr(ψ + rψr) =

1

4πr(rψ)r,

(x2φ)x =1

2√π

(x√xψ)x =

3√x

4√πψ +

x√x

2√πψx =

3√x

4√πψ +

x√x

2√πrxψr =

3

4rψ +

1

4r2ψr,

(x2φ)xx =3

4rxψ +

3

4rrxψr +

1

42rrxψr +

1

4r2rxψrr =

1

8πr(3ψ + 5rψr + r2ψrr)

=1

8πr((r2ψ)rr + (rψ))r).

This directly gives problem (5.20) since φ(x, t) satisfies (2.13).

Again, we prove that (5.25)–(5.26) and (5.27)–(5.28) are equivalent. Explicitly (5.27) reads, forall (x, t) ∈ R+ × R+,

ψ(r, t) =2

r√

4πb(t)

∫ ∞−∞

e−

(log(πr2) + b(t)− w(t)− y)2

4b(t) eyφ0(ey) dy

=1

r√πb(t)

∫ ∞−∞

e−

(log(r) +

b(t)

2− w(t)

2− z)2

b(t) 2πe2zφ0(πe2z) dz

(by change of variable z =y

2− log(π)

2)

=1

r√πb(t)

∫ ∞−∞

e−

(log(r) +

b(t)

2− w(t)

2− z)2

b(t) Ψ0(z) dz (by (5.26))

=1

r

(K

(·, b(t)

4

)∗Ψ0

)(log(r) +

b(t)

2− w(t)

2

)

=1

r(K (·, b∗(t)) ∗Ψ0) (log(r) + b∗(t)− w∗(t)) (by (5.22)),

as required.

Page 63: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

63 A DETAILS FOR THE RELATIONS BETWEEN DISTRIBUTIONS

Three-dimensional case

If radius distribution satisfies (2.17)–(2.21) We give the derivation of problem (5.31) bymeans of the change of variable (5.29). We get the following identities:

ψt = 4πr2φt = (4π)1/3(3x)2/3φt,

(rψ)r = 4π(r3φ)r = 12πr2φ+ 4πr3xrφx = 3(4π)1/3(3x)2/3(φ+ xφx) = 3(4π)1/3(3x)2/3(xφ)x,

(r2ψ)r = 4π(r4φ)r = 16πr3φ+ 4πr4xrφx = 12xφ+ 9x2φx,

(r2ψ)rr = 12xrφ+ 12xxrφx + 18xxrφx + 9x2xrφxx = 3(4π)1/3(3x)2/3(4φ+ 10xφx + 3x2φxx)

= 3(4π)1/3(3x)2/3(3(x2φ)xx − 2(xφ)x).

This easily gives problem (5.31) since ψ(r, t) satisfies (2.17).

We show now that (5.36)–(5.37) and (5.38)–(5.39) are equivalent. When writing (5.38) explicitly,we get for all (x, t) ∈ R+ × R+,

φ(x, t) =1

3x√

4πb(t)

∫ ∞−∞

e−

(log

((3x

)1/3)

+ b(t)− w(t)− y

)2

4b(t) eyψ0(ey) dy

=1

x√

36πb(t)

∫ ∞−∞

e−

(log(x) + 3b(t)− 3w(t)− z)2

36b(t) ez/3

(4π)1/333/2ψ0

((3

)1/3

ez/3

)dz

(by change of variable z = 3y + log

(4π

3

))

=1

x√

36πb(t)

∫ ∞−∞

e−

(log(x) + 3b(t)− 3w(t)− z)2

36b(t) Φ0(z) dz (by (5.37))

=1

x(K(·, 9b(t)) ∗ Φ0)(log(x) + 3b(t)− 3w(t))

=1

x(K(·, b∗(t)) ∗ Φ0)(log(x) + b∗(t)− w∗(t)) (see (5.33)),

as we require.

If volume distribution satisfies (2.22)–(2.25) Let us proceed similarly to the radius casein three dimensions. We give the derivation of problem (5.40) by the change of variable (5.29).We have the following identities:

φt =1

(4π)1/3(3x)2/3ψt =

1

4πr2ψt,

Page 64: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

64 A DETAILS FOR THE RELATIONS BETWEEN DISTRIBUTIONS

(xφ)x =1

(4π)1/332/3(x1/3ψ

)x

=1

(4π)1/335/3x2/3ψ +

1

(4π)1/3x1/332/3rxψr

=1

12πr2(ψ + rψr) =

1

12πr2(rψ)r

(x2φ)x =1

(4π)1/332/3(x4/3ψ)x =

4x1/3

(4π)1/335/3ψ +

x4/3

(4π)1/335/3ψx

=4x1/3

(4π)1/335/3ψ +

x4/3

(4π)1/335/3rxψr =

1

9

(4rψ + r2ψr

),

(x2φ)xx =1

9

(4rxψ + 4rrxψr + 2rrxψr + r2rxψrr

)=

1

36πr2(4ψ + 6rψr + r2ψrr)

=1

36πr2((r2ψ)rr + 2(rψ)r).

Hence problem (5.40) since φ(x, t) satisfies (2.22).

We prove now that (5.45)–(5.46) and (5.47)–(5.48) are equivalent. Explicitly (5.47) reads, for all(x, t) ∈ R+ × R+,

ψ(r, t) =3

r√

4πb(t)

∫ ∞−∞

e−

(log

(4π

3r3)

+ b(t)− w(t)− y)2

4b(t) eyφ0(ey) dy

=1

r

√4

9πb(t)

∫ ∞−∞

e

(log(r) +

b(t)

3− w(t)

3− z)2

4b(t)

9 4πe3zφ0

(4π

3e3z)

dz

(by change of variable z =y

3− log(4π/3)

3)

=1

r

√4

9πb(t)

∫ ∞−∞

e

(log(r) +

b(t)

3− w(t)

3− z)2

4b(t)

9 Ψ0(z) dz (by (5.46))

=1

r

(K

(·, b(t)

9

)∗Ψ0

)(log(r) +

b(t)

3− w(t)

3

)

=1

r(K (·, b∗(t)) ∗Ψ0) (log(r) + b∗(t)− w∗(t)) (by (5.42)),

as required.

Page 65: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

65 B CODE

B Code

We give in this appendix the printouts of the MATLAB code that the author has programmedand used for the numerical analysis of section 6.

Script 1: grain size distribution.m� �1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% MAIN SCRIPT %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%% Author : Francesco Saver io Patacch in i %%%%%%%%%%%%%%%%%%4 %%%%%% MSc Modern App l i ca t i ons o f Mathematics , Un ive r s i ty o f Bath , UK %%%%%5 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%6

7

8 function g r a i n s i z e d i s t r i b u t i o n ( dim )9

10 s t a r t = t ic ; % Store s t a r t . . .11 % time o f execut ion12

13 i f dim ˜= 2 && dim ˜= 314 error . . .15 ( ’ e r r o r : must ente r 2 or 3 as dimension ’ ) ; % Print e r r o r . . .16 % i f wrong input17 end18

19

20 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Parameters %%%%%%%%%%%%%%%%%%%%%%%%%%%%%21 tq = 150 ; % Quenching time22 rho0 = 1 ; % Reference . . .23 % growth ra t e24 Peq = 0 . 4 5 ; % Equi l ibr ium . . .25 % f r a c t i o n26 alpha = 0 . 0 0 1 ; % Nucleat ion ra t e27 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%28

29 %%%%%%%%%%%%%%%%% Find , wr i t e and p lo t tdata and gdata %%%%%%%%%%%%%%%%30 [ tdata , gdata ] = s o l v e g ( rho0 , Peq , alpha , tq , dim ) ; % Generate gdata . . .31 % and tdata . . .32 % ( data g and . . .33 % time t between . . .34 % 0 and tq )35 w r i t e g ( tdata , gdata ) ; % Write data in . . .36 % f i l e g . csv37 [ tdata v , v ] = s o l v e v ( rho0 , Peq , alpha , tq , dim ) ; % Find d r i f t . . .38 % v e l o c i t y v f o r . . .39 % each time tdata v40

41 p l o t g ( tdata , gdata ) ; % Plot gdata42 p l o t v ( tdata v , v ) ; % Plot v43 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%44

Page 66: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

66 B CODE

45

46 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Parameters %%%%%%%%%%%%%%%%%%%%%%%%%%%%%47 t0 = 1 . 6 453 6 ; % I n i t i a l time48 tmax = 150 ; % Upper bound . . .49 % f o r time50 t s t ep = 180 ; % Step in vec to r . . .51 % t between t i . . .52 % mes to be c a l . . .53 % cula ted54 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%55

56 %%%%%%%%%%%% Read t and g with step tstep , from t0 to tmax %%%%%%%%%%%57 moments phi0 = solve moments phi0 ; % Find i n i t i a l . . .58 % moments f o r . . .59 % area /volume60 [ t , g ] = read g ( t0 , t s tep , tmax , moments phi0 ) ; % Read g and t . . .61 % from f i l e g . csv62 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%63

64

65 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Parameters %%%%%%%%%%%%%%%%%%%%%%%%%%%%%66 beta = [ 0 0 . 0 1 ] ; % D i f f u s i o n . . .67 % c o e f f i c i e n t s68 xmax = 150 ; % Upper bound . . .69 % f o r area /volume70 xspac ing = 0 . 0 1 ; % Spacing bet . . .71 % ween each x . . .72 % to be c a l c u l a t e d73 r a n g e t p l o t = length ( t ) : length ( t ) ; % Times so lu . . .74 % t i o n s must be . . .75 % plo t t ed76 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%77

78 %%%%%%%%%%%%%%%%% Find and p lo t s o l u t i o n s phi and p s i %%%%%%%%%%%%%%%%%79 x = 0 : xspac ing : xmax ; % Area/volume gr id80 i f dim == 281 r = sqrt ( x/pi ) ; % Radius g r id in . . .82 % two dimensions83 else84 r = (3/(4∗ pi ) ∗x ) . ˆ ( 1 / 3 ) ; % Radius g r id in . . .85 % three dimensions86 end87

88 phi = s o l v e p h i (x , t , g , beta ) ; % Find s o l u t i o n phi89 p s i = s o l v e p s i (x , r , t , phi , dim ) ; % Find s o l u t i o n p s i90

91 t p l o t = t ( r a n g e t p l o t ) + t0 ; % Time s c a l e . . .92 % f o r p l o t s ( s e t . . .93 % i n i t i a l time . . .94 % back to t0 )95 p l o t s o l ( phi , ps i , x , r , tp lo t , r ange tp l o t , dim ) ; % Plot s o l u t i o n96 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

Page 67: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

67 B CODE

97

98

99 e lapsed = toc ( s t a r t ) ; % Store e lapsed . . .100 % time o f execut ion101 [ ’ Total computation time : ’ num2str( e l apsed ) ] % Print execu . . .102 % t ion time103

104 end� �Script 2: solve g.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%% FIND DATA g ACCORDING TO PARAMETERS SET IN MAIN SCRIPT %%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function [ tdata , gdata ] = s o l v e g ( rho0 , Peq , alpha , tq , dim )7

8 trange = [ 0 tq ] ; % Time range to . . .9 % be cons ide red . . .

10 % (up to quen . . .11 % ching time )12

13 Z0 = zeros (1 , dim + 1) ; % I n i t i a l i s e . . .14 % s o l u t i o n o f ode4515

16 opt ions = odeset ( ’ RelTol ’ ,1 e−7, ’ AbsTol ’ ,1 e−7) ; % Set p r e c i s i o n . . .17 % opt ions f o r ode4518 [ tdata , Z ] = ode45 (@( t , Z) system P . . .19 ( t , Z , rho0 , Peq , alpha , dim) , trange , Z0 , opt ions ) ; % Solve ode . . .20 % system to f i n d Z21 P = Z ( : , dim + 1) ; % Get P22

23 N = zeros ( length ( tdata ) ,1 ) ; % I n i t i a l i s e N24 for i = 1 : length ( tdata )25 N( i ) = i n t e g r a l (@( s ) i n t e r p o l a t e P . . .26 ( tdata ,P, s , Peq , alpha ) ,0 , tdata ( i ) ) ; % Find N by c a l . . .27 % c u l a t i n g in . . .28 % t e g r a l o f . . .29 % alpha ∗ ( 1 . . .30 % − P/Peq ) bet . . .31 % ween 0 and t32 end33

34 gdata = P. /N; % Compute gdata35 gdata (1 ) = 0 ; % Set g (1 ) = 0 . . .36 % ( g at r e a l . . .37 % time 0)38

39 end� �

Page 68: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

68 B CODE

Script 3: system P.m� �1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%% DEFINE DIFFERENTIAL SYSTEM USED TO FIND P %%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function system P = system P ( t , Z , rho0 , Peq , alpha , dim )7

8 i f dim == 29 rho = rho0 ∗ ( Peq − Z(3) ) /(1 − Z(3) ) ; % Growth ra t e rho

10 system P = [ alpha ; rho ∗ Z(1) ; . . .11 2∗pi ∗ rho ∗ (1 − Z(3) ) ∗ Z(2) ] ; % Def ine system . . .12 % in two dimensions13 else14 rho = rho0 ∗ ( Peq − Z(4) ) /(1 − Z(4) ) ; % Growth ra t e rho15 system P = [ alpha ; rho ∗ Z(1) ; 2∗ rho ∗ Z(2) ; . . .16 4∗pi ∗ rho ∗ (1 − Z(4) ) ∗ Z(3) ] ; % Def ine system17 % in three . . .18 % dimensions19 end20

21 end� �Script 4: interpolate P.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%% GET INTEGRAND OF NUMBER OF NUCLEI N %%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function P int = i n t e r p o l a t e P ( t ,P, s , Peq , alpha )7

8 P int = interp1 ( t ,P, s , ’ s p l i n e ’ ) ; % I n t e r p o l a t e P . . .9 % with s p l i n e s . . .

10 % between a l l . . .11 % times t and . . .12 % eva luate P int . . .13 % at s14

15 P int = alpha ∗(1 − P int /Peq ) ; % Compute . . .16 % integrand o f N17

18 end� �Script 5: write g.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%% WRITE DATA gdata AND tdata IN g . csv %%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function w r i t e g ( tdata , gdata )

Page 69: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

69 B CODE

7

8 dlmwrite ( ’ g . csv ’ , [ tdata , gdata ] , ’ p r e c i s i o n ’ , . . .9 ’ %.6 f ’ ) ; % Write . . .

10 % [ tdata , gdata ] . . .11 % in f i l e g . csv12

13 end� �Script 6: solve v.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%%%%%% FIND DRIFT VELOCITY v %%%%%%%%%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function [ tdata v , v ] = s o l v e v ( rho0 , Peq , alpha , tq , dim )7

8 trange = [ 0 tq ] ; % Time range to . . .9 % be cons ide red . . .

10 % (up to quen . . .11 % ching time )12

13 Z0 = zeros (1 , dim + 1) ; % I n i t i a l i s e . . .14 % s o l u t i o n o f ode4515

16 opt ions = odeset ( ’ RelTol ’ ,1 e−13, ’ AbsTol ’ ,1 e−13) ; % Set p r e c i s i o n . . .17 % opt ions f o r . . .18 % ode45 ( t h i s i s . . .19 % higher than . . .20 % the one used . . .21 % to only f i n d g . . .22 % as we need . . .23 % more time . . .24 % step s to c a l . . .25 % c u l a t e d e r i . . .26 % vat ive o f g . . .27 % ( see below ) )28

29 [ tdata v , Z ] = ode45 (@( t , Z) system P . . .30 ( t , Z , rho0 , Peq , alpha , dim) , trange , Z0 , opt ions ) ; % Solve ode . . .31 % system to f i n d Z32 P = Z ( : , dim + 1) ; % Get P33

34 N = zeros ( length ( tdata v ) ,1 ) ; % I n i t i a l i s e N35 for i = 1 : length ( tdata v )36 N( i ) = i n t e g r a l (@( s ) i n t e r p o l a t e P . . .37 ( tdata v ,P, s , Peq , alpha ) ,0 , tdata v ( i ) ) ; % Find N by c a l . . .38 % c u l a t i n g in . . .39 % t e g r a l o f . . .40 % alpha ∗ ( 1 . . .41 % − P/Peq ) bet . . .42 % ween 0 and t

Page 70: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

70 B CODE

43 end44

45 gdata = P. /N; % Compute gdata46 gdata (1 ) = 0 ; % Set g (1 ) = 0 . . .47 % ( g at r e a l . . .48 % time 0)49

50 datastep = tdata v (2 ) − tdata v (1 ) ; % Time step o f data51 dg = d i f f ( gdata ) / datastep ; % Approximate . . .52 % d e r i v a t i v e o f g53

54 v = 1/2 ∗ dg . / gdata ( 2 : length ( gdata ) ) ; % Compute v55

56 end� �Script 7: plot g.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% PLOT g = P/N %%%%%%%%%%%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function p l o t g ( t , g )7

8 f igure9 p = plot ( t , g ) ; % Plot g ( t )

10 set (p , ’ LineWidth ’ , 1 . 1 ) ;11 hold a l l12

13 xlabel ( ’ t ’ ) ;14 ylabel ( ’ g ( t ) ’ )15

16 end� �Script 8: plot v.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%%%%%%% PLOT DRIFT VELOCITY v %%%%%%%%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function p l o t v ( t , v )7

8 f igure9 p = plot ( t ( 2 : length ( t ) ) , v ) ; % p lo t v ( t )

10 set (p , ’ LineWidth ’ , 1 . 1 ) ;11 hold a l l12

13 xlabel ( ’ t ’ ) ;14 ylabel ( ’ v ( t ) ’ ) ;15 axis ( [ 0 25 0 v (1 ) ] ) ; % Set axes range16

Page 71: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

71 B CODE

17 end� �Script 9: solve moments phi0.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%% FIND MOMENTS OF ORDERS 0 AND 1 OF INITIAL DISTRIBUTION phi0 %%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function moments phi0 = solve moments phi07

8 [ min0 , max0 , N0 ] = parameters s impson moments phi0 ; % Get parameters . . .9 % f o r Simpson ’ s . . .

10 % r u l e11

12 h0 = (max0 − min0 ) /N0 ; % Get l ength o f . . .13 % each s u b i n t e r v a l14

15 gr id0 = zeros (N0+1 ,1) ; % I n i t i a l i s e . . .16 % Simpson gr id17 for i = 1 : ( N0 + 1)18 gr id0 ( i ) = min0 + ( i −1)∗h0 ; % Get Simpson gr id19 end20

21 moments phi0 = zeros ( 1 , 2 ) ; % I n i t i a l i s e . . .22 % moments o f . . .23 % phi0 ( o rde r s 0 . . .24 % and 1)25 for i = 1 :N026 moments phi0 subint = simpson moments phi0 . . .27 ( g r id0 ( i ) , g r id0 ( i +1) , h0 ) ; % Get moments o f . . .28 % phi0 on sub . . .29 % i n t e r v a l30 moments phi0 = moments phi0 . . .31 + moments phi0 subint ; % Update moments . . .32 % of phi033 end34

35 end� �Script 10: parameters simpson moments phi0.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%% STORE PARAMETERS FOR SIMPSON’ S RULE TO GET MOMENTS OF phi0 %%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function [ min0 , max0 , N0 ] = parameters s impson moments phi07

8 min0 = 1e−15; % Lower bound . . .9 % of i n t e g r a l . . .

10 % f o r area /volume

Page 72: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

72 B CODE

11 max0 = 10 ; % Upper bound . . .12 % of i n t e g r a l . . .13 % f o r area /volume14 N0 = 10000 ; % Number o f sub . . .15 % i n t e r v a l s16

17 end� �Script 11: simpson moments phi0.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%% SIMPSON’ S RULE TO GET MOMENTS OF ORDERS 0 AND 1 OF %%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%% INITIAL DISTRIBUTION phi0 %%%%%%%%%%%%%%%%%%%%%%%%4 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%5

6

7 function moments phi0 subint = simpson moments phi0 . . .8 ( min0 subint , max0 subint , h0 )9

10 mid0 subint = ( min0 subint + max0 subint ) /2 ; % Get mid po int11

12 phi0 min = integrand moments phi0 ( min0 subint ) ; % Compute in . . .13 % tegrands o f . . .14 % moments o f . . .15 % phi0 at lower . . .16 % bound17 phi0 mid = integrand moments phi0 ( mid0 subint ) ; % Compute in . . .18 % tegrands o f . . .19 % moments o f . . .20 % phi0 at mid po int21 phi0 max = integrand moments phi0 ( max0 subint ) ; % Compute in . . .22 % tegrands o f . . .23 % moments o f . . .24 % phi0 at upper . . .25 % bound26

27 moments phi0 subint = h0/6 ∗ ( phi0 min . . .28 + 4∗phi0 mid + phi0 max ) ; % Compute . . .29 % Simpson ’ s r u l e . . .30 % on s u b i n t e r v a l . . .31 % f o r moments . . .32 % of phi033

34 end� �Script 12: integrand moments phi0.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%% DEFINE INTEGRANDS OF MOMENTS OF INITIAL DISTRIBUTION phi0 %%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

Page 73: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

73 B CODE

6 function integrand moments phi0 = integrand moments phi0 ( x )7

8 integrand moments phi0 = zeros ( 1 , 2 ) ; % I n i t i a l i s e in . . .9 % tegrand o f . . .

10 % i n i t i a l area / . . .11 % volume moments12 % ( orde r s 0 and 1)13

14 for n = 1 :215 integrand moments phi0 (n) = x . ˆ ( n−1) .∗ phi0 ( x ) ; % Compute in . . .16 % tegrand f o r . . .17 % area /volume18 end19

20 end� �Script 13: phi0.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%% DEFINE INITIAL AREA/VOLUME DISTRIBUTION phi0 %%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%% (COMMENT THOSE THAT ARE NOT USED) %%%%%%%%%%%%%%%%%%%4 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%5

6

7 %%%%%%%%%%%%%%%%%%%%% Unimodal lognormal d i s t r i b u t i o n %%%%%%%%%%%%%%%%%%%%%8 function phi0 = phi0 ( x )9

10 sigma = 0 . 1 ; % Sca l e parameter11 mode = 0 . 6 ; % Mode12 mu = log (mode) + sigma ˆ2 ; % Locat ion . . .13 % parameter14

15 phi0 = 1 . / ( sqrt (2∗pi ) ∗x∗ sigma ) . . .16 .∗ exp(−( log ( x ) − mu) .ˆ2/(2∗ sigma ˆ2) ) ; % Compute phi017

18 end19 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%20

21 %%%%%%%%%%%%%%%%%%%%%% Bimodal lognormal d i s t r i b u t i o n %%%%%%%%%%%%%%%%%%%%%22 function phi0 = phi0 ( x )23

24 sigma = 0 . 1 ; % Sca l e parameter25 mode = 0 . 3 ; % Mode26 mu = log (mode) + sigma ˆ2 ; % Locat ion . . .27 % parameter28 l i n k = 0 . 6 ; % Link pos i . . .29 % t ion . . .30 % between the . . .31 % two d i s t r i . . .32 % but ions . . .33 % ( must be on . . .34 % the g r id x )

Page 74: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

74 B CODE

35

36

37 m = 0 ; % I n i t i a l i s e . . .38 % number o f . . .39 % x <= l i n k40 for i = 1 : length ( x )41 i f x ( i ) <= l i n k42 m = m + 1 ; % Update m43 end44 end45

46 phi0smal l = zeros (1 ,m) ; % I n i t i a l i s e . . .47 % phi0 be f o r e . . .48 % l i n k49 p h i 0 l a r g e = zeros (1 , length ( x )−m) ; % I n i t i a l i s e . . .50 % phi0 a f t e r l i n k51

52 phi0smal l ( : ) = 1 . / ( sqrt (2∗pi ) ∗x ( 1 :m) ∗ sigma ) . . .53 .∗ exp(−( log ( x ( 1 :m) ) − mu) .ˆ2/(2∗ sigma ˆ2) ) ; % Compute . . .54 % phi0smal l55 p h i 0 l a r g e ( : ) = 1 . / ( sqrt (2∗pi ) ∗( x (m+1: length ( x ) ) . . .56 − l i n k ) ∗ sigma ) .∗ exp(−( log ( x (m+1: length ( x ) ) . . .57 − l i n k ) − mu) .ˆ2/(2∗ sigma ˆ2) ) . . .58 + 1 . / ( sqrt (2∗pi ) ∗ l i n k ∗ sigma ) . . .59 .∗ exp(−( log ( l i n k ) − mu) .ˆ2/(2∗ sigma ˆ2) ) ; % Compute . . .60 % p h i 0 l a r g e61

62 phi0 = 0 .5 ∗ [ phi0smal l , p h i 0 l a r g e ] ; % Compute phi063

64 end65 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%66

67 %%%%%%%%%%%%%%%%%%%%%%% Unimodal normal d i s t r i b u t i o n %%%%%%%%%%%%%%%%%%%%%%68 function phi0 = phi0 ( x )69

70 sigma = 0 . 1 ; % Sca l e parameter71 mu = 0 . 6 ; % Locat ion . . .72 % parameter73

74

75 phi0 = 1 . / ( sqrt (2∗pi ) ∗ sigma ) . . .76 .∗ exp(−(x − mu) .ˆ2/(2∗ sigma ˆ2) ) ; % Compute phi077

78 end79 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%80

81 %%%%%%%%%%%%%%%% E l l i p t i c compactly supported d i s t r i b u t i o n %%%%%%%%%%%%%%%%82 function phi0 = phi0 ( x )83

84 a = 0 . 2 ; % Longer a x i s85 b = 2/( pi∗a ) ; % Shorter a x i s . . .86 % ( so that . . .

Page 75: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

75 B CODE

87 % mass i s 1)88 x0 = 0 . 6 ; % Centre89

90

91 phi0 = zeros (1 , length ( x ) ) ; % I n i t i a l i s e phi092 m = 0 ; % I n i t i a l i s e . . .93 % number o f . . .94 % x < x0 − a95 n = 0 ; % I n i t i a l i s e . . .96 % number o f . . .97 % x0 − a < x . . .98 % < x0 + a99 for i = 1 : length ( x )

100 i f x ( i ) < x0 − a101 m = m + 1 ; % Update m102 end103 i f x ( i ) > x0 − a && x ( i ) < x0 + a104 n = n + 1 ; % Update n105 end106 end107

108 phi0 (m+1:m+n) = b∗sqrt (1 − ( ( x (m+1:m+n) . . .109 − x0 ) . / a ) . ˆ 2 ) ; % Compute phi0110

111 end112 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%113

114 %%%%%%%%%%%%%%% Exponent ia l compactly supported d i s t r i b u t i o n %%%%%%%%%%%%%%115 function phi0 = phi0 ( x )116

117 c = 1/0 .0160702 ; % ”Amplitude”118 h = 1 ; % ” Height ”119 k = 0 . 3 ; % ”Width”120 x0 = sqrt ( k ) + 0 . 1 ; % ” Centre ”121

122

123 phi0 = zeros (1 , length ( x ) ) ; % I n i t i a l i s e phi0124 m = 0 ; % I n i t i a l i s e . . .125 % number o f x . . .126 % < x0 − s q r t ( k )127 n = 0 ; % I n i t i a l i s e . . .128 % number o f . . .129 % x0 − s q r t ( k ) . . .130 % < x < x0 + . . .131 % s q r t ( k )132 for i = 1 : length ( x )133 i f x ( i ) < x0 − sqrt ( k )134 m = m + 1 ; % Update m135 end136 i f x ( i ) > x0 − sqrt ( k ) && x ( i ) < x0 + sqrt ( k )137 n = n + 1 ; % Update n138 end

Page 76: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

76 B CODE

139 end140

141 phi0 (m+1:m+n) = c∗ exp(−h . / ( k−(x (m+1:m+n) . . .142 − x0 ) . ˆ 2 ) ) ; % Compute phi0143

144 end145 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%� �

Script 14: read g.m� �1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%% READ IN FILE g . csv AND PREPARE [ t , g ] %%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function [ t , g ] = read g ( t0 , t s tep , tmax , moments phi0 )7

8 data = importdata ( ’ g . csv ’ , ’ , ’ ) ; % Import gdata . . .9 % and tdata . . .

10 % ( data g and . . .11 % t between 0 and12 % tq )13 tdata = data ( : , 1 ) ; % Get data tdata14 gdata = data ( : , 2 ) ; % Get data gdata15

16 datastep = tdata (2 ) − tdata (1 ) ; % Time step o f data17

18 m = 0 ; % I n i t i a l i s e . . .19 % number o f data . . .20 % < t021 for i = 1 : length ( tdata )22 i f tdata ( i ) < t023 m = m + 1 ; % Update m24 end25 end26

27 tdata1 = tdata (m+1: length ( tdata ) ) ; % Store tdata . . .28 % > t029 gdata1 = gdata (m+1: length ( gdata ) ) ; % Store gdata . . .30 % with time > t031

32

33 g0 = moments phi0 (2 ) ; % Get i n i t i a l . . .34 % f i r s t moment . . .35 % of area /volume . . .36 % and use i t to . . .37 % d e f i n e g at . . .38 % time t039 i f g0 >= gdata1 (1 )40 error . . .41 ( [ ’ must ente r an i n i t i a l ’ . . .42 ’ d i s t r i b u t i o n with f i r s t moment < ’ . . .

Page 77: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

77 B CODE

43 num2str( gdata1 (1 ) ) ] ) ; % Print e r r o r . . .44 % i f i n i t i a l . . .45 % d i s t r i b u t i o n . . .46 % does not have . . .47 % f i r s t moment . . .48 % coherent with g49 end50

51 tdata1 = [ t0 ; tdata1 ] ; % Add i n i t i a l . . .52 % time to tdata153 gdata1 = [ g0 ; gdata1 ] ; % Add i n i t i a l g . . .54 % to gdata155

56

57

58 i f tmax < tdata1 ( length ( tdata1 ) )59 m = 0 ; % I n i t i a l i s e . . .60 % number o f . . .61 % tdata1 <= tmax62 for i = 1 : length ( tdata1 )63 i f tdata1 ( i ) <= tmax64 m = m + 1 ; % Update m65 end66 end67 t = tdata1 ( 1 : t s t ep :m) ; % Store tdata1 . . .68 % with step t s t ep69 % up to tmax70 g = gdata1 ( 1 : t s t ep :m) ; % Store gdata1 . . .71 % with step t s t ep72 % up to tmax73 end74

75 i f tmax >= tdata1 ( length ( tdata1 ) )76 tda ta1 ex t ra = transpose . . .77 ( ( tdata1 ( length ( tdata1 ) ) . . .78 + datastep ) : datastep : tmax) ; % Get extra time . . .79 % with time step . . .80 % datastep81 gdata1 ext ra = gdata1 ( length ( gdata1 ) ) . . .82 ∗ ones ( length ( tda ta1 ex t ra ) ,1 ) ; % Get extra g . . .83 % ( s e t i t cons . . .84 % tant a f t e r tq )85 tdata1 = [ tdata1 ; tda ta1 ex t ra ] ; % Add extra time . . .86 % to tdata187 gdata1 = [ gdata1 ; gdata1 ext ra ] ; % Add extra g . . .88 % to gdata189

90 t = tdata1 ( 1 : t s t ep : length ( tdata1 ) ) ; % Store tdata1 . . .91 % with step t s t ep92 % up to tmax93 g = gdata1 ( 1 : t s t ep : length ( tdata1 ) ) ; % Store gdata1 . . .94 % with step t s t ep

Page 78: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

78 B CODE

95 % up to tmax96

97

98 end99

100

101 t = t − t0 ; % Trans late time . . .102 % by t0 in order . . .103 % s o l v e problem . . .104 % with i n i t i a l . . .105 % time 0106

107 end� �Script 15: solve phi.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%%%%%%%%% FIND SOLUTION phi %%%%%%%%%%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function phi = s o l v e p h i (x , t , g , beta )7

8 [ ymin , ymax ,N] = parameters s impson phi ; % Get parameters . . .9 % f o r Simpson ’ s . . .

10 % r u l e11

12 h = (ymax − ymin ) /N; % Get l ength o f . . .13 % each s u b i n t e r v a l14

15 y = zeros (N+1 ,1) ; % I n i t i a l i s e . . .16 % Simpson gr id17 for i = 1 :N+118 y ( i ) = ymin + ( i −1)∗h ; % Get Simpson gr id19 end20

21 phi = zeros ( length ( t ) , length ( x ) ) ; % I n i t i a l i s e phi22 phi ( 1 , 2 : length ( x ) ) = phi0 ( x ( 2 : length ( x ) ) ) ; % Store i n i t i a l23 % d i s t r i b u t i o n phi024 phi ( : , 1 ) = 0 ; % Set phi = 0 at . . .25 % x = 0 f o r a l l . . .26 % t ( see r epor t )27

28 s t a r t = t ic ; % Store s t a r t . . .29 % time o f Simp . . .30 % son ’ s r u l e31 for j = 2 : length ( t )32 for i = 1 :N33 ph i s ub i n t = simpson phi ( y ( i ) , y ( i +1) ,h , x . . .34 ( 2 : length ( x ) ) , t ( j ) , g ( j ) , g (1 ) , beta ) ; % Get phi . . .35 % on s u b i n t e r v a l36 phi ( j , 2 : length ( x ) ) = phi ( j , 2 : length ( x ) ) . . .

Page 79: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

79 B CODE

37 + ph i s ub i n t ; % Update phi38 end39 end40

41 e lapsed = toc ( s t a r t ) ; % Store end . . .42 % time o f Simp . . .43 % son ’ s r u l e44 [ ’ Computation time f o r Simpons r u l e : ’ . . .45 num2str( e l apsed ) ] % Print Simpon ’ s . . .46 % r u l e time47

48 end� �Script 16: parameters simpson phi.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%% STORE PARAMETERS FOR SIMPSON’ S RULE TO GET INTEGRAL OF SOLUTION phi %%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function [ ymin , ymax ,N] = parameters s impson phi7

8 ymin = −3; % Lower bound . . .9 % of i n t e g r a l

10 ymax = 2 ; % Upper bound . . .11 % of i n t e g r a l12 N = 300 ; % Number o f sub . . .13 % i n t e r v a l s14

15 end� �Script 17: simpson phi.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%% SIMPSON’ S RULE TO GET SOLUTION phi %%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function ph i s ub i n t = simpson phi . . .7 ( min subint , max subint , h , x , t , g , g0 , beta )8

9 mid subint = ( min subint + max subint ) /2 ; % Get mid po int10

11 min phi = in t eg rand ph i ( min subint , x , t , g , g0 , beta ) ; % Compute in . . .12 % tegrands o f . . .13 % phi at lower . . .14 % bound15 mid phi = in t eg rand ph i ( mid subint , x , t , g , g0 , beta ) ; % Compute in . . .16 % tegrands o f . . .17 % phi at mid po int18 max phi = in t eg rand ph i ( max subint , x , t , g , g0 , beta ) ; % Compute in . . .19 % tegrands o f . . .

Page 80: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

80 B CODE

20 % phi at upper . . .21 % bound22

23 ph i s ub i n t = h/6 ∗ ( min phi + 4∗mid phi . . .24 + max phi ) ; % Compute . . .25 % Simpson ’ s r u l e . . .26 % on s u b i n t e r v a l . . .27 % f o r phi28

29 end� �Script 18: integrand phi.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%% DEFINE INTEGRAND OF SOLUTION phi %%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function i n t eg rand ph i = in t eg rand ph i (y , x , t , g , g0 , beta )7

8 wt = w( g , g0 ) ; % Get w at g9 bt = b( t , g , g0 , beta ) ; % Get b at time t

10 phi0exp = phi0 (exp( y ) ) ; % Get phi0 ( exp ( y ) )11

12 i n t eg rand ph i = 1 ./ x .∗ 1 ./ sqrt (4∗pi∗bt ) . . .13 .∗ exp(−( log ( x ) + bt − wt − y ) .ˆ2/(4∗ bt ) ) . . .14 ∗ exp( y ) ∗ phi0exp ; % Compute in . . .15 % tegrand o f . . .16 % s o l u t i o n phi17

18 end� �Script 19: w.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%% DEFINE ANTIDERIVATIVE w OF DRIFT VELOCITY v %%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function w = w(g , g0 )7

8 w = log ( g/g0 ) ; % Compute w at g9

10 end� �Script 20: b.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%% DEFINE ANTIDERIVATIVE b OF DIFFUSION COEFFICIENT beta %%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

Page 81: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

81 B CODE

6 function b = b( t , g , g0 , beta )7

8 wt = w( g , g0 ) ; % Get w at g9 b = beta (1 ) ∗ t + beta (2 ) ∗wt ; % Compute b at . . .

10 % time t11

12 end� �Script 21: solve psi.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%%%%%%%%% FIND SOLUTION p s i %%%%%%%%%%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function p s i = s o l v e p s i (x , r , t , phi , dim )7

8 p s i = zeros ( length ( t ) , length ( x ) ) ; % I n i t i a l i s e p s i9

10 i f dim == 211 for j = 1 : length ( t )12 p s i ( j , : ) = 2∗pi∗ r .∗ phi ( j , : ) ; % Compute p s i in . . .13 % two dimensions14 end15 else16 for j = 1 : length ( t )17 p s i ( j , : ) = 4∗pi∗ r . ˆ 2 . ∗ phi ( j , : ) ; % Compute p s i in . . .18 % three dimensions19 end20 end21

22 end� �Script 22: plot sol.m� �

1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%2 %%%%%%%%%%%%%%%%%%%%%%%% PLOT SOLUTIONS phi AND p s i %%%%%%%%%%%%%%%%%%%%%%%3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%4

5

6 function p l o t s o l ( phi , ps i , x , r , tp lo t , r ange tp l o t , dim )7

8 f igure9 phi x = zeros (1 , length ( x ) ) ;

10 for j = r a n g e t p l o t11 phi x ( : ) = phi ( j , : ) ; % Plot s o l u t i o n . . .12 % phi ( x )13 p = plot (x , ph i x ) ;14 set (p , ’ LineWidth ’ , 1 . 1 ) ;15 hold a l l16 end17

Page 82: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

82 C GUIDE TO THE CODE

18 i f dim == 219 t i t l e ( ’ Area d i s t r i b u t i o n ’ ) ;20 else21 t i t l e ( ’ Volume d i s t r i b u t i o n ’ ) ;22 end23

24 xlabel ( ’ x ’ ) ;25 ylabel ( ’ phi ( x ) ’ ) ;26 legend ( s t r c a t ( ’ t = ’ , num2str( t p l o t ) ) ) ;27

28 f igure29 p s i r = zeros (1 , length ( r ) ) ;30 for j = r a n g e t p l o t31 p s i r ( : ) = p s i ( j , : ) ; % Plot s o l u t i o n . . .32 % p s i ( r )33 p = plot ( r , p s i r ) ;34 set (p , ’ LineWidth ’ , 1 . 1 ) ;35 hold a l l36 end37

38 t i t l e ( ’ Radius d i s t r i b u t i o n ’ ) ;39 xlabel ( ’ r ’ ) ;40 ylabel ( ’ p s i ( r ) ’ ) ;41 legend ( s t r c a t ( ’ t = ’ , num2str( t p l o t ) ) ) ;42

43 end� �

C Guide to the code

We dedicate this appendix to explaining how to run the author’s MATLAB code used for thesimulations of section 6 and given in appendix B.

The code is composed of 22 different scripts, as given in appendix B. The main script is calledgrain_size_distribution.m (see script 1) and takes one argument dim, corresponding to thephysical dimension of the problem and which should be either the number 2 or 3. The resultgiven by the program splits into four graphs:

• the ratio g(t) := P (t)N(t) against time t,

• the drift velocity v(t) against time t,

• the area – if dim = 2 – or volume – if dim = 3 – distribution against x,

• the respective radius distribution against r.

The last two graphs can be plotted at a single time, or at many different times.

There are parameters that may be changed to adapt the program to what one looks for. Theseparameters define either physical quantities, as the dimension of the problem, the quenching

Page 83: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

83 C GUIDE TO THE CODE

time tq, the reference growth rate ρ0, the equilibrium ferrite phase fraction Peq, the nucleationrate α, the initial time t0, the diffusion coefficients β0 and β1, and the initial distribution φ0,2d orφ0,3d; or numerical quantities, as the number of times at which the solutions must be computedand plotted, the maximum area or volume and radius up to which the solutions must be plotted,and the parameters relative to the Simpson’s rules used. First, we have the argument of the mainfunction grain_size_distribution (script 1):

• dim: physical dimension of the problem (must be either 2 or 3).

We have three sets of parameters in the main script grain_size_distribution.m (script 1):

• tq: quenching time (time up to which g(t) and v(t) are plotted),

• rho0: reference growth rate,

• Peq: equilibrium ferrite fraction (must be positive and less than 1),

• alpha: nucleation rate.

• t0: initial time (must be positive),

• tmax: maximum time up to which the solution should be computed,

• tstep: index step in vectors tdata and gdata – created by the function solve_g (script2) – characterising the number of times for which the solutions are computed.

• beta: vector containing the diffusion coefficients β0 and β1,

• xmax: maximum area or volume up to which the solutions should be plotted,

• xspacing: spacing between each area or volume plotted,

• range_tplot: range of times to be plotted among the times for which the solutions arecomputed (for example, range_tplot=1:1 only plots the initial distributions, range_

tplot=length(t):length(t) only plots the distributions at tmax, and range_tplot=1:

length(t) plots the distributions at all the times they are computed).

The following parameters are in the script parameters_simpson_moments_phi0.m (script 10):

• min0: lower bound for the area or volume used to compute the mass and the first momentof the initial distribution φ0,2d(x) or φ0,3d(x) (must be positive and such that the signifi-cant part of the initial distribution lies in the interval [min0,max0]),

• max0: upper bound for the area or volume used to compute the mass and the first momentof the initial distribution (see min0 above),

• N0: number of subintervals for the Simpson’s rule used to compute the mass and firstmoment of the initial distribution.

The parameters below are in the script parameters_simpson_phi.m (script 16):

• ymin: lower bound for the area or volume used to compute the convolution integral in thesolution (6.1) or (6.2) (must be such that the significant part of φ0,2d (ey) or φ0,3d (ey) liesin the interval [ymin,ymax]),

• ymax: upper bound for the area or volume used to compute the convolution integral in thesolution (see ymin above),

• N: number of subintervals for the Simpson’s rule used to compute convolution integral inthe solution.

Page 84: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

84 C GUIDE TO THE CODE

Finally, the initial distribution should be entered in the script phi0.m (script 13). The five initialdistributions in tables 1 and 2 are already set in the script for the two-dimensional case. Theinitial distributions that are not used should be commented (%)

We give here the various steps that the program goes through ones it is run. To run the program,it suffices to type grain_size_distribution(dim) in the MATLAB command line, with dim

being either the number 2 or number 3. Then, the code

1. reads the first set of parameters tq, rho0, Peq and alpha,

2. uses them to generate the discretised time tdis and the data g(tdis) up to the quenchingtime tq, respectively called tdata, gdata and tq (this is done by the function solve_g

(script 2), which uses the MATLAB solver ode45 to solve the differential system (6.8) or(6.9) to get P , and employs spline interpolation between the times in tdata using theMATLAB function interp1 in order to get N),

3. writes these data in file g.csv via the function write_g,

4. finds the drift velocity v(t′dis) up to the quenching time tq via the function solve_v (script6), which works analogously to solve_g (t′dis is another discretised time which is finer thantdis, as we need v evaluated at more times in order to calculate the derivative of g by finitedifferences more accurately),

5. plots both gdata and v against their respective discrete times tdata and tdata_v via thefunctions plot_g and plot_v (scripts 7 and 8),

6. reads the set of parameters t0, tmax and tstep,

7. computes the mass and first moment of the initial distribution entered in the functionphi0 (script 13) by the Simpson’s rule with the parameters min0, max0 and N0 (see script10),

8. reads tdata and gdata in the file g.csv via the function read_g (script 14) (only keepsthe times that are between t0 and tq; if tmax is larger than tq, then constant data areadded to gdata up to tmax with value the last component of vector gdata, and with timestep that of tdata; if tmax is smaller than tq, the times above tmax are simply cut fromgdata and tdata; also, t0 and the corresponding first moment g0 are added to the data,and if the initial distribution set in function phi0 (script 13) has too large first moment,the program outputs an error message; it alos generates the vectors t and g by taking thedata in the new tdata and gdata each tstep row; it finally translates t by t0 in order tostart from time 0),

9. reads the set of parameters beta, xmax, xspacing and range_tplot,

10. generates the grids for the area or volume and for the radius by the transformations x = πr2

in two dimensions and x = 4π3 r

3 in three dimensions,

11. finds the solutions phi and psi at each time in t, respectively the area or volume distri-bution and the radius distribution, calling the functions solve_phi (script 15) – whichimplements the Simpson’s rule with parameters ymin, ymax and N (see script 16) – andsolve_psi (script 21) – which simply applies the changes of variable (5.9) and (5.29),

12. plots the solutions at each time given in range_tplot by means of the function plot_sol

(script 22).

Page 85: Master’s Thesis - fpatacchini.files.wordpress.com · thesis has been highly exciting, enjoyable and gratifying. I nally thank Tony Shard-low for accepting to be the checker of my

85 C GUIDE TO THE CODE

Remark C.1 (Choice of the initial distribution in function phi0 (script 13)). The initialarea or volume distribution must always be set such that its first moment respects remark 6.1,i.e, it must be slightly smaller than the datum in gdata with corresponding time tdata (see step2 above) immediately larger than t0. Also, the mass of the initial distribution must be one, or asnear as possible to it. These restrictions can be fulfilled by tuning the parameters of the initialdistribution given in the function phi0 (script 13) and by displaying the moments computed inthe function solve_moments_phi0 (script 9); for this, simply withdraw the ; after the call tothe function solve_moments_phi0 at line 57 of the main script grain_size_distribution.m

(script 1). The parameters given in table 2, section 6.2, are examples that respect these require-ments, and may be used for this.