Vous êtes sur la page 1sur 26

Analytical and Computational

Solutions for Deposition Processes


in Disorderly Surface Growth
Boris (Bo Wen) Lin, Christian Lau

University of Southern California


Phys 316 - Thermodynamics and Statistical Mechanics
Dr. Christoph A. Haselwandter
May 5th, 2015

Abstract
In this paper we present a concise introduction to the general methodologies
of disorderly surface growth. The dynamics of far from equilibrium surface
growth systems can be investigated from a scaling approach making heavy
use of fractal geometry. The information related to the complex behavior
of these systems is therefore collapsed in a few quantities, known as critical
exponents, that regulate their scaling properties. An introduction to the
foundations of this theoretical framework is presented through the example of the Ballistic Deposition model and the relevance of correlation for
saturation phenomena is discussed. Armed with the necessary theoretical
knowledge, both the Random Deposition model and the Random Deposition with Surface Relaxation model are solved exactly, providing the values
of their critical exponents. To that aim several new methods are presented
and applied to the individual models, especially the devising of continuum
stochastic growth equations through symmetry considerations and all the
related techniques adopted to solve exactly for the critical exponents.

Introduction
Far from complying with the wishful rules of conventional geometry, nature
abounds with examples of rough morphologies. Materials science oers a
bewildering array of phenomena characterized by disorderly surface growth,
from the everyday experience of fluid flow in porous media and flame fronts
propagation - that everybody can recreate by spilling coee on a tablecloth
or setting fire to a paper sheet - to microscopic deposition processes, that
play a fundamental role in todays technologies like Molecular Beam Epitaxy
(MBE). Further examples can be found in the biological sciences, as in the

case of bacterial growth in petri dishes or DNA sampling, and even in the
study of coastlines, cloud formations and botany.
The study of the fundamental properties of the rough shapes arising
from such phenomena began to be seriously tackled by mathematicians only
in the 1960s, with the pioneering works of Benoit Mandelbrot [1], who laid
the foundations of what later became known as fractal geometry. Advances
in physics have been somewhat slower, hampered by the fact that most
phenomena in disorderly surface growth operate far from the thermodynamic
equilibrium (deposition processes, for example, dont allow energy nor the
number of particles to be conserved at all, almost by definition), therefore
the methods of equilibrium statistical mechanics and thermodynamics are
inadequate and largely unsuccessful. Nowadays, however, disorderly surface
growth is a thriving and expanding multidisciplinary field that can count on
several dierent and mutually consistent investigation methodologies.
Scaling methods, building on the fractal concept of self-anity, allow
to reduce the apparently unassailable complexity of such systems by identifying a set of simple quantities, called critical exponents, that completely
describe the dynamics and morphology of the resulting surface. In addition,
numerous experimental methods have been developed for the study of interface motion and deposition processes in the comfort of our laboratories,
with resolutions previously inconceivable, as in the case of the Scanning
Tunneling Microscope (STM).
Computers are also playing an unprecedented role, being the natural
instruments for the implementation of discrete models in simulations, thus
complementing and integrating the insights obtained in traditional experimental settings.
Lastly, the theoretical advances in the fields of stochastic dierential
equations and renormalization group theory have provided scientists with
a wealth of techniques for deriving continuum growth equations displaying
the same properties of most microscopic discrete models and unifying the
disparate phenomena under analysis through the introduction of universality
classes.
In this research paper we will touch upon all these methods, apart from
the experimental approach, through the exposition of a topical class of phenomena in disorderly surface growth: deposition processes. One of the most
famous models, that of Ballistic Deposition (BD), will lead us to the presentation of basic scaling concepts (Section1), like that of critical exponents. A
rapid exposition of elementary notions in fractal geometry follows in Section
2, to oer a deeper theoretical understanding of the subject at hand.
Building on the knowledge exposed, in Section 3 we finally present the
model of Random Deposition (RD), for which analytical solutions for the
discrete system and its continuum analog are both provided.
Nevertheless, as a rule of thumb, not always it is possible to find solutions
in closed form in the discrete formulation of the problem, therefore a section
2

