Electromagnetic waveguide port boundary condition

Hello all.
As a followup to the work presented at FEniCS 2026, I have finished the first version of a somewhat detailed description of the waveguide boundary condition implementation using DolfinX 0.9. It can be found here.. The code I used to verify the method is on Github.

What I would like to do is improve the waveguide mode generation procedure. In the present verification of the method, I used analytic functions that describe the electromagnetic mode profiles, since the empty waveguide example is a very simple structure. To handle more complicated waveguide structures (like multiple microstrip or coplanar waveguides), I need to numerically generate the port waveguide modes using a 2D EM solver. I need to generate 2D submeshes over the waveguide ports in the 3D structure where I solve for waveguide modes.

As I see it, I need to:

  • Install newer version of DolfinX (11 as suggested at FEniCS 2026 meeting)
  • Learn to generate submeshes over 2D port surfaces
  • Solve for propagating modes in ports
  • Apply port BCs to 3D model using modes generated by 2D model on submeshes
  • Solve full 3D model

First things first - a question: Is there a Spack installation for version 11 of DolfinX? (Spack is my preferred installation method.)

Yes, there is a 0.11.0.post0 release of py-fenics-dolfinx on spack: Spack Packages

Hi! Sorry for the long delay, but I have finally got around to trying the version 11 install. I used the following line in Spack

spack add py-fenics-dolfinx@0.11.0.post0 +slepc4py

and Spack tells me it cannot find the package.

==> Error: No version exists that satisfies these input specs:
    py-fenics-dolfinx@0.11.0.post0+slepc4py

When I do not use the version designation, Spack defaults to version 0.9.0. How do I specify version 11 in the spack “add” line?
Another question:
When slepc is enabled, this automatically adds PETSc as a dependency? I see that there is a conflict between +petsc and +slepc flags. I would like to handle both eigenvalue and driven problems.

This is the allowed setup for DOLFINx:

Please try updating your spack install:

spack repo update
spack info py-fenics-dolfinx

should then list 0.11 as an option that you can add.

Thanks! That worked! Everything compiled without a hitch.

>>> import dolfinx
>>> print(dolfinx.__version__)
0.11.0.post0