2. SD cham_elem_s#

2.1. SD description#

This data structure makes it possible to represent the values of discretized fields on the cells of a mesh.

More precisely, access to a real (or complex,…) value of the field is done by specifying:

  • the number of the mesh supporting the finite element (IMA),

  • the number of the stitch (IPT),

  • the number of the sub-point within the point (ISP) (ISP =1 in general),

  • the number of the component of the quantity associated with the field (ICMP),

cham_elem_s (K19): := record


♦ '. CESK ': OJB S V K8 long = 3

♦ '. CESD ': OJB S V I long = 5 + 4*nb_ MAILLE

♦ '. CESC ': OJB S V K8 long = nb_ CMP

♦ '. CESV ': OJB S V /R/C/I/... long = nbval

♦ '. CESL ': OJB S V L long = nbval

2.2. Purpose. CESK#

. CESK (1)

mailla: name of the mesh underlying the fiel_elem_s.

. CESK (2)

nomgd: name of the quantity associated with the fiel_elem_s (“DEPL_R”, “SIEF_R”,…)

. CESK (3)

/” ELNO “: known field at element nodes, /” ELGA “: field known at the Gauss points of the elements, /” ELEM “: constant field per element (we will then say that it is known at the center of gravity)

2.3. Purpose. CESD#

. CESD (1)

nb_ MAILLE: number of cells in the underlying mesh.

. CESD (2)

nb_ CMP: number of CMPS carried by the dots. It is the dimension of the object. CESC

. CESD (3)

nbptmx: maximum number of points carried by the stitches

. CESD (4)

nbspmx: maximum number of sub-points carried by mesh points

. CESD (5)

nucmpmx: the highest order number of the CMP possible in the fiel_elem_s (in the order of the object. CESC)

. CESD (5+4* (ima-1) +1)

nbpt (ima): number of points in the ima mesh.

. CESD (5+4* (ima-1) +2)

nbsp (ima): number of sub-points in the ima mesh.

. CESD (5+4* (ima-1) +3)

nbcmp (ima)

nbcmp (ima): maximum number of CMPS carried by the sub-points of the points of the ima mesh.

. CESD (5+4* (ima-1) +4)

IAD (ima): IAD +1 is the address in the objects. CESLet. CESVde the 1st CMP of the 1st sub-point of the 1st point of the ima mesh (if they exist)

2.4. Purpose. CESC#

. CESC (icmp)

cmp_i: name of the th CMP of the fiel_elem_s

Note:

The order of CMPS in. CESC may be any. You do not have to respect the order of the size catalog. On the other hand, the CMPS must be part of the CMPS of the size nomgd (except for the size VARI_R ) .

2.5. Items. CESL and. CESV#

These objects contain the values of the field _elem_s (. CESV) and booleans (. CESL) indicating whether these values have been affected (or if they are undetermined).

The type JEVEUX (R/C/I/K8,…) of the object. CESV is the size nomgd.

The dimension of these 2 vectors is nbval:

Nbval is the sum over all the ima cells of nbpt (ima) *nbsp (ima)*nbcmp (ima)

to access the ICMP -th CMPdu ISP -th sub- POINTdu IPT -th POINTde the IMA -th MAILLEd “un cham_elem_s, we use the utility routine CESEXI:

CALL CESEXI (STOP, JCESD, JCESL, IMA, IPT, ISP, ICMP, IAD)

where: JCESD and JCESL are the addresses of the objects. CESD and. CESL from fiel_elem_s.

IAD is the « way out » of this routine.

if IAD > 0, it means that the component you are looking for exists in the fiel_elem_s. It can then be retrieved by: VALEUR = ZR (JCESV -1+ IAD) (if the field is real).

if IAD < 0, it means that the requested component has a possible place in the fiel_elem_s but that it is not currently affected. You can then assign a value in the _elem_s field by doing:

ZR (JCESV -1+ IAD) = VALEUR

ZR (JCESL -1+ IAD) =. TRUE.

if IAD = 0, it means that the component you are looking for has no possible place in the fiel_elem_s. That is to say that at least one of the following conditions is true:

IMA > nb_ MAILLE

IPT > nbpt (IMA)

ISP > NbSp (IMA)

ICMP > nbcmp (IMA)

2.6. Example of a loop on the values of a fiel_elem_s#

CALL JEVEUO (CES//'. CESD ',' L ', JCESD)

CALL JEVEUO (CES//'. CESL ',' L ', JCESL)

CALL JEVEUO (CES//'. CESV ',' L ', JCESV)

NBMA = ZI (JCESD -1+1)

DO 40, IMA = 1, NBMA

NBPT = ZI (JCESD -1+5+4* (IMA -1) +1) NBSP = ZI (JCESD -1+5+4* (IMA -1) +2) NBCMP = ZI (JCESD -1+5+4* (IMA -1) +3) DO 30, IPT = 1, NBPT DO 20, ISP = 1, NBSP DO 10, ICMP = 1, NBCMP CALL CESEXI (STOP, JCESD, JCESL, IMA, IPT, ISP, ICMP, IAD) IF (IAD .GT.0) VALEUR = ZR (JCESV -1+ IAD)