- website: grausam
- script: https://people.math.ethz.ch/~grsam/NUMPDEFL/NUMPDE.pdf
- local copy: NUMPDE.pdf
- exercises: grausam/NPDEFL_Problems.pdf
- local copy: NPDEFL_Problems.pdf
- exercise repository: https://gitlab.math.ethz.ch/ralfh/NPDERepo
- community solutions: exams.vis.ethz.ch
- cpp reference: https://en.cppreference.com/
- lehrfm: GitHub / doxygen
- eigen documentation: https://eigen.tuxfamily.org/
- exam
- NumPDE midterm (@2026-04-17)
- chapter 1+2 (mainly)
- NumPDE endterm (@2026-05-29)
- chapter 9 (time-derivative)+12 (??)
- NumPDE midterm (@2026-04-17)
- practice classes:
remove pauses in videos:
pip install auto-editor auto-editor <video> --margin 0.2sec # if output is black, stream and audio channels are swapped. fix it (before runnign audio-editor): ffmpeg -i <video> -map 0:v -map 0:a -c copy <output>
- midterm: none
- endterm: probably none
Exercises
-> FS2026_tasks
Week 1 (16.02.-20.02.): 4 h 45 min
Week 2 (23.02.-27.02.): 6 h 45 min
-
- solution for h): 20260226_NumPDE_1.2)h)
Week 3 (02.03.-06.03.): 7 h 5 min
Week 4 (09.03.-13.03.): 5 h 45 min
Week 5 (16.03.-20.03.): 7 h 5 min
Week 6 (23.03.-27.03.): 5 h 50 min
Week 7 (30.03.-03.04.): 6 h 5 min
Week 8 (13.04.-17.04.): 4 h
Week 9 (20.04.-24.04.): 3 h 30 min
Week 10 (27.04.-01.05.): 4 h 10 min
Week 11 (04.05.-08.05.): 7 h 15 min
-
- this was the most challenging task till now. It takes way longer than 7.5 hours
Week 12 (11.05.-15.05.): 7h 10 min
-
- in
stokesminielement.h, dimension needs to be changed 9x9 -> 11x11 but is not mentioned in solution (error was extremely confusing) - in solution of 12-2)i), the norms for 12.2.27 and 12.2.28 are wrong? ask TA?
- in
13. week (18.05.-22.05.): 7 h 10 min
Videos
- week (16.02.-20.02.):
- week (23.02.-27.02.):
- week (02.03.-06.03):
- week (09.03.-13.03):
- week (16.03.-20.03):
- week (23.03.-27.03.):
- week (30.03.-03.04.):
- week (13.04.-17.04.):
- week (20.04.-24.04.):
- week (27.04.-01.05.):
- week (04.05.-08.05.):
- week (11.05.-15.05.):
- week (18.05.-22.05.):
- week (25.05.-29.05.): no videos
Q&A
#timestamp 2026-03-20
bilinear form is coercive
- continuity / boundedness:
- coercivity:
from this comes the Poincare inequality and uniform positive definite property
- (simplify strong form, then) convert to weak form
- choose suitable test function
- e.g.
- IBP (use Green's formula)
- Incorporate b.c. (if needed)
- for Dirichlet (essential) -> nothing to do
- choose suitable fct. space
- minimal suitable fct. space (often
) - here, we need at list one derivative for
#timestamp 2026-05-15
endterm
- chapter 9 will be about discretising Method of Lines (butcher tableau)
for forms: see https://www.math.ucla.edu/~tao/preprints/forms.pdf
Vorlesung
1. Second-Order Scalar Elliptic Boundary Value Problems
Video 1.2.1: Elastic Membranes
Goal: compute shape of string (1D)/membrane (2D) under vertical loading
The configuration space of a mathematical model is a set, each of whose elements completely describe all relevant aspects of a state of the modeled physical system.
- string must be continuous
string not ripped apart - b.c.: u(a),u(b) given



-> but need formula for potential energy

Video 1.2.2 Eloectrostatic Fields (6min)


Note:
The physical field will attain minimal electromagnetic field energy (1.2.2.16)
Video 1.2.3 Quadratic Minimization Problems (21 min)

A minimization problem
is called a quadratic minimization problem, if
extension to affine space:


Recall from LA:


we are trying to find the most stable/lowest energy state of the system. The idea is to find a general formula for the structurally similar string/membrane/electricity problem, which can be described by a Quadratic functional:
However, we can only solve the problem if the energy formula has a minimum (imagine the energy formula as a paraboloid "bowl"):

Thus, for
-> bilinear form must be at least semi-positive definite , where energy norm. -> linear form must be bounded/continuous with respect to energy norm. This ensures the "load" isn't so strong that it rips the system apart.
#todo add some integrals to the tldr
Video 1.3 Sobolev spaces (22 min)
have a bad reputation as having a useless mathematical sophistication

choose
=> energy space generated by


in contrast to

Sobolev space without boundary conditions:

the
If

Most concrete results about Sobolev spaces boil down to relationships between their norms. The spaces themselves remain intangible, but the norms are very concrete and can be computed and manipulated as demonstrated above.
- Do not be afraid of Sobolev spaces!
- It is only the norms that matter for us, the 'spaces' are irrelevant!
Under the assumptions of Thm. 1.3.4.23 we have for a continuous, piecewise smooth function
If
space - space of all functions where . Here, b.c. are meaningless, since changing the function at a single point costs zero energy space - "energy space" for membranes; includes functions where derivatives are square-integrable. Unlike , the b.c. cannot be ignored, since changing a point blows up the derivative -space - with zero b.c. - one can think of
as the space of peicewise smooth, globally continuous functions
- one can think of
Functions of an
Functions of the
Note that
Video 1.4 Linear Variational Problems (21 min)



Poincare-friedrich?

Video 1.5 Equilibrium Models: Boundary Value Problems (22 min)


=> 2-pt BVP (a Dirichlet problem) in strong form (vs. "weak form" = LVP)


If
then


Video 1.6 Diffusion Models: Stationary Heat Conduction (5 min)


by combining those two using Gauss theorem, we get:

=> we reach at the same PDE as for the membrane model
Video 1.7 Boundary Conditions (07.35 min)

example of a mixed BVP:

For second order elliptic boundary value problems exactly one boundary condition is needed on every part of
Video 1.8 Second-Order Elliptic Variational Problems (13 min)

for Dirichlet BVP:

for Radiation BVP:

for Neumann BVP:



If
Video 1.9 Essential and Natural Boundary Conditions (18 min)
summary of 1.4 - 1.9:





For a summary of this week, see the notes from the exercise session:
-> ETH_NumericalMethodsForPDE_Übungen#^75b794
2. Finite Element Methods (FEM)
Video 2.2 Principles of Galerkin Discretization (25 min)
graph LR A[Variational boundary
value problems] -- discretization --> B["System of a finite number of equations for (real) unknowns"]

garlekin discretization in two steps:
Replace the infinite-dimensional function space
-> "h"


- Choose basis, then plug basis expansions int DVP, and use (bi-linearity)


The choice of the basis


Properties all Garlekin matrices for a DVP (all matrices from a congruence clas) share:
- regularity (invertibility)
- symmetry
- pos.dev.

Video 2.3 Case Study: Linear FEMfor Two-Point Boundary Value Problems (24 min)
NOTE:

Idea underlying the finite element method: approximate



Video 2.4 Case Study: Triangular Linear FEMin Two Dimensions I (28 min)
- In 1D, we partition the domain
into an 1D Mesh - In 2D, we use triangulation

-
- means: no hanging nodes (nodes that are on the edge of another triangle)

set of edges
test space in 2 (space of M-p.w. linear continuous function on

tent function alternative in 2D:

In 2D, the Galerking matrix does not have a nice structure like in 1D; however, it is still sparse, since nodes unconnected by edges result in a 0 in the Matrix:

Video 2.4 Case Study: Triangular Linear FEMin Two Dimensions II (32 min)
Galerkin discretization based on a nodal basis of tent functions and a triangular mesh:


there are two approaches to creating the Galerkin-matrix:
- assemble matrix from all vertices

Problems:
- Edges not available in data structure (see first 2.4 video)
- Triangles adjacent to nodes not available
- cell-oriented approach, by "distribute & add"



dof: degrees of freedom

now, we assemble everything:

for the RHS, we can compute the integral using composite trapezoidal rule (we are working with triangles anyways):

We are trying to get variational problems from infinite-dimensional function spaces to something discrete by
- choosing a finite-dimensional subspace
, where the bilinear and linear form remain well-defined - choosing an ordered basis
for the subspace , and using the basis to convert problem into a linear system
In those two steps, the problem can be transformed into a LSE
In the first step of the discretization, our goal is to replace space
- define Mesh
. Normally, we use triangulation - pay attention that the mesh does not have "hanging nodes" (2.4.1) - choose a "building block" function to use for each cell. Normally, pecewise linear functions are used, evtl. quadratic or cubic polynomials
- ensure
-> do not use piecewise constants, since then , e.g. if
- incoroporate boundary conditions, in case of Dirichlet by discarding any basis functions with nodes on the boundary
4. choose a basis
- convert to a linear system by exploiting bilinearity of
and linearity of :
: Galerkin/stiffness matrix, , how basis functions interact through the bilinear form : load vector, : solution vector; the final Galerkin solution (basis, weighted by solution vector)
- no impact on Galerking solution; however:
- basis functions with small local support (e.g. tent function) results in a sparse matrix -> desired outcome
- basis choice determines condition number of matrix -> sensitivity to rounding errors
Video 2.5 Building Blocks of General Finite Element Methods (22 min)
meshes
2D: {cells, edges, nodes}=(mesh/geometric) entities
polynomials

1st option: e.g.
Space of tensor product polynomials of degree
2nd option: e.g.
basis functions (also called global shape functions (GSF), degrees of freedom)
Third main ingredient of FEM: locally supported basis functions (see Section 2.2 for role of bases in Galerkin discretization)
Basis functions
- (
) is basis of , - (
) each is associated with a single geometric entity (cell/edge/face/vertex) of , - (
) , if associated with cell/edge/face/vertex .
we want local support:
- if
, don't overlap, entries in Galerkin matrix => sparse matrix
generalization of barycentric coordinate functions:

Video 2.6 Lagrangian Finite Element Methods (23 min)

one triangle, with Kardinal property:

gluing triangles (interpolation nodes):

-> globally continuous piecewise function
for more dimensions, we "subdivide"; then, we might also have interpolation nodes inside the shape

for hybrid mesh:

works, becuase functions
works for any degree!
Video 2.7.2 Mesh Information and Mesh Data Structures (21 min)
problems with FEM:

// factory object creates mesg entities auto of 2D mesh data structure from information contained in mesh_file
auto factory = std::make_unique<lf::mesg::hybrid2d::MeshFactory>(2);
lf::io::GmshReader readermove(factory), mesh_file.string();
we need
- container (tranversal + ordering/indexing of entities)
- topology (incidence/adjecency)
- geometry (node locations, entity shapes)

mesh
- index access

- loops:
for(const lf::mesh::Entity &entity : mesh.Entitiy(codimension));
topology layer


access:

auto sub_entities_range = entity.SubEntities(sub_codimension);
for(const: lf::mesh::Entity &subentity : sub_entities_range)
mesh.Index(subentity);
geometry layer
- geometry object attached for every entity interface

const lf::geometry::Geometry *geo_ptr = entity.Geometry();
Eigen::MatrixXd corners = lf::geometry::Corners(*geo_ptr);
Video 2.7.4 Assembly Algorithms (26 min)
continuation of 2.4
assembly algorithms: building of FE Galerkin amtrix/r.h.s. vector from local contributions
we can split the integrals from the weak form into sums of local contributions (see exercise lession, week3, thu, hongg)



LehrFM numbering rules:



- dimension of Space
- Number of local Dofs (number of local shape functions)
- array of locglobmap for all local indices of entity
- number of local/global shape functions associatet with entity
- global indices of associated local shape functions of indices (not discussed until now)
- global index of entity associated with dof
Initalize dynamic Dof Handler:

for lagr. FE: uniform no of GSFs associated with entities of same type -> initalization can be simplified:
using dof_map_t = std::map<lf::base::RefEl, base::size_type>;
UniformFEDofHandler(std::shared_ptr<const lf::mesh::Mesh> mesh_p,
dof_map_t dofmap);
example:

distribute pattern used for assembly
- loops over entities +
DofHandlerqueries + local operation
not copied: code 2.7.4.23: Assembly function of LehrFEM++
Video 2.7.5 Local Computations (26 min)
either by analytic computation (only if we have polynomials -> locally constant functions on each cell of the mesh) or
analytic computation:
For any non-degenerate
e.g.

local quadrature
- in 1D: affine mapping
+ transformation formula for integrals - local quadrature rules used in finite element methods are botained by transformation from (a few) local quadrature rules defined on reference elements.
- in 2D:

(affine mapping maps lines to lines)
general formula:

example on

however, if

in LehrFEM, we can use:

A local quadrature rule according to Def. 2.7.5.9 is said to be order
- for a simplex
(triangle, tetrahedron) it is exact for all polynomials , - for a tensor product element
(rectangle, brick) it is exact for all tensor product polynomials .
"order
transformation on affine maps preserves polynomials
-> integral transformation doesn't change order of polynomials

quadrature rules in LehrFEM: reference object shape + desired order

not copied: code 2.7.5.41: Entity-based composite numerical quadrature
Video 2.7.6 Treatment of Essential Boundary Conditions (21 min)
#todo understand offset function:



maybe missed something relevant...

using LehrFM:

not copied code 2.7.6.17: Transformation function, which generates the block matrix from above
Problem:
Weak form:
- Boundary conditions: Dirichlet (essential)
// 1. Load Mesh and Setup DofHandler for Linear FE (1 DOF per node)
auto factory = std::make_unique<lf::mesh::hybrid2d::MeshFactory>(2);
lf::io::GmshReader readermove(factory), "mesh.msh";
auto mesh_p = reader.mesh();
lf::assemble::UniformFEDofHandler dofh(mesh_p, {{lf::base::RefEl::kPoint(), 1}});
// 2. Prepare Global System Containers (N x N)
lf::assemble::COOMatrix<double> A_triplets(dofh.NumDofs(), dofh.NumDofs());
Eigen::VectorXd rhs = Eigen::VectorXd::Zero(dofh.NumDofs());
// 3. Assemble Stiffness Matrix (using built-in Laplace Provider)
lf::uscalfe::LinearFELaplaceElementMatrix elmat_builder;
lf::assemble::AssembleMatrixLocally(0, dofh, dofh, elmat_builder, A_triplets);
// 4. Handle Dirichlet Boundary Conditions (Offset Function)
auto bd_flags = lf::mesh::utils::flagEntitiesOnBoundary(mesh_p, 2); // Flag nodes
auto selector = [&](unsigned int idx) -> std::pair<bool, double> {
auto node = dofh.Entity(idx);
return {bd_flags(*node), 0.0}; // Fix boundary nodes to 0.0
};
lf::assemble::FixFlaggedSolutionCompAlt(selector, A_triplets, rhs);
// 5. Solve
Eigen::SparseMatrix<double> A = A_triplets.makeSparse();
Eigen::SparseLU<Eigen::SparseMatrix<double>> solver(A);
if(solver.info() != Eigen::Success) abort();
Eigen::VectorXd solution = solver.solve(rhs);
- codim:
0->cells,1->edges,2->nodes COOMatrexavoids memory shifts during assemblyAssembleMatrixLocallyis templated -> works independent of test/trial space
Video 2.8 Parametric Finite Element Methods I (22 min)
remaining challenge: what to do with general mesh (curved edges, triangles + quadrilaterals)
Affine equivalence

affine pullback preserves polynomials:
If
general quadrilateral lagrangian FE
- so far: GSF -> LSF #todo: look this up again
- now: start from LSF
on reference element -> inverse pullback:
-> gluing: GSF
bilinear transformation: componentwise (tensor product) polynomial

gluing:
-> local shape functions are no longer bilinear, since
The local shape functions
Video2.8 Parametric Finite Element Methods II (27 min)

Note that possibility of gluing needs to be checked!
#todo: what are we doing here?
[...]


In order to define a
- a function realizing
, - and the evaluation
.
// interface in LF++:
size_type ScalarReferenceFiniteElement::NumRefShapeFunctions() const;
size_type ScalarReferenceFiniteElement::NumRefShapeFunctions(dim_t codim) const;
size_type ScalarReferenceFiniteElement::NumRefShapeFunctions(dim_t codim, sub_idx_t subidx) const;
Eigen::Matrix<SCALAR, Eigen::Dynamic, Eigen::Dynamic>
ScalarReferenceFiniteElement::EvalReferenceShapeFunctions(
const Eigen::MatrixXd& refcoords) const;
Eigen::Matrix<SCALAR, Eigen::Dynamic, Eigen::Dynamic>
ScalarReferenceFiniteElement::GradientsReferenceShapeFunctions(
const Eigen::MatrixXd& refcoords) const;
didn't copy code 2.8.3.29: Eval() method for parametric element matrix provider
Boundary Approximation by Parametric FEM:

"6-node triangle" in LehrFEM++:

Question: why is this better than simply splitting the curve into multiple triangles? The approximation wouldn't be much worse than by this approach.
Let
For Gradients,
#todo what is the difference between
| Notation | Name | Acts On | Direction |
|---|---|---|---|
| Mapping | Points (Coordinates) | ||
| Inverse Mapping | Points (Coordinates) | ||
| Pullback | Functions / Forms | ||
| Inverse Pullback | Functions / Forms |
3. FEM: Convergence and Accuracy
Video 3.1 Abstract Galerkin Error Estimates (20 min)
convergence (how fast does
Discretization error
Bound relevant norm of discretization error
A relevant norm:
- LVP
(energy function)
Let
and let Ass. 3.1.1.2–Ass. 3.1.1.4 be satisfied. Then, with
galerkin orthogonality:

from this follows Pythagoras theorem:


or shorter:
Under Ass. 3.1.1.2–Ass. 3.1.1.4 the energy norm of the Galerkin discretization error for (2.2.0.2) satisfies
-> Galerking solution is optimal (in energy)
- minimizes
over
-> As regards the energy norm, the Galerkin solution is the best possible solution we can obtain in a given trial space.
- Galerking error estimates in energy form approximation error estimates
- we can improve the result by enlarging the space (refinement)

- 2d triangular: regular refinement by splitting triangle into 4 congruent triangles
- use
lf::refinementin LF++
Video 3.2 Empirical (Asymptotic) Convergence of Lagrangian FEM (26 min)
Asymptotic Convergence
Crucial: our notion of convergence is asymptotic!
sequence of discrete models
created by variation of a discretization parameter.
Given a mesh
- limit
-> 0 - for p-refinement, discretication DP
degree p
cost might depend on dimension
algebraic and exponential convergence
(asymptotically for
- log-log plot with straigt line: algebraic convergence
- lin-log plor with line: exponential convergence
-> (integral) error norms can usually be computed only by numerical quadrature (/sampling) of sufficiently high order
Example:
- alg. cvg., but slow convergence for non-smooth solutions (h-refinement)
cvg. seems to be faster than -cvg (?)
- exp. cvg.(p-refinement)
-> there might be pre-asymptotic behaviour (no convergence until mesh fine / polynomial degree high)
| Feature | h-Refinement | p-Refinement |
|---|---|---|
| Strategy | Subdivide mesh cells ( |
Increase local polynomial degree ( |
| Typical Convergence | Algebraic: |
Exponential: |
| Limiting Factor | Polynomial degree |
Smoothness |
| Space Property | Often results in nested spaces (e.g., via regular refinement) | Inherently leads to nested finite element spaces |
Video 3.3 A Priori (Asymptotic) Finite Element Error Estimates I (10 min)
Foundation: Cea's lemma
a suitable "candidate function"
Note: For 2nd-order elliptic Dirichlet BVP:
-> algebraic cvg., rate 1
-> algebraic cvg. rate 2
-> algebraic cvg. rate 2
Video 3.3 A Priori (Asymptotic) Finite Element Error Estimates II (18 min)
- interpolation errors in order to bound the energy norm of the discretization error for lagrangian FEM
- still looking for piecewise linear FE, but now in 2D
The linear interpolation operator
uniquely fixes element of piecweise FE space

For a simplex
and the shape regularity measure of a simplicial mesh
is similarity-invariant (rotation, scaling, translation) - depends only on it's smallest angle
- expresses distortion compared to equilateral triangle
:

For any
-> alg. cvg. rate 2
-> alg. cvg. rate 1
where
#todo learn multi-index notation
The
Sobolev space
increasing regularity of functions
measures "ruggedness" of functions
The
rewriting error bounds using Sobolev norms, we get:
Under the assumptions/with notations of Thm. 3.3.2.21 (
Theorem answers:
"How many derivatives must a function have (in a weak, square-integrable sense) before we can guarantee it is actually a continuous, point-wise defined function?"
e.g.
Video 3.3 A Priori (Asymptotic) Finite Element Error Estimates III (16 min)
Let
- best approximation error
bounds for FE discretization error for 2nd-order elliptic BVPs (there: exact solution of BVP) in energy norm - "generic constant":
- actual value unknown
- dependence known
If we assume uniform shape-regularity and local quasi-uniformity of the mesh, then, from theorem 3.3.5.6 we get:
=> Algebraic convergence of discretization error with respect to N (DOFs), rate
- rate limited by
- polynomial degree
- smoothness
- polynomial degree
- rate deteriorates for larger
By what extra cost can we buy a certain improvement of the FEM solution? (3.3.5.23)
Assuming the a priori error estimate is sharp (the actual error follows the theoretical trend), the relationship between error reduction and computational cost is:
- The Goal (Gain): Reduce the discretization error (energy norm) by a factor of
. - The Price (Cost): Increase the number of unknowns (
) by a factor of:
- The Curse of Dimension (
): As the spatial dimension increases, the cost of reducing error grows exponentially. Accuracy is much "cheaper" in 1D than in 3D. - Optimal Efficiency (
): For best gain/cost, polynomial degree should match solution's smoothness ( ) - Smoothness Matters: For very smooth solutions (
is large), high-order elements ( ) reduce the required increase in significantly compared to linear elements ( ). - The "Slow" Limit: If the solution is not smooth (small
), increasing the polynomial degree does not help efficiency, because the cost factor will be stuck at regardless of how high you choose .
| type of refinement | alg. cvg. rate |
|---|---|
| h-refinement ( |
|
| h-refinement (low regularity of u: |
|
| p-refinement ( |
|
| p-refinement (perfectly smooth (analytic) solution) (because |
theorem doesn't work |
Here is a compressed summary of Unit 3.3 for your markdown callout, based on the course videos and documents:
- Cea's Lemma: energy norm of discretization
best approximation error of FE space - accuracy is governed by the mesh width (
), the polynomial degree ( ), and the Sobolev smoothness ( ) of the exact solution.
General
where the generic constant
Algebraic Convergence Trends (
- Curse of Dimension: Convergence speed deteriorates as the spatial dimension
increases. - Rate Limits: The rate is limited by either the polynomial degree
(for smooth solutions) or the solution's lack of regularity (for rough solutions).
Asymptotic Efficiency (Cost-Benefit): Reducing the error by a factor
#todo Learn more about Sobolev regularity (solution
Video 3.4 Elliptic Regularity Theory (11 min)
WHat is the Sobolev regularity of solutions of elliptic BVP?
If
In addition, for such
probably irrelevant:
Let
Then
with regular part
=> reentrant corners lead to very poor regularity
however, for convex problems, the dirichlet solution is in
If
Video 3.5 Variational Crimes (15 min)
"theory is incredibly difficult"
Variational crime: instead of solving exact discrete variational problem, we solve a perturbed one:
-> inevitable, since some functions are only given in procedural form
Variational crimes must not affect (type and rate) of asymptotic convergence
- Impact of Numerical Quadrature
Note: To show that QR is of order 2 -> show that it integrates polybomials of order 1 exactly (n-1) -> integrates
Finite element theory tells us that the above guideline can be met, if the local numerical quadrature rule has sufficiently high order. The quantitative results can be condensed into the following rules of thumb:
| Target Accuracy | Required Quadrature Order |
|---|---|
| Order |
|
| Order |
Example of crime: Using midpoint rule (order 2) for quadratic elements (
- Impact of boundary approximation
If
for quadratic FEM, use quadratic boundary approximation (see chapter 2)
Example of crime: When
Video 3.8 Validation and Debugging of Finite Element Codes (13 min)
-> if code converges mroe slowly than theory predicts, there is almost certainly a bug
3 main methods:
- observing convergence between mesh levels
test code by comparing solutions on a sequence of nested meshes created by regular refinement
- refine mesh ->
should shrink - norm of the difference,
should display the same algebraic convergence rate ( ) as the actual discretization error - shortcut: compare the difference of their norms (
), should also converge at rate
- method of manufactured solutions
most popular way to test a solver
- Step 1: Pick a simple domain and a smooth analytic function
to be your "exact solution". - Step 2: Use the strong form of the PDE to symbolically calculate what the source function
and boundary data must be to produce that solution . - Step 3: Run your solver with this "manufactured"
and and measure the error using overkill quadrature. - Debugging: Plot the error on a log-log scale. If the slope (rate) is wrong, simplify the problem—for example, set the reaction coefficient
to zero to see if the bug is in the stiffness matrix or the mass matrix.
- Direct Testing of Bilinear Forms
test specific parts of your code, e.g. Galerkin matrix for a specific boundary term
- Pick a smooth function
and compute the value of the bilinear form analytically using a tool like Mathematica.
-> difference between the analytical value and the discrete value should converge at the polynomial degree rateas the mesh is refined.
- Avoid polynomial solution: polynomial as manufactured solution will have 0 error -> no convergence rate
- Smothness matters: singularities in the solution can "foil" the fast convergence you expect to see
9. Second-Order Linear Evolution Problems
Video 9.2.1 Heat Equation (10 min)
- linear evolution: time-dependent / transient
- posed on space-time cylinder

9.2 Parabolic Initial-Boundary Value Problems
balance law:

using localization and fourier law, we get:
spatial b.c.:
(although the boundary conditions are now dependent from x and t)
initial conditions (temporal b.c.):
combined:
Video 9.2.2 Heat Equation: Spatial Variational Formulation (8 min)
Spatial variational form of (7.1.1.5)–(7.1.1.7): seek
abstract linear evolution problem:
- a, m are independent of time and s.p.d
- solution will depend linearly on f,
Video 9.2.3 Stability of Parabolic Evaolution Problems (10 min)
#todo sould I add solution of 1D heat equation?
#todo TA prioritized a different part of the viedo/chapter
reminder: Poincare-Friedrichs inequality:
For
where
Exponential decay of energy during parabolic evolution without excitation ("Parabolic evolutions dissipate energy")
Video 9.2.4 Spatial Semi-Discretization: Method of Lines (6 min)
-> spatial Galerkin discretization of 6.2.2.8 yields:
Combining (7.1.4.1) and (7.1.4.2) we obtain
with
- s.p.d. stiffness matrix
, (independent of time), - s.p.d. mass matrix
, (independent of time), - source (load) vector
, (time-dependent), coefficient vector of a projection of onto .
(7.1.4.4) is an ordinary differential equation (ODE) for
- but only semi-discretization, since
is still function of continuous time
=> MOL-ODE is semi-discrete
Video 9.2.7 Timestepping for Method-of-Lines ODE (30 min)
since s.p.d., can be invertedy -> use Cholesky-decomposition ( #todo what is that?)
Explicit Euler timestepping is not stable (exponential blow-up) in case of large timestep combined with fine mesh.
Let
where the "generic constants" (
-> timestep constraint:
diagonalization of RK-SSM (

Necessary condition for
The discrete evolution
RK-SSM for
with rational stability function
RK-SSM is unconditionally stable for MOL-ODE if
- evne desirable
for
A Runge-Kutta single-step method satisfying (7.1.7.45) is called
for all , and - "
" .

necessarily implicit
Video 9.2.8 Fully Discrete Method of Lines: Convergence (18 min)
- Heat Equation (Strong Form): transient heat equation on a space-time cylinder
, subject to initial and boundary conditions: - Spatial Variational Formulation: By treating time
as a passive parameter and applying integration by parts in the spatial domain, the PDE is converted to a weak form:
- Abstract Formulation: The weak form is generalized into an abstract parabolic evolution problem using the mass bilinear form
and the stiffness bilinear form :
- Method of Lines ODE: Applying Galerkin discretization in space (e.g., using finite elements) transforms the abstract evolution into a system of ordinary differential equations for the coefficient vector
:
where
5. Runge-Kutta Method (Full Discretization): Finally, the semi-discrete ODE is integrated in time using a single-step method (SSM). For parabolic problems, L-stable Runge-Kutta methods (such as Radau methods) are preferred to ensure stability:
resulting in a fully discrete scheme where the total error is the combined effect of spatial and temporal discretization.

Guideline: spatial and temporal resolution have to be adjusted in tandem
for a conditionally stable explicit method, we often have timestep constraint
-> if we reduce mesh for accuracy, we have to reduce the timestep more severly than accuarcy requires -> inefficiency "overkill constraint"
-> use unconditionally stable implicit methods instead
10. Modeling Fluid Flow
Video 10.1.1 Modeling Fluid Flow (7 min)
flow field
- needs to be at least Lipschitz-continuous
- if
-> no in/outflow -> streamlines exists for all times
streamline ODE
flow map
- where
solves IVP for streamline with - properties:
Video 10.1.2 Heat Convection and Diffusion (5 min)
=> linear scalar convection-diffusion equation for energy (CDE) (1.6.0.3) + (10.1.2.4):
Suitable boundary conditions fitting a PDE are determined by the highest-order term.
Here: diffusion term
Video 10.1.3 Incompressible Fluids (10 min)
A fluid flow is called incompressible, if the associated flow map
for all sufficiently small
mathematically:
Let
where
A stationary fluid flow in
scalar convection-diffusion equation for incompressible flow:
- where
Let
Video 10.1.4 Time-Dependent (Transient) Heat Flow in a Fluid (4 min)
new: time-dependent velocity field
- now, conservation of energy also contains change in time:
yields transient CDE:
for incompressible fluid
Video 10.2.1 Singular Perturbation (16 min)
linear variational problem (
not symmetric no energy norm continuous on , since bounded (2nd part of bilinear form vanishes) is positive definite
#todo maybe some notes on the derivation of notion?
use method of characteristics (MoC) to compute
A boundary value problem depending on parameter
For the pure transport problem
but not on its complement in

: Dirichlet b.c. can be imposed everywhere on : Dirichlet b.c. can be imposed only on
=> singular perturbation

On a closed streamline we cannot find a point
Video 10.2.2 Upwinding (13 min)
- singularly perturbed for
: Dirichlet b.c. can only be imposed on inflow boundary
#todo look at derivation of 10.2.2.2
for
(Linearly interpolated) discrete solution satisfies maximum principle (3.7.2.1).
- (3.7.2.8): positive diagonal entries,
, - (3.7.2.9): non-positive off-diagonal entries,
, - “(3.7.2.10)”: diagonal dominance,
.
- Goal:
-robust method (satisfaction of maximum principle) - Mechanism of Upwinding: use one-sided difference quotients in direction of velocity ("upwind" direction)
- In 1D: use backwards diff. quotient to satisfy algebraic sign conditions regardless of
(forwards diff. quotient only works for ) - 2D/3D: standard Galerking methods produces "terrible oscillation" -> upwinding needed
- In 1D: use backwards diff. quotient to satisfy algebraic sign conditions regardless of
"tradeoff between cvg. speed and accuracy ()"
Video 10.2.2.1 Upwind Quadrature (17 min)
different derivation of upwinding for 1D: apply global composite trapezoidal rule to 2nd term of convertcion-diffusion 2-pt BVP:

upwind quadrature rule approximates the convective bilinear form as a weighted sum over all mesh nodes
(Vertex Mass): This is the weight associated with node , representing the area of the node patch surrounding it. It is calculated as one-third of the sum of the areas of all triangles sharing vertex :
: The value of the test function at the node (which is if is the basis function and otherwise).
p.w. linear functions:
=> idea: use values from upstream triangle

The gradient value used in the quadrature is then defined by the limit:
using "tent function" basis
=> fulfills algebraic sign conditions =>
#todo not happy with this summary
Video 10.2.2.2 Streamline Diffusion (19 min)
upwinding =
problem:

enhancing diffusion
Since the solution is smooth along streamlines, then adding diffusion in the direction of streamlines cannot do much harm.
solution: anisotropic artificial diffusion in streamline direction
- on cell
replace:
local velocity (e.g., obtained by averaging) method parameter controlling the strength of anisotropic diffusion ( - dependent
This tampering affects the solution
- we want the original solution
still solves the stabilized VP -> consistent modification
A variational problem is called a consistent modification of another, if both possess the same (unique) solution(s): If
then, it should also solve modified LVP:
to satisfy this, we add a residual (term that vanishes for exact solution)
Choice of
- pros: sharp jump -> no smoothing (compared to upwind quadrature)
- pros: faster convergence than upwind quadrature (upwind quadrature sacrifices cvg.)
- cons: ("small") overshoots
- cons: violation of max principle
No
Video 10.3.1 Method of Lines (13 min)
Method of Lines (MOL) for transient convection-diffusion problems: "half-way" discretization strategy that converts a time-dependent partial differential equation (PDE) into a system of ordinary differential equations (ODEs) by first discretizing only the spatial variables:
transient convection-diffusion equation with Dirichlet boundary conditions:
- Spatial Discretization:
is treated as parameter, spatial domain is discretized (e.g., using finite elements on a fixed mesh) => system of ODEs for the time-dependent basis expansion coefficients
*
*
*
*
*
2. Temporal Discretization: solve ODE system using numerical integrator (timestepping method) to obtain a fully discrete solution.
robustness:
- spatial discretization: use
-robust discretization for convective term (e.g. upwind schema) - timestepping stability: use e.g. implicit euler/SDIRK-2
12. Finite Elements for the Stokes Equations
Video 12.1 Modeling the Flow of a Viscous Fluid (30 min)
(substantial modelling component in this chapter)
- thermodynamic perspective:
(incompressible)
- assumptions:
- small Reynolds number -> slow flows / small
/ sticky fluid - energy dissipation mainly/only occurs in eddies -> curl
- dissipation: kinetic energy -> heat
- small Reynolds number -> slow flows / small
- boundary conditions:
- no-slip:
on
- no-slip:
with these assumptions, we get the space:
balance between 2nd law of T.D. (entropy maximized) and 1st law of T.D. (conservation of energy):
converted to quadratic minimization problem:
#todo review questions
Video 12.2.1 The Stokes Equations: Constrained variational formulation (20 min)
For
where
using lemma 12.2.1.2 + divergence constraint (
on the space
- s.p.d.
(since all gradients of components vanish) - not decoupled (since
couples components of velocity field, unfortunately)
#todo review questions
Video 12.2.2 The Stokes Equations: Saddle Point Problem Formulation (55 min)
[AI] We want to solve a constrained minimization problem. We introduce a state space
Any solution

[AI] To find the saddle point, we evaluate the partial derivatives of
Setting the derivatives to zero yields a system of variational equations. If
...we get to the variational saddle point problem (SPP)
is the Lagrange multiplier / "pressusre" is also called "elliptic"
Seek the velocity field
[AI] Ensuring uniqueness of pressure: By Gauss' theorem,
If the following two conditions are satisfied,
(i) the bilinear form
(ii) the bilinear form
then the variational saddle point problem (12.2.2.50) possesses a unique solution
with

- LBB2
(trivial kernel) has full rank is regular - LBB1
is symmetric positive definite (elliptic) on the null space of the saddle point system matrix is invertible, giving a unique solution for and unique solution
Applied to stokes SPP:
where
and are Hilbert spaces, with norms and , respectively, and are continuous/bounded bilinear forms, and are continuous/bounded linear forms.
note: complex derivation using Theorem (12.2.2.38): existence of stable velocity potentials can be looked up in the script; however, we get:
The linear variational saddle point problem (12.2.2.19) ("Stokes problem") has a unique solution
Video 12.2.3 Stokes System of Partial Differential Equations (15 min)

For the solution
Stokes equation:
pressure poisson: If
-> cannot be solved, missing b.c. for
#todo review questions
12.3 Galerking Discretization of the Stokes Saddle Point Problem
Video 12.3.1 Pressure Instability (40 min)
applying galerking discretization to the problem from chapter 12.1/.2:
- Step 1 (space discretization)
DVP:
- Step 2 (choosing basis functions)
of , of - + expansion:
leads to saddle point LSE:
with matrix entries:
- Note that saddle point matrix is symmetric, but not s.p.d.
pressure instability
-> only if -> unique - only if
has trivial kernel, the solution is unique
- only if
- however, this is only a necessary (not sufficient!) condition -> we might get oscillations anyway (BAD NEWS)
Video 12.3.2 Stable Galerkin Discretization of Stokes Saddle Point Problem (30 min)
must be "large enough to fix the pressure"
#todo why, exactly?
example: by rising velocity field space
A pair of finite element spaces
where the constant
must be independent of !
- velocity component: unconditional stability
- pressure component:
The finite element spaces
inf-sup cond.:
-> #todo conclusion?
Video 12.3.3 Convergence of Stable FEM for Stokes (30 min)
abstract lax equivalence principle
using residual equation + assumption +
->
- Quasi-optimality:
independent of data, discretization parameters
If a discrete linear variational problem is stable according to Ass. 12.3.3.5, then Galerkin solutions are quasi-optimal.
which leads to:
If
with a constant
- Note: norm of velocity error also depends best-approx. error of pressure space
- slower convergence error matters more!
but we don't want a poor pressure space to affect the convergence of velocity solution:
A pair of finite element spaces
with
A pair of finite element spaces
If we assume this, from
we get:
and since this is a version of Galerkin orthogonality, (similar to proof for Cea's lemma)
-> optimality, if approximating function in discrite space of functions with vanishing div
-> however, no practical spaces have been found that satisfy this criterion -> currently useless
#todo review questions
Video 12.3.4 The Taylor-Hood Finite Element Method (15 min)
- stable FE are balanced, if convergence (#^12-3-3-13) has same order for smooth
- requirements for Stokes FEM:
- The pair
of finite element spaces must be stable ( Def. 12.3.2.7) - The velocity finite element space
should provide the same rate of algebraic convergence of the -best approximation error w.r.t. as the pressure space in . - The velocity finite element space
should guarantee 1 and 2 with as few degrees of freedom as possible.
-> 2. and 3. concern efficiency. A stable way to satisfy the requirements is the Taylor-Hood (PS-P1) finite element method for Stokes problem:
- a triangular/tetrahedral or rectangular/hexahedral mesh
of , which may even be hybrid, see Section 2.5.1, - the velocity space:
, and - the pressure space:
, which means a continuous pressure approximation.
and are a stable pair! - algebraic convergence, order 2 for
- velocity,
-norm - pressure,
-norm
- velocity,
Video 12.3.5 The Non-Conforming Crouzeix-Raviart FEM (40 min)
- non-conforming:
The Crouzeix-Raviart finite element space on a triangular mesh
- global shape functions:

- local shape functions (LSF)
associated with edges of triangle :

CR-P0 FEM for Stokes:

DVP: seek
- for all
. - derivatives restricted to cell
, since not known outside
- spaces are balanced (even optimal)
- stable, if:
With a constant
- Note: here, we refer to the broken
norm and bilinear form:
- for proof, see script #todo see script
- for proof, we use the edge average interpolation operator:
With a constant
intermediate result:
and remember:
#todo review questions
#todo tldr not useful
with a, b form:
13. Finite-Element Exterior Calculus (FEEC)
13.1 (Differential) Forms
Video 13.1.2 Fields and Integral Forms/Currents (28 min)
- Electric Field (
): Measured via work along directed paths Fundamental nature is a 1-form. - Magnetic Induction (
): Measured via flux through oriented surfaces Fundamental nature is a 2-form.
->
Orientation:

An (integral)
where
on domain

Notation:
| Field Type | Form Degree | Integrated Over... | Examples |
|---|---|---|---|
| Scalar Field | 0-form | Points | Temperature, Electric Potential |
| Circulation | 1-form | Curves | Electric Field ( |
| Flux | 2-form | Surfaces | Magnetic Induction ( |
| Density | 3-form | Volumes | Mass Density, Charge Density |
An integral
- Continuous: Small surface deformations lead to small changes in value.
- Additive:
for disjoint . - Orientation-reversing:
. - Dimension-consistent:
for surfaces with .
- Notation: as a duality pairing:
.
Video 13.1.3 Differential Forms (56 min)
we now go from global measurements of fields (integral forms) to local characterization:
can be regarded as a linear mapping from displacements into should be read as an anti-symmetric bilinear form
An alternating
which
- is linear in each of its
arguments, and which - changes sign, when any two arguments are swapped ("alternating").
when any two arg. vectors are the same
when args. are linearly depependent
it returns the signed volume of the parallelotope spanned by its arguments
Notation:
linear forms on - dimension formula: (
, is -subsets of a basis of )
Vector proxies: differential forms in
- 0-form
: Proxy is a scalar function . - 1-form
: Proxy is a vector field such that . - 2-form
: Proxy is a vector field such that . - 3-form
: Proxy is a scalar function such that .
Integration over manifolds: integral of a diff. form
Continuous differential
"For piecewise smooth forms to define a valid global integral form, they must agree on the tangent space of the interface
- 0-forms: Must be globally continuous.
- 1-forms: Must have tangential continuity (jump in
). - 2-forms: Must have normal continuity (jump in
). - 3-forms: No continuity required.
Video 13.1.4 Exterior Calculus (70 min)
pullbacks:

Given a
Using the notations of Def. 13.1.4.4, the pullback
which ensures compatibility with the pullback of integral forms.
Vector Proxy Formulas (in 3D):
- 0-forms:
(Standard function pullback). - 1-forms:
(Covariant transformation). - 2-forms:
(Piola transformation).
orientation of

Let
are defined as
where the boundary
fundamental identity
The exterior derivative of a continuously differentiable differential form
for all

For every domain
3D Vector Proxy Identifications:
(0-form 1-form). (1-form 2-form). (2-form 3-form).
For every domain
that is, the image of
Let
For a vector space
(
for all
Exterior Product
Let
For any domain
example from video: 20260513_NumPDE_video13.1.5_maxwell
Video 13.1.5 Sobolev Spaces of Differential Forms (18 min)
Let
Then we define the Hilbert space of square-integrable differential
For a domain
which becomes a Hilbert space with the basis-dependent norm
3. Vector Proxy Identifications (in 3D)
| Form Degree | Sobolev Space | Vector Analytic Proxy | Property |
|---|---|---|---|
| 0-form | |||
| 1-form | |||
| 2-form |

Let
Then
Practical 3D Continuity:
- 0-forms: Global continuity.
- 1-forms: Tangential continuity (
). - 2-forms: Normal continuity (
).
- coefficient functions
- intrinsic space (basis-independent), norm basis-dependent
Sobolev Space of "Finite Energy" Fields
- Norm:
. - The exterior derivative
is a bounded linear operator mapping .
Zero Boundary Conditions (
- forms with vanishing tangential trace on
- example:
(PEC boundary conditions for the electric field, 13.1.3.43)
13.2 Discrete Differential Forms
13.2.1 Cochain Calculus (67 min)
Introduce discrete integral
reminder: Integral form: assigns value -> oriented surface
Cochain ("discrete integral form") Assigns values to specific
-Cochain ( ): A mapping from the set of -facets of a mesh to .
in 3D:
| Cochain | assignes values to... |
|---|---|
| 0-cochain | nodes |
| 1-cochain | edges |
| 2-cochain | faces |
| 3-cochain | cells |
- Because there are a finite number of facets (
), an -cochain can be identified simply as a vector in .
A generalized oriented mesh
such that
: every -facet is an oriented (*), relatively open, bounded, -dimensional, non-degenerate -surface , - the facets form a partition of
:
- for every
, its boundary is the union of the closures of finitely many -facets:
- the intersection of the closures of any two
-facets is an -facet,
- for every
, there is a such that .
For cochain to define values consistently, the mesh must be oriented. Each facet has an intrinsic orientation (e.g., the direction of an edge). When we look at the boundary of a face, the face's orientation induces a direction on its edges.
Given
example:

Given a generalized oriented mesh
incidence matrix representation
- matrix representation of the discrete exterior derivative,

| Matrix | Calculus Proxy | Maps... |
|---|---|---|
| Discrete Gradient | Nodes |
|
| Discrete Curl | Edges |
|
| Discrete Divergence | Faces |
For any generalized mesh
- the boundary of a boundary is empty
Let
- (topological assumption:) every oriented, compact and closed
-dimensional sub-manifold of is the boundary of an -dimensional sub-manifold
then
Let the domain
| Category | Degree |
Degree |
Degree |
Degree |
|---|---|---|---|---|
| Physical Nature | Scalar Value | Circulation | Flux | Density |
| Mathematical Nature | Real Number | Linear Form (Functional) | Alternating Bilinear Form | Alternating Trilinear Form |
| Local Action |
Scalar value |
Maps 1 vector: |
Maps 2 vectors: |
Maps 3 vectors: |
| Integral Form ( |
Value at a point | Work along a curve | Flow through a surface | Amount in a volume |
| Differential Form ( |
Scalar function |
1-linear form (Linear functional) | Alternating 2-linear form | Alternating 3-linear form |
| Alternating Property | N/A | (Linear by default) | Swapping any two vectors flips the sign | |
| 3D Vector Proxy ( |
Scalar function |
Vector field |
Vector field |
Scalar function |
| Proxy Evaluation | Dot product: |
Cross product: |
Determinant: |
|
| Integration (Eq. 13.1.3.34) | Value at point |
Path integral: |
Flux integral: |
Volume integral: |
| Exterior Deriv. ( |
Gradient | Curl | Divergence | Zero ( |
| Sobolev Space | ||||
| Mesh Entity (Facet) | Node (Vertex) | Edge | Face | Cell |
| Cochain ( |
Values on nodes | Values on edges | Values on faces | Values on cells |
13.2.2 Whitney Forms (70 min)
Goal:
interpolation condition:
- Plaintext: goal is to turn cochain values into integral form that can be localized to a differential form
Local Whitney Forms (Basis Functions) On a simplex
: (Standard "tent" or P1 functions). : (Edge-associated basis). - Key Property: They satisfy the cardinal basis property:
.
general formula for d-simplex
The local interpolant of the exterior derivative of an
-> Whitney forms are not just any interpolant; they are structure-preserving
- taking the derivative of the reconstructed field is the same as reconstructing the field from the discrete derivative of the cochain
vector proxy formulas for the spaces spanned by local Whitney
| Degree ℓ | span{v. p.(βf,Kℓ)}f∈Fℓ(K) | Cochain coeff. |
|---|---|---|
Given an
as
with
- Continuity: Inherently satisfy the tangential continuity required for membership in
- Association: Each global basis function is associated with exactly one mesh facet (node, edge, or face) and is locally supported on adjacent cells.
- Boundary Conditions: W0ℓ(M) is spanned by basis forms associated only with interior facets.
We call the integral
the
given a simplicial mesh
as a finite-element subspace of the Sobolev space
Convergence
- reminder:if a finite-element space
locally contains all polynomials of degree , then, for "sufficiently smooth" , and on uniformly shape regular meshes with meshwidth ,
- here
, and thus algebraic cvg. of order 1
13.3 Whitney FEM for Computational Electromagnetism
13.3.1 Energies and Linear Material Laws (35 min)
Maxwells equations are underdetermined -> need "closure equations"
- We have two 1-forms (
) and two 2-forms ( ), plus the current . - Material Laws provide the required link: they map 1-forms to 2-forms.
Field energy functionals
- Electric Energy:
. - Magnetic Energy:
.
Both electric and magnetic field energies are homogeneous quadratic functionals, that is, there are bilinear forms
Moreover we expect
-> we want
3D: For local linear materials, the energy is the integral of a local quadratic form:
- Permittivity Tensor (
): . - Permeability Tensor (
): . - Nature:
and are symmetric positive definite matrices.
using the wedge product, we get weak formulation
- this is a bijection
inserting this, we get:
Combining the expressions from image_1e0f33.png and image_1e0f17.png for the electromagnetic energy balance, the relationship is given by:
13.3.2.1 Electromagnetic Wave Equations (45 min)
IBVP for EM fields:
- we have Maxwell's equations, Material Laws (weak form) and b.c.
In variational form:
- derivation: time differentiation, substitution of time derivatives with maxwell's equations, integration by parts
Seek
when we combine the terms, we get:
- compared to Poynting's theorem, power flux through
is missing because of the b.c. -> energy change is only caused by work of source current
use material law, differentiate in time, test with exterior derivative, 2nd term vanish (both for 1st and 2nd formula), (integration by parts), extract PDE:
#todo missed some derivations that seem interesting
We get to
Seek
for all
Which is a form we've already seen in chapter 9.2:
with function space
-> electromagnetic wave equations have a lot in common with scalar wave equations
- finite speed of propagation
- expands with at most max speed (for
):
- domain of influence and dependence
13.3.2.3 Method of lines for Electromagnetic Wave Equations, Timestepping for Semi-Discrete Electromagnetic Wave Equations (45 min)
we start from #^13-3-2-6:
Seek
and such that
method lines (MOL):
stage 1: spatial galerkin discretization
- Trial (& test spaces) -> fin.dim. subspaces independent of time
- For
use - For
use
- choose ordered bases
: use Whitney 1-forms : 3 basis 1-forms per cell, v.p.
MOL-ODE: Seek time-dependent basis expansion coefficient vectors
and such that
- preserves constraits
- continuity equation
- structure defines discrete Hamiltonian system -> reason why semi-descrete system (and Carank-Nicolson discretization, see later) conserve discrete
some other notes:
- Recall:
- Observe:
stage 2: timestepping -> see chapter 9.3.4 (which was not part of the course)
- temporal grid
, final time - Crank-Nicolson timestepping (RK-SSM/implicit midpoint SSM)
- replace time derivatives with diff. quotients, averages
- fully implicit method (have to calculate LSE for every timestep)
- discrete energy balance
- timestepping alternative: Leapfrog
- use staggered temporal grid

- use staggered temporal grid
- only partially implicit (but also only conditionally stable, not discussed in this video)
- you only need to solve linear systems for
separately
- you only need to solve linear systems for
- we cannot use Mass lumping, but not available for general for Whitney FE
boundary conditions:
- space
imposes Perfect Electrical Conductor (PEC) b.c.
13.3.3 Magnetostatic
13.3.3.1 Magnetostatics: Formulations Based on Scalar Potentials (30 min)
static settings: fields do not depend on time,
- built-in constraints are no longer automatically enforced by reduced Maxwell's equations, need additional demands:
Magnetostatic BVP:
weak MLs:
two ways to convert to variational form:
- Formulations based on Scalar Potential
We assume that the assumptions of Thm. 13.1.4.81 on
- Every oriented closed 2-surface
is the boundary of a sub-domain . - Every closed directed curve in
is the boundary of an oriented surface .
and we get (after some transformations, i.b.p.):
Seek
For local, linear ML, v.p.,
now, we can replace
- seek
in
- option 2 for conversion to variational form not explained
13.3.3.2 Magnetostatics: Vector-Potential-Based Variational Formulations (40 min)
LLML & vector proxy formulation:
with b.c. hidden in formulation
#todo didn't understand this part
minute 13: great explanation of Lagrange multiplier
Augmented LSE :
applied to our variational form:
Seek
- notice that
or LLML, vector proxy notation:
Seek
for all
Galerking discretization
- choose f.d. subspaces -> Whitney FE spaces
- also add vanishing mean constraint
Seek
, , and such that for all
, .
- ordered bases (whitney 1/O-forms)
with
dummy unknowns
13.3.3.3-13.3.3.4 Saddle-Point Variational Problems, Discrete LBB-Conditions for a-Based Magnetostatics (60 min)
start: #^13-3-3-28 Is a saddle point variational problem
we define the kernel of
In Euclidean setting, we get a saddle point LSE:

- checking #^LBB conditions:
- LBB2:
- LBB2:
- LBB1:
- LBB2:
Galerkin discretization:
- step 1
- LBB2 in discrete setting
- Discrete LBB conditions
Let the assumptions of Thm. 12.2.2.23 be satisfied. Also assume discrete counterparts of (LBB1) and (LBB2), namely the discrete LBB-conditions
then the discrete variational saddle point problem (12.2.2.49) possesses a unique solution
where
- ellipticity on kernel of
- in-sup condiction
-> existence, uniqueness, stability of solution + quasi-optimality
- quasi-optimality:
- step 2 of Galerkin discretization:
ordered bases
note, that for our problem, while LBB2 always holds, LBB1 only holds if we assume simple topology (#^simple-topology), which we can prove using
Under Ass. 13.3.3.7 and with a constant
Taking for granted Ass. 13.3.3.7 (#^simple-topology) we have
with a constant
since LBB1 & LBB2 holds, we get quasi-optimality (for uniformly shape regular families of meshes)
Provided that
holds true for uniformly shape regular families of simplicial meshes
algebraic cvg with rate 1!
comparing the two different discretizations:
#todo
Formatting
We're converting image into markdown + latex formulas. For normal text, normal markdown. For boxes, use callouts. The format of callouts is the following:
> [!name] <title>
> content
Note that there is no empty line between the callout header and the content!
- orange boxes: convert to !intermediate
- lemmas, theorems (yellow): convert to !lemma, !theorem
- definitions (red): convert to !definition
For inline latex, the format is the following:
For one-line latex, the format is the following:
- note the newlines in between
$$and the content - for latex blocks in callouts, please do not write newlines: if possible, the whole latex block should be on one line
For multiline latex, the format is the following:
Highlighted text can be highlighted in markdown, too: highlight. This is not standard commonmark, but if you see highlighted text in the image, highlight it when converting, too. Same for bold: if a text is emphasised, make it bold.
- Note that highlighting can only be used for markdown, not for latex
- If something cannot be converted to pure markdown, warn me instead of attempting to use non-standard syntax.
- For this task, you may omit any custom formats specified earlier.
- Your answer should consist solely of the markdown (and the warning if something cannot be converted). No follow-up suggestions, questions, clarifications.
- for colors in latex, use
\textcolor{color}{content}instead of\color{color}{content} - whenever possible (i.e. for latex blocks (not inline)), use
\tag{...}to write the number