varying Dirichlet BC on curved boundary
Hi,
I try to prescribe tangential velocity on the surface of the circle. The following representation invokes PETSC error:
u_bc=Expression
bc = DirichletBC(
Is there any other possibility to implement such type of bc?
Thanks!
# -------
from dolfin import *
mesh = UnitCircleMesh(10)
V = VectorFunctionS
P = FunctionSpace(
W = MixedFunctionSp
T = interpolate(
g = Function(
Ra = Constant(100.0)
eta = Constant(1.0)
def strain(v):
return 0.5*(grad(v) + grad(v).T)
def boun(x, on_boundary):
return on_boundary
u_bc=Expression
bc = DirichletBC(
(u, p) = TrialFunctions(W)
(v, q) = TestFunctions(W)
F = (2.0*eta*
a = lhs(F)
L = rhs(F)
res = Function(W)
solve(a=
u_,p_ = split(res)
plot(u_
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- DOLFIN Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Jan Domurath
- Solved:
- Last query:
- Last reply: