Open iBatistic opened 5 days ago
This looks really impressive.
The code is nicely structured and easy to follow.
By the way, I was recently reading the Zienkiewicz book (volume 1) and interesting they suggest a similar least squares approach for "recovering" the stress from the displacement field (in Chapter 15 - Errors, Recovery Processes, and Error Estimates). Essentially, they can get more accurate (and higher order of accuracy) stresses by fitting a least squares plane about each vertex through the surrounding elements' Gauss points, and this is how they interpolate stresses from Gauss points to the mesh vertices.
Here are some initial results; I’ll get back to you soon after I check in more detail how it works. I haven’t yet added treatment for boundary cells and faces on the edge. If you're interested in the code, you can check it on my
solids4foam-ib
fork on the branchsolids4foam/feature-petsc-snes
inlinGeomTotalDispSolid.C
from line 220 to 475 (everything is still in one place).