on the Random Deposition with Surface Relaxation (RDSR) model will


follow (Section 4), exemplifying a case in which the use of stochastic growth
equations, obtained through symmetry considerations, is both necessary and
practical.
A brief conclusion at the end of the paper will help the reader to put the
results previously exposed into the more general context of fractal surfaces
and disorderly surface growth, summarizing the lessons that can be learned
from this booming field and oering some suggestions on its future direction.

Scaling concepts and the Ballistic Deposition


model: a motivating example

The Ballistic Deposition (BD) model was first introduced for the description
of colloidal porous aggregates [2, 3] and only successively, with the study of
vapor deposition, the attention of most scientists was caught by the nontrivial properties of the surface it generates [4]. In this paper we will study
the two-dimensional on-lattice version of the model, in which rigid particles,
represented by squares, fall perpendicularly from an infinite height along
one of L columns, chosen randomly, on top of an initially flat surface, as
shown in Figure 1.

Figure 1

The particles, upon reaching the surface, stick either to the bottom of
their column or at an height equal to the nearest neighbor they encounter
along their trajectory. The unit time is chosen to correspond to the deposition of L particles and L is taken to represent the system size. Some
quantities of interest are introduced, as the mean height
3

!
= 1
h(t)
h(i, t)
L
i=1

where h(i, t) is the height of the i-th column at time t, and the interface
width
"
#
L
#1 !
$
(h(i, t) h(i, t))2
w(L, t) =
L
i=1

which is a measure of the roughness of the surface at time t and system


size L.
We have implemented the model to study computionally the evolution
of these two quantities. The surface obtained is shown in Figure 2, which
is a snapshot of the dynamic evolution of the system during a real-time
simulation. The code for the implementation in python can be found in
Appendix 3.

Figure 2

The behavior in time of the mean height is straightforward: if the deposition rate is constant h(t) increases linearly with time, h(t) t. Quite
more perplexing is the behavior of w(L, t), which can be obtained computationally, and is as follows

%
t
w(L, t)
wsat

if t tx
if t tx

Initially w(L, t) increases as a power law of time, with exponent , known


as the growth exponent. When a given time tx is reached, known as crossover
or saturation time, the width reaches the saturation value wsat . These two
last quantities, tx and wsat , can be shown to depend on the system size
through power laws
wsat L
tx Lz
where the two exponents and z take the name of roughness and dynamic exponent respectively.

Figure 3

Due to these functional relations, plotting w(L, t) as a function of time


yields dierent curves for dierent values of L, as can be seen in our computational results shown in Figure 3, but a simple process can be devised to
conflate them:
- first, the width is divided by the saturation value wsat , with the result
that all the curves reach the same plateau at their respective crossover times,
- secondly, the time is rescaled by t/tx , with the result that all curves
saturate at the same time.
5

Mathematically we obtain the following scaling relation:


& '
t

w(L, t) = L f
Lz

where f (u) is known as scaling function and satisfies the following asymptotic behavior
%
u
if u 1
f (u)
const if u 1
An additional important result is that the critical exponents , and
z, are not unrelated. By imposing the continuity of the width function at
crossover time we obtain

The scaling relation we just saw is known as the Family-Vicsek scaling


relation, but of course alternative scaling relations exist. For example the
following functional expression for w(L, t) is perfectly viable
& '
L

w(L, t) t g
t
in which the scaling function satisfies
%
const if u 1
g(u)
u
if u 1
tx = L = z =

Furthermore, by imposing the continuity of w(L, t) at tx , the coecient


