Can fenics handle plasma coupled equations?

I am not even sure if I should have sent this topic to the Slack Community instead.
As a complete neophyte in FEniCS, I would like to know if it can solve the following problem before I spend more time in learning how to use it.
I have 3 coupled PDEs over 2 contiguous domains, one air and the other solid. More specifically, a Poisson equation and two continuity equations.
One continuity equation solves for the ion density n1 and the other for n2. Both ions only exist in the air domain.
Denoting the potential by V, ion mobilities by a1, a2 and ion diffusion coefficients by D1 and D2,
the flux F1 for n1 is a1 * grad V * n1 + D1 grad n1
the flux F2 for n2 is a2 * grad V * n2 + D2 grad n2
The source term for both continuity equations is
alpha * |F1| - r * n1 * n2
where alpha is an ionization coefficient and r is a constant recombination coefficient.
a1, a2,alpha are functions of the electric field = -gradV and that they are obtained from interpolation of tabulated values.
The space charge density for the Poisson equation is e*(n1+n2) where e is the electric charge.
The Poisson equation reduces to a Laplace equation in the solid as there is no net charge in it.
Denote the surface charge density at the air/solid interface by S and the permittivity of a medium by c, there are 3 boundary condition at that interface. The first is
(cgrad V)|air side - (cgrad V)|solid side = S
where
dS/dt = e*(F1+F2)
Denoting the unit vector normal to the interface and comma (.) for the dot product. we finally have (always at the same interface)
F1.n= (a1gradV|air side + f1)n1+g(F2.n)
F2.n= (a2
gradV|air side + f2)*n1
where f1, f2 and g are given constants.

(In reality, I have 3 ions and the solid is small and surrounded by air from all sides so that I set the electric field and fluxes to 0 at infinity. I also apply a known time dependent voltage for part of the the air solid interface and inside the solid there is a ground with a given width. Nevertheless, it is sufficient to simplify the problem to the above description)

See https://multiphenics.github.io/

Furthermore, in future please use \LaTeX when typing the mathematical expressions, because your post, as it is written now, is almost unreadable.

Thank you for the hint. I will look into multiphenics. However, I don’t know LaTeX so that it will take me so time to learn how to use it. In the meantime, as a picture is worth a 1000 words, I am uploading a very clear freehand description of my problem (sorry, but you will have to find a way to stop the .webp animation as you don’t support the .html format).

[REMOVED BY ADMINISTRATOR]

See, e.g., Learn LaTeX in 30 minutes - Overleaf, Online LaTeX Editor

or more specifically for communication of mathematics concepts: Mathematical expressions - Overleaf, Online LaTeX Editor

E.g. $a + b = c$ yields a + b = c.

and

$$
a + b = c
$$

gives

a + b = c

Why not just upload two pngs of the individual pages?

I’


m only allowed one per post which means I have to sent 3 consecutive png’s
here is the first

now the second

and finally the last one !

The closest tutorial I have is tutorial_lagrange_multipliers_interface

1 Like

Actually, the boundary condition for the electric field on the air solid interface is a discontinuous version of the Poisson equation. Using Green’s identity, the weak form will implicitly contain it with a term involving the surface charge density. There is no need to invoke Lagrange multiplier in this case. And the boundary conditions for flux on that interface can be seen from the above equations to be a Robin condition. Dolfinx takes care of those as well as non linear equations. But can it solve 4 PDES simultaneously, namely the Poisson and the 3 ion continuity equations ?

Forget about the lagrange multiplier, and read that example as a way to have two equations in different subdomains, which seems to be your case.