18 Solutions of the one-dimensional diffusion equation Flashcards

1
Q

The one-dimensional diffusion equation

A

∂p(x, t)/∂t = D(∂^2p(x, t)/∂x^2)

where D is the diffusivity or diffusion coefficient/constant

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

solving the one-dimensional diffusion eq on R line

A

A solution is
N(x, t) = (4πDt)^{− 1/2} *
exp(−[(x − x_0)^2]/[4Dt]).

bell curve, max not at 0, can positive for some neg x values

whatever value of x_0 we choose, the solution that satisfies
integral from -inf to inf of N(x,t) .dx = 1 is as above

peak at x_0

we need this to be able to interpret function N as probability density

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

checking the solution of the one-dimensional diffusion eq on R line

A

using N(x,t)
∂N/∂x = -x/2Dt (N)
∂²N/∂x² = -(1/2Dt)
N + (-x/2Dt)(-x/2Dt)N
= (-1/2Dt)
N + (x²/4D²t²)*N

(treat t as constant)

∂N/∂t =[2piD/((4piDt)^(3/2))]exp(-x^2/4Dt)+1/(4piDt)^0.5exp(-x²/4Dt)
=-(1/2t)N +N(x²/4Dt²)

issue is that i can’t have t=0
on denominator width of the curve =t

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

The Fourier transform

A

helps to describe the motion in more than one way.
We can solve the diffusion equation on x ∈ IR by a Fourier
transform.
We take our function in terms of x and t
multiply by exp(isx)
and integrate wrt x

F(N) = N˜(s, t)
= (1/√2π) ∫_[-∞,∞] of
N(x, t)e^{isx} dx.

Linear solution multiplied still satisfies the linear ODE, we transformed using that particular constant we want to think of it as a pdf

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

We think of the function N(x, t) at at time t as being
decomposed into Fourier components in x

A

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

“What is the fourier transform of the derivative of the function”

solving in Fourier space
transform the initial conditions

A

F(∂N/∂t) = -isN~

F(∂²N∂t²) = -s²N~

∂N~/∂t =-Ds~N~
N~(s,t)= N~(s,0)exp(-Ds²t)

N~(s,0)= (1/√2π) ∫_[-∞,∞] of
N(x, 0)e^{isx} dx.

for every s (each value of x treated seperately)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

inverse fourier transform

A

we start of thinking in x,t would like it back in x and t

N(x,t) = (1/√2π) ∫_[-∞,∞] of
N~(x, t)e^{-isx} dx.
(negative in exp)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

inverse fourier transform of 2 products

A

f

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

inverse fourier transform of
(e^{−s/2Dt})

A

f

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

approx bell shape with

A

sin functions
approx

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

I= ∫_[-∞,∞] of exp(-x²).dx integrate

A

I² = ∫[-∞,∞] of exp(-x²).dx * ∫[-∞,∞] of exp(-y²).dy

= ∫[-∞,∞] ∫[-∞,∞] exp(-y²) exp(-x²).dx.dy

x=rcosθ y=rsinθ
x²+y² = r² dxdy=r dθdr

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

18.3 L5 (The diffusion equation on the semi-infinite line and the method
of images)

A

the diffusion equation on the semi-infinite line

subject to
absorbing (Dirichlet) and reflecting (Neumann)

BCs at one end of the semi-infinite line. The
other boundary condition simply requires the density to vanish at the other end of the semiinfinite line (e.g. x → −∞)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Consider the diffusion equation which gives solutions to be considered as a sum of N’s
N_1 +N_2 +… etc

A

for each N we could choose a different x_0
this would give rise to a series of bell curves all translated, e.g. their x_0 giving the peaks differ

you would also have to change the prefactor so that the sum of integrals from -inf to inf =1 to interpret as a pdf HOWEVER

(linear partial differential equation)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

L5: Brownian motion in one dimension absorbed at 0

condition?

A

Suppose that particles are absorbed whenever they reach zero.
Then the probability density, which we now denote pₖ(x, t), still obeys the diffusion equation when x > 0, but
with the extra condition

pₖ(0, t) = 0 ∀t

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

L5: Brownian motion in one dimension absorbed at 0

solution

A

The solution is now
pₖ(x, t)
= (4πDt)^{− 1/2} *
[
exp(−[(x − x₀)²]/[4Dt]).
-
exp(-(x+x₀)²/4Dt)]

the difference of two terms
one gaussian shape centred at x₀
subtract
gaussian shape centred at -x₀

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

L5: Brownian motion in one dimension absorbed at 0

pdf

A

density pₖ(x, t) is
defined for x ≥ 0
(not valid for negative values of x)
brownian walker wanders for large values of x,
if gets to 0 then absorbs
property:
pₖ(0, t) = 0 ∀t

curve that follows the subtraction of two bell curves (one upside down)
is the difference of two Gaussian density functions, one centred at x₀ at the other at −x₀.

however now we dont have the condition of intgeral =1 as brownian walkers get absorbed, so if they are absorbed we have less and less and probability integrates to <1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

L5: Brownian motion in one dimension absorbed at 0

pₖ(x, t)
= (4πDt)^{− 1/2} *
[
exp(−[(x − x₀)^2]/[4Dt]).
-
exp(-(x+x₀)²/4Dt)]
also written

A

pₖ(x, t)
= (4πDt)^{− 1/2} *

exp(−[(x − x₀)^2]/[4Dt])*
[1- exp(-(x*x₀)/Dt)]

written otherwise
as

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

L5: Brownian motion in one dimension absorbed at 0
**
obtaining solution**

pₖ(x, t)
= (4πDt)^{− 1/2} *
[
exp(−[(x − x₀)^2]/[4Dt]).
-
exp(-(x+x₀)²/4Dt)]
also written alt how?

A

(x+x₀)² = x²+2xx₀ +x₀²
=x²-2xx₀ +x₀² +4xx₀
=(x − x₀)² + 4xx₀

(x+x₀)² /4Dt = (x − x₀)²/4Dt + xx₀/Dt

exp(-(x+x₀)² /4Dt )

= exp(-(x − x₀)²/4Dt - xx₀/Dt)
= exp(-(x − x₀)²/4Dt) *exp( xx₀/Dt))

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

L5: Brownian motion in one dimension absorbed at 0

pdf written alternatively

A

(considering the “blue dashed curve now”)
to get this pdf we can see we have multiplied the standard pdf for gaussian shifted to the x_0
by [1- exp(-(x*x₀)/Dt)]

We are modelling brownian walkers starting somewhere, if they can wander back and forth but get absorbed i must have reduced the density so i am reducing by this factor which is between 0 and 1 (1-exp(something))

(pₖ(x, t)
= (4πDt)^{− 1/2} *

exp(−[(x − x₀)^2]/[4Dt])*
[1- exp(-(x*x₀)/Dt)])

22
Q

L5: Brownian motion in one dimension absorbed at 0

the conditional probability

A

To obtain pk(x, t) from the density without absorption, we may multiply by the probability of not having reached 0 before t,
conditioned on being at x at time t, which is
by [1- exp(-(x*x₀)/Dt)]

the conditional probability of having hit 0 given that the Brownian walker started at x_0 and ends at x

23
Q

Brownian motion or the Wiener process
mini- summary
L5

A

continuous time process
stochastic process in continuous space and
time is standard Brownian motion

The position at time t is the random variable denoted Wₜ

It is a Markov process with the property that, no matter how small ∆t is,
W_{t+∆t} − Wₜ
has a Gaussian distribution with mean zero and variance ∆t, and is independent of the value of Wₜ

If f(x, t) is the probability density function of Wt then
∂f/∂t =(1/2)∂²f/∂x²

24
Q

The probability density for unconditioned
Brownian motion at b − x is

A

