H Field BCs for Nedelec Basis Functions

Hi,

How can I implement this boundary condition. I can implement Dirichlet, Neumann or Robin boundary conditions but for this condition but for this equation, I cannot use ufl.curl command, H is the Nedelec 1 vector basis function for my case. For example, I implemented n x E using this code:

u_D3 = fem.Function(V)
u_D3.x.array[:] = 0+0j
dofs_D3 = fem.locate_dofs_topological(V, fdim, facets3)
bcD3 = fem.dirichletbc(u_D3, dofs_D3)

However, for this problem, I cannot use ufl.curl command.

u_D3 = fem.Function(V)
u_D33= ufl.curl(u_D3)
u_D33.x.array[:] = 0+0j
dofs_D3 = fem.locate_dofs_topological(V, fdim, facets3)
bcD3 = fem.dirichletbc(u_D3, dofs_D3)``


 The error is: ---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
Cell In[24], line 6
      4 u_D3 = fem.Function(V)
      5 u_D33= ufl.curl(u_D3)
----> 6 u_D33.x.array[:] = 0+0j
      7 dofs_D3 = fem.locate_dofs_topological(V, fdim, facets3)
      8 bcD3 = fem.dirichletbc(u_D3, dofs_D3)

AttributeError: 'Curl' object has no attribute 'x'


How can I implement this BC for H  field BCs?

Thank you

Are you using a mixed formulation involving both E and H? Additionally, is this a time domain formulation? If so, it might be more complex.

We could provide more accurate assistance if you could share additional details about the problem, including the weak form before applying the boundary conditions.