Example 114: Defining a curved 2D FEM mesh


The comfile run by this example is as follows:

#Example_114  Defining a curved 2D FEM mesh                            
                                                                       
fem                             #Set the FEM environment                  
fem define window;c                                                    
fem define nodes;r;fem_mesh;example #Defines 6 nodes as in Example_111
fem draw nodes    
fem define heading "Curved element example"  #all files prompted will now
#                               !  contain this heading.
fem define bases;p;femcurve     #Define a 2D_Cubic_linear basis:
#                               !  define 2 Xi coordinates; 
#                               !  Xi(1) interpolant is Cubic Hermite;
#                               !  Xi(2) interpolant is Linear Lagrange;
#                               !  default all other options.
fem define elements;r;fem_mesh;example #define 2 elements as in Example_111.
fem draw lines 
fem list nodes                  #Note that the nodal values are in the first
#                               !  column and the derivatives are in the
#                               !  second column.
fem change lines;m              #Change the shape of the lines with 
#                               !  Bezier control points.  Pick the line 
#                               !  control point ('+') and move the mouse 
#                               !  to control the slope at the nodes (the first
#                               !  click picks the control point, the 
#                               !  second relocates it). Middle button to
#                               !  finish            
fem list nodes                  #Note the nodal derivatives have now 
#                               !  changed                           
fem change nodes;m              #Use this to reposition a node if 
#                               !  needed.  The first click of the 
#                               !  mouse picks the node, the second
#                               !  relocates it. Middle button to finish
fem draw gauss                  #Show the location of the element Gauss
#                               !  points.  Note there are 3 Guass 
#                               !  points along the xi(1)-coordinates 
#                               !  (cubic Hermite basis) and 2 along   
#                               !  the xi(2)-coordinates (linear basis).  
fem list heading                #Display current file heading.       
fem define heading "Final mesh" #File heading for subsequent files is
#                               !  now "Final mesh".               
fem define nodes;w;new_femcurve #New nodes written to file 
#                               !  NEW_FEMCURVE.ipnode with new 
#                               !  heading.

Files used by this example are:

Name                 Modified     Size

example_114.com 20-Feb-2004 2.7k fem_mesh.ipelem 10-Apr-2000 633 fem_mesh.ipnode 10-Apr-2000 2.1k femcurve.ipbase 10-Apr-2000 1.5k new_femcurve.ipnode 10-Apr-2000 3.3k triangle.ipelem 10-Apr-2000 622

Download the entire example:

Name                      Modified     Size

examples_1_11_114.tar.gz 18-Aug-2006 104k

Graphical output from this problem is given here.


Html last generated: Wed Mar 9 16:00:54 2016

Input last modified: Fri Feb 20 13:12:45 2004


CMISS Help / Examples / 1 / 11 / 114