VECFEM3 Reference Manual: vemu02

Type: FORTRAN routine

Google


NAME

vemu02 - reads a VECFEM mesh file

SYNOPSIS

CALL VEMU02(
LIVEM, IVEM, LNEK, NEK, LRPARM, RPARM, LIPARM, IPARM, LDNOD, DNOD, LRDPRM, RDPARM, LIDPRM, IDPARM, LNODN, NODNUM, LNOD, NOD, LNOPRM, NOPARM, LBIG, RBIG, IBIG)
INTEGER
LIVEM, LNEK, LRPARM, LIPARM, LDNOD, LRDPRM, LIDPRM, LNODN, LNOPRM, LBIG
INTEGER
IVEM(LIVEM), NEK(LNEK), IPARM(LIPARM), DNOD(LDNOD), IDPARM(LIDPRM), NODNUM(LNODN), IBIG(*)
DOUBLE PRECISION
RPARM(LRPARM), RDPARM(LRDPRM), NOD(LDNOD), NOPARM(LNOPRM), RBIG(LBIG)

PURPOSE

vemu02 reads the mesh from a file on the first process and distributes the mesh to the processes. The data has to be written in the special format specified below. Only isoparametrical meshes are supported. A mixed finite element mesh can be created from the read mesh by vemgen(later) or vemge2. vemu02 can be called without a preceding vemdis call, but you have to call vemdis before you call any other VECFEM routine.

ARGUMENTS

LIVEM integer, scalar, input, local
Length of the integer information vector, LIVEM>= MESH+ NINFO.
IVEM integer, array: IVEM(LIVEM), input/output, local/global
Integer information vector.
(1)=MESH, input, local
Start address of the mesh informations in IVEM, MESH>203+ NPROC.
(2)=ERR, output, global
Error number.
0program terminated without error.
90LBIG is too small.
95mesh arrays are too small.
96unexpected element type.
97DIM or NK is illegal.
99fatal error.
(5)=NIVEM, output, local
Used length of IVEM.
(27)=LOUT, input, local
Unit number of the standard output file, normally 6.
(28)=OUTCNT, input, local
Output control flag, normally 1.
0only error messages are printed.
>0a protocol is printed.
(29), input, local
Unit of the mesh file. The unit is only used on the process 1. On the assigned data set the 'REWIND'-command has to be executable.
(200)=NPROC, input, global
Number of processes, see combgn.
(201)=MYPROC, input, local
Logical process id number, see combgn.
(202)=NMSG, input/output, global
Message counter. The difference of the input and the output values gives the number of communications during the vemu02 call.
(204)=TIDS(1), input, global
Begin of the list TIDS which defines the mapping of the logical process ids to the physical process ids. See combgn.
(MESH), input/output, local
Start of mesh informations, see mesh.
(MESH+2)=NK, input, global
Number of solution components. If NK is greater than NK specified in the mesh file, the missing components get no Dirichlet conditions. If NK is lower than NK specified in the mesh file, the additional components in the mesh file are ignored.
(MESH+3)=DIM, input, global
Space dimension, 1<=DIM<=3.
LNEK integer, scalar, input, local
Length of the element array.
NEK integer, array: NEK(LNEK), output, local
Array of the elements, see mesh.
LRPARM integer, scalar, input, local
Length of the real parameter array.
RPARM double precision, array: RPARM(LRPARM), output, local
Real parameter array, see mesh.
LIPARM integer, scalar, input, local
Length of the integer parameter array.
IPARM integer, array: IPARM(LIPARM), output, local
Integer parameter array, see mesh.
LDNOD integer, scalar, input, local
Length of the array of the Dirichlet nodes.
DNOD integer, array: DNOD(LDNOD), input, local
Array of the Dirichlet nodes, see mesh.
LRDPRM integer, scalar, input, local
Length of the real Dirichlet parameter array.
RDPARM double precision, array: RDPARM(LRDPRM), output, local
Array of the real Dirichlet parameters, see mesh.
LIDPRM integer, scalar, input, local
Length of the integer Dirichlet parameter array.
IDPARM integer, array: IDPARM(LIDPRM), output, local
Array of the integer Dirichlet parameters, see mesh.
LNODN integer, scalar, input, local
Length of the array of the id numbers of the geometrical nodes.
NODNUM integer, array: NODNUM(LNODN), output, local
Array of the id numbers of the geometrical nodes, see mesh.
LNOD integer, scalar, input, local
Length of the array of the coordinates of the geometrical nodes.
NOD double precision, array: NOD(LNOD), output, local
Array of the coordinates of the geometrical nodes, see mesh.
LNOPRM integer, scalar, input, local
Length of the array of the node parameters.
NOPARM double precision, array: NOPARM(LNOPRM), output, local
Array of the node parameters, see mesh.
LBIG integer, scalar, input, local
Length of the real work array. The needed length of LBIG depends on the given mesh. A minimal length of LBIG cannot be given. It should be as large as possible.
RBIG double precision, array: RBIG(LBIG), work array, local
Real work array.
IBIG integer, array: IBIG(*), work array, local
Integer work array, RBIG and IBIG have to be defined by the EQUIVALENCE statement.

