Example 5533: Isovolumic contraction/ejection of a high order prolate model with two wall elements

Two prolate elements (region 1: lambda tricubic Hermite; mu,theta trilinear; hydrostatic pressure nodally interpolated) of incompressible pole zero material is inflated to 1kPa. Then inflated prolate is initially contracted isovolumically then ejection is simulated.
NOTE: Adding the cavity elements to the mesh changes the scale factors for the wall elements, because they are "Calculated from arithmetic mean arc length". This means that the converged solution for the passive wall inflation problem is not a converged solutionn for the coupled problem if the new scale factors are used. To get around this you willl see that the scale factors are written out (saved) for the wall region before defining the cavity elements, after which the wall scale factors are re-read. There is a check that the passive inflation solution is indeed a converge soln for the coupled problem.


The comfile run by this example is as follows:

#Example_5533:  Contraction of an inflated highorder (lambda tricubic) two element mesh 
#
#
# If the example path is not set, default to current directory
if (!defined $example) {
    $example = "./";
}
# Drop off the trailing / in the example path
$chopped = chop $example;
if ($chopped ne "/") {
    $example .= $chopped;
}

fem define parameters;r;profib_tricubic;example;

# Read in geometry/problem for wall region
$WALL = 1;
fem define coor;r;wall;example reg $WALL;    #prolate spheriodal coords
fem define node;r;;example reg $WALL;        #6 nodes
fem define base;r;;example;                  #lambda tricubic; mu/theta trilinear
fem define elem;r;;example reg $WALL;        #2 wall elements
fem define fibr;r;;example reg $WALL;        #fibre: endo 65 deg; epi -55 deg
#                                            ! sheet: endo -45 deg; epi  45 deg
fem define elem;r;;example fibre reg $WALL;
fem define equa;r;;example reg $WALL lock;   #Incomp finite elasticity; Galerkin FEM
fem define mate;r;;example reg $WALL;        #pole zero law
fem define acti;r;wall0_00;example reg $WALL #passive inflation
fem define init;r;wall_def;example reg $WALL #inflate to 1kPa (reads in inflated mesh
#				             ! (results from example_5534)
fem define solv;r;wall;example reg $WALL;    #LU
#
# ############################################ 
# Inflated solution is converged OK! 
# ############################################ 
#
#fem define window;
#fem draw lines;
#fem draw lines deformed dotted;             #draw inflated solution

#
# Save scale factors for the wall elements (see note in description)
fem define base;r;wall_readse;example;    #redefine bases to read in scale factors 
fem define line;w;wall reg $WALL;         #write out scale factors for wall elements
fem define base;r;wall;example;           #redefine bases to calculate scale factors
#

#
# Set up cavity region geometry
$CAVITY = 2;
fem define region;r;coupled;example;
fem define coord;r;cavity;example region $CAVITY;
fem define node;r;cavity;example region $CAVITY;
fem define element;r;cavity;example region $CAVITY;
#
# Set up equations, material properties and initial conditions
# for cavity region
fem define equation;r;coupled;example region $WALL,$CAVITY lock;
fem define material;r;cavity_isovol;example region $CAVITY;
fem define initial;r;cavity;example region $CAVITY;
#
# Define cavity-to-wall coupling and solution procedure information
fem define coupling;r;coupled;example;
fem define solve;r;coupled_lu_nosparse;example coupled region $WALL,$CAVITY;
#
# Transfer wall deformation from the inflation problem to 
# geometric dependent variables for the cavity region
fem update solution coupled source_region $WALL;
#
# Set up the reference state for the cavity region to be the deformed 
# configuration from the inflation problem.  To set up the 
# 'inflated cavity', the x-coord ('in 1' represents the 1st RC coord)
# for the central cavity node (node 6) is set to the average of the 
# x-coords for the adjacent interface nodes (node 2 - this could 
# be a list of nodes)
fem update solution cavity_reference average 6 in 1 node 2 region $CAVITY;
#
# Re-read scale factors for the wall elements
fem define base;r;wall_readse;example;     #redefine bases to read in scale factors 
fem define line;r;wall reg $WALL;          #read in scale factors for wall elements
fem define base;r;wall;example;            #redefine bases to calculate scale factors

#
# List undeformed (pre-inflation) and inflated cavity volumes
fem list element total region $CAVITY;
fem list element deformed total region $CAVITY;
# ############################################
# cavity volume inflated from 34ml to 68ml.
# ############################################
#
fem define window;
fem draw lines rgb=grey region $WALL,$CAVITY;
fem draw;add lines deformed dotted rgb=red region $WALL,$CAVITY;
#

# Save deformed configurations for end diastole
fem define initial;w;profib_enddiast region $WALL,$CAVITY;

# Check that the current coupled solution is converged (as expected!)
fem evaluate reactions coupled;
# ############################################
# inflated state is a converged solution for the coupled problem!
# ############################################
#
# ISOVOLUMIC CONTRACTION
#

# Increment intracell calcium conc and solve for isovolumic contraction
# and save deformed configurations for end isovolumic contraction
fem define active;r;profib_contract;example;
fem solve coupled increment 0.0;
fem define initial;w;profib_endisovolcontr region $WALL,$CAVITY;

