Support for Real and Complex Numbers ------------------------------------ DOLFINX provides builds with both real and complex number support making use of PETSc with real or complex number support. python3-dolfinx will bring in python3-dolfinx-real (real number support) by default. Complex number support is provided by python3-dolfinx-complex. In the C++ components, libdolfinx-dev brings in libdolfinx-real-dev (real number support) by default. Complex number support is provided by libdolfinx-complex-dev. libdolfinx-real-dev provides dolfinx_real.pc for pkg-config. libdolfinx-complex-dev provides dolfinx_complex.pc. Both real and complex packages can be installed at the same time. If not otherwise specified, the selected version of dolfinx is the one built against the preferred version of PETSc in /usr/lib/petsc. By default this is petsc-real, but can be controlled by update-alternatives --config petsc The alternative build of DOLFINX can be accessed by setting PETSC_DIR as an environment variable where needed, e.g. PETSC_DIR=/usr/lib/petscdir/petsc-complex python3 -c "import dolfinx; print(dolfinx.__path__); print('supports complex numbers: ', dolfinx.has_petsc_complex)" Depending on your application, you might also need to set the SLEPC_DIR environment variable, e.g. SLEPC_DIR=/usr/lib/slepcdir/slepc-complex or SLEPC_DIR=$( echo $PETSC_DIR | sed "s/petsc/slepc/g" ) Conditional Support for SuperLU-Dist ------------------------------------ In principle dolfin supports SuperLU-Dist. However the superlu-dist package distributed by Debian is mostly useless since mc64, one of its core functions, cannot legally be redistributed and so has been removed from the Debian package. For this reason, we have given preference to mumps over superlu_dist. You may specify superlu_dist if desired (or if you have a local build of superlu_dist that includes mc64), for instance with solve(a == L, u, bc, solver_parameters={'linear_solver': 'superlu_dist'}) You may also successfully use superlu_dist without mc64 by specifying C++: PETScOptions::set("-mat_superlu_dist_rowperm", "NATURAL"); Python: PETScOptions.set('-mat_superlu_dist_rowperm', 'NATURAL') Performance will likely be reduced. The same problem applies to superlu, from which mc64 has also been removed. superlu still functions successfully however (mc64 is not core for the serial version of SuperLU).