ITADN

Shorthand for adding multiple fields to the dofhandler

#1275OpenKnutAM 创建于 2026-01-29
K
KnutAMcommented
Original suggestion here [#676](https://github.com/Ferrite-FEM/Ferrite.jl/issues/676#issuecomment-1514542497), with #872 we could have ```julia fields = (u = Lagrange{RefTriangle, 2}()^2, p = Lagrange{RefTriangle, 1}()) qr = QuadratureRule{RefTriangle}(2) ipg = geometric_interpolation(grid) dh = DofHandler(grid) add!(dh, fields) close!(dh) cmv = MultiFieldCellValues(qr, fields, ipg) ``` (And for convenience we could also support `dh = DofHandler(grid, fields)` which closes automatically which is nice for quick examples :))
1 条评论