diff --git a/cosserat-continuum-wong-pellegrino-wrinkling.parset b/cosserat-continuum-wong-pellegrino-wrinkling.parset index 6e911f027772be6ea357e1758f31f96a1d413d0c..bb02f57c778401fad194bcec76db9b4ec4f468db 100644 --- a/cosserat-continuum-wong-pellegrino-wrinkling.parset +++ b/cosserat-continuum-wong-pellegrino-wrinkling.parset @@ -90,6 +90,4 @@ kappa = 1 dirichletVerticesPredicate = "x[1] < 0.0001 or x[1] > 0.128 - 0.0001" # Initial deformation -#initialDeformation = "[x[0], x[1], 0.002*cos(1e4*x[0])]" -# Series expansion of the cosine, because I haven't figured out how to use math stuff in dunepython yet -initialDeformation = "[x[0], x[1], 1e-15*(1- 0.5*(1e4*x[0])*(1e4*x[0]) + (1.0/24)*(1e4*x[0])*(1e4*x[0])*(1e2*x[0])*(1e4*x[0]))]" +initialDeformation = "[x[0], x[1], 0.002*math.cos(1e4*x[0])]" diff --git a/cosserat-continuum.cc b/cosserat-continuum.cc index e4a14226fb7b46c6529ac34ddc66f04bd637cf76..f9d529d78d9aa864817bcebaa973b3b6a4b187d2 100644 --- a/cosserat-continuum.cc +++ b/cosserat-continuum.cc @@ -171,6 +171,7 @@ int main (int argc, char *argv[]) try // Start Python interpreter Python::start(); Python::Reference main = Python::import("__main__"); + Python::run("import math"); //feenableexcept(FE_INVALID);