67 TYPE(t_region
),
POINTER :: regions(:)
73 CHARACTER(2*CHRLEN+17) :: fname
75 INTEGER :: iregfile, ipc, jpc, kpc, ndim
77 INTEGER :: inoff, ijnoff, ijkn, errorflag
78 INTEGER,
ALLOCATABLE :: ivar(:,:)
82 REAL(RFREAL),
POINTER :: xyz(:,:)
83 REAL(RFREAL),
ALLOCATABLE :: rvar(:,:), xyzfile(:,:)
89 global => regions(ireg)%global
92 'RFLO_WriteGridRegion.F90' )
96 ALLOCATE( ivar(4,1),stat=errorflag )
97 ALLOCATE( rvar(1,1),stat=errorflag )
98 global%error = errorflag
99 IF (global%error /= 0) CALL
errorstop( global,err_allocate,&
107 DO iregfile=1,global%nRegions
108 IF (regions(iregfile)%mixtInput%moveGrid) movegrid = .true.
113 IF (global%flowType==flow_unsteady .AND. &
114 movegrid .AND. global%currentTime>0._rfreal)
THEN
115 IF (global%gridFormat == format_ascii)
THEN
116 WRITE(fname,
'(A,1PE11.5)') trim(global%outDir)//trim(global%casename)//
'.grda_', &
118 OPEN(if_grid,file=fname,
form=
'formatted',
status=
'unknown', &
120 ELSE IF (global%gridFormat == format_binary)
THEN
121 WRITE(fname,
'(A,1PE11.5)') trim(global%outDir)//trim(global%casename)//
'.grdb_', &
123 OPEN(if_grid,file=fname,
form=
'unformatted',
status=
'unknown', &
126 CALL
errorstop( global,err_unknown_format,&
129 rvar(1,1) = global%currentTime
134 IF (global%gridFormat == format_ascii)
THEN
135 WRITE(fname,
'(A)') trim(global%outDir)//trim(global%casename)//
'.grda'
136 OPEN(if_grid,file=fname,
form=
'formatted',
status=
'unknown', &
138 ELSE IF (global%gridFormat == format_binary)
THEN
139 WRITE(fname,
'(A)') trim(global%outDir)//trim(global%casename)//
'.grdb'
140 OPEN(if_grid,file=fname,
form=
'unformatted',
status=
'unknown', &
143 CALL
errorstop( global,err_unknown_format,&
146 rvar(1,1) = 0._rfreal
149 global%error = errorflag
150 IF (global%error /= 0) &
152 __line__,
'File: '//trim(fname) )
162 ndim = (regions(ireg)%levels(1)%grid%ipc+1)* &
163 (regions(ireg)%levels(1)%grid%jpc+1)* &
164 (regions(ireg)%levels(1)%grid%kpc+1)
165 ALLOCATE( xyzfile(3,ndim),stat=errorflag )
166 global%error = errorflag
167 IF (global%error /= 0) CALL
errorstop( global,err_allocate,&
175 xyz => regions(ireg)%levels(1)%grid%xyz
182 ijkn = indijk(
i,
j,
k,inoff,ijnoff)
183 xyzfile(1,
n) = xyz(xcoord,ijkn)
184 xyzfile(2,
n) = xyz(ycoord,ijkn)
185 xyzfile(3,
n) = xyz(zcoord,ijkn)
193 ivar(2,1) = regions(ireg)%levels(1)%grid%ipc
194 ivar(3,1) = regions(ireg)%levels(1)%grid%jpc
195 ivar(4,1) = regions(ireg)%levels(1)%grid%kpc
202 DEALLOCATE( xyzfile,stat=errorflag )
203 global%error = errorflag
204 IF (global%error /= 0) CALL
errorstop( global,err_deallocate,&
209 IF (ireg == global%nRegions)
THEN
210 CLOSE(if_grid,iostat=errorflag)
211 global%error = errorflag
212 IF (global%error /= 0) &
214 __line__,
'File: '//trim(fname) )
**********************************************************************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 jpnbeg
subroutine rflo_writedatafileint(global, fileId, form, nDim1, nDim2, ivar)
**********************************************************************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 kpnbeg
subroutine registerfunction(global, funName, fileName)
int status() const
Obtain the status of the attribute.
subroutine rflo_writegridregion(iReg, regions)
**********************************************************************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 jpnend
subroutine rflo_getnodeoffset(region, iLev, iNodeOffset, ijNodeOffset)
**********************************************************************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 ipnbeg
**********************************************************************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 form
subroutine rflo_getdimensphysnodes(region, iLev, ipnbeg, ipnend, jpnbeg, jpnend, kpnbeg, kpnend)
subroutine errorstop(global, errorCode, errorLine, addMessage)
subroutine rflo_writedatafilereal(global, fileId, form, nDim1, nDim2, var)
subroutine deregisterfunction(global)
**********************************************************************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 ipnend