can be shown to be equal to = 1/z = /.
Clearly the most puzzling characteristic of the BD model is the very
existence of a saturation value for w(L, t). As can be shown from simple
considerations on the functional dependence of wsat on L, saturation must
be a finite-size eect, in other words it occurs because the system size L
is finite. But this condition is not sucient, as will be seen in Section 3,
while discussing the RD model. Another requirement that is necessary for
saturation is the presence of correlation. More specifically, due to the fact
that the height at which a falling particle stops depends on the height of the
neighboring columns, there is a correlation length given by
%
t1/z if t tx

L
if t tx

that represents the capacity of each column to influence the height of its
neighbors and thus communicate, given sucient time, with a large portion
of the surface. As soon as reaches the value L, corresponding to complete
communication along the surface, saturation kicks in as a finite-size eect.
6

Basic notions of fractal geometry

To better understand the significance and nature of the critical exponents


we found in the study of the BD model, we now turn to a brief exposition
of the fundamental insights and concepts at the heart of fractal geometry.
Fractals can be surprising and puzzling mathematical objects at a first
glance, but their basic defining properties are few and intuitive, namely selfsimilarity or self-anity (depending on the scale invariance they obey) and
fractional dimension.

2.1

Self-similarity

We will start by presenting self-similar fractals. The fractal shown in Figure


4 is known as the Vicseks fractal and is a typical example of a self-similar
deterministic fractal. Its construction is performed in numbered steps and,
as is evident from a quick inspection, if a part of the structure at the k-th
step is subject to an isotropic scale transformation of the form
(x1 , x2 ) & (bx1 , bx2 )
with a suitable coecient b, it can be perfectly juxtaposed to the whole
structure at the (k 1)-th step. This property of invariance under isotropic
scale transformations is known as self-similarity. In the limit in which the
structure has evolved for an infinite number of steps a fractal object is
obtained.

Figure 4

There are several definitions of the dimension of a fractal: the box counting dimension, the information dimension and the correlation dimension are
only some of them. In this paper we will employ the box counting definition,
which is in all likelihood the most intuitive one.
Let dE denote the so called embedding dimension, that is the smallest
Euclidean dimension of the space in which the object can be embedded. In
our example dE = 2, since the Vicsek fractal is defined on a Euclidean plane.
Imagine to cover the object with N (l) dE -dimensional balls of linear size l.
The dE -dimensional volume enclosed by this covering is then V (l) = N (l)ldE
7

. For non-fractal objects the number of boxes needed scales as N (l) ldE ,
as should be expected. Fractals, on the other hand, enjoy the property of
being fully covered by N (l) ldf boxes, where df < dE is called fractal
dimension. df can be calculated by the relation
df = lim

l0

ln(N (l))
ln(1/l)

In the case of Vicseks fractal, for example, we can cover the entire surface
at step k with 5k squares of linear size 3k , as a quick inspection of Figure
5 will readily confirm. Therefore its fractal dimension is
ln(5k )
ln(5)
=
= 1.4649 . . . < 2 = dE
k+ ln(3k )
ln(3)

df = lim

therefore this structure, despite living in a 2-dimensional Euclidean space,


is neither a line nor a surface, but an object of fractional dimension, i.e. a
fractal [5].

2.2

Self-anity

Not all fractals are self-similar. Indeed in the case of the fractal shown in
Figure 5, a portion at the k-th step can be juxtaposed exactly to the whole
structure at the (k 1)-th step only if its scaled dierent along the two
axes directions. In another words what is needed is an anisotropic scale
transformation of the form:
(x1 , x2 ) & (bx1 , b x2 )
where the exponent is termed Holder exponent or self-ane exponent.
It must be noticed that for = 1 we obtain again the case of self-similarity.
In general for a fractal function, h(
x), defined on a d-dimensional domain
the scaling relation is
h(
x) b h(b
x)
Invariance under anisotropic transformations is called self-anity and
the fractals satisfying this invariance are called self-ane. This property is
of fundamental importance since most surfaces in disorderly surface growth
- and many other application fields of fractal geometry - are self-ane rather
than self-similar.

Figure 5

It is possible to associate a fractal dimension to self-ane fractals in


