On 12/06/2016 06:49 PM, [email protected] wrote:
Dear All,
I hope you have had a great time. I have a general question. I define total
strain and deviatoric part of the elastic strain tensor in two different ways
as below:

1- Total strain tensor:
const SymmetricTensor<2, dim> total_strain = 0.5*(Grad_u + transpose(Grad_u));
  (Tensor<2, dim> &Grad_u)

const SymmetricTensor<2, dim> total_strain = symmetrize(Grad_u);

These should yield the same. Can you give an example of where they are 
different?


2-Deviatoric strain
dev_T_elastic =  deviator(T_elastic);

dev_T_elastic = T_elastic - (1/dim) * trace(T_elastic) * (Tensor<2,
dim>(StandardTensors<dim>::I))/3.0;

The expression '1/dim' is computed in integer arithmetic and evaluates to zero. You want to write this as '1.0/dim'. That should do the trick. Want to try it out?

Best
 W.

--
------------------------------------------------------------------------
Wolfgang Bangerth          email:                 [email protected]
                           www: http://www.math.colostate.edu/~bangerth/

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to