Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PERI_PrintUserInput.F90
Go to the documentation of this file.
1 ! *********************************************************************
2 ! * Rocstar Simulation Suite *
3 ! * Copyright@2015, Illinois Rocstar LLC. All rights reserved. *
4 ! * *
5 ! * Illinois Rocstar LLC *
6 ! * Champaign, IL *
7 ! * www.illinoisrocstar.com *
8 ! * sales@illinoisrocstar.com *
9 ! * *
10 ! * License: See LICENSE file in top level of distribution package or *
11 ! * http://opensource.org/licenses/NCSA *
12 ! *********************************************************************
13 ! *********************************************************************
14 ! * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, *
15 ! * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES *
16 ! * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND *
17 ! * NONINFRINGEMENT. IN NO EVENT SHALL THE CONTRIBUTORS OR *
18 ! * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER *
19 ! * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, *
20 ! * Arising FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE *
21 ! * USE OR OTHER DEALINGS WITH THE SOFTWARE. *
22 ! *********************************************************************
23 !******************************************************************************
24 !
25 ! Purpose: Write out PERI user input for checking purposes.
26 !
27 ! Description: none.
28 !
29 ! Input: region = user input in current region.
30 !
31 ! Output: to standard output (monitor).
32 !
33 ! Notes: none.
34 !
35 !******************************************************************************
36 !
37 ! $Id: PERI_PrintUserInput.F90,v 1.4 2008/12/06 08:44:36 mtcampbe Exp $
38 !
39 ! Copyright: (c) 2001 by the University of Illinois
40 !
41 !******************************************************************************
42 
43 SUBROUTINE peri_printuserinput( region ) ! PUBLIC
44 
45  USE moddatatypes
46  USE modglobal, ONLY : t_global
47  USE moddatastruct, ONLY : t_region
48  USE moderror
49  USE modparameters
51  IMPLICIT NONE
52 
53 ! ... parameters
54  TYPE(t_region) :: region
55 
56 ! ... loop variables
57 
58 ! ... local variables
59  CHARACTER(CHRLEN) :: rcsidentstring
60  TYPE(t_global), POINTER :: global
61 
62  INTEGER :: flowkind, split(3)
63  REAL(RFREAL) :: rgas
64 
65 ! ... cpr and channel local variables
66  REAL(RFREAL) :: meanpgrad, bulkmflux, delta
67 
68 ! ... cpr local variables
69  REAL(RFREAL) :: minjrate, cprepsilon, headpres, headtemp
70 
71 ! ... channel local variables
72  INTEGER :: pgradtype
73  REAL(RFREAL) :: retau, utau, ucenter, tauwall, skinfriction
74 
75 !******************************************************************************
76 
77  rcsidentstring = '$RCSfile: PERI_PrintUserInput.F90,v $'
78 
79  global => region%global
80  CALL registerfunction( global,'PERI_PrintUserInput',&
81  'PERI_PrintUserInput.F90' )
82 
83 ! get pointers and parameters -------------------------------------------------
84 
85 ! general:
86  rgas = global%refCp*(1._rfreal - 1._rfreal/global%refGamma)
87  flowkind = region%periInput%flowKind
88  split(1:3) = region%periInput%split(icoord:kcoord)
89 
90 ! CPR and channel:
91  delta = global%refLength
92  meanpgrad = region%periInput%meanPgrad
93  bulkmflux = region%periInput%bulkmFlux
94 
95 ! CPR:
96  minjrate = region%periInput%minjRate
97  cprepsilon = region%periInput%cprEpsilon
98  headpres = region%periInput%headPres
99  headtemp = region%periInput%headTemp
100 
101 ! channel:
102  pgradtype = region%periInput%pgradType
103  retau = region%periInput%cnlRetau
104  utau = region%periInput%cnlUtau
105  ucenter = region%periInput%cnlCvel
106 
107  tauwall = global%refDensity*utau**2._rfreal
108  skinfriction= 2._rfreal*(utau/ucenter)**2._rfreal
109 
110 ! periodic flow case selection
111 
112  WRITE(stdout,1005) solver_name//' Specific flow case, periodic flow:'
113  IF (flowkind==peri_flow_cpr) THEN
114  WRITE(stdout,1030) solver_name//' periodic flow kind = CPR'
115  ELSEIF (flowkind==peri_flow_channel) THEN
116  WRITE(stdout,1030) solver_name//' periodic flow kind = CHANNEL'
117  ELSEIF (flowkind==peri_flow_bola) THEN
118  WRITE(stdout,1030) solver_name//' periodic flow kind = Boundary Layer'
119  ENDIF
120  WRITE(stdout,1010) solver_name//' i,j,k parallel split =', &
121  split(icoord),split(jcoord),split(kcoord), &
122  ' (1 = split domain, 0 = unsplit)'
123 
124 ! model tools selection
125 
126  IF (flowkind==peri_flow_cpr) THEN
127 
128 ! - CPR part
129 
130  WRITE(stdout,1030) solver_name//' input-data relevant to CPR flow:'
131 
132  WRITE(stdout,1020) solver_name//' derived gas constant =',rgas
133  WRITE(stdout,1020) solver_name//' mass injection rate =',minjrate
134  WRITE(stdout,1020) solver_name//' ratio inj/bulk mrate =',cprepsilon
135  WRITE(stdout,1020) solver_name//' head end pressure =',headpres
136  WRITE(stdout,1020) solver_name//' head end temperature =',headtemp
137  WRITE(stdout,1020) solver_name//' lengthscale delta =',delta
138  WRITE(stdout,1020) solver_name//' based on above parameters:'
139  WRITE(stdout,1020) solver_name//' bulk mass flux =',bulkmflux
140  WRITE(stdout,1020) solver_name//' mean pressure grad. =',meanpgrad
141 
142  ELSEIF (flowkind==peri_flow_channel) THEN
143 
144 ! - CHANNEL part
145 
146  WRITE(stdout,1030) solver_name//' input-data relevant to Channel flow:'
147  IF (pgradtype == cnl_pgrad_tauwall) THEN
148  WRITE(stdout,1030) solver_name//' calc. method dpdx = tau wall based'
149  ELSE
150  WRITE(stdout,1030) solver_name//' calc. method dpdx = mass flux based'
151  ENDIF
152  WRITE(stdout,1020) solver_name//' reTau =',retau
153  WRITE(stdout,1020) solver_name//' utau =',utau
154  WRITE(stdout,1020) solver_name//' ucenter =',ucenter
155  WRITE(stdout,1020) solver_name//' tauWall =',tauwall
156  WRITE(stdout,1020) solver_name//' skinFriction =',skinfriction
157  WRITE(stdout,1020) solver_name//' based on above parameters:'
158  WRITE(stdout,1020) solver_name//' bulk mass flux =',bulkmflux
159  WRITE(stdout,1020) solver_name//' mean pressure grad. =',meanpgrad
160 
161  ELSEIF (flowkind==peri_flow_bola) THEN
162  ENDIF
163 
164 ! finish ----------------------------------------------------------------------
165 
166  CALL deregisterfunction( global )
167 
168 1005 FORMAT(/,a)
169 1010 FORMAT(2x,a,3i4,a)
170 1020 FORMAT(2x,a,e12.5)
171 1030 FORMAT(2x,a)
172 
173 END SUBROUTINE peri_printuserinput
174 
175 !******************************************************************************
176 !
177 ! RCS Revision history:
178 !
179 ! $Log: PERI_PrintUserInput.F90,v $
180 ! Revision 1.4 2008/12/06 08:44:36 mtcampbe
181 ! Updated license.
182 !
183 ! Revision 1.3 2008/11/19 22:17:49 mtcampbe
184 ! Added Illinois Open Source License/Copyright
185 !
186 ! Revision 1.2 2004/06/11 21:49:40 wasistho
187 ! prepared for RFLU
188 !
189 ! Revision 1.1 2004/06/08 23:56:56 wasistho
190 ! changed nomenclature
191 !
192 ! Revision 1.4 2003/09/22 20:18:37 wasistho
193 ! fix screen output of i,j,ksplit
194 !
195 ! Revision 1.3 2003/09/18 01:57:23 wasistho
196 ! added ijksplit and pgradType in PERI_PgradUpdate
197 !
198 ! Revision 1.2 2003/04/02 01:49:13 wasistho
199 ! minimize CPR user input
200 !
201 ! Revision 1.1.1.1 2003/03/29 03:36:30 wasistho
202 ! install ROCPERI
203 !
204 !
205 !
206 !******************************************************************************
207 
208 
209 
210 
211 
212 
213 
subroutine registerfunction(global, funName, fileName)
Definition: ModError.F90:449
void int int REAL * x
Definition: read.cpp:74
RT delta(int i) const
Definition: Direction_2.h:159
void split(Box &region, bool f_neg)
Definition: kdtree_d.h:600
subroutine deregisterfunction(global)
Definition: ModError.F90:469
subroutine peri_printuserinput(region)
RT a() const
Definition: Line_2.h:140