Hello,
As things stand, I am applying a constant body and tension force on an imported mesh of a cube (not dependant of the shape of the mesh). Is it possible to apply a normal force or a tangential force depending on each node of the surface of application? I know it is possible to use Expression
or Function
but I don’t know how.
Thanks a lot for your help !
B = Constant(mesh, PETSc.ScalarType((0, 0, 0)))
T = Constant(mesh, PETSc.ScalarType((100, 0, 0)))
# Stored strain energy density (compressible neo-Hookean model)
psi = ufl.variable((mu / 2.0) * (Ic - 2) - mu * ufl.ln(J) + (lmbda / 2.0) * (ufl.ln(J))**2)
# dx = ufl.Measure("dx")
# Pi = psi*dx - ufl.inner(b, u)*dx
# First Piola-Kirchhoff Stress
P = ufl.diff(psi, F)
metadata = {"quadrature_degree": 4}
ds = ufl.Measure('ds', domain=mesh, subdomain_data=ft, metadata=metadata)
dx = ufl.Measure("dx", domain=mesh, subdomain_data = ct, metadata=metadata)
# Define form F (we want to find u such that F(u) = 0)
F = ufl.inner(ufl.grad(v), P)*dx(10) - ufl.inner(v, T)*ds(14) - ufl.inner(v, B)*dx(10)