60 TYPE(t_region
),
TARGET :: region
63 INTEGER ::
i,
j,
k, ijk, ijkn(8)
66 INTEGER :: icoff, ijcoff, inoff, ijnoff, ibc, iec, ndum, ijknbeg, ijknend
69 REAL(RFREAL) :: gam1, qvel, xc, xb, xe, velx
71 TYPE(t_mixt),
POINTER :: mixt
77 'PREP_InitializeFlowField.F90' )
81 mixt => region%levels(ilev)%mixt
82 input = region%mixtInput
83 ndum = region%nDumCells
92 ALLOCATE( mixt%cv(5,ibc:iec),stat=errorflag )
93 region%global%error = errorflag
94 IF (region%global%error /= 0) &
95 CALL
errorstop( region%global,err_allocate,__line__ )
97 IF (
input%prepIniCase==initflo_uniform)
THEN
98 IF (
input%iniXsplit > 0.5_rfreal*huge(1._rfreal))
THEN
100 gam1 = region%global%refGamma - 1._rfreal
101 qvel = 0.5_rfreal*(
input%iniVelX*
input%iniVelX+ &
105 mixt%cv(cv_mixt_dens,ijk) =
input%iniDens
106 mixt%cv(cv_mixt_xmom,ijk) =
input%iniVelX*
input%iniDens
107 mixt%cv(cv_mixt_ymom,ijk) =
input%iniVelY*
input%iniDens
108 mixt%cv(cv_mixt_zmom,ijk) =
input%iniVelZ*
input%iniDens
109 mixt%cv(cv_mixt_ener,ijk) =
input%iniPress/gam1 +
input%iniDens*qvel
116 ijk = indijk(
i,
j,
k,icoff,ijcoff)
117 ijkn(1) = indijk(
i ,
j ,
k ,inoff,ijnoff)
118 ijkn(2) = indijk(
i+1,
j ,
k ,inoff,ijnoff)
119 ijkn(3) = indijk(
i+1,
j+1,
k ,inoff,ijnoff)
120 ijkn(4) = indijk(
i ,
j+1,
k ,inoff,ijnoff)
121 ijkn(5) = indijk(
i ,
j ,
k+1,inoff,ijnoff)
122 ijkn(6) = indijk(
i+1,
j ,
k+1,inoff,ijnoff)
123 ijkn(7) = indijk(
i+1,
j+1,
k+1,inoff,ijnoff)
124 ijkn(8) = indijk(
i ,
j+1,
k+1,inoff,ijnoff)
126 gam1 = region%global%refGamma - 1._rfreal
128 (region%levels(ilev)%grid%xyz(xcoord,ijkn(1)) + &
129 region%levels(ilev)%grid%xyz(xcoord,ijkn(2)) + &
130 region%levels(ilev)%grid%xyz(xcoord,ijkn(3)) + &
131 region%levels(ilev)%grid%xyz(xcoord,ijkn(4)) + &
132 region%levels(ilev)%grid%xyz(xcoord,ijkn(5)) + &
133 region%levels(ilev)%grid%xyz(xcoord,ijkn(6)) + &
134 region%levels(ilev)%grid%xyz(xcoord,ijkn(7)) + &
135 region%levels(ilev)%grid%xyz(xcoord,ijkn(8)))
136 IF (xc <=
input%iniXsplit)
THEN
137 qvel = 0.5_rfreal*(
input%iniVelX*
input%iniVelX+ &
141 mixt%cv(cv_mixt_dens,ijk) =
input%iniDens
142 mixt%cv(cv_mixt_xmom,ijk) =
input%iniVelX*
input%iniDens
143 mixt%cv(cv_mixt_ymom,ijk) =
input%iniVelY*
input%iniDens
144 mixt%cv(cv_mixt_zmom,ijk) =
input%iniVelZ*
input%iniDens
145 mixt%cv(cv_mixt_ener,ijk) =
input%iniPress/gam1+
input%iniDens*qvel
147 qvel = 0.5_rfreal*(
input%iniVelX2*
input%iniVelX2+ &
151 mixt%cv(cv_mixt_dens,ijk) =
input%iniDens2
152 mixt%cv(cv_mixt_xmom,ijk) =
input%iniVelX2*
input%iniDens2
153 mixt%cv(cv_mixt_ymom,ijk) =
input%iniVelY2*
input%iniDens2
154 mixt%cv(cv_mixt_zmom,ijk) =
input%iniVelZ2*
input%iniDens2
155 mixt%cv(cv_mixt_ener,ijk) =
input%iniPress2/gam1+
input%iniDens2*qvel
163 IF (
input%prepIniCase==initflo_piston_expan)
THEN
168 ijk = indijk(
i,
j,
k,icoff,ijcoff)
169 ijkn(1) = indijk(
i ,
j ,
k ,inoff,ijnoff)
170 ijkn(2) = indijk(
i+1,
j ,
k ,inoff,ijnoff)
171 ijkn(3) = indijk(
i+1,
j+1,
k ,inoff,ijnoff)
172 ijkn(4) = indijk(
i ,
j+1,
k ,inoff,ijnoff)
173 ijkn(5) = indijk(
i ,
j ,
k+1,inoff,ijnoff)
174 ijkn(6) = indijk(
i+1,
j ,
k+1,inoff,ijnoff)
175 ijkn(7) = indijk(
i+1,
j+1,
k+1,inoff,ijnoff)
176 ijkn(8) = indijk(
i ,
j+1,
k+1,inoff,ijnoff)
177 ijknbeg = indijk(1 ,
j ,
k ,inoff,ijnoff)
178 ijknend = indijk(
idcend-ndum+1,
j ,
k ,inoff,ijnoff)
180 gam1 = region%global%refGamma - 1._rfreal
182 (region%levels(ilev)%grid%xyz(xcoord,ijkn(1)) + &
183 region%levels(ilev)%grid%xyz(xcoord,ijkn(2)) + &
184 region%levels(ilev)%grid%xyz(xcoord,ijkn(3)) + &
185 region%levels(ilev)%grid%xyz(xcoord,ijkn(4)) + &
186 region%levels(ilev)%grid%xyz(xcoord,ijkn(5)) + &
187 region%levels(ilev)%grid%xyz(xcoord,ijkn(6)) + &
188 region%levels(ilev)%grid%xyz(xcoord,ijkn(7)) + &
189 region%levels(ilev)%grid%xyz(xcoord,ijkn(8)))
190 xb = region%levels(ilev)%grid%xyz(xcoord,ijknbeg)
191 xe = region%levels(ilev)%grid%xyz(xcoord,ijknend)
194 velx = (xc-
input%iniXsplit)/ &
195 region%global%refLength*
input%iniVelX
197 qvel = 0.5_rfreal*(velx*velx+ &
201 mixt%cv(cv_mixt_dens,ijk) =
input%iniDens
202 mixt%cv(cv_mixt_xmom,ijk) = velx*
input%iniDens
203 mixt%cv(cv_mixt_ymom,ijk) =
input%iniVelY*
input%iniDens
204 mixt%cv(cv_mixt_zmom,ijk) =
input%iniVelZ*
input%iniDens
205 mixt%cv(cv_mixt_ener,ijk) =
input%iniPress/gam1+
input%iniDens*qvel
**********************************************************************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 idcend
subroutine registerfunction(global, funName, fileName)
subroutine rflo_getnodeoffset(region, iLev, iNodeOffset, ijNodeOffset)
subroutine rflo_getdimensdummy(region, iLev, idcbeg, idcend, jdcbeg, jdcend, kdcbeg, kdcend)
**********************************************************************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 kdcbeg
subroutine input(X, NNODE, NDC, NCELL, NFCE, NBPTS, NBFACE, ITYP, NPROP, XBNDY, XFAR, YFAR, ZFAR)
subroutine rflo_getcelloffset(region, iLev, iCellOffset, ijCellOffset)
**********************************************************************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 idcbeg
**********************************************************************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 jdcend
**********************************************************************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 jdcbeg
subroutine errorstop(global, errorCode, errorLine, addMessage)
subroutine deregisterfunction(global)
subroutine initializeflowfield(iLev, region)