Skip to content

Incorrect Jacobian indexing in Nedelec DOF basis transformation #1221

@Ady0333

Description

@Ady0333

Describtion

In TransformNedelecDofBasis.evaluate! (src/FESpaces/CurlConformingFESpaces.jl), the Jacobian array Jtx is indexed using the local loop index p instead of the global node index from dofs.face_nodes[face].

Current code:

F = transpose(Jtx[p])

But p is only a local index on the face, while Jtx is indexed globally over all DOF quadrature points in the cell.

For faces beyond the first, this ends up using the Jacobian from a wrong quadrature point during the Piola transform of the DOF moments.


Expected behavior

The Jacobian should be accessed using the corresponding global node index:

F = transpose(Jtx[face_point_ids[p]])

Impact

This affects H(curl) (Nedelec) elements on non-affine meshes (e.g. quads/hexes or curved geometries), where the Jacobian varies within the cell.

It can lead to incorrect DOF basis transformation and wrong assembled system matrices without any runtime error.


Affected File

src/FESpaces/CurlConformingFESpaces.jl

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions