Compumag TEAM Problem 13:
Given a current density $J$ in the coil and a (nonlinear) material law, compute the magnetic flux density $B$
Given a current density $J$ in the coil and a (nonlinear) material law, compute the magnetic flux density $B$
$\bullet$ Motivation
$\bullet$ Maxwell's equations for magnetostatics
$\bullet$ Vector potential formulation
$\bullet$ Scalar potential formulation
$\bullet$ A new "mixed" scalar potential formulation
$\bullet$ Outlook
Let $\Omega\subseteq\mathbb{R}^d$. Then Maxwell's equations for magnetostatics are
Nonlinear material law
Here $\textcolor{red}{f}$ and $\textcolor{blue}{g}$ are the energy and coenergy density functions.
Possible formulations
Vector potential formulation
Scalar potential formulation
Why use one over the other? Efficiency, accuracy, access to solvers, convenience $\ldots$
Derivation
Assumption: $\Omega$ is simply connected!
Weak formulation, assuming $n\times H = n\times f'(\curl A) = 0$ on $\partial\Omega$:
Find $A\in H^*(\curl,\Omega) = \{u\in L^2(\Omega)^3\;|\; \curl u\in L^2(\Omega)^3 \textcolor{red}{\text{ + gauging}}\}$ such that
Existence and uniqueness is guaranteed, if $f$ is smooth and strongly coercive with non-negative, bounded second derivatives.
Find $A\in H^*(\curl,\Omega)$ such that $(f'(\curl A), \curl v) = (J,v)$ for all $v\in H^*(\curl,\Omega)$.
Equivalent to the convex minimization problem
How do we solve the nonlinear problem?
Initialize with $A^0=0$. Newton step: $A^{n+1} = A^n + \alpha^n\; \delta A^n$, where $\delta A^n$ solves
Find $\delta A^n\in H^*(\curl,\Omega)$ such that
Here the relaxation step $\alpha^n$ is determined by Armijo backtracking.
The same holds on the discrete level, for any conforming subspace $V_h\subseteq H^*(\curl,\Omega)$
Number of iterations depends only on the nonlinearity $f$ (Felix' Talk Thursday, H3)
Derivation
Assumption: We have an $H_J$ such that $\curl H_J = J$.
Weak formulation, assuming $n\cdot B = n\cdot g'(H_J+\grad\psi) = 0$ on $\partial\Omega$:
Find $\psi\in H^1_*(\Omega) = \{u\in L^2(\Omega)\;|\; \grad u\in L^2(\Omega),\;\int_\Omega u = 0\}$ such that
Existence and uniqueness is guaranteed, if $g$ is smooth and strongly coercive with non-negative, bounded second derivatives.
Find $\psi\in H^1_*(\Omega)$ such that $(g'(H_J + \grad\psi), \grad v) = 0$ for all $v\in H^1_*(\Omega)$.
Equivalent to the convex minimization problem
How do we solve the nonlinear problem?
Initialize with $\psi^0=0$. Newton step: $\psi^{n+1} = \psi^n + \alpha^n\; \delta \psi^n$, where $\delta \psi^n$ solves
Find $\delta \psi^n\in H^1_*(\Omega)$ such that
Here the relaxation step $\alpha^n$ is determined by Armijo backtracking.
The same holds on the discrete level, for any conforming subspace $W_h\subseteq H^1_*(\Omega)$
Number of iterations depends only on the nonlinearity $g$ (Felix' Talk Thursday, H3)
Vector potential
$(f'(\curl A), \curl v) = (J,v)$
(Discrete) Newton step:
where $V_h \subseteq H^*(\curl,\Omega)$ Gauging!
Discrete spaces
$V_h = \N_k\cap H^*(\curl,\Omega)$ (Nedelec)
For $k=0$: #ne $\sim$ $6\cdot$ #np DOFs
Number of iterations
For our example: $\approx 20$
Scalar potential
$(g'(H_J + \grad\psi), \grad v) = 0$
(Discrete) Newton step:
where $W_h \subseteq H^1_*(\Omega)$
Discrete spaces
$W_h = P_{k+1} \cap H^1_*(\Omega)$
For $k=0$: #np DOFs
Number of iterations
For our example: $\approx 40$
Vector potential
Scalar potential
A lot more relaxation steps are necessary for the scalar potential formulation in comparison to the vector potential formulation!
The different number of iterations is a well documented fact:
- Kovács, Kuczmann (2011). Solution of the TEAM workshop problem No. 7 by the Finite Element Method
- Dular et. al. (2021). Finite-Element Formulations for Systems With High-Temperature Superconductors
Hypothesis: In general, for ferromagnetic materials, the coenergy-based formulations require more iteration steps than the energy-based formulations
Fact: Vector-potential formulation is more costly than the scalar-potential.
Question: Can we get the best of both worlds, i.e. having to solve small systems and have a low number of iterations?
Vector potential
Minimization problem
Scalar potential
Minimization problem
Mixed scalar potential
Direct derivation
Weak formulation, assuming $n\cdot B = 0$ on $\partial\Omega$:
Find $(B,\psi)\in L^2(\Omega)^3\times H^1_*(\Omega)$ such that
Find $(B_h,\psi_h)\in Q_h\times V_h \subseteq L^2(\Omega)^3\times H^1_*(\Omega)$ such that
Here $V_h = P_{k+1}\cap H^1_*(\Omega)$ and $Q_h = P_k^3\cap L^2(\Omega)^3$
Note : $\psi$ is approximated in the same space as for the scalar potential formulation.
Initialize with $(B_h^0,\psi_h^0)=0$. In each Newton step, solve for the update $(\delta B_h^n,\delta\psi_h^n)$
Find $(\delta B_h^n,\delta \psi_h^n)\in Q_h\times V_h$ such that
Number of iterations: about 20!
Problem : saddle point structure... how can we solve it efficiently?
Each Newton step has the form
Let us look at the system of equations in more detail...
Schur complement:
In the linear case, the matrices for the scalar potential and the new mixed formulation are the same! What makes the nonlinear case so different?
The Newton directions are different!
Scalar potential
Mixed Scalar potential
These are to be understood weakly.
While the Newton directions are different, they both converge to the same solution!
Slight overhead by having to invert $\ttA$ and "composing" the matrix $\ttB^\top\ttA^{-1}\ttB$
Vector potential
Mixed scalar potential
Scalar potential
We have proposed a new mixed scalar potential formulation
It has the same computational complexity as the standard scalar potential formulation
It has a similar number of iterations as the vector potential formulation
This result heavily depends on the "shape" of the nonlinearity. It holds for ferromagnetic materials, but not for superconductors.