dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #19714
Re: [Question #125426]: Dirichlet b.c. applied to components
Question #125426 on DOLFIN changed:
https://answers.launchpad.net/dolfin/+question/125426
Status: Open => Answered
Anders Logg proposed the following answer:
On Tue, Sep 14, 2010 at 08:01:18PM -0000, Joe Morris wrote:
> New question #125426 on DOLFIN:
> https://answers.launchpad.net/dolfin/+question/125426
>
> What is the preferred means for applying a Dirichlet b.c. to the components of a vector unknown (in order to implement free-slip or "roller" b.c.s).
>
> E.g.:
>
> u[0]=0 on x=0, but u[1], u[2] are free...
>
> Doing a search, I've seen discussion of free-slip b.c.s in the context of Unicorn. Separately, there are discussions of attempts to legislate u.n=0 in the form itself. Is there a means to do it with native dolfin using one of the BC classes? I "only" want to deal with the simple case I describe above, not the more general u.n=0 case.
>
> Thanks,
Just do
bc = DirichletBC(V.sub(0), 0, "x[0] == 0.0")
This will set the x-component to zero at x = 0.
--
Anders
--
You received this question notification because you are a member of
DOLFIN Team, which is an answer contact for DOLFIN.