Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ReadMixtureSection.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: Read in user input related to mixture.
26 !
27 ! Description: None.
28 !
29 ! Input:
30 ! regions Data for regions
31 !
32 ! Output: None.
33 !
34 ! Notes: None.
35 !
36 ! ******************************************************************************
37 !
38 ! $Id: ReadMixtureSection.F90,v 1.5 2008/12/06 08:44:09 mtcampbe Exp $
39 !
40 ! Copyright: (c) 2005 by the University of Illinois
41 !
42 ! ******************************************************************************
43 
44 SUBROUTINE readmixturesection(regions)
45 
46  USE moddatatypes
47  USE modglobal, ONLY: t_global
48  USE moderror
49  USE modparameters
50  USE moddatastruct, ONLY: t_region
51 
52  USE modinterfaces, ONLY: readsection
53 
54  IMPLICIT NONE
55 
56 ! ******************************************************************************
57 ! Declarations and definitions
58 ! ******************************************************************************
59 ! ==============================================================================
60 ! Arguments
61 ! ==============================================================================
62 
63  TYPE(t_region), DIMENSION(:), POINTER :: regions
64 
65 ! ==============================================================================
66 ! Local variables
67 ! ==============================================================================
68 
69  INTEGER :: ireg,nvals
70 
71 #ifdef RFLU
72  INTEGER, PARAMETER :: nvals_max = 2
73 #endif
74 
75  CHARACTER(10) :: keys(nvals_max)
76  LOGICAL :: defined(nvals_max)
77  REAL(RFREAL) :: vals(nvals_max)
78  TYPE(t_global), POINTER :: global
79 
80 ! ******************************************************************************
81 ! Start
82 ! ******************************************************************************
83 
84  global => regions(1)%global
85 
86  CALL registerfunction(global,'ReadMixtureSection',&
87  'ReadMixtureSection.F90')
88 
89 ! specify keywords and search for them
90 
91  nvals = nvals_max
92 
93 #ifdef RFLU
94  keys(1) = 'FROZENFLAG'
95  keys(2) = 'GASMODEL'
96 #endif
97 
98 #ifdef RFLU
99  CALL readsection(global,if_input,nvals,keys,vals,defined)
100 
101  DO ireg = lbound(regions,1),ubound(regions,1)
102  IF ( defined(1) .EQV. .true. ) THEN
103  IF ( nint(vals(1)) == 1 ) THEN
104  regions(ireg)%mixtInput%frozenFlag = .true.
105  ELSE
106  regions(ireg)%mixtInput%frozenFlag = .false.
107  END IF ! NINT(vals(1))
108  END IF ! defined
109  END DO ! iReg
110 
111  DO ireg = lbound(regions,1),ubound(regions,1)
112  IF ( defined(2) .EQV. .true. ) THEN
113  regions(ireg)%mixtInput%gasModel = nint(vals(2))
114  END IF ! defined
115  END DO ! iReg
116 #endif
117 
118 ! ******************************************************************************
119 ! End
120 ! ******************************************************************************
121 
122  CALL deregisterfunction(global)
123 
124 END SUBROUTINE readmixturesection
125 
126 ! ******************************************************************************
127 !
128 ! RCS Revision history:
129 !
130 ! $Log: ReadMixtureSection.F90,v $
131 ! Revision 1.5 2008/12/06 08:44:09 mtcampbe
132 ! Updated license.
133 !
134 ! Revision 1.4 2008/11/19 22:17:23 mtcampbe
135 ! Added Illinois Open Source License/Copyright
136 !
137 ! Revision 1.3 2006/04/07 15:19:15 haselbac
138 ! Removed tabs
139 !
140 ! Revision 1.2 2005/11/10 22:20:06 fnajjar
141 ! ACH: Added frozenFlag
142 !
143 ! Revision 1.1 2005/10/31 19:23:53 haselbac
144 ! Initial revision
145 !
146 ! ******************************************************************************
147 
148 
149 
150 
151 
152 
153 
subroutine readmixturesection(regions)
subroutine registerfunction(global, funName, fileName)
Definition: ModError.F90:449
subroutine readsection(global, fileID, nvals, keys, vals, defined)
**********************************************************************Rocstar Simulation Suite Illinois Rocstar LLC All rights reserved ****Illinois Rocstar LLC IL **www illinoisrocstar com **sales illinoisrocstar com WITHOUT WARRANTY OF ANY **EXPRESS OR INCLUDING BUT NOT LIMITED TO THE WARRANTIES **OF FITNESS FOR A PARTICULAR PURPOSE AND **NONINFRINGEMENT IN NO EVENT SHALL THE CONTRIBUTORS OR **COPYRIGHT HOLDERS BE LIABLE FOR ANY DAMAGES OR OTHER WHETHER IN AN ACTION OF TORT OR **Arising OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE **USE OR OTHER DEALINGS WITH THE SOFTWARE **********************************************************************INTERFACE USE ModDataTypes USE nvals
subroutine deregisterfunction(global)
Definition: ModError.F90:469