2021-10-18 14:37:10 +02:00
2021-10-18 14:32:00 +02:00
2021-10-18 14:37:10 +02:00
2021-10-18 14:32:00 +02:00
2021-10-18 11:56:38 +02:00

Diffusion module

This is the according repository to the diffusion module we discussed earlier. With this readme I will document all my steps I've done and will do.

Theory

  • $\alpha$ - diffusion coefficient (dependent on species and direction(?))
  • $h=1/M$ : with $M^2 = [0,1]^2$ - grid divided into parts between 0 and 1 (spatial step)
  • $k=T/N$ : with $N = [0,T]$ - time step size
  • coefficients of the given equation from the paper are:

    • $\alpha_xk/h^2$ in x direction
    • $\alpha_yk/h^2$ in y direction
    • $1+2*(\alpha_xk/h^2) + 2*(\alpha_xk/h^2)$ for the same grid cell with n+1 time step

So as a conclusion: We get a system of equations to solve for $u$. Maybe use LU-Decomposition here. It is easy to implement, deterministic and also performant. Since each $u_j$ is dependent on $u_{j-1}$ this will be hard to parallelize but I will keep parallelization in mind.

Regarding the borders: I'm not quite sure what to do. Maybe it might be a good idea to use a simple gaussian kernel here to smooth those two columns and two lines.

Implementation

So currently I consider to implement the following methods for the module:

  • decompose matrix A into L and U
  • better use a library like Eigen here:

    • using SparseMatrix to represent matrix $A$
    • SparseLU to solve
Description
No description provided
Readme GPL-2.0 6.5 MiB
Languages
Jupyter Notebook 47%
C++ 33.4%
R 10.8%
HTML 6.1%
CMake 1.3%
Other 1.4%