f(x,t) =
(1/2πt)⁻¹/² exp(-(b-x)²/2t)

proability that I hit a target that is b away starting at 0
x_0=0

unconditioned brownian motion

25
The probability density Brownian motion at b − x, conditioned on having hit b is
f(x,t) = (1/2πt)⁻¹/² exp(-(b-x)²/2t) * exp(-bx/t) conditioned version
26
Thus... probability that W_s > b at some time s between 0 and t, given that W_0 = 0 and W_t = b − x, is
P[**H**₆< t| Wₜ=b-x] = exp(-bx/t)
27
L5: Brownian motion in one dimension absorbed at 0 passage time def
First passage time to b H_b = inf{t>0: Wₜ=b} its a RV defined as the first time the Brownian walker reaches b
28
L5: Brownian motion in one dimension absorbed at 0 passage time derivation
P[H_b b] (at some point reach level b, equally likely to go up and down) = 2P[H_bb] (proability that i reach b, is twice the probability that i reach b and i'm greater than b) I started at 0, i ended up greater than b so now: im greater than b =2P[W_t >b] = (2/πt)¹/² ∫_[b,∞] exp(-y²/2t) .dy we know how to find this as its general with D=1/2 =1-erf(b/(2t^0.5))
29
L5: Brownian motion in one dimension absorbed at 0 passage time derivation function
R(t) = d/dt( P[**H**_b
30
Exit from an interval
τ_a = inf{t : Wₜ = a}, first passage time to a τ_b = inf{t : Wₜ= b}, first passage time to b τ = min(τa, τb). We will study probability that i hit b before a p(x) = P[τ_b < τ_a] T(x) be the mean value of the exit time: T(x) = E(τ ). the mean time it takes to hit either a or b and these will only dep on x_0
31
l5: brownian motion in 1D ∂p(x, t)/∂t = D(∂^2p(x, t)/∂x^2) boundary conditions mixed meaning: dP/dx=0 when x=0 for all t p(L,t)=0 for all t (in exam might ask this using slightly different notation)
diagram: space LINE from 0 to L moving between 2 walls stick to one bounce off the other dP/dx=0 when x=0 for all t (reflecting) p(L,t)=0 for all t (absorbing)
32
boundary conditions mixed meaning: might ask exam question p(x,t) =F(x)G(t) in the diffusion equ gives what
as d/dt(p) = D d²/dx²(p) gives F(x)dG/dt = DG (d²F/dx²) (1/GD) dG/dt = F''/F (1/D)(G.)/G = F''/F = -λ G. here dG/dt
33
boundary conditions mixed meaning: might ask exam question p(x,t) =F(x)G(t) in the diffusion equ gives (1/D)(G.)/G = F''/F solve this
The question might not say "do seperation of variables in this way, you will have to choose" we get (1/D)(G.)/G = F''/F = -λ G. here dG/dt (1/D)(dG/dt)/G = (dF/dx)/F =-λ a constant as usual Gₙ(t) = Gₙ(0)* exp(-Dλₙt) (sol should be second nature to you now: we have constant equal to two differential equations. multiple λₙ for which in each case i get G. =-λₙGD which gives this sol) (we have the second derivative of a function=-λₙ*function itself F''= -λₙF for the spacial function we have cos and sin, ensuring λₙ is positive) General form F_n(x) = aₙ sin( √λₙx) + bₙcos(√λₙx) (we know this is the form as
34
(we have the second derivative of a function=-λₙ*function itself F''= -λₙF for the spacial function we have cos and sin, ensuring λₙ is positive) general form of sol
General form F_n(x) = aₙ sin( √λₙx) + bₙcos(√λₙx)
35
generl form of sol for Gₙ(t) = Gₙ(0)* exp(-Dλₙt)
Gₙ(t) = Gₙ(0)* exp(-Dλₙt) (sol should be second nature to you now: we have constant equal to two differential equations. multiple λₙ for which in each case i get G. =-λₙGD which gives this sol)
36
boundary conditions mixed meaning: might ask exam question p(x,t) =F(x)G(t) in the diffusion equ gives (1/D)(G.)/G = F''/F solve this using boundary conditions dP/dx=0 when x=0 for all time t p(L,t)=0 for all t final solution
Gₙ(t) = Gₙ(0)* exp(-Dλₙt) Fₙ(x) = aₙ sin( √λₙx) + bₙcos(√λₙx) **Gₙ(t)F'ₙ(0) =0 for all t** F'ₙ(0) =0 for all t F'ₙ(x) = aₙ √{λₙ}cos(√λₙ x) - bₙ√{λₙ}sin(√λₙ x) so F'ₙ(0)= aₙ √{λₙ} =0 means only way to have this is **aₙ =0** **pₙ(L,t)=Fₙ(L)Gₙ(t)=0 for all t** Fₙ(L)=0 for all t Fₙ(L)= aₙ sin( √{λₙ} L) + bₙcos(√{λₙ} L) =0 means bₙcos(√{λₙL}) =0 √{λₙ}L = π/2, 3π/2, 5π/2,.... √{λₙ = (π/L) (2n+1)/2 n=0, 1,2,3,... so final solution p(x,t) = Σ_[n=0, ∞] bₙcos[ (π/L) (n+0.5)x]* exp(-D (π/L)² (n+0.5)²t) diagram: decrease part of cos graph to x=L
37
calculate b_n "could be asked in an exam" in general" e.g. so final solution p(x,t) = Σ_[n=0, ∞] bₙcos[ (π/L) (n+0.5)x]* exp(-D (π/L)² (n+0.5)²t)
general formula bₙ =(2/L) ∫₀ ᴸ p(x,0) cos((πx/L) ( n+0.5)) similar to inverse fourier transform but b_n comes from the initial density and initial density can be written as a sum of cos and sin. if we take the product and integrate over the domain [0,L] Delta function as I either get 0 if i have the same factor or i get L/2 if i dont thus p(x,0)=δ(x-x_0)
38
ch 18 continued example... if p(x,0)=δ(x-x_0) b_n what does it dep on?
if my initial condition says tht the brownian walker is definitely at x₀ then we write the initial state is a delta function at x₀ and b_n = (2/L) cos((πx₀/L) ( n+0.5)) b_n is a constant- doesnt dep on x doesnt dep on t- solution for eq not involving t but does dep on L: length of domain initial position x₀ also affects
39
example conditioned: b_n question
For where we have the sum p(x,t) = Σ_[n=0, ∞] bₙcos[ (π/L) (n+0.5)x]* exp(-D (π/L)² (n+0.5)²t) is b_n "absorbed G_n(0)" x=0 t=0 p(0,0)= G_n(0)F(0) = Σ_[n=0, ∞] bₙ = G_n(0) * bₙ yes, Gₙ(t)= Gₙ(0)* exp(-Dλₙt) if Gₙ(0) = 1 then then you will have all the constants in a_n and the b_n
40
continued example L5 ch18 general formula bₙ =(2/L) ∫₀ ᴸ p(x,0) cos((πx/L) ( n+0.5)) p(x,t) = Σ_[n=0, ∞] bₙcos[ (π/L) (n+0.5)x]* exp(-D (π/L)² (n+0.5)²t) if i now take CosAcosB = 0.5(cos(A+b)+ cos(A-B))
rewrite Σ_[n=0, ∞] bₙcos[ (π/L) (n+0.5)x]* exp(-D (π/L)² (n+0.5)²t) using that it is a product of cos (b_n is cos) x-x_0 and x+x_0 but here on finite domain you can write any funct as a sum of cos and sin
41
The diffusion equation on the semi-infinite line and the method of images (MATH5566M extra topic) . . recap
we continue this. Diffusion on [0, ∞) with absorbing/reflecting BC and one initial point ‘source’ differences with the bounded case highlighted: We can interpret diffusion on this semi infinite line with one absorbing or one reflecting at 0 and assuming we have an initial point source(idea that one point where mass is initially concentrated, positive) we interpret this as: Diffusion on IR with two initial sources/sinks (one is a fictitious ‘image’ of the other) (
42
The diffusion equation on the semi-infinite line and the method of images (MATH5566M Consider the fundamental solution for the diffusion in IR (with initial condition as a point density ‘source’ centered in x₀
p(x, 0) = p₀(x) = δ(x − x₀) The fundamental solution (centered in x0) is p⁽¹⁾(x, t; x₀) = (1/√{4Dπt}) exp{−(x−x₀)²/4Dt) ⁽¹⁾ as 1D **THIS IS A NORMAL DISTRUBITION** shape of fundamental sol: -------0---------x₀----------------- initial source at x₀ concentrated mass. Diffusion occurs and guassian shape appears with variance proportional to the time (this is the shape of the fundamental solution with the dirac delta for the initial condition in 1D) p(x,t)
43
The diffusion equation on the semi-infinite line and the method of images (MATH5566M considering the fundamental solution for the diffusion in IR (with initial condition as a point density ‘source’ centered in x₀ FOR AN ABSOBING BOUNDARY AT 0 what is it?
BC s p(0,t)=0 (absorbing BC) p(x, 0) = p₀(x) = δ(x − x₀) (point source) The fundamental solution (centered in x0) is p⁽¹⁾(x, t; x₀) = (1/√{4Dπt}) exp{−(x−x₀)²/4Dt)
44
Diffusion in [0,∞) with absorbing boundary model and BCs
∂p(x, t)/∂t = D∂²p(x, t)/∂x² x ∈ [0, ∞), t ≥ 0 p(0, t) = 0 (absorbing boundary) p(x, 0) = δ(x − x0) (point source (Dirac delta) in x₀) The solution is p(x, t) =(1/√{4Dπt}) (exp{−(x−x₀)²/4Dt) - exp{−(x+x₀)²/4Dt)) (minus the reflected) =p⁽¹⁾(x, t; x₀) - p⁽¹⁾(x, t; -x₀)
45
interpreting: The solution is p(x, t) =(1/√{4Dπt}) (exp{−(x−x₀)²/4Dt) - exp{−(x+x₀)²/4Dt)) =p⁽¹⁾(x, t; x₀) - p⁽¹⁾(x, t; -x₀) why is it that? consider initial gaussian distribution at source
consider shape of fundamental sol: -------0---------x₀----------------- initial source at x₀ concentrated mass. Diffusion occurs and guassian shape appears with variance proportional to the time consider the symmetrical point: mirror image of curve at -x₀ normal distribution negative but centred at -x₀ (mirrored in x-axis) sum of these shape: at 0 then have opposite signs so sum of these is 0 at x₀ sum of these is slghtly lower than original peak, but will follow general shape graph follows a lower shape than original now both of these were sols of the PDE and as the PDE is linear we can sum these and this wills till satisfy the PDE r at x0. Difference of two fundamental solutions in IR: one centered in x0 and one centred in −x0. Positive sign: ‘source’ Negative sign: ‘sink’ we check the sum still satisfies PDE and BCs: YES
46
consider the symmetrical point: mirror image of curve at -x₀ normal distribution negative but centred at -x₀ does the sum satisfy the BCs?
Difference of two fundamental solutions in IR: one centered in x0 and one centred in −x0. Positive sign: ‘source’ Negative sign: ‘sink’ ∂p(x, t)/∂t = D∂²p(x, t)/∂x² x ∈ [0, ∞), t ≥ 0 p(0, t) = 0 (absorbing boundary) by construction satisfied p(x, 0) = δ(x − x0) (point source (Dirac delta) in x₀) at t=0 δ(x − x0) + δ(x + x0) = {infinite at x0 {infinite at -x0 {0 elsewhere we only consider positive values of x>0 so 0 on here as required
47
Difference of two fundamental solutions in IR: one centered in x0 and one centred in −x0. Positive sign: ‘source’ Negative sign: ‘sink’
Positive sign: ‘source’ if we start with a dirac delta that is +ve source of individuals spreading out Negative sign: ‘sink’ dirac delta -ve if we start with a solution that is negative a sink attracts individuals and thus population disappears, negative contribution to population due to negative sign
48
L5: Diffusion in [0,∞) with reflecting boundary at 0 give the BCs and problem
Consider now the diffusion problem in [0, ∞) ∂p(x, t)/∂t = D∂²p(x, t)/∂x² x ∈ [0, ∞), t ≥ 0 ∂p(0, t)/∂x = 0 (reflecting boundary) p(x, 0) = δ(x − x0) (point source (Dirac delta) in x0)
49
L5: Diffusion in [0,∞) with reflecting boundary at 0 give the BCs and problem Consider now the diffusion problem in [0, ∞) ∂p(x, t)/∂t = D∂²p(x, t)/∂x² x ∈ [0, ∞), t ≥ 0 ∂p/∂x(0, t) = 0 (reflecting boundary) p(x, 0) = δ(x − x0) (point source (Dirac delta) in x0) SOLUTION
p(x, t) =(1/√{4Dπt}) (exp{−(x−x₀)²/4Dt) **+** exp{−(x+x₀)²/4Dt)) (minus the reflected) =p⁽¹⁾(x, t; x₀) + p⁽¹⁾(x, t; -x₀) we could solve again using assuming seperation and superposition etc gone through:... G(t)∝exp(-λDt) F(x)= a sin({√λ}x) + bcos({√λ}x) BC: absorbing F(0)=0 family of sines b=0 F(x)= a sin({√λ}x) with a second BC we can fix λ but we dont have one in this case: any λ works(taking care with sign>0) superposition principle instead with an integral for an positive real value of λ all poss values ∫ over [0, ∞] final solution p(x,t) = ∫ a(λ) sin({√λ}x)exp(-λDt) .dλ coeff a dep onλ : a(λ) (aₙ in prev) and is fixed by initial condition gives from orthogonal family of sin a(λ)= (2/π) ∫_[0, ∞] [ p₀(x) sin({√λ}x).dx for every value of λ sol for semi infinite:
50
method for diffusion eq solving for reflecting absorbing boundaries
p(x,t) =F(x)G(t) (1/D) G(t)/G*(t) = F''(x)/F(x)=- λ λ>0 G(t)∝exp(-λDt) space function: F''(x)= - λF(x) gives F(x)= a sin({√λ}x) + bcos({√λ}x) a and b are determined by BC absorbing or reflecting with a second BC we can fix λ superposition principle used as sum from n=0, ... for all values of λ if lambda based on n discrete values if λ any real superposition uses integrals
51
L5: Diffusion in [0,∞) with reflecting boundary at 0 give the BCs and problem Consider now the diffusion problem in [0, ∞) ∂p(x, t)/∂t = D∂²p(x, t)/∂x² x ∈ [0, ∞), t ≥ 0 ∂p/∂x(0, t) = 0 (reflecting boundary) p(x, 0) = δ(x − x0) (point source (Dirac delta) in x0) SOLUTION EXPLAINED p(x, t) =(1/√{4Dπt}) (exp{−(x−x₀)²/4Dt) **+** exp{−(x+x₀)²/4Dt)) (minus the reflected) =p⁽¹⁾(x, t; x₀) + p⁽¹⁾(x, t; -x₀)
consider again a mirror image: consider the fundamental solution on the Real line : gaussian distribution centred at x0 we impose a reflecting boundary at 0: mirror image but with opposite derivative: mirror image wrt to y-axis instead centred at -x0 same value at 0 but different derivatives: actually opposite signs and thus derivative of sum is 0 which is what we require sum of two gaussian distributions with positive sign so both are SOURCES checking BCS
52