I’m currently working on a 3D eddy current problem regarding a conducting cube in homogenous magnetic field in the time domain. While doing this some questions arose about the correct implementation of non-homogeneous Dirichlet boundary conditions.

with the entries in the list being the different surfaces (1: bottom, 2: top, 3: left, 4: right, 5: front, 6: back). Drawing these onto the mesh shows in the GUI that the values are set to the correct surfaces.

Even though there is a lot of well written documentation I don’t fully understand how to mark the boundaries correctly as the keyword BND tells Set that the CoefficientFunction need only be interpolated at the marked boundaries.
Note the attached code. Any help is very much appreciated as I’m pretty new to FEM-Simulation in general.

thanks again for your super fast help. Unfortunately I still have a problem with my current test case for Eddy currents.

To slim the overall problem I’m currently tryin to solve a simple test case for a pure homogenous magnetic field. Here I’m using [tex]A = \left(
\begin{array}{c}
y\
-x\
0\
\end{array}
\right)[/tex]
for my Dirichlet boundary conditions. Unfortunately that doesn’t result the correct magnetic field.

I also found some examples for Eddy current problems (pretty much the same problem) from your User-Meeting 2019. Sadly I currently can’t completely comprehend why these boundary conditions have been used.

I attached the volume and the code again. I’m sure there is just a small mistake about the implementation. Maybe someone knows where the problem is.

EDIT: Could solve it myself will be marked as resolved!