This example uses the centreline command to create a line of data points along the centre of mass of a tubular surface mesh.
The data points are generated along the axial xi direction (xi 2) beginning from the start element 1. The number of axis divisions is set to 2 which means two points will be generated along each axial element. Each centreline point is calculated by determining the centre of mass for a curve in the circumferential xi direction (xi 1). The generated points are stored in the same region as the surface mesh and can then be listed or exported.
Note that gaussian quadrature assuming cubic elements is used to calculate the centre of mass points. If cubic elements are used in the circumferential direction then the calculation is exact, otherwise the data points will only be an approximation to the centre of mass.
The view_centreline.com file can be used with cmgui to view the original surface mesh and the generated data points.
Once the data points have been generated a mesh of the line can be created by using the cmgui command gfx snake or by fitting an initial line mesh to the data.
# Create a centreline of data points for a surface mesh # Author: Peter Bier fem def param;r;$example/tract # define a rectangular cartesian 3D coordinate system fem def coord 3,1 # define a bi-cubic hermite basis function for the surface elements # and a linear lagrange basis for using to interpolate along the circumference # to calculate the centre of mass. fem def base;r;$example/tract # read in the surface mesh node points fem def node;r;$example/tract # read in the surface mesh element points fem def elem;r;$example/tract # Calculate the centreline data points # default values for the axial and circumferential xi directions are used # The default starting element number 1 is also used. # 2 points will be generated for each element along the axial direction fem def data;c centreline axis_divisions 2 # list the created data points fem list data # export the created data points for viewing fem export data;centreline # a centreline mesh can now be created by: # using the cmgui command gfx snake # or fitting a line to the data
Name Modified Size
example_13d.com 27-Mar-2003 1.0k centreline.exdata 20-Mar-2003 1.7k centreline.ipdata 20-Mar-2003 14k tract.exelem 20-Mar-2003 49k tract.exnode 20-Mar-2003 27k tract.ipbase 27-Mar-2003 2.3k tract.ipelem 20-Mar-2003 25k tract.ipnode 20-Mar-2003 73k tract.ippara 27-Mar-2003 5.9k view_centreline.com 20-Mar-2003 390
Name Modified Size
examples_1_13_13d.tar.gz 18-Aug-2006 42k
Status | Tested | Real time (s) | |
i686-linux | |||
cm | Success | Sun Mar 6 00:01:32 2016 | 0 |
cm-debug | Success | Sat Mar 5 00:01:52 2016 | 0 |
mips-irix | |||
cm | Success | Sun Aug 19 01:24:05 2007 | 4 |
cm-debug | Success | Wed Aug 15 01:21:13 2007 | 5 |
cm-debug-clear-malloc | Success | Sat Aug 18 01:23:10 2007 | 8 |
cm-debug-clear-malloc7 | Success | Mon Aug 20 01:21:05 2007 | 8 |
cm64 | Success | Sun Aug 19 01:24:26 2007 | 2 |
cm64-debug | Success | Tue Aug 21 01:20:34 2007 | 5 |
cm64-debug-clear-malloc | Success | Thu Apr 1 10:10:10 2004 | 3 |
rs6000-aix | |||
cm | Success | Wed Mar 4 01:06:47 2009 | 1 |
cm-debug | Success | Mon Mar 2 01:06:14 2009 | 1 |
cm64 | Success | Wed Mar 4 01:06:47 2009 | 0 |
cm64-debug | Success | Tue Mar 3 01:11:34 2009 | 1 |
x86_64-linux | |||
cm | Success | Sun Mar 6 00:01:00 2016 | 0 |
cm-debug | Success | Sat Mar 5 00:01:11 2016 | 0 |
i686-linux | |||
Success | cm: | ndiff test: no significant differences with generic answer. | |
Success | cm-debug: | ndiff test: no significant differences with generic answer. | |
mips-irix | |||
Success | cm: | ndiff test: no significant differences with generic answer. | |
Success | cm-debug: | ndiff test: no significant differences with generic answer. | |
Success | cm-debug-clear-malloc: | ndiff test: no significant differences with generic answer. | |
Success | cm-debug-clear-malloc7: | ndiff test: no significant differences with generic answer. | |
Success | cm64: | ndiff test: no significant differences with generic answer. | |
Success | cm64-debug: | ndiff test: no significant differences with generic answer. | |
Success | cm64-debug-clear-malloc: | ndiff test: no significant differences with generic answer. | |
rs6000-aix | |||
Success | cm: | ndiff test: no significant differences with generic answer. | |
Success | cm-debug: | ndiff test: no significant differences with generic answer. | |
Success | cm64: | ndiff test: no significant differences with generic answer. | |
Success | cm64-debug: | ndiff test: no significant differences with generic answer. | |
x86_64-linux | |||
Success | cm: | ndiff test: no significant differences with generic answer. | |
Success | cm-debug: | ndiff test: no significant differences with generic answer. |
Html last generated: Sun Mar 6 05:50:07 2016
Input last modified: Thu Mar 27 09:03:04 2003