I need to apply boundary condition after reading data from .txt file. Any clue, how can I apply?
from dolfin import *
import matplotlib.pyplot as plt
from dolfin import *
mesh = UniSquareMesh(10,10)
V = VectorFunctionSpace(mesh, "Lagrange", 1)
left = CompiledSubDomain("near(x[1], side) && on_boundary", side = 0.0)
right = CompiledSubDomain("near(x[1], side) && on_boundary", side = 1.0)
# read data from txt to apply BC on right (tt)
bcl = DirichletBC(V, Constant((0,0)), left)
bcr = DirichletBC(V.sub(1), tt, right, method = 'pointwise')
Hi, I have tried applying the same logic to my problem but getting some error while assigning to ux in the loop (AttributeError: ‘function’ object has no attribute ‘setValueLocal’): Please find MWC