1
!-------------------------------------------------------------------------------
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
!-------------------------------------------------------------------------------
26
( ncelet , ncel , nvar , &
30
!===============================================================================
34
! CLIPPING DE PHI EN V2F (PAS DE CLIPPING SUR F_BARRE)
36
!-------------------------------------------------------------------------------
39
!__________________.____._____.________________________________________________.
40
! name !type!mode ! role !
41
!__________________!____!_____!________________________________________________!
42
! ncelet ! i ! <-- ! number of extended (real + ghost) cells !
43
! ncel ! e ! <-- ! nombre de cellules !
44
! nvar ! e ! <-- ! nombre de variables !
45
! iwaphi ! e ! <-- ! niveau d'impression !
46
! propce ! tr ! <-- ! tableaux des variables au pdt courant !
48
! rtp ! tr ! <-- ! tableaux des variables au pdt courant !
49
! (ncelet,nvar) ! ! ! !
50
!__________________!____!_____!________________________________________________!
52
! TYPE : E (ENTIER), R (REEL), A (ALPHANUMERIQUE), T (TABLEAU)
53
! L (LOGIQUE) .. ET TYPES COMPOSES (EX : TR TABLEAU REEL)
54
! MODE : <-- donnee, --> resultat, <-> Donnee modifiee
55
! --- tableau de travail
56
!===============================================================================
58
!===============================================================================
60
!===============================================================================
69
!===============================================================================
75
integer nvar, ncelet, ncel
77
double precision propce(ncelet,*)
78
double precision rtp(ncelet,nvar)
83
integer nclpmx, nclpmn
84
double precision xphi, xal, vmin, vmax, var
86
!===============================================================================
88
!===============================================================================
89
! 1. Pour le phi-fbar et BL-v2/k model, reperage des valeurs de phi
90
! superieures a 2 et clipping de phi en valeur absolue
91
! pour les valeurs negatives
92
!===============================================================================
94
!===============================================================================
95
! 1.a Stockage Min et Max pour listing
96
!===============================================================================
107
if (irangp.ge.0) then
116
!==============================================================================
117
! 1.b Reperage des valeurs superieures a 2, pour affichage seulement
118
!==============================================================================
120
if (iwaphi.ge.2) then
123
if (rtp(iel,iphi).gt.2.d0) nclpmx = nclpmx+1
125
if(irangp.ge.0) call parcpt(nclpmx)
127
if (nclpmx.gt.0) write(nfecra,1000) nclpmx
130
!==============================================================================
131
! 1.c Clipping en valeur absolue pour les valeurs negatives
132
!==============================================================================
137
if (xphi.lt.0.d0) then
138
rtp(iel,iphi) = -xphi
142
if(irangp.ge.0) call parcpt(nclpmn)
146
!===============================================================================
147
! 2. Pour le BL-v2/k model, clipping de alpha a 0 pour les valeurs negatives
148
! et a 1 pour les valeurs superieurs a 1
149
!===============================================================================
153
!===============================================================================
154
! 2.a Stockage Min et Max pour listing
155
!===============================================================================
166
if (irangp.ge.0) then
175
!==============================================================================
176
! 2.b Clipping a 0 pour les valeurs negatives et a 1 pour les valeurs
178
!==============================================================================
184
if (xal.lt.0.d0) then
188
if (xal.gt.1.d0) then
204
!===============================================================================
206
!===============================================================================
208
#if defined(_CS_LANG_FR)
210
1000 format('ATTENTION VARIABLE PHI' &
211
'VALEUR MAXIMALE PHYSIQUE DE 2 DEPASSEE SUR ',I10, &
216
1000 format('WARNING VARIABLE PHI' &
217
'MAXIMUM PHYSICAL VALUE OF 2 EXCEEDED FOR ',I10, &