60 TYPE(t_region
) :: region
63 INTEGER ::
i,
j,
k, ipatch
68 INTEGER :: ilev, icoff, ijcoff, inoff, ijnoff, ijkc0, ijkc1, ijkn
70 REAL(RFREAL) :: gfaca, flima, coefa, tempa, stboltz, rati, beta
71 REAL(RFREAL) :: qrx, qry, qrz, modsf, fr
72 REAL(RFREAL),
POINTER ::
rhs(:,:), si(:,:), sj(:,:), sk(:,:)
73 REAL(RFREAL),
POINTER ::
gradi(:,:),
gradj(:,:), gradk(:,:)
74 REAL(RFREAL),
POINTER :: rdv(:,:), qri(:), qrj(:), qrk(:)
75 REAL(RFREAL),
POINTER :: gofact(:), flim(:), coef(:,:), wvint(:,:)
80 'RADI_DiffRadFlux.F90' )
84 ilev = region%currLevel
93 si => region%levels(ilev)%grid%si
94 sj => region%levels(ilev)%grid%sj
95 sk => region%levels(ilev)%grid%sk
97 rhs => region%levels(ilev)%mixt%rhs
98 gradi => region%levels(ilev)%mixt%gradi
99 gradj => region%levels(ilev)%mixt%gradj
100 gradk => region%levels(ilev)%mixt%gradk
102 rdv => region%levels(ilev)%radi%dv
103 flim => region%levels(ilev)%radi%fluxLim
104 coef => region%levels(ilev)%radi%radCoef
105 gofact => region%levels(ilev)%radi%goFact
106 qri => region%levels(ilev)%radi%qri
107 qrj => region%levels(ilev)%radi%qrj
108 qrk => region%levels(ilev)%radi%qrk
109 wvint => region%levels(ilev)%radi%wvInt
112 stboltz = region%radiInput%stBoltz
114 beta = region%mixtInput%betrk(region%irkStep)
121 ijkc0 = indijk(
i ,
j,
k,icoff,ijcoff)
122 ijkc1 = indijk(
i-1,
j,
k,icoff,ijcoff)
123 ijkn = indijk(
i ,
j,
k,inoff,ijnoff)
125 gfaca = 0.5_rfreal*(gofact(ijkc0)+gofact(ijkc1))
126 flima = 0.5_rfreal*(flim(ijkc0)+flim(ijkc1))
127 coefa = 0.5_rfreal*(coef(ijkc0,radi_coeff_extinct)+ &
128 coef(ijkc1,radi_coeff_extinct))
129 tempa = 0.5_rfreal*(rdv(dv_radi_teff,ijkc0)+rdv(dv_radi_teff,ijkc1))
130 coefa = gfaca*rati*flima*stboltz*tempa**3/coefa
132 qrx = coefa*
gradi(gr_mixt_tx,ijkn)
133 qry = coefa*
gradi(gr_mixt_ty,ijkn)
134 qrz = coefa*
gradi(gr_mixt_tz,ijkn)
136 fr = qrx*si(xcoord,ijkn)+ &
137 qry*si(ycoord,ijkn)+ &
140 rhs(cv_mixt_ener,ijkc0) =
rhs(cv_mixt_ener,ijkc0) - fr*beta
141 rhs(cv_mixt_ener,ijkc1) =
rhs(cv_mixt_ener,ijkc1) + fr*beta
144 modsf =
sqrt( si(xcoord,ijkn)*si(xcoord,ijkn) + &
145 si(ycoord,ijkn)*si(ycoord,ijkn) + &
146 si(zcoord,ijkn)*si(zcoord,ijkn))
147 qri(ijkn) = -fr/modsf
155 ijkc0 = indijk(
i ,
j,
k,icoff,ijcoff)
156 ijkc1 = indijk(
i-1,
j,
k,icoff,ijcoff)
157 ijkn = indijk(
i ,
j,
k,inoff,ijnoff)
159 wvint(xcoord,ijkc0) = wvint(xcoord,ijkc0) +
gradi(gr_mixt_tx,ijkn)
160 wvint(ycoord,ijkc0) = wvint(ycoord,ijkc0) +
gradi(gr_mixt_ty,ijkn)
161 wvint(zcoord,ijkc0) = wvint(zcoord,ijkc0) +
gradi(gr_mixt_tz,ijkn)
163 wvint(xcoord,ijkc1) = wvint(xcoord,ijkc1) +
gradi(gr_mixt_tx,ijkn)
164 wvint(ycoord,ijkc1) = wvint(ycoord,ijkc1) +
gradi(gr_mixt_ty,ijkn)
165 wvint(zcoord,ijkc1) = wvint(zcoord,ijkc1) +
gradi(gr_mixt_tz,ijkn)
175 ijkc0 = indijk(
i,
j ,
k,icoff,ijcoff)
176 ijkc1 = indijk(
i,
j-1,
k,icoff,ijcoff)
177 ijkn = indijk(
i,
j ,
k,inoff,ijnoff)
179 gfaca = 0.5_rfreal*(gofact(ijkc0)+gofact(ijkc1))
180 flima = 0.5_rfreal*(flim(ijkc0)+flim(ijkc1))
181 coefa = 0.5_rfreal*(coef(ijkc0,radi_coeff_extinct)+ &
182 coef(ijkc1,radi_coeff_extinct))
183 tempa = 0.5_rfreal*(rdv(dv_radi_teff,ijkc0)+rdv(dv_radi_teff,ijkc1))
185 coefa = gfaca*rati*flima*stboltz*tempa**3/coefa
187 qrx = coefa*
gradj(gr_mixt_tx,ijkn)
188 qry = coefa*
gradj(gr_mixt_ty,ijkn)
189 qrz = coefa*
gradj(gr_mixt_tz,ijkn)
191 fr = qrx*sj(xcoord,ijkn)+ &
192 qry*sj(ycoord,ijkn)+ &
195 rhs(cv_mixt_ener,ijkc0) =
rhs(cv_mixt_ener,ijkc0) - fr*beta
196 rhs(cv_mixt_ener,ijkc1) =
rhs(cv_mixt_ener,ijkc1) + fr*beta
199 modsf =
sqrt( sj(xcoord,ijkn)*sj(xcoord,ijkn) + &
200 sj(ycoord,ijkn)*sj(ycoord,ijkn) + &
201 sj(zcoord,ijkn)*sj(zcoord,ijkn))
202 qrj(ijkn) = -fr/modsf
210 ijkc0 = indijk(
i,
j ,
k,icoff,ijcoff)
211 ijkc1 = indijk(
i,
j-1,
k,icoff,ijcoff)
212 ijkn = indijk(
i,
j ,
k,inoff,ijnoff)
214 wvint(xcoord,ijkc0) = wvint(xcoord,ijkc0) +
gradj(gr_mixt_tx,ijkn)
215 wvint(ycoord,ijkc0) = wvint(ycoord,ijkc0) +
gradj(gr_mixt_ty,ijkn)
216 wvint(zcoord,ijkc0) = wvint(zcoord,ijkc0) +
gradj(gr_mixt_tz,ijkn)
218 wvint(xcoord,ijkc1) = wvint(xcoord,ijkc1) +
gradj(gr_mixt_tx,ijkn)
219 wvint(ycoord,ijkc1) = wvint(ycoord,ijkc1) +
gradj(gr_mixt_ty,ijkn)
220 wvint(zcoord,ijkc1) = wvint(zcoord,ijkc1) +
gradj(gr_mixt_tz,ijkn)
230 ijkc0 = indijk(
i,
j,
k ,icoff,ijcoff)
231 ijkc1 = indijk(
i,
j,
k-1,icoff,ijcoff)
232 ijkn = indijk(
i,
j,
k ,inoff,ijnoff)
234 gfaca = 0.5_rfreal*(gofact(ijkc0)+gofact(ijkc1))
235 flima = 0.5_rfreal*(flim(ijkc0)+flim(ijkc1))
236 coefa = 0.5_rfreal*(coef(ijkc0,radi_coeff_extinct)+ &
237 coef(ijkc1,radi_coeff_extinct))
238 tempa = 0.5_rfreal*(rdv(dv_radi_teff,ijkc0)+rdv(dv_radi_teff,ijkc1))
240 coefa = gfaca*rati*flima*stboltz*tempa**3/coefa
242 qrx = coefa*gradk(gr_mixt_tx,ijkn)
243 qry = coefa*gradk(gr_mixt_ty,ijkn)
244 qrz = coefa*gradk(gr_mixt_tz,ijkn)
246 fr = qrx*sk(xcoord,ijkn)+ &
247 qry*sk(ycoord,ijkn)+&
250 rhs(cv_mixt_ener,ijkc0) =
rhs(cv_mixt_ener,ijkc0) - fr*beta
251 rhs(cv_mixt_ener,ijkc1) =
rhs(cv_mixt_ener,ijkc1) + fr*beta
254 modsf =
sqrt( sk(xcoord,ijkn)*sk(xcoord,ijkn) + &
255 sk(ycoord,ijkn)*sk(ycoord,ijkn) + &
256 sk(zcoord,ijkn)*sk(zcoord,ijkn))
257 qrk(ijkn) = -fr/modsf
265 ijkc0 = indijk(
i,
j,
k ,icoff,ijcoff)
266 ijkc1 = indijk(
i,
j,
k-1,icoff,ijcoff)
267 ijkn = indijk(
i,
j,
k ,inoff,ijnoff)
269 wvint(xcoord,ijkc0) = wvint(xcoord,ijkc0) + gradk(gr_mixt_tx,ijkn)
270 wvint(ycoord,ijkc0) = wvint(ycoord,ijkc0) + gradk(gr_mixt_ty,ijkn)
271 wvint(zcoord,ijkc0) = wvint(zcoord,ijkc0) + gradk(gr_mixt_tz,ijkn)
273 wvint(xcoord,ijkc1) = wvint(xcoord,ijkc1) + gradk(gr_mixt_tx,ijkn)
274 wvint(ycoord,ijkc1) = wvint(ycoord,ijkc1) + gradk(gr_mixt_ty,ijkn)
275 wvint(zcoord,ijkc1) = wvint(zcoord,ijkc1) + gradk(gr_mixt_tz,ijkn)
282 DO ipatch=1,region%nPatches
**********************************************************************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
**********************************************************************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 kpcbeg
subroutine registerfunction(global, funName, fileName)
**********************************************************************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 jpcbeg
**********************************************************************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 ipcend
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
**********************************************************************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 ipcbeg
subroutine radi_diffradflux(region)
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 iEndG gradi(:,:)
**********************************************************************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 jpcend
**********************************************************************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 deregisterfunction(global)
subroutine rflo_getdimensphys(region, iLev, ipcbeg, ipcend, jpcbeg, jpcend, kpcbeg, kpcend)
**********************************************************************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 iEndG gradj(:,:)
subroutine radi_diffradfluxpatch(region, patch)