Very likely bug in `Hyperelasticity<HyperelasticLawT>::ComputeChainRule` for I4 and I6
There was lines such as
const auto& dI4dC = law.template GetSecondDerivativeWrtCauchyGreen<::MoReFEM::InvariantNS::index::I4>();
,
it is very likely it is in fact GetFirstDerivativeWrtCauchyGreen
that is intended here! (in any case the local variable name is not consistant with the value put inside.
It is very likely in the tests this component is 0 anyway: changing Second to First in the formula doesn't change the fact that the test pass...
Thanks to @adalmora for finding it!