ufl team mailing list archive
-
ufl team
-
Mailing list archive
-
Message #00192
Re: Dirichlet boundary conditions
If we should add notation for boundary conditions to UFL, then I think
it must also be supported through the UFC interface so that the
assembler may assemble the correct matrix/vector directly (without
zeroing out entries in a separate step).
Regarding the notation, maybe it should be a constraint on the
function spaces. Take for example Poisson with u = g on the boundary:
Find u in H^1_g : a(v, u) = L(v) for all v in H^1_0
The boundary conditions are part of the test and trial spaces
(subscripts g and 0 on H^1). We could do something like
V = FunctionSpace("Lagrange", "triangle", 1) # test space
W = FunctionSpace("Lagrange", "triangle", 1) # trial space
V.restrict(g)
W.restrict(0)
a = dot(grad(v), grad(u))*dx
L = v*f*dx
--
Anders
Attachment:
signature.asc
Description: Digital signature
Follow ups
References