| Start page of documentation | Download the code | Documentation: PDF, PS |
| Previous: Discretisation in a rectangle | Next: Additional equations for jumps |
The points where the 5-point stencil is cut by the interface are called irregular points. There, the approximation (2) has to be corrected by adding so called correction terms. They can be written for each of the appearing derivatives in (1) separately.
Consider a situation like in figure above and
let
be the coordinates of the
intersection point
and
: coordinates of the
intersection point
.
Let
,
,
,
. Then, the
corrected differences of second order derivatives are
In general, jump in
the mixed derivative is not used in expressions
(3-6) and
jumps in
-derivatives are not used at
-intersections, as well as
jumps in
-derivatives are not used in
-intersections.
All jumps are stored in one supervector
(see
ASSEMBLE/run_ejiim.m, variable J) with ordering
With this, approximation of the differential operator
in domain
can be written as
Matrix
, in code stored in variable P is constructed
of two parts
Each of
and
is constructed as
sum
Note: Matrix
depends only on the differential operator and
geometry. No dependence on boundary conditions!
Construction of the matrix
is done in function
DIFFOP/corrections.m.
The interface information is stored in the structure variable IX, see
Section 3 for details.
Constructing of
matrix
Idea: run a loop over all intersection points and check, which grid points are affected.
We know that
derivative is affected only
by
-type intersections, so the matrix
has zeros in the right block, corresponding to
-type
intersection points.
In a loop over all
-intersections:
Construction of
is done completely analogously,
only now zeros are in the left block of
and loop
has to be done over all intersections.
In the actual version of the code, the EJIIM system is solved
by Matlab `
'-operator. For larger problems, especially
three dimensional, the Schur-complement approach together with
some fast solver for inverting the operator
is highly
suggested [3,1,2].
| Previous: Discretisation in a rectangle | Next: Additional equations for jumps |