← Back to team overview

ufl team mailing list archive

Dirichlet boundary conditions

 

Should we include Dirichlet conditions in UFL ? 

It could be done with the notion of traces: 

g = Function(...)
u = TrialFunction(...)
T = FacetTrace(...)

T*u = g 

meaning that u = g on the boundary. 
One could also have T(i) for the trace
on subdomain i. 

I think it also could be put into the UFC assembly loop in a nice way, 

assembly(...){

  ...

  assembleCells(...);
  
  assembleExteriorFacets(...);

  assembleInteriorFacets(...);

  enforceTraces(...);

}


The bad thing is that it affects both the right and left hand side so
that the matrix and the right hand side need to be assembled at the same
time (or one could make a very sparse matrix that resemble applying the
constraints). 

Kent




Follow ups