next up previous contents
Next: area_element_group index geometry_entity_item geometry_entity_index Up: TOCHNOG User's manual - Previous: end_initia (last record of   Contents

Input file, data part

Data items

Data items in the data part are used to control the calculation, select required output, give unknowns initial values, etc.. Note that an end_data record is needed.


data_item index data_values
...
data_item index data_values
end_data

Consider the following example


element 0 -tria3 0 1 2
element 1 -tria3 1 2 3
node 0 0. 0.
node 1 1. 0.
node 2 0. 1.
node 3 1. 1.
...
end_data

Note that the data items element and node are indexed. In fact most data items need to be indexed. Indexing starts at 0 (all numbering in TOCHNOG starts at 0). Indices need not strictly be sequential (e.g. only the indices 1,2 and 5 of a data item may be specified).

Ranges

Ranges are general input formats used for indices and data values. Possible ranges are illustrated by the following examples


12
-all
-ra part1 part2 ...-ra

The -all range is not available for indices. The -ra are delimiters of complex ranges. Each complex range part, e.g. part1, consists by example out of

35
-from 5 -to 16
-from 5 -to 25 -step 2

The data values for a data item can be specified as a range if this is allowed for in the description of the data item. All words in the data part (or part of an index) need to be preceeded with a 'tic' (-). In the example the node_dof records 1 to 100 are initialized


node_dof -ra -from 1 -to 100 -ra 1. 0. 0.

Define blocks

You can define a word to represent a set of strings. For each word defined, you need to specify a start_define ...end_define block. Within the block, you first specify the word, and then you specify the set of strings. Later in the data part, you can use the defined words as the replacement of the set of strings.

Example:


start_define
velocity 1.34
end_define
start_define
left_edge geometry_line 1
end_define
...
left_edge 0. 0. 0. 10. 1.e-4
...
bounda_unknown 1 -left_edge -velx
bounda_time 1 0. 0. 100. velocity
...

The words plus, minus, multiply and divide as used in arithmetic blocks are prohibited in define blocks.

Arithmetic blocks

You also can use the arithmetic expressions plus, minus, multiply and divide. We show some examples:


(make A equal to 4.1)
start_arithmetic
A 1.1 plus 3
end_arithmetic
...
(make B equal to 3.2)
start_arithmetic
B 3.2
end_arithmetic
...
(make C equal to 7.6)
start_arithmetic
C A plus B
end_arithmetic
...
(make D equal to 15.2)
start_arithmetic
D A plus B multiply 2.
end_arithmetic

Expressions will be evaluated from left to right. Words from define blocks will not be recognized in arithmetic blocks.

Conditional blocks

Parts of the input file can be processed conditionally within start_if ...end_if blocks. The is illustrated below with an example:

Example:


start_define
do_complete_calculation true
end_define
...
start_if do_complete_calculation
...
end_if
...

The part in the start_if ...end_if block is only done if do_complete_calculation is set to true, like in the example. If do_complete_calculation is set to false that part will be skipped.



Automatic counting: the counters

The words counter_a, counter_b, counter_c and counter_d are reserved words in the data part. If they are found, they will be substituted by their integer value. Initially the value is 0 for both, and each time a counter is encountered it will be increased by 1. The example below shows a typical application.


start_define
left_edge geometry_line counter_a
end_define
start_define
right_edge geometry_line counter_a
end_define
...
left_edge 0. 0. 0. 10. 1.e-4
right_edge 2. 0. 2. 10. 1.e-4
...
bounda_unknown 1 -left_edge -velx
bounda_time 1 0.
bounda_unknown 2 -right_edge -velx
bounda_time 2 1.3
...

Notice that we automatically give the geometry lines a unique number in this way; the unique number is not really of interest in the remainder of the input file, so the application of a counter is convenient.

Finally, also the words counter_a_apply, counter_b_apply, counter_c_apply and counter_d_apply are available. They will be substituted by the current value of the counters, without that the counters are incremented.

Control indices

All possible data items are defined in the following sections. It only makes sense to specify some of the data items before the calculation; the other data items are only meant to be printed after the calculation. The example below specifies a 1D temperature calculation.


echo -no
number_of_space_dimensions 1
condif_temperature
end_initia

node 1 0
node 2 1
node 3 2

element 1 -bar2 1 2
element 2 -bar2 2 3

bounda_unknown 0 1 -temp
bounda_time 0 0.0 0. 1. 1. 100. 1.
bounda_unknown 1 3 -temp
bounda_time 1 0.0 0.0 100.0 0.

group_type 0 -condif
group_condif_density 0 1.0
group_condif_capacity 0 0.1
group_condif_conductivity 0 0.1
group_condif_flow 0 0.

control_timestep 0 0.1 10.0
control_print 0 -time_current -node_dof
control_print_database 1 -yes
control_timestep 2 0.2 10.0
control_print 2 -time_current -node_dof

end_data

Note how the indices of control items like control_timestep and control_print are used to control the sequence of events. First, (index=0) time steps of size 0.1 are taken and for each time step results are printed. Then (index=1) the database is printed which can serve as a point of restart. Finally (index=2) time steps of size 0.2 are taken and for each time step results are printed.

Numbering of values in records

The numering of values in records in illustrated by node_dof records. Look at the following piece of input file


...
number_of_space_dimensions 2
materi_velocity
materi_stress
end_initia
...
node_dof 1 0.0 0.0 -1.0 0.0 0.0 -1.0 0.0 -1.0
node_dof 2 0.0 0.0 -1.0 0.0 0.0 -1.0 0.0 -1.0
...
end_data

Here node_dof records 1 and 2 are initialized. The initial velocities are 0, and for the initial stresses we use $\sigma\_{xx} = -1$, $\sigma\_{yy} = -1$ and $\sigma\_{zz} = -1$. The total list of unknowns in the node_dof record is -velx, -vely, -sigxx, -sigxy, -sigxz, -sigyy, -sigyz and -sigzz.

We refer to -velx as the 0'th value in the node_dof record, -vely as the 1'th value, etc. So printing the history of the -sigxx stress of node_dof record 1 is obtained by this:


...
control_timestep 10 ...
control_print_history 10 -node_dof 1 2
...
end_data

where the number 2 refers to the -sigxx stress. See also the definition of the control_print_history record for this. As an alternative, sometimes you can use names in stead of numbers, by example here:


...
control_timestep 10 ...
control_print_history 10 -node_dof 1 -sigxx
...
end_data

Types of unknowns

Some of the unknowns are principal unknowns: these are materi_velocity, condif_temperature, groundflow_pressure, wave_fscalar. These are the unknowns which are solved by the equilibrium equations (conservation laws).

The other unknowns, like materi_stress and so, follow from these principal unknowns (strains follow from displacement derivatives, stresses follow from strains by material laws, etc.).

Furthermore, for all the unknowns we have primary values, which are the unknowns themselves, and derived unknowns, which are the space and time derivatives of the primary unknowns.



Subsections
next up previous contents
Next: area_element_group index geometry_entity_item geometry_entity_index Up: TOCHNOG User's manual - Previous: end_initia (last record of   Contents
tochnog 2001-09-02