68 TYPE(t_region
),
POINTER :: pregion
74 CHARACTER(CHRLEN) :: rcsidentstring
75 INTEGER :: errorflag,ipatch,nbfaces,nbfacestot,nspecies
77 TYPE(t_grid),
POINTER :: pgrid
79 TYPE(t_patch),
POINTER :: ppatch
85 rcsidentstring =
'$RCSfile: SPEC_RFLU_AllocateMemoryTStep.F90,v $ $Revision: 1.7 $'
87 global => pregion%global
90 'SPEC_RFLU_AllocateMemoryTStep.F90')
97 pmixtinput => pregion%mixtInput
99 nspecies = pregion%specInput%nSpecies
112 DO ipatch = 1,pgrid%nPatches
113 ppatch => pregion%patches(ipatch)
115 nbfaces = nbfaces + ppatch%nBTris + ppatch%nBQuads
116 nbfacestot = nbfacestot + ppatch%nBTrisTot + ppatch%nBQuadsTot
123 ALLOCATE(pregion%spec%cvOld(nspecies,pgrid%nCellsTot),stat=errorflag)
124 global%error = errorflag
125 IF (global%error /= err_none)
THEN
126 CALL
errorstop(global,err_allocate,__line__,
'pRegion%spec%cvOld')
133 ALLOCATE(pregion%spec%rhs(nspecies,pgrid%nCellsTot),stat=errorflag)
134 global%error = errorflag
135 IF (global%error /= err_none)
THEN
136 CALL
errorstop(global,err_allocate,__line__,
'pRegion%spec%rhs')
139 ALLOCATE(pregion%spec%diss(nspecies,pgrid%nCellsTot),stat=errorflag)
140 global%error = errorflag
141 IF (global%error /= err_none)
THEN
142 CALL
errorstop(global,err_allocate,__line__,
'pRegion%spec%diss')
145 IF ( global%flowType == flow_unsteady )
THEN
146 ALLOCATE(pregion%spec%rhsSum(nspecies,pgrid%nCellsTot),stat=errorflag)
147 global%error = errorflag
148 IF (global%error /= err_none)
THEN
149 CALL
errorstop(global,err_allocate,__line__,
'pRegion%spec%rhsSum')
152 nullify(pregion%spec%rhsSum)
163 IF ( pmixtinput%spaceOrder > 1 )
THEN
164 ALLOCATE(pregion%spec%gradCell(xcoord:zcoord,nspecies,pgrid%nCellsTot), &
166 global%error = errorflag
167 IF ( global%error /= err_none )
THEN
168 CALL
errorstop(global,err_allocate,__line__,
'pRegion%spec%gradCell')
171 nullify(pregion%spec%gradCell)
178 IF ( pmixtinput%flowModel == flow_navst )
THEN
179 ALLOCATE(pregion%spec%gradFace(xcoord:zcoord,nspecies,pgrid%nFaces), &
181 global%error = errorflag
182 IF ( global%error /= err_none )
THEN
183 CALL
errorstop(global,err_allocate,__line__,
'pRegion%spec%gradFace')
186 nullify(pregion%spec%gradFace)
189 IF ( pgrid%nPatches > 0 )
THEN
190 DO ipatch = 1,pregion%grid%nPatches
191 ppatch => pregion%patches(ipatch)
194 ALLOCATE(ppatch%spec%gradFace(xcoord:zcoord,nspecies,ppatch%nBFaces), &
196 global%error = errorflag
197 IF ( global%error /= err_none )
THEN
198 CALL
errorstop(global,err_allocate,__line__,
'pPatch%spec%gradFace')
201 nullify(ppatch%spec%gradFace)
LOGICAL function rflu_decideneedbgradface(pRegion, pPatch)
subroutine registerfunction(global, funName, fileName)
subroutine spec_rflu_allocatememorytstep(pRegion)
subroutine errorstop(global, errorCode, errorLine, addMessage)
subroutine deregisterfunction(global)