# Read in previous converged solution for end isovolumic contraction
# and check that the current coupled solution is converged (as expected!)
#fem define initial;r;profib_endisovolcontr region $WALL,$CAVITY;
#fem define solve;r;coupled_lu_nosparse;example coupled region $WALL,$CAVITY;
#fem evaluate reactions coupled;
#
fem draw;add lines deformed dotted rgb=blue region $WALL,$CAVITY;
#
# Check that cavity volume has not changed
fem list element deformed total region $CAVITY;
# ############################################
# This contraction phase was indeed isovolumic!
# (cavity volume still 68ml).
# ############################################ 
#
# EJECTION
#
# Decrease cavity 'stiffness parameter' and solve for ejection
# and save deformed configurations for end ejection
fem define material;r;cavity_eject;example region $CAVITY;
fem solve coupled increment 0.0;
fem define initial;w;profib_endeject region $WALL,$CAVITY;
 
# Read in previous converged solution for end ejection
# and check that the current coupled solution is converged (as expected!)
#fem define initial;r;profib_endeject;example region $WALL,$CAVITY;
#fem define solve;r;coupled_lu_nosparse;example coupled region $WALL,$CAVITY;
#fem evaluate reactions coupled;
#
fem draw;add lines deformed dotted rgb=green region $WALL,$CAVITY;
#
# Determine cavity volume at end-ejection.  
# NOTE: to calc cavity volume, the deformed position of the central
# cavity node must be recalc'ed from the averaged adjacent wall nodes.
# After doing this the current solution is meaningless, ie. best to save
# deformed configurations for both regions before this (as above).
fem update solution cavity_reference average 6 in 1 node 2 region $CAVITY;
fem list element deformed total region $CAVITY;
# ############################################
# Not a huge ejection fraction (!!!), but neverless a decrease 
# in volume from 68ml to 66ml.
# ############################################

Additional testing commands:

fem list initial region $WALL,$CAVITY
fem write iod

Files used by this example are:

Name                            Modified     Size

example_5533.com 18-Aug-2004 6.4k cavity.ipcoor 10-Apr-2000 710 cavity.ipelem 10-Apr-2000 1.2k cavity.ipinit 12-Dec-2002 1.7k cavity.ipnode 10-Apr-2000 4.8k cavity_eject.ipmate 10-Apr-2000 386 cavity_isovol.ipmate 10-Apr-2000 390 coupled.ipcoup 21-Aug-2002 437 coupled.ipcoup.old 10-Apr-2000 386 coupled.ipregi 10-Apr-2000 94 coupled.irequa 02-May-2004 3.8k coupled_cavity_tricubic.com 20-Nov-2001 4.5k coupled_cavity_tricubic.out 10-Apr-2000 26k coupled_lu_nosparse.irsolv 16-Aug-2010 2.6k coupled_lu_nosparse.irsolv.old 13-Apr-2007 2.4k profib_contract.ipacti 03-Mar-2004 735 profib_enddiast.irinit 18-Aug-2004 26k profib_endeject.irinit 18-Aug-2004 26k profib_endisovolcontr.irinit 18-Aug-2004 26k profib_tricubic.ippara 17-Dec-2002 5.9k test_output.com 10-Apr-2000 52 wall.ipbase 10-Apr-2000 12k wall.ipcoor 10-Apr-2000 710 wall.ipelem 10-Apr-2000 1.2k wall.ipelfb 10-Apr-2000 618 wall.ipequa 02-May-2004 2.0k wall.ipfibr 30-Jan-2001 1.7k wall.ipinit 12-Dec-2002 1.6k wall.ipline 18-Aug-2004 10k wall.ipmate 12-Dec-2002 6.3k wall.ipnode 10-Apr-2000 4.8k wall.ipshee 10-Apr-2000 915 wall.ipsolv 16-Aug-2010 2.3k wall.ipsolv.old 13-Apr-2007 2.1k wall0_00.ipacti 03-Mar-2004 735 wall_def.ipinit 18-Aug-2004 15k wall_readse.ipbase 10-Apr-2000 12k

Download the entire example:

Name                           Modified     Size

examples_5_55_553_5533.tar.gz 17-Aug-2010 36k

Testing status by version:

StatusTestedReal time (s)
i686-linux
cmFailureSun Mar 6 00:37:45 201621
last breakTue Feb 24 03:40:00 201522
last successSun Apr 17 01:05:00 201139
cm-debugFailureSun Mar 6 01:01:03 201641
last breakTue Feb 24 03:47:00 201540
last successSat Apr 16 01:11:00 201174
mips-irix
cmSuccessSun Aug 19 03:18:18 2007109
cm-debugSuccessWed Aug 15 03:41:51 2007337
cm-debug-clear-mallocSuccessSat Aug 18 04:08:42 2007347
cm-debug-clear-malloc7SuccessMon Aug 20 04:25:41 2007347
cm64SuccessSun Aug 19 03:20:56 2007116
cm64-debugSuccessTue Aug 21 03:02:48 2007354
cm64-debug-clear-mallocSuccessFri May 20 10:36:19 2005141
rs6000-aix
cmSuccessWed Mar 4 01:15:07 200912
cm-debugSuccessMon Mar 2 01:25:27 2009114
cm64SuccessWed Mar 4 01:16:00 200913
cm64-debugSuccessTue Mar 3 01:34:32 2009105
x86_64-linux
cmFailureSun Mar 6 00:03:33 201610
last breakTue Aug 12 00:19:00 201411
last successSun Apr 17 00:30:00 201112
cm-debugFailureSun Mar 6 00:04:23 201622
last breakTue Aug 12 00:02:00 201426
last successSat Apr 16 00:23:00 201126

Testing status by file:


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

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


CMISS Help / Examples / 5 / 55 / 553 / 5533