I try to test a MBB beam problem. It is a linear elastic problem in a rectangle domain. And I try to choose different Young's modulus to get the maximum displacement of each problem. However the maximum displacement seems to be the same whatever the young's modulus is. Could you please help me. I really confused. THANKS
""" MBB beam. Impose zero displacement at the centers of the left and the right side, and a point load on the middle of the top."""
from dolfin import *
Create mesh and define function space
mesh = RectangleMesh(0.0,0.0,4.0,1.0,160,40)
V = VectorFunctionSpace(mesh, "Lagrange", 1)
Mark boundary subdomians
boundary_parts = MeshFunction('size_t', mesh, mesh.topology().dim()-1)
boundary_parts.set_all(0)
class LeftBoundary(SubDomain):
def inside(self, x, on_boundary):
tol = 1E-14 # tolerance for coordinate comparisons
return abs(x[0]) < tol and abs(x[1]-0.5) < tol
Gamma_L = LeftBoundary()
class RightBoundary(SubDomain):
def inside(self, x, on_boundary):
tol = 1E-14 # tolerance for coordinate comparisons
return abs(x[0]-4) < tol and abs(x[1]-0.5) < tol
Gamma_R = RightBoundary()
class PointLoad(SubDomain):
def inside(self, x, on_boundary):
tol = 1E-14 # tolerance for coordinate comparisons
return abs(x[0]-2) < tol and abs(x[1]-1)<tol
Gamma_P = PointLoad()
Gamma_P.mark(boundary_parts, 3)
Define functions
u = TrialFunction(V) # Trial displacement
v = TestFunction(V) # Test function
B = Constant((0.0, 0.0)) # Body force per unit volume
T = Constant((0.0, -0.2)) # Point load on the boundary
Kinematics
d = u.geometric_dimension()
I = Identity(d) # Identity tensor
stress = sym(grad(u)) # Green Lagrange tensor
Elasticity parameters
E, nu = 10.0, 0.3
mu, lmbda = Constant(E/(2(1 + nu))), Constant(Enu/((1 + nu)(1 - 2nu)))
stress
def sigma(v):
return 2.0musym(grad(v)) + lmbdatr(sym(grad(v)))I
Define Dirichlet boundary (x = 0 or x = 1)
c = Expression(("0.0", "0.0"))
bcl = DirichletBC(V, c, Gamma_L, method='pointwise')
bcr = DirichletBC(V, c, Gamma_R, method='pointwise')
bcp = DirichletBC(V, T, Gamma_P, method='pointwise')
bcs = [bcl, bcr, bcp]
Total potential energy
dss = ds[boundary_parts]
a = inner(sigma(u), sym(grad(v)))dx
L = inner(B, v)dx + inner(T, v)*dss(3)
Solve variational problem
A, b = assemble_system(a, L, bcs)
u = Function(V)
U = u.vector()
solve(A, U, b)
Save solution in VTK format
file = File("displacement.pvd");
file << u;
Plot and hold solution
print U.array().max()
plot(u, mode = "displacement", interactive = True)