I am implementing a hyperelastic model in fenics. I define:
dx = Measure(‘dx’,domain=mesh, subdomain_data=matdomain)
My strain energy formula is simply:
psi = 1/2mu( inner(F,F) - 3 - 2ln(det(F)) ) + 1/2lmbda*(1/2*(det(F)**2 - 1) - ln(det(F)))
After running the solver, I want to compute the total strain energy. Is this the appropriate method:
psi_total = assemble(psi*dx)
The results look reasonable, this is more of a sanity check. Apologies if this question is addressed elsewhere I am new to the forum.