UFL-manipulation utilities#
Custom UFL operations for handling average operations on arguments.
TODO: Average operations on coefficients.
- class fenicsx_ii.ufl_operations.Average(u: Argument, restriction_operator, restriction_space)[source]#
Averaging operator.
- Parameters:
u – Argument to be averaged.
restriction_operator – Operator that restricts from the parent space to the averaged space.
restriction_space – Function space on the new mesh.
- class fenicsx_ii.ufl_operations.DomainReplacer(new_domain: Mesh, compress: bool | None = True, visited_cache: dict[tuple, Expr] | None = None, result_cache: dict[Expr, Expr] | None = None)[source]#
Replace domain in
ufl.SpatialCoordinateanddolfinx.fem.Constantwith a user provideddolfinx.mesh.Mesh.Note
The geometrical dimension of the new mesh must be the same as the original mesh.