1
1
!-------------------------------------------------------------------------------
3
! This file is part of the Code_Saturne Kernel, element of the
4
! Code_Saturne CFD tool.
6
! Copyright (C) 1998-2009 EDF S.A., France
8
! contact: saturne-support@edf.fr
10
! The Code_Saturne Kernel is free software; you can redistribute it
11
! and/or modify it under the terms of the GNU General Public License
12
! as published by the Free Software Foundation; either version 2 of
13
! the License, or (at your option) any later version.
15
! The Code_Saturne Kernel is distributed in the hope that it will be
16
! useful, but WITHOUT ANY WARRANTY; without even the implied warranty
17
! of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18
! GNU General Public License for more details.
20
! You should have received a copy of the GNU General Public License
21
! along with the Code_Saturne Kernel; if not, write to the
22
! Free Software Foundation, Inc.,
23
! 51 Franklin St, Fifth Floor,
24
! Boston, MA 02110-1301 USA
26
!-------------------------------------------------------------------------------
31
( numgep , nomcas , nomrep , nomfmt , optfmt , &
34
!===============================================================================
38
! CREATION D'UN "WRITER" A PARTIR DES DONNEES FOURNIES PAR LA
39
! COUCHE FORTRAN : ENCAPSULATION COUCHE C POUR LA TRANSMISSION
40
! DES LONGUEURS DES CHAINES DE CARACTERES
42
! UN WRITER CORRESPOND AU CHOIX D'UN NOM DE CAS, DE REPERTOIRE,
43
! ET DE FORMAT, AINSI QU'UN INDICATEUR PRECISANT SI LES MAILLAGES
44
! ASSOCIES DOIVENT DEPENDRE OU NON DU TEMPS, ET LA FREQUENCE
45
! DE SORTIE PAR DEFAUT POUR LES VARIABLES ASSOCIEES
47
!-------------------------------------------------------------------------------
49
!__________________.____._____.________________________________________________.
50
! name !type!mode ! role !
51
!__________________!____!_____!________________________________________________!
52
! numgep ! e ! <-- ! identificateur du gestionnaire !
53
! ! ! ! (< 0 pour gestionnaire reserve, !
54
! ! ! ! > 0 pour gestionnaire utilisateur) !
55
! nomcas ! a ! <-- ! nom du cas associe !
56
! nomrep ! a ! <-- ! nom du repertoire associe !
57
! nomfmt ! a ! <-- ! nom de format associe !
58
! optfmt ! e ! <-- ! options associees au format !
59
! indmod ! e ! <-- ! 0 : maillages figes !
60
! ! ! ! 1 : maillages deformables !
61
! ! ! ! 2 : maillages modifiables !
62
! ntchr ! e ! <-- ! frequence de sortie par defaut !
63
!__________________!____!_____!________________________________________________!
65
! TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
66
! L (LOGIQUE) .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
67
! MODE : <-- donnee, --> resultat, <-> Donnee modifiee
68
! --- tableau de travail
69
!===============================================================================
73
!===============================================================================
75
!===============================================================================
77
!===============================================================================
79
!===============================================================================
83
character*32 nomcas , nomfmt
84
character*96 nomrep , optfmt
85
integer numgep , indmod , ntchr
89
integer lnmcas , lnmrep , lnmfmt , lopfmt
91
!===============================================================================
98
call pstcw1 (numgep, nomcas, nomrep, nomfmt, optfmt, &
100
lnmcas, lnmrep, lnmfmt, lopfmt, &
109
( nummai , nommai , &
110
nbrcel , nbrfac , nbrfbr , lstcel , lstfac , lstfbr )
112
!===============================================================================
116
! CREATION D'UN MAILLAGE DE POST TRAITEMENT A PARTIR DES DONNEES
117
! FOURNIES PAR LA COUCHE FORTRAN : ENCAPSULATION COUCHE C
118
! POUR LA TRANSMISSION DES LONGUEURS DES CHAINES DE CARACTERES
120
! LES LISTES DE CELLULES OU FACES A EXTRAIRE SONT TRIEES EN SORTIE,
121
! QU'ELLES LE SOIENT DEJA EN ENTREE OU NON.
123
! LA LISTE DES CELLULES ASSOCIEES N'EST NECESSAIRE QUE SI LE NOMBRE
124
! DE CELLULES A EXTRAIRE EST STRICTEMENT SUPERIEUR A 0 ET INFERIEUR
125
! AU NOMBRE DE CELLULES DU MAILLAGE.
127
! LES LISTES DE FACES NE SONT PRISES EN COMPTE QUE SI LE NOMBRE DE
128
! CELLULES A EXTRAIRE EST NUL ; SI LE NOMBRE DE FACES DE BORD A
129
! EXTRAIRE EST EGAL AU NOMBRE DE FACES DE BORD DU MAILLAGE GLOBAL,
130
! ET LE NOMBRE DE FACES INTERNES A EXTRAIRE EST NUL, ALORS ON
131
! EXTRAIT PAR DEFAUT LE MAILLAGE DE BORD, ET LA LISTE DES FACES DE
132
! BORD ASSOCIEES N'EST DONC PAS NECESSAIRE.
134
!-------------------------------------------------------------------------------
136
!__________________.____._____.________________________________________________.
137
! name !type!mode ! role !
138
!__________________!____!_____!________________________________________________!
139
! nummai ! e ! <-- ! identificateur du maillage !
140
! ! ! ! (< 0 pour maillage reserve, , !
141
! ! ! ! > 0 pour maillage utilisateur) !
142
! nommai ! a ! <-- ! nom du maillage associe !
143
! nbrcel ! e ! <-- ! nombre de cellules associees !
144
! nbrfac ! e ! <-- ! nombre de faces internes associees !
145
! nbrfbr ! e ! <-- ! nombre de faces de bord associees !
146
! lstcel ! e ! <-- ! liste des cellules associees !
147
! ! e ! ! (inutile si nbrcel >= ncel) !
148
! lstfac ! e ! <-- ! liste des faces internes associees !
149
! lstfbr ! e ! <-- ! liste des faces de bord associees !
150
! ! e ! ! (inutile si nbrfbr = nfabor !
151
! ! e ! ! et nbrfac = 0 ) !
152
!__________________!____!_____!________________________________________________!
154
! TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
155
! L (LOGIQUE) .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
156
! MODE : <-- donnee, --> resultat, <-> Donnee modifiee
157
! --- tableau de travail
158
!===============================================================================
162
!===============================================================================
164
!===============================================================================
166
!===============================================================================
168
!===============================================================================
173
integer nummai, nbrcel, nbrfac, nbrfbr
175
integer lstcel(nbrcel), lstfac(nbrfac), lstfbr(nbrfbr)
181
!===============================================================================
185
call pstcm1 (nummai, nommai, lnmmai, &
187
nbrcel, nbrfac, nbrfbr, lstcel, lstfac, lstfbr)
3
! This file is part of Code_Saturne, a general-purpose CFD tool.
5
! Copyright (C) 1998-2011 EDF S.A.
7
! This program is free software; you can redistribute it and/or modify it under
8
! the terms of the GNU General Public License as published by the Free Software
9
! Foundation; either version 2 of the License, or (at your option) any later
12
! This program is distributed in the hope that it will be useful, but WITHOUT
13
! ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
14
! FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
17
! You should have received a copy of the GNU General Public License along with
18
! this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
19
! Street, Fifth Floor, Boston, MA 02110-1301, USA.
21
!-------------------------------------------------------------------------------
192
23
subroutine psteva &
267
93
subroutine pstsnv &
270
96
( nomvar , nomva2 , nomva3 )
272
98
!===============================================================================
276
! SUPPRESSION DU CARACTERE X, x, OU 1 D'UNE CHAINE DE CARACTERES
277
! FORTRAN SI LES CHAINES COMPAREES SONT IDENTIQUES AU DERNIER
278
! CARACTERE PRES, RESPECTIVEMENT Y, y, OU 2 ET Z, z, OU 3
102
! Remove character X, x, or 1 from a Fortran character string if the
103
! compared strings are identical except for the last character, respectively
104
! Y, y, or 2 and Z, z, or 3.
280
106
!-------------------------------------------------------------------------------
282
108
!__________________.____._____.________________________________________________.
283
109
! name !type!mode ! role !
284
110
!__________________!____!_____!________________________________________________!
285
! nomvar ! e ! <-- ! nom de la variable associee !
286
! nomva2 ! e ! <-- ! nom de la variable 2 associee !
287
! nomva3 ! e ! <-- ! nom de la variable 3 associee !
111
! nomvar ! s ! <-- ! name of the first associated variable !
112
! nomva2 ! s ! <-- ! name of the second associated variable !
113
! nomva3 ! s ! <-- ! name of the third associated variable !
288
114
!__________________!____!_____!________________________________________________!
290
! TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
291
! L (LOGIQUE) .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
292
! MODE : <-- donnee, --> resultat, <-> Donnee modifiee
293
! --- tableau de travail
116
! Type: i (integer), r (real), s (string), a (array), l (logical),
117
! and composite types (ex: ra real array)
118
! mode: <-- input, --> output, <-> modifies data, --- work array
119
!===============================================================================
121
!===============================================================================
123
!===============================================================================
294
125
!===============================================================================
298
!===============================================================================
300
!===============================================================================
302
!===============================================================================
304
!===============================================================================
308
131
character*32 nomvar, nomva2, nomva3
347
! On supprime le caractere lie a la dimension
170
! Remove the character related to the spatial axis
349
IF ( NOMVAR(II:II) .EQ. 'X' &
350
.AND. NOMVA2(II:II) .EQ. 'Y' &
351
.AND. NOMVA3(II:II) .EQ. 'Z') THEN
353
ELSE IF ( NOMVAR(II:II) .EQ. 'x' &
354
.AND. NOMVA2(II:II) .EQ. 'y' &
355
.AND. NOMVA3(II:II) .EQ. 'z') THEN
357
ELSE IF ( NOMVAR(II:II) .EQ. '1' &
358
.AND. NOMVA2(II:II) .EQ. '2' &
359
.AND. NOMVA3(II:II) .EQ. '3') THEN
172
if ( nomvar(ii:ii) .eq. 'X' &
173
.and. nomva2(ii:ii) .eq. 'Y' &
174
.and. nomva3(ii:ii) .eq. 'Z') then
176
else if ( nomvar(ii:ii) .eq. 'x' &
177
.and. nomva2(ii:ii) .eq. 'y' &
178
.and. nomva3(ii:ii) .eq. 'z') then
180
else if ( nomvar(ii:ii) .eq. 'U' &
181
.and. nomva2(ii:ii) .eq. 'V' &
182
.and. nomva3(ii:ii) .eq. 'W') then
184
else if ( nomvar(ii:ii) .eq. 'u' &
185
.and. nomva2(ii:ii) .eq. 'v' &
186
.and. nomva3(ii:ii) .eq. 'w') then
188
else if ( nomvar(ii:ii) .eq. '1' &
189
.and. nomva2(ii:ii) .eq. '2' &
190
.and. nomva3(ii:ii) .eq. '3') then
363
! Si l'on a supprime l'avant-dernier caractere, on
364
! decale le dernier caractere
194
! If the next-to last character was removed, the last one must be shifted.
366
196
if (ii .eq. jj+1) then
367
197
nomvar(ii:ii) = nomvar(jj:jj)