Morpho-lang / morpho

The Morpho language 🦋. Morpho is a small embeddable language for scientific computing applications.
MIT License
33 stars 11 forks source link

CauchyGreenStrain #270

Open softmattertheory opened 5 months ago

softmattertheory commented 5 months ago

Makes the Cauchy Green strain tensor:

C = (F G - 1)/2

where:

C vanishes if the deformed and reference frames coincide.

You must supply a reference mesh to your Integral constructor; you can then call cgtensor() within an integrand:

fn integrand(x, f) {
   var cg = cgtensor()
   return cg.trace()
}

var a = AreaIntegral(integrand, phi, reference=mref)