Commit 425e1732 by Jigyasa Watwani

working numerical solution, non-jumpy analytical solution

parents 67b71518 13251701
import dolfin as df
import numpy as np
import progressbar
import os
df.set_log_level(df.LogLevel.ERROR)
df.parameters['form_compiler']['optimize'] = True
class GrowthDiffusion(object):
def __init__(self, parameters, mDir=''):
# read in parameters
for key in parameters:
setattr(self, key, parameters[key])
self.mesh = df.Mesh(os.path.join(mDir, self.meshfile))
if __name__ == '__main__':
import json
assert os.path.isfile('parameters.json'), 'parameters.json file not found'
with open('parameters.json') as jsonFile:
params = json.load(jsonFile)
# parse parameters
assert params['growth'] in ('none', 'linear', 'exponential'), 'Unknown growth model'
gd = GrowthDiffusion(params)
\ No newline at end of file
\documentclass[11pt, reqno]{amsart}
\usepackage{amssymb, amsmath, datetime, xcolor, soul, graphicx}
\linespread{1.25}
\usepackage[colorlinks=true, citecolor=blue, urlcolor=blue]{hyperref}
% shortcuts
\newcommand{\vect}[1]{\boldsymbol{#1}}
\newcommand{\tens}[1]{\mathsf{#1}}
\newcommand{\uvec}[1]{\hat{\boldsymbol{#1}}}
\newcommand{\eqn}[1]{\begin{align}#1\end{align}}
\newcommand{\eq}[1]{\begin{align*}#1\end{align*}}
\begin{document}
\title{Diffusion on growing domains}
\date{\currenttime, \today}
\maketitle
Largely following \href{https://journals.plos.org/plosone/article?id=10.1371/journal.pone.0117949}{Exact Solutions of Linear Reaction-Diffusion Processes on a Uniformly Growing Domain: Criteria for Successful Colonization}, M J Simpson, PLoS One (2015).
\section{Kinematics}
We consider a linear reaction-diffusion process on a growing disk labelled by points $\vect{r} = (r, \varphi)$ with $0 < r < R(t)$ and $0 \leq \varphi < 2\pi$ where $R(t)$ is the increasing radius of the domain. Domain growth is associated with a \emph{radial} velocity field $\vect{v} = v(r,t) \, \uvec{r}$ which causes points on a circle of radius $r$ to move to a circle of radius $r + v(r,t) \, \tau $ in a short time $\tau$. By considering the expansion of an element of initial size $\Delta r$, we can derive an expression relating $R(t)$ and $v(r,t)$ which can be written as
\eqn{
\frac{dR(t)}{dt} = \int_0^{R(t)} \frac{\partial v}{\partial r} dr
.
\label{eq:growing_radius}
}
We consider uniform growth, i.e., $\partial_r v$ is independent of $r$ but potentially depends on time $t$, so that we have $\partial_r v = \sigma(t)$. Combining this with \eqref{eq:growing_radius} gives
\eqn{
\frac{\partial v}{\partial r} = \sigma(t) = \frac{1}{R(t)} \frac{dR(t)}{dt}.
\label{eq:growth_rate}
}
Assuming that the circular domain elongates with its center fixed, i.e., $v(0,t) = 0$, integrating \eqref{eq:growth_rate} gives
\eqn{
v(r,t) = \frac{r}{R(t)} \frac{dR(t)}{dt}.
}
\section{Mass conservation}
We now consider the conservation of a mass density $C(\vect{r}, t)$, assuming that it evolves according to a linear reaction-diffusion mechanism. The associated conservation statement on the growing domain can be written as
\eqn{
\partial_t C = D \nabla^2 C - \nabla \cdot (\vect{v} C) + k \, C,
\label{eq:general_reaction_diffusion}
}
where $D>0$ and $k$ are the diffusion constant and reaction rate respectively.
We assume azimuthal symmetry $C(\vect{r}, t) = C(r, t)$, i.e., the dynamics is independent of $\varphi$. Then
\eqn{
\frac{\partial C}{\partial t} = D \, \frac{1}{r^2} \, \frac{\partial}{\partial r} \left(r^2 \frac{\partial C}{\partial r} \right) - \frac{1}{r^2} \, \frac{\partial (r^2 v C)}{\partial r} + k \, C,
\label{eq:azimuthal_symmetry}
}
and impose zero diffusive flux conditions $\partial_r C = 0$ at $r=0$ and at $r=R(t)$. With some given initial conditions $C(r, 0)$ our aim is to find the exact solution of \eqref{eq:azimuthal_symmetry}.
\section{Exact solution}
We first transform the spatial variable to a fixed domain $\xi = \dfrac{r}{R(t)}$. Then
\eqn{
\frac{\partial C}{\partial t} =
}
\end{document}
\ No newline at end of file
{
"dimension" : 1,
"mesh" : 32,
"system_size_by_2PI" : 1 ,
"Dc" : 1.0,
"growth" : "none",
"growth_parameter" : 1.0,
"reaction_rate" : 1.0,
"timestep" : 0.01,
"savetime" : 0.1,
"maxtime" : 10.0
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment