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
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.
26
21
!-------------------------------------------------------------------------------
28
23
subroutine strpre &
31
( idbia0 , idbra0 , itrale , italim , ineefl , &
32
ndim , ncelet , ncel , nfac , nfabor , nfml , nprfml , &
33
nnod , lndfac , lndfbr , ncelbr , &
34
nideve , nrdeve , nituse , nrtuse , &
35
ifacel , ifabor , ifmfbr , ifmcel , iprfml , &
36
ipnfac , nodfac , ipnfbr , nodfbr , &
26
( itrale , italim , ineefl , &
38
idevel , ituser , ia , &
39
xyzcen , surfac , surfbo , cdgfac , cdgfbo , xyznod , volume , &
40
28
rtp , rtpa , propce , propfa , propfb , &
42
flmalf , flmalb , xprale , cofale , depale , rdevel , rtuser , &
30
flmalf , flmalb , xprale , cofale , depale )
45
32
!===============================================================================
53
40
!__________________.____._____.________________________________________________.
54
41
! name !type!mode ! role !
55
42
!__________________!____!_____!________________________________________________!
56
! idbia0 ! i ! <-- ! number of first free position in ia !
57
! idbra0 ! i ! <-- ! number of first free position in ra !
58
43
! itrale ! e ! <-- ! numero d'iteration pour l'ale !
59
44
! italim ! e ! <-- ! numero d'iteration couplage implicite !
60
45
! ineedf ! e ! <-- ! indicateur de sauvegarde des flux !
61
! ndim ! i ! <-- ! spatial dimension !
62
! ncelet ! i ! <-- ! number of extended (real + ghost) cells !
63
! ncel ! i ! <-- ! number of cells !
64
! nfac ! i ! <-- ! number of interior faces !
65
! nfabor ! i ! <-- ! number of boundary faces !
66
! nfml ! i ! <-- ! number of families (group classes) !
67
! nprfml ! i ! <-- ! number of properties per family (group class) !
68
! nnod ! i ! <-- ! number of vertices !
69
! lndfac ! i ! <-- ! size of nodfac indexed array !
70
! lndfbr ! i ! <-- ! size of nodfbr indexed array !
71
! ncelbr ! i ! <-- ! number of cells with faces on boundary !
72
46
! nvar ! i ! <-- ! total number of variables !
73
47
! nscal ! i ! <-- ! total number of scalars !
74
! nphas ! i ! <-- ! number of phases !
75
! nideve, nrdeve ! i ! <-- ! sizes of idevel and rdevel arrays !
76
! nituse, nrtuse ! i ! <-- ! sizes of ituser and rtuser arrays !
77
! ifacel(2, nfac) ! ia ! <-- ! interior faces -> cells connectivity !
78
! ifabor(nfabor) ! ia ! <-- ! boundary faces -> cells connectivity !
79
! ifmfbr(nfabor) ! ia ! <-- ! boundary face family numbers !
80
! ifmcel(ncelet) ! ia ! <-- ! cell family numbers !
81
! iprfml ! ia ! <-- ! property numbers per family !
82
! (nfml, nprfml) ! ! ! !
83
! ipnfac ! te ! <-- ! position du premier noeud de chaque !
84
! (nfac+1) ! ! ! face interne dans nodfac (optionnel) !
85
! nodfac ! te ! <-- ! connectivite faces internes/noeuds !
86
! (lndfac) ! ! ! (optionnel) !
87
! ipnfbr ! te ! <-- ! position du premier noeud de chaque !
88
! (nfabor+1) ! ! ! face de bord dans nodfbr (optionnel) !
89
! nodfbr ! te ! <-- ! connectivite faces de bord/noeuds !
90
! (lndfbr) ! ! ! (optionnel) !
91
! idevel(nideve) ! ia ! <-> ! integer work array for temporary development !
92
! ituser(nituse) ! ia ! <-> ! user-reserved integer work array !
93
! ia(*) ! ia ! --- ! main integer work array !
94
! xyzcen ! ra ! <-- ! cell centers !
95
! (ndim, ncelet) ! ! ! !
96
! surfac ! ra ! <-- ! interior faces surface vectors !
97
! (ndim, nfac) ! ! ! !
98
! surfbo ! ra ! <-- ! boundary faces surface vectors !
99
! (ndim, nfabor) ! ! ! !
100
! cdgfac ! ra ! <-- ! interior faces centers of gravity !
101
! (ndim, nfac) ! ! ! !
102
! cdgfbo ! ra ! <-- ! boundary faces centers of gravity !
103
! (ndim, nfabor) ! ! ! !
104
! xyznod ! ra ! <-- ! vertex coordinates (optional) !
105
! (ndim, nnod) ! ! ! !
106
! volume(ncelet) ! ra ! <-- ! cell volumes !
107
48
! rtp, rtpa ! ra ! <-- ! calculated variables at cell centers !
108
49
! (ncelet, *) ! ! ! (at current and previous time steps) !
109
50
! propce(ncelet, *)! ra ! <-- ! physical properties at cell centers !
118
59
! xprale(ncelet ! tr ! --> ! sauvegarde de la pression, si nterup !
120
61
! depale(nnod,3 ! tr ! <-- ! deplacement aux noeuds !
121
! rdevel(nrdeve) ! ra ! <-> ! real work array for temporary development !
122
! rtuser(nrtuse) ! ra ! <-> ! user-reserved real work array !
123
! ra(*) ! ra ! --- ! main real work array !
124
62
!__________________!____!_____!________________________________________________!
126
64
! TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
127
65
! L (LOGIQUE) .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
128
66
! MODE : <-- donnee, --> resultat, <-> Donnee modifiee
129
67
! --- tableau de travail
68
!===============================================================================
70
!===============================================================================
72
!===============================================================================
75
use dimens, only: ndimfb
79
use albase, only: nalimx
131
87
!===============================================================================
135
!===============================================================================
137
!===============================================================================
151
!===============================================================================
155
integer idbia0 , idbra0 , itrale , italim , ineefl
156
integer ndim , ncelet , ncel , nfac , nfabor
157
integer nfml , nprfml
158
integer nnod , lndfac , lndfbr , ncelbr
159
integer nideve , nrdeve , nituse , nrtuse
93
integer itrale , italim , ineefl
161
integer ifacel(2,nfac) , ifabor(nfabor)
162
integer ifmfbr(nfabor) , ifmcel(ncelet)
163
integer iprfml(nfml,nprfml)
164
integer ipnfac(nfac+1), nodfac(lndfac)
165
integer ipnfbr(nfabor+1), nodfbr(lndfbr)
166
95
integer impale(nnod)
167
integer idevel(nideve), ituser(nituse)
170
double precision xyzcen(ndim,ncelet)
171
double precision surfac(ndim,nfac), surfbo(ndim,nfabor)
172
double precision cdgfac(ndim,nfac), cdgfbo(ndim,nfabor)
173
double precision xyznod(ndim,nnod), volume(ncelet)
174
97
double precision rtp(ncelet,*), rtpa(ncelet,*)
175
98
double precision propce(ncelet,*)
176
99
double precision propfa(nfac,*), propfb(nfabor,*)
178
101
double precision flmalf(nfac), flmalb(nfabor), xprale(ncelet)
179
102
double precision cofale(nfabor,8)
180
103
double precision depale(nnod,3)
181
double precision rdevel(nrdeve), rtuser(nrtuse), ra(*)
183
105
! Local variables
185
integer idebia, idebra, ifinia
186
107
integer istr, ii, ifac, inod, iel, indast
187
108
integer iflmas, iflmab,iclp,iclu,iclv,iclw
110
integer, allocatable, dimension(:) :: lstfac
190
112
!===============================================================================
194
116
! 1. INITIALISATION
195
117
!===============================================================================
200
iflmas = ipprof(ifluma(iu(1)))
201
iflmab = ipprob(ifluma(iu(1)))
202
iclp = iclrtp(ipr(1),icoef)
203
iclu = iclrtp(iu(1),icoef)
204
iclv = iclrtp(iv(1),icoef)
205
iclw = iclrtp(iw(1),icoef)
120
iflmas = ipprof(ifluma(iu))
121
iflmab = ipprob(ifluma(iu))
122
iclp = iclrtp(ipr,icoef)
123
iclu = iclrtp(iu,icoef)
124
iclv = iclrtp(iv,icoef)
125
iclw = iclrtp(iw,icoef)
207
127
!===============================================================================
208
128
! 2. PREDICTION DU DEPLACEMENT DES STRUCTURES