firedrakeproject / firedrake

Firedrake is an automated system for the portable solution of partial differential equations using the finite element method (FEM)
https://firedrakeproject.org
Other
509 stars 159 forks source link

Elastodynamics example #2289

Open zthowin opened 2 years ago

zthowin commented 2 years ago

Hello, I'd like to add a quasi-one-dimensional elastodynamics problem to the examples. The problem at hand has an analytical solution developed by Eringen & Suhubi (in https://doi.org/10.1002/zamm.19800601028) which I will use for measurements of error vs. mesh refinement and order of interpolation.

I have developed implicit integration schemes using Newmark-beta parameters as well as explicit integration schemes using central-differencing in time for unlumped (consistent) and lumped mass matrices. The latter is giving me some trouble despite referencing a solution in #539; the numerical solution is quite different from the analytical solution. I am attaching a MWE prior to the pull request for the longer code if anyone has time to take a look and give feedback as to where I'm erring. Thanks!

elastodynamics-mwe.zip

wence- commented 2 years ago

Thanks! Perhaps the best way to debug this is to actually open a PR with the demo, and we can discuss there. I guess that since you're using piecewise linear elements, the lumping scheme should work OK. Can you explain in a bit more detail how the solution goes wrong?