Dear Phuoc, see my answers below:
On Fri, Jan 19, 2018 at 3:02 PM, Huu Phuoc BUI <[email protected]> wrote: > Dear Yves, > > Thank you for your reply! > > We expressed the divergence of stress tensor with respect to the variable > u. In the expression, we have something like Grad(Trace(Grad_u)), and > Trace(Hess_u). When assembling these terms with GetFEM, there is an error > in assembly string. I tried to assembly separately these two terms. Both > did not work. > > For the first term Grad(Trace(Grad_u)), I think the error comes from the > fact that, in GetFEM, we can only use Grad operator with a variable, i.e., > Grad_u, Grad_Test_u, etc. Therefore, we can not write directly > Grad(Trace(Grad_u)). Is it right? > Correct. > > For the second term Trace(Hess_u), I think the error comes from the Trace > operator, since in the GetFEM documentation, it is stated that Trace > operator is used for a square matrix. In our case, since u is a vector > field, Hess_u is a tensor of order 3. Can we use Trace operator in assembly > string for a tensor of order 3? > What should the trace of a 3rd order tensor be? Lets say H_ijk is a 3 order tensor. If e.g. you want to calculate a vector v_i = H_ikk (summation over k), as far as I remember you can get it with "H:Id(3)", please try. > Thank you in advance for your reply. > > Best regards, > Phuoc > > Best regards Kostas