DATA FORMAT

The mesh file has three parts. In the first part the geometrical nodes are specified, in the second part the elements are described and in the third part the Dirichlet conditions are set.

Nodes

The node coordinates are written to unit UNIT by the following FORTRAN code:

    WRITE(UNIT,*) NDEG
    DO i=1,NDEG
      WRITE(UNIT,*) NODNUM,NOD(1),NOD(2),NOD(3)
    ENDDO

where NDEG is the number of nodes in the mesh and the node with node id NODNUM has the coordinates (NOD(1), NOD(2), NOD(3)).
For a two-dimensional mesh, set NOD(3)=0; for a one-dimensional mesh, set NOD(2)=NOD(3)=0.

Elements

The elements are written to unit UNIT by the following FORTRAN code:

    WRITE(UNIT,*) NGROUP
    DO k=1,NGROUP
       WRITE(UNIT,*) NE,CLASS,FORM,GEOTYP
       DO i=1,NE
          WRITE(UNIT,*) ELEMID,INDEX,(NEK(j),j=1,GEOTYP)
       ENDDO
    ENDDO

where NGROUP specifies the number of different element types and NE the number of elements of type (CLASS, FORM, GEOTYP). ELEMID is the id number of the element and must be unique. INDEX is an arbitray integer values. It is stored as the second integer vector parameter and can be used to refer into a material table. NEK gives the id number of the GEOTYP nodes which describe the element. The following figure shows the allowed elements of order two and the succession of the describing nodes:

domain

CLASS

FORM

GEOTYP

VECFEM elements

point

0

1

1

1

line

1

2

3

1--3--2

area

2

3

6

3
| \
6  5
|    \
1--4--2

 

2

4

8

4--7--3
|     |
8     6
|     |
1--5--2

volume

3

6

15

       6
     / : \
   15  :  14
  /    :    \
 4-----13------5
 |      :      |
 |     12      |
 |      :      |
10      3      11
 |    /   \    |
 |  9       8  |
 | /          \|
 1------7------2

 

3

4

10

4
|\ \
| \  10
|  \    \
|   9      3
|    \   /  |
8      X    6
|     / \   |
|   7    \  |
| /        \
1----5------2

 

3

8

20

     8-----19------7
    / :            /:
  20  :          18 :
  /   :         /   :
 5-------17-----6    :
 |     :        |    :
 |    16        |   15
13     :       14    :
 |     4-----11-|----3
 |    /         |   /
 |  12          | 10
 | /            |/
 1-------9------2

Additionally vemu02 considers all VECFEM elements which are described in the manual.

Dirichlet Conditions

The Dirichlet conditions are written to unit UNIT by the following FORTRAN code:

    WRITE(UNIT,*) NK
    DO d=1,NK
       WRITE(UNIT,*) NDC
       DO i=1,NDC
          WRITE(UNIT,*) DNOD,PREVALUE
       ENDDO
    ENDDO

where NK specifies the number of solution components and NDC the number of nodes with Dirichlet conditions for component d. DNOD is the id number of the node at which a Dirichlet condition is set, and PREVALUE is a real number which in general specifies the value of the Dirichlet Condition at this node.

EXAMPLE

see vemexamples.

METHOD

On the first process, vemu02 passes through the mesh file twice. In the first pass the program checks the mesh file and computes the needed length for the mesh arrays. In the second pass vemu02 reads the mesh data and distributes the mesh to the other processes so that the mesh arrays are occupied evenly.

The Nodes

If DIM=3, vemu02 reads the x1-,x2- and x3-coordinates from the mesh file. If DIM=2, only the x1- and x2- coordinates are read, and if DIM=1, only the x1-coordinate is read.

The Elements

The id numbers of the geometrical nodes which define the elements are stored into NEK. The groups are split up by the element parameters (GEOTYP,FORM,CLASS) so that a minimal number of groups will be created. Therefore the actual number of groups in the mesh could be different from the number of groups specified in the mesh file. The element id is stored as the first integer vector parameter. The index INDEX is stored as the second integer parameter.

Dirichlet Conditions

The id numbers of the geometrical nodes which are specified for Dirichlet conditions are stored into DNOD. The real parameter PREVALUE for the condition is stored as the first real vector parameter.

REFERENCES

[FAQ], [DATAMAN], [DATAMAN2], [P_MPI].

SEE ALSO

VECFEM, vemcompile, vemrun, vemhint, mesh, vemexamples, vemdis.

COPYRIGHTS

Program by
Program by L. Grosz, 1994-1996. opyrights by Universitaet Karlsruhe 1989-1996. Copyrights by Lutz Grosz 1996. All rights reserved. More details see VECFEM.
by L. Grosz, Auckland , 6. June, 2000.