roughly the same way it is done for self-similar ones. The mathematical
details and a brief discussion of the limits of this definition are discussed in
Appendix 1.

The Random Deposition model: an introduction to stochastic growth equations

The Random Deposition (RD) model is an extremely simple discrete growth


model for which it is possible to compute exactly the scaling exponents. Its
solution can be found by working in the setting of the discrete model itself,
which is entirely a consequence of the rare simplicity of its formulation, or by
devising an appropriate stochastic growth equation describing its dynamic
on a continuum spatial domain. This latter choice is usually the only option
left in the case of more complex and realistic models, as we will see in the
case of the Random Deposition with Surface Relaxation model presented in
Section 4.
Not unlike the BD model, also the RD model is a two-dimensional onlattice model in which particles are represented by square falling perpendicularly along one of L columns, chosen randomly, from an infinite height on
an initially flat surface. The only dierence with the BD model is that each
particle stops at the height of the column along which its moving, with no
interaction with neighboring particles. In other words, the height in columns
is uncorrelated. As we will see this has profound consequences.
9

3.1

Discrete system exact solution

This model has been implemented in python for simulation purposes. The
code can be found in Appendix 4 and a snapshot of a real-time simulation
is shown in Figure 6.

Figure 6

Given the discrete growth formulation, an exact solution can be found


analytically without too much eort [6]. We start by noticing that each one
of the L columns has a probability p = 1/L of increasing its height by one.
Therefore the probability that a column has height h after the deposition of
N particles follows a binomial distribution of the form
& '
N h
p(h, N ) =
p (1 p)N h
h
By defining time as the mean number of deposited layers, t = N/L, we
readily obtain
< h >= N p =

10

N
=t
L

< h2 >= N p(1 p) + N 2 p2


