This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Hyperelasticity demo: strain and stress

+1 vote

Hi,

Using the Hyperelasticity demo as an example (cpp version), what's the best way to compute the stress and strain values and save to a vtk file for visualization? Would I need to create another ufl file that defines a functional for strain and stress?

asked May 22, 2014 by Theodore FEniCS Novice (780 points)

1 Answer

+1 vote
 
Best answer

Yes, you need to create another UFL file to project gradients of the displacement onto another basis.

You can use LocalSolver to perform projections onto discontinuous bases efficiently, which is helpful for large problems.

answered Jun 12, 2014 by Garth N. Wells FEniCS Expert (35,930 points)
selected Jun 13, 2014 by Theodore

Hi Garth, could you elaborate a little on why and when LocalSolver is useful please?

This might be helpful for others, so I just posted it as 'question' and answered it myself:

http://fenicsproject.org/qa/3858/what-is-dolfin-localsolver-and-how-do-i-use-it

Great, thanks!

...