Example a/evaluate_grid: evaluate_grid: Evaluate a curve product field into grid points.

This example uses multiplies three curves to define a potential field which varies with the xi directions. This field is evaluated into an existing grid point storage and written out.

Screenshot of example a/evaluate_grid

The comfile run by this example is as follows:

#This example uses multiplies three curves to define a potential field which
#varies with the xi directions.
#This field is evaluated into an existing grid point storage and written out.

#Read in our element geometry
gfx read node $example/stomach.exnode
gfx read elem $example/stomach.exelem

#Define a grid by reading in one that has the desired resolution
gfx read elem $example/field.exelem.bz2
#Specify the grid point numbers for the grid points
gfx read elem $example/grid.exelem.bz2

#Read in three curves which are going to be multiplied into a
#product to define the field values we want.
open com $example/epsilon_xi1.curve.com exec
open com $example/epsilon_xi2.curve.com exec
open com $example/epsilon_xi3.curve.com exec

$GROUP = "stomach";

gfx define field xi_texture xi_texture_coordinates seed_element $SEED_ELEMENT
gfx define field xi1_curve curve_lookup curve xi1 source xi_texture.1
gfx define field xi2_curve curve_lookup curve xi2 source xi_texture.2
gfx define field xi3_curve curve_lookup curve xi3 source xi_texture.3
gfx define field temp multiply fields xi1_curve xi2_curve
gfx define field values multiply fields temp xi3_curve

#Evaluate the field values into the grid point storage
gfx evaluate egroup $GROUP destination potential source values

#Write out the evaluated grid point values
gfx write elem values_$GROUP.exelem group $GROUP fields potential;
#Write out the corresponding grid point numbers
gfx write elem number_$GROUP.exelem group $GROUP fields grid_point_number

Files used by this example are:

Name                      Modified     Size

evaluate_grid.com 17-Mar-2014 1.5k COPYRIGHT 17-Mar-2014 504 epsilon_xi1.curve.com 17-Mar-2014 155 epsilon_xi1.curve.exelem 17-Mar-2014 843 epsilon_xi1.curve.exnode 17-Mar-2014 748 epsilon_xi2.curve.com 17-Mar-2014 154 epsilon_xi2.curve.exelem 17-Mar-2014 843 epsilon_xi2.curve.exnode 17-Mar-2014 748 epsilon_xi3.curve.com 17-Mar-2014 153 epsilon_xi3.curve.exelem 17-Mar-2014 640 epsilon_xi3.curve.exnode 17-Mar-2014 377 field.exelem.bz2 17-Mar-2014 62k grid.exelem.bz2 17-Mar-2014 833k stomach.exelem 17-Mar-2014 512k stomach.exnode 17-Mar-2014 150k

Download the entire example:

Name                             Modified     Size

examples_a_evaluate_grid.tar.gz 09-Mar-2016 4.2M

Testing status by version:

StatusTestedReal time (s)
cmgui-wxFailureSun Mar 6 00:25:49 20169
last breakMon Aug 25 13:14:00 201419
cmgui-wx-debugFailureSun Mar 6 00:28:08 201613
last breakMon Aug 25 13:22:00 201434
cmgui-wx-debug-memorycheckFailureSun Mar 6 00:54:38 201635
last breakMon Aug 25 13:45:00 201495
cmgui-wx-debug-valgrindFailureSun Mar 6 02:35:12 2016486
last breakTue Feb 24 01:17:00 2015462
cmgui-wxFailureSun Mar 6 00:02:01 20164
last breakFri Aug 15 00:17:00 20144
cmgui-wx-debugFailureSun Mar 6 00:02:32 20168
last breakFri Aug 15 00:18:00 201410
cmgui-wx-debug-memorycheckFailureSun Mar 6 00:04:20 201620
last breakFri Aug 15 00:18:00 201426
cmgui-wx-debug-valgrindFailureSun Mar 6 00:15:26 2016345
last breakSun Mar 6 00:09:00 2016345
cmgui-wx-gcc-cad-debug-valgrindSuccessThu Jan 7 00:16:58 2016358

Testing status by file:

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

Input last modified: Wed Mar 9 15:49:34 2016

CMISS Help / Examples / a / evaluate_grid