We see therefore that the mean height scales linearly with time, h t.
The interface width is
)
(

1
N
w(t) = N p(1 p) =
(1 ) t
L
L
therefore the growth exponent is = 1/2. The behavior of the interface
width has been computationally studied and results for dierent values of
the system size L are shown in Figure 7.

Figure 7

In the absence of correlation, the correlation length, , is identically zero.


This means that a necessary condition to have the phenomenon of saturation
is missing in the case of the RD model, therefore the roughness exponent
is not defined (for consistency it is said to be infinite, to allow wsat to be
infinite) and the resulting surface is not self-ane.

3.2

Continuum stochastic growth equation and its solution

Associating a continuum stochastic growth equation to the model is often


the only way to directly calculate the scaling exponents of the system. The
objective is to find an appropriate partial dierential equation describing
the growth of the function h(
x, t) denoting the height of a column above

11

position x
, where x
now lies, in general, in a d-dimensional continuum domain. Successively the equation must be perturbed with the introduction of
a stochastic term accounting for the randomness of the deposition process.
There are various techniques involved in devising the correct equation,
but these will be discussed more thoroughly in Section 4. A suitable equation
for the RD model is the following
h(
x, t)
= F + (
x, t)
t
where F is a constant denoting the average number of particles depositing at site x
and (
x, t) is a random process satisfying
< (
x, t) >= 0
< (
x, t)(
x , t ) >= 2Dd (
xx
)(t t )
Suitable distributions for (
x, t) are for example the Gaussian distribution or the Bernoulli distribution. Solving for h(
x, t) by integrating the
equation with respect to time we obtain
* t
h(
x, t) = F t +
d (
x, )
0

From which we can derive the first and second moment


*

< h(
x, t) > = < F t > + <
d (
x, ) >
0
* t
= Ft +
d < (
x, ) >= F t
0

where we have used the fact that the expected value of (


x, t) is zero.
And

2 2

d (
x, )
d (
x, ) >
< h (
x, t) = < F t > + < 2F t
d (
x, ) > + <
0
0
0
* t * t
* t
2 2
d < (
x, )(
x, ) >
d < (
x, ) > +
d
= F t + 2F t
0
0
0
* t * t
d 2D( )
= F 2 t2 +
d
0

= F 2 t2 + 2Dt

Substituting these results in the expression of w(t) we find


w(t) =

2Dt t
12

which implies that the growth exponent is = 1/2, in agreement with


the exact solution found in Paragraph 3.1.

The Random Deposition with Surface Relaxation model

The Random Deposition with Surface Relaxation (RDSR) model [7] is a


two-dimensional on-lattice variation of the basic RD. The crucial dierence
is that falling particles, upon reaching the top of their column, are allowed
to diuse locally, i.e. they can move to the top of one of the two neighboring
columns if its height is lower than the one its currently occupying, as shown
in Figure 8 . This process, known as surface relaxation, produces a smoothing eect on the surface and is introduced in order to mimic the occupation
of the locally stable lowest-energy configuration of the system. The coupling
of the columns heights caused by the discrete system dynamics generates a
non-zero correlation length and therefore saturation.

Figure 8

A computer simulation of the model has been implemented, see Figure


9 and Appendix 4 for the code, indicating that the values of the critical
exponents are
= 0.24 0.01
= 0.58 0.02

13

Figure 9

These values cannot be analytically obtained by solving for the discrete


system dynamics, which is intractable. The only hope is to introduce a
stochastic growth equation that captures, as best as possible, the relevant
properties of the system shown, for example, in the time evolution of the
width as a function of system size L obtained through our simulations in
Figure 10.

14

Figure 10

4.1

The Edwards-Wilkinson equation

Finding a stochastic growth equation that accurately reproduces the critical


exponents of a discrete system is usually not an easy feat. One method to
identify a suitable candidate for such an equation is that of starting from a
stochastic dierential equation of a very general form, like
h(
x, t)
= G(h, x, t) + (
x, t)
t
where G(h, x, t) is a generic function and (
x, t) obeys the same properties listed in Paragraph 3.2, and successively ruling out all the terms that
are incompatible with the systems symmetries [8]. For the case at hand, we
notice that the RDSR model displays several dierent symmetries:
- Invariance under translations in time. The growth equation cannot
depend on the arbitrary definition of time zero. Therefore we deduce that
under t & t + d the equation is left unchanged only if we rule out explicit
time dependence of G.
- Translation invariance along the growth direction. Analogously to the
previous case, the equation cannot depend on the level of zero height: under
h & h + d the equation is left unchanged only if we rule out an explicit
dependence of G from h.
- Translation in the direction perpendicular to the growth direction. The
equation must not depend on the actual value of x
on which its computed.

15

Imposing that invariance under x


& x
+ d is respected we see that G cannot
explicitly depend on x
.
- Rotation and inversion symmetry about the growth direction n. This
invariance allows us to rule out all odd order derivatives of h in the coordinates.
- Up/Down symmetry for h. Assuming that negative and positive deviations from the mean height are equally likely, we must rule out even powers
of h and its gradient.
The terms left are all derivatives of h of even order and all their combinations with even powers of the gradient, so the equation assumes the
form
h(
x, t)
= (2 h) + . . . + (2n h) + (2 h)(h)2 + . . . + (2k h)(h)2j + (
x, t)
t
In studying the system we are interested only in its scaling properties,
that is we are interested in the long-time (t +) long-distance (
x +)
behavior of the equation. In this limit, known as hydrodynamic limit, several
higher order terms can be neglected, as is shown in Appendix 2, and the
final form of the stochastic growth equation is
h(
x, t)
= v2 h(
x, t) + (
x, t)
t
where v is the surface tension. This equation is known as the EdwardsWilkinson equation [9]. There are two ways of investigating the scaling
properties of this stochastic equation: the scaling approach, which is a simple
exploitation of the hydrodynamic limit under self-ane transformations,
and the complete analytical solution, which provides an exact solution by
integrating the equation with respect to time and solving for h(
x, t) in the
Fourier space.

4.2

Scaling approach

We start with the assumption that the function h(


x, t) must be self-ane,
therefore we impose invariance under the following transformations
x & bx
h & b h
t & bz t
The equation then becomes

16

h(
x, t)
= vb2 2 h(
x, t) + bd/2z/2 (
x, t)
t
and, after rearranging the terms, we obtain
bz

h(
x, t)
= vbz2 2 h(
x, t) + bd/2+z/2 (
x, t)
t
We now notice that in the hydrodynamic limit there should be no dependence on b, therefore we obtain two relations on the three critical exponents
by imposing that the powers of b are identically zero. The third known
relation z = / provides the missing information to solve for the three
exponents exactly and we thus readily obtain
=

2d
2

2d
4

z=2

4.3

Exact solution

Exploiting the linearity of the Edwards-Wilkinson equation we can obtain


an exact solution by Fourier transforming the function h(
x, t). We find
h(
x, t) =

)
(k,
vk 2 i

) is the Fourier transform of the noise process. We can thus


