Example 5i2: Mesh with 2 collased elements and an element adjacent to a collapsed one.

Mesh with 2 collased elements and an element adjacent to a collapsed one.

The comfile run by this example is as follows:

# Example 5i2 

fem def para;r;memory
#set diag on

fem de coord;r;allow_mapping

$name = "example_5i2";

fem define bas;r;TriCubicHerm
fem def;add base;r;BiCubicHerm
fem def;add base;r;TriLinearPress
fem def;add base;r;BiLinear

fem define node;r;$name
fem define elem;r;$name

fem def fibre;d
fem def elem;d          fibre

#set diag on
for $j (1..3){
   # This option will make all the lines straight
   fem update nodes deriv $j versions individual

   #fem update nodes deriv $j
#set diag off

# the scale factors are not correct after the above so fix them 
fem update node scale_factor

# Export initial mesh
$ref = "initial";

fem export nodes;$ref as $ref;
fem export elements;$ref as $ref;

fem define node;w;$name."_exp"
fem define elem;w;$name."_exp"

# Refine doesn't work because the mappings are not updated.
#fem refine xi 1
#fem refine xi 2
#fem refine xi 3

fem def equa;r;mechanics          lock
fem def mat;r;mooney_rivlin

fem group element all external s3=0 as BOTTOM;
fem group nodes xi3=0 element BOTTOM as BOTTOMNODES;

fem group element all external s3=1 as TOP;
fem group nodes xi3=1 element TOP as TOPNODES;

fem list nodes groups

fem def init;r;displace_zx_3elements

# for testing
#fem def node;w;after
#fem def node;w;dep_after dep 1

#the above 2 files are the same

fem def solve;r;cubeherm

# for testing
#fem def node;w;after2
#fem def node;w;dep_after2 dep 1

# the above 2 files are different

# kludge to fix issue above
fem def mapping;r;$name
fem update solution geom

#fem eval reac
fem solv inc 0

fem solv inc 0.0001 iter 20 error 1e-4
fem solv inc 0.0009 iter 20 error 1e-4
fem solv inc 0.009 iter 20 error 1e-4
fem solv inc 0.09 iter 20 error 1e-6
fem solv inc 0.4 iter 20 error 1e-8
fem solv inc 0.5 iter 30 error 1e-10

$name = "deformed";

fem export nodes;$name as $name field offset 0
fem export elements;$name as $name field offset_elem 0

#view in cmgui if desired
system "cmgui view.com"

Files used by this example are:

Name                          Modified     Size

example_5i2.com 09-Mar-2007 1.9k BiCubicHerm.ipbase 09-Mar-2007 1.6k BiLinear.ipbase 09-Mar-2007 1.2k TriCubicHerm.ipbase 09-Mar-2007 1.9k TriLinear.ipbase 09-Mar-2007 1.4k TriLinearPress.ipbase 09-Mar-2007 1.9k allow_mapping.ipcoor 09-Mar-2007 658 cubeherm.ipsolv 16-Aug-2010 3.1k cubeherm.ipsolv.old 13-Apr-2007 3.0k deformed.exelem 09-Mar-2007 24k deformed.exnode 09-Mar-2007 14k displace_zx_3elements.ipinit 09-Mar-2007 6.4k example_5i2.ipelem 09-Mar-2007 4.1k example_5i2.ipmap 09-Mar-2007 19k example_5i2.ipnode 09-Mar-2007 32k example_5i2_exp.ipelem 09-Mar-2007 4.3k example_5i2_exp.ipnode 09-Mar-2007 30k initial.exelem 09-Mar-2007 21k initial.exnode 09-Mar-2007 13k mechanics.ipequa 09-Mar-2007 2.1k memory.ippara 09-Mar-2007 5.9k mooney_rivlin.ipmate 09-Mar-2007 2.3k newton.ipsolv 16-Aug-2010 3.1k newton.ipsolv.old 13-Apr-2007 3.0k partial.ipinit 09-Mar-2007 94k view.com 09-Mar-2007 2.3k

Download the entire example:

Name                      Modified     Size

examples_5_5i_5i2.tar.gz 17-Aug-2010 24k

Html last generated: Sun Mar 6 05:50:29 2016

Input last modified: Mon Aug 16 11:19:19 2010

CMISS Help / Examples / 5 / 5i / 5i2