Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PEUL_BcondOutflow.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: update values in dummy cells for smoke at outflow boundary patch.
26 !
27 ! Description: none.
28 !
29 ! Input: region = region dimensions, user input
30 ! patch = current patch.
31 !
32 ! Output: region%levels%peul = smoke variables in dummy cells.
33 !
34 ! Notes: none.
35 !
36 !******************************************************************************
37 !
38 ! $Id: PEUL_BcondOutflow.F90,v 1.5 2008/12/06 08:44:38 mtcampbe Exp $
39 !
40 ! Copyright: (c) 2002 by the University of Illinois
41 !
42 !******************************************************************************
43 
44 SUBROUTINE peul_bcondoutflow( region,patch )
45 
46  USE moddatatypes
47  USE modbndpatch, ONLY : t_patch
48  USE moddatastruct, ONLY : t_region
49  USE modglobal, ONLY : t_global
50  USE moderror
51  USE modparameters
53 
56  IMPLICIT NONE
57 
58 #include "Indexing.h"
59 
60 ! ... parameters
61  TYPE(t_region), INTENT(INOUT) :: region
62  TYPE(t_patch), INTENT(IN) :: patch
63 
64 ! ... loop variables
65  INTEGER :: idum, i, j, k
66 
67 ! ... local variables
68  CHARACTER(CHRLEN) :: rcsidentstring
69 
70  INTEGER :: ibeg, iend, jbeg, jend, kbeg, kend, idir, jdir, kdir
71  INTEGER :: ilev, lbound, icoff, ijcoff, ijkc, ijkc1, ijkd
72 
73  REAL(RFREAL), POINTER :: cv(:,:)
74 
75  TYPE(t_global), POINTER :: global
76 
77 !******************************************************************************
78 
79  rcsidentstring = '$RCSfile: PEUL_BcondOutflow.F90,v $ $Revision: 1.5 $'
80 
81  global => region%global
82 
83  CALL registerfunction( global,'PEUL_BcondOutflow',&
84  'PEUL_BcondOutflow.F90' )
85 
86 ! begin -----------------------------------------------------------------------
87 
88 ! get dimensions and pointers
89 
90  ilev = region%currLevel
91  lbound = patch%lbound
92 
93  CALL rflo_getpatchindices( region,patch,ilev, &
94  ibeg,iend,jbeg,jend,kbeg,kend )
96  CALL rflo_getcelloffset( region,ilev,icoff,ijcoff )
97 
98  cv => region%levels(ilev)%peul%cv
99 
100 ! loop over all cells of a patch
101 
102  DO idum=1,region%nDumCells
103 
104  IF (idum==1) THEN
105  DO k=kbeg,kend
106  DO j=jbeg,jend
107  DO i=ibeg,iend
108  ijkd = &
109  indijk(i- idum *idir,j- idum *jdir,k- idum *kdir,icoff,ijcoff)
110  ijkc = &
111  indijk(i-(idum-1)*idir,j-(idum-1)*jdir,k-(idum-1)*kdir,icoff,ijcoff)
112  ijkc1 = &
113  indijk(i-(idum-2)*idir,j-(idum-2)*jdir,k-(idum-2)*kdir,icoff,ijcoff)
114 
115  cv(:,ijkd) = 2._rfreal*cv(:,ijkc ) - cv(:,ijkc1) ! to be changed by
116  ! convective bc
117  ENDDO ! i
118  ENDDO ! j
119  ENDDO ! k
120  ELSE
121  DO k=kbeg,kend
122  DO j=jbeg,jend
123  DO i=ibeg,iend
124  ijkd = &
125  indijk(i- idum *idir,j- idum *jdir,k- idum *kdir,icoff,ijcoff)
126  ijkc = &
127  indijk(i-(idum-1)*idir,j-(idum-1)*jdir,k-(idum-1)*kdir,icoff,ijcoff)
128  ijkc1 = &
129  indijk(i-(idum-2)*idir,j-(idum-2)*jdir,k-(idum-2)*kdir,icoff,ijcoff)
130 
131  cv(:,ijkd) = 2._rfreal*cv(:,ijkc ) - cv(:,ijkc1)
132  ENDDO ! i
133  ENDDO ! j
134  ENDDO ! k
135  ENDIF ! idum
136  ENDDO ! idum
137 
138 ! finalize --------------------------------------------------------------------
139 
140  CALL deregisterfunction( global )
141 
142 END SUBROUTINE peul_bcondoutflow
143 
144 !******************************************************************************
145 !
146 ! RCS Revision history:
147 !
148 ! $Log: PEUL_BcondOutflow.F90,v $
149 ! Revision 1.5 2008/12/06 08:44:38 mtcampbe
150 ! Updated license.
151 !
152 ! Revision 1.4 2008/11/19 22:17:51 mtcampbe
153 ! Added Illinois Open Source License/Copyright
154 !
155 ! Revision 1.3 2006/03/16 20:36:50 wasistho
156 ! reset to linear extrap. for now
157 !
158 ! Revision 1.2 2006/03/15 19:50:30 wasistho
159 ! improve peul outflow
160 !
161 ! Revision 1.1 2004/12/01 21:09:17 haselbac
162 ! Initial revision after changing case
163 !
164 ! Revision 1.3 2003/05/15 02:57:05 jblazek
165 ! Inlined index function.
166 !
167 ! Revision 1.2 2003/04/09 15:12:04 jferry
168 ! miscellaneous stylistic changes
169 !
170 ! Revision 1.1 2003/02/11 22:52:50 jferry
171 ! Initial import of Rocsmoke
172 !
173 !******************************************************************************
174 
175 
176 
177 
178 
179 
180 
**********************************************************************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 SUBROUTINE ibeg
subroutine rflo_getpatchdirection(patch, idir, jdir, kdir)
j indices k indices k
Definition: Indexing.h:6
subroutine registerfunction(global, funName, fileName)
Definition: ModError.F90:449
subroutine rflo_getpatchindices(region, patch, iLev, ibeg, iend, jbeg, jend, kbeg, kend)
**********************************************************************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 SUBROUTINE jdir
Definition: patch.h:74
**********************************************************************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 SUBROUTINE knode iend
blockLoc i
Definition: read.cpp:79
**********************************************************************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 SUBROUTINE idir
subroutine rflo_getcelloffset(region, iLev, iCellOffset, ijCellOffset)
subroutine peul_bcondoutflow(region, patch)
j indices j
Definition: Indexing.h:6
**********************************************************************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 SUBROUTINE knode jend
**********************************************************************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 SUBROUTINE kdir
**********************************************************************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 SUBROUTINE knode jbeg
**********************************************************************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 SUBROUTINE knode kbeg
subroutine deregisterfunction(global)
Definition: ModError.F90:469