where (k,
exploit the known form of the correlation function of the noise to obtain the
correlation function of the Fourier transform of h(
x, t)
)h(k , ) >=
< h(k,

)(k , )
(k,
(vk 2 i)(vk2 i )

Finally, by operating the inverse Fourier transform and after some algebraic steps, we obtain the correlation function for h(
x, t)
&
'
v|t t |
D
2d

< h(
x, t)h(
x , t ) >=
|
xx
| f
2v
|
xx
|2
where the function f (u) has scaling properties
%
const
for u +
f (u)
(2d)/2
u
for u 0

17

By comparing this function with the general Family-Vicsek scaling relation we obtain the same values for the critical exponents that we found
behavior, in perfect agreement with the scaling approach.
It is also instructive to emphasize how these exponents agree with the
experimental results. This seems to suggest that both the actual RDSR
model and its continuum growth version display identical scaling behaviors,
and thus belong to the same universality class.

Conclusion

We have briefly introduced the reader to the methodologies of disorderly


surface growth, showing how to describe the complex behavior of these systems in terms of a few key quantities, the critical exponents, that regulate
their scaling properties. We have also expounded upon their mathematical significance in the context of fractal geometry. The main models of
Ballistic Deposition, Random Deposition and Random Deposition with Surface Relaxation have been introduced and solved, whenever possible, either
within the discrete formulation or in the more general context of continuum
stochastic growth modeling. We have also discussed the role of correlation
in the emergence of saturation phenomena and the importance of symmetry
considerations in building appropriate stochastic growth equations lying in
the same universality class as the discrete systems analyzed.
From this overview of the field of disorderly surface growth it must be
clear that the mathematical challenges posed by the complex behavior of surfaces are of a unique and unprecedented nature. We have just barely began
to unravel such fundamental principles as self-anity, universality classes
and stochastic modeling. Obviously several central issues remain open, first
of all the ubiquity of fractal properties in nature, which is in itself puzzling.
It seems natural to ask whether there are limits to the applicability of this
new kind of mathematics. In other words, how universal are universality
classes? The fact that rough surface can be obtained in artificial ways, like
in the study of long-range correlations in DNA samples [10] or in the study
of financial time series, seems to indicate that the only limit is our imagination and creativity and this motivates most of the multidisciplinary nature
of these studies.
There are principles so deeply hidden in nature that unraveling them
must reward the investigator with insights as precious as those lying at the
bottom of every revolution in science. That the study of fractal surfaces is
a step in the right direction seems to be beyond doubt. Whether the theoretical framework being currently built will allow us to reach revolutionary
levels of understanding in the study of nature is, however, still an open question and, as in the case of any bet with nature, the outcome cannot be safely
predicted without first reaching the end of the investigative trail.

18

Appendix 1
Suppose to have a real function defined on a d-dimensional domain, for
example [0, 1]d . We divide the domain in N boxes of linear size l = 1/N 1/d .
In the codomain every box is expanded by a factor l because of the
self-anity of the function, with a roughness exponent . To cover this
volume we need /l l1 more box for each box in the domain. From
this we get that the total number of boxes is
N (l) N l1 = ld l1 = l1d
therefore the fractal dimension is df = d+1. Clearly assuming such a
relation is always true implies that the fractal is self-similar, not self-ane.
This demonstration in fact is true only in the limit of small l. For large
enough l, in fact, 1/l and the fractal dimension becomes df = d.

19

Appendix 2
As will be remembered, in the solution of the Edwards-Wilkinson equation
time and height must be scaled by the dynamic and roughness exponents
respectively:
h & b h
t & bz t
In the asymptotic limit we are interested in the behavior of functions
for t + and x +, which also implies b +. Keeping this in
mind we will show that the second order derivative of h(x, t) in t goes to
zero faster than the first order one, thus justifying the absence of this term
(known as inertial term) from the Edwards-Wilkinson equation.
Under the self-ane transformation the partial derivatives change in the
following way
h
h
& bz
t
t
2h
h
& b2z
2
t
t
In the asymptotic limit the second order derivative approaches zero faster
than the first order one by a factor bz , therefore for b + it is safe to
ignore the inertial term.

20

Appendix 3
Standard modules are imported, including the submodule matplotlib.animation
providing real-time frame-by-frame animations using the basic framework of
the matplotlib module.
import glob
import numpy as np
import time
from pylab import cm
from matplotlib import pyplot as plt
from matplotlib import colors
import matplotlib.animation as animation
Global variables for the system are initialized.
#initialize variables
L = 60
t = 1000
h_ceil = 100
h_max = 0
X = np.zeros((h_ceil,L), dtype=np.int)
H = np.zeros((L,),dtype=np.int)
The algorithm is implemented in the updating function of the simulation
frames. The function assesses nearest-neighbors and checks for the possibility of side-sticking.
fig = plt.figure()
ax1 = fig.add_subplot(1,1,1)
def updatefig(*args):
global x,H,X,h_max,h_ceil
x = np.random.random_integers(0,L-1)
if x > 0 and x < L-1:
nbhd = [H[x-1],H[x],H[x+1]]
elif x == L-1:
nbhd = [H[x-1],H[x]]
elif x == 0:
nbhd = [H[x],H[x+1]]
local_max = max(nbhd)
if H[x] == local_max:
H[x] = H[x] + 1
else:
H[x] = local_max
h_max = max(H)
21

X[h_ceil-H[x],x] = 1
return plt.imshow(X),
Finally the animation is called in the main body of the program and
frames are shown in real-time through the matplotlib viewer.
ani = animation.FuncAnimation(fig, updatefig, interval=10, blit=True)
plt.show()

22

Appendix 4
Standard libraries are imported, including the submodule matplotlib.animation,
which provides real-time simulations frame by frame.
import glob
import numpy as np
import time
from pylab import cm
from matplotlib import pyplot as plt
from matplotlib import colors
import matplotlib.animation as animation
Global variables for the system are introduced. Notice that the height
is stored as an array, indexed by the position of each column.
L = 50
t = 1000
h_ceil = 100
h_max = 0
X = np.zeros((h_ceil,L), dtype=np.int)
H = np.zeros((L,),dtype=np.int)
Finally the animation is implemented by defining the updating function
which contains the core of the system time evolution algorithm.
fig = plt.figure()
ax1 = fig.add_subplot(1,1,1)
def updatefig(*args):
global x,H,X,h_max,h_ceil
x = np.random.random_integers(0,L-1)
H[x] = H[x] + 1
h_max = max(H)
X[h_ceil-H[x],x] = 1
return plt.imshow(X),
ani = animation.FuncAnimation(fig, updatefig, interval=1, blit=True)
plt.show()

23

Appendix 5
Modules are imported
import glob
import numpy as np
import time
from pylab import cm
from matplotlib import pyplot as plt
from matplotlib import colors
import matplotlib.animation as animation
Global variables for the simulation are initialized.
L = 30
t = 1000
h_ceil = 80
h_max = 0
set_epsilon = 5
X = np.zeros((h_ceil,L), dtype=np.int)
H = np.zeros((L,),dtype=np.int)
fig = plt.figure()
ax1 = fig.add_subplot(1,1,1)
As usual, the basic algorithm is implemented in the updating function
for the animation. Local minima are first searched for, both on the left and
on the right of the falling particle. Their values are then compared and the
particle is moved to the column with local lowest-energy level. In case the
nearest neighbor columns have same height, one of them is picked randomly.
def updatefig(*args):
global x,H,X,h_max,h_ceil
x = np.random.random_integers(0,L-1)
l_epsilon = set_epsilon
r_epsilon = set_epsilon
#change epsilon to fit within length constraint
if (L-1-x) <= r_epsilon:
r_epsilon = L-x-1
if x <= l_epsilon:
l_epsilon = x
r_local_min = H[x]
r_local_min_x = x
l_local_min = H[x]
l_local_min_x = x
24

local_min_x = x
for i in range(x-1,x-l_epsilon-1,-1):
if H[i] < l_local_min:
l_local_min = H[i]
l_local_min_x = i
elif H[i] > l_local_min:
break
for j in range(x+1,x+r_epsilon+1):
if H[j] < r_local_min:
r_local_min = H[j]
r_local_min_x = j
elif H[j] > r_local_min:
break
toss = np.random.random_integers(0,1)
if l_local_min <= r_local_min:
local_min_x = l_local_min_x
elif l_local_min == r_local_min:
if toss == 0:
local_min_x = r_local_min_x
elif toss == 1:
local_min_x = l_local_min_x
else:
local_min_x = r_local_min_x
H[local_min_x] = H[local_min_x] + 1
h_max = max(H)
X[h_ceil-H[local_min_x],local_min_x] = 1
return plt.imshow(X),
Finally the animation is called in the main body program and the realtime evolution is printed on the screen, frame by frame.
ani = animation.FuncAnimation(fig, updatefig, interval=1, blit=True)
plt.show()

25

Bibliography
[1] B. Mandelbrot, The fractalist: Memoir of a Scientific Maverick, (Vintage, Reprint edition 2014).
[2] M. J. Vold, A numerical approach to the problem of sediment volume,
J. Coll. Sci. 14, 168-174 (1959)
[3] M. J. Vold, Sediment volume and structure in dispersions of anisotropic
particles, J. Phys. Chem. 63, 1608-1612 (1959)
[4] R. Baiod, D. Kessler, P. Ramanlal, L. Sander and R. Savit, Dynamical
scaling of the surface of finite-density ballistic aggregation, Phys. Rev. A
38, 3672-3678 (1988)
[5] B. Mandelbrot, The Fractal Geometry of Nature, (Freeman, San Francisco, 1982).
[6] J. D. Weeks and G. D. Gilmer, Dynamics of Crystal Growth, Adv.
Chem. Phys. 40, 157-228 (1979)
[7] F. Family, Scaling of rough surfaces: eects of surface diusion, J.
Phys. A 19, L441-L446 (1986)
[8] T. Hwa and M. Kadar, Avalanches, hydrodynamics and discharge
events in models of sandpiles, Phys. Rev. A 45, 7002-7001 (1992)
[9] S. F. Edwards and D. R. Wilkinson, The surface statistics of a granular aggregate, Proc. R. Soc. London A 381, 17-31 (1982)
[10] S. V. Buldyrev, A.-L. Goldberger, S. Havlin, C.-K. Peng and H.
E. Stanley, Fractals in biology and medicine: from DNA to the hearbeat,
in Fractals in Science, edited by A. Bunde and S. Havlin (Springer-Verlag,
Berlin, 1994)

26

Vous aimerez peut-être aussi