97 CHARACTER(CHRLEN) :: &
98 RCSIdentString =
'$RCSfile: RFLU_ModOLES.F90,v $ $Revision: 1.10 $'
105 INTEGER,
PUBLIC :: maxCalls,nDim,nEval,workArraySize,workArraySizeNew
106 INTEGER,
PARAMETER,
PUBLIC :: DCUHRE_LOOP_LIMIT = 5, &
107 MAX_CALLS_FACTOR = 5, &
108 MAX_CALLS_LIMIT = 50000000, &
109 MAX_CALLS_START = 100000, &
111 INTEGER,
PUBLIC :: dummy(1)
112 INTEGER,
DIMENSION(:),
ALLOCATABLE,
PUBLIC :: symMapI45OLES
114 REAL(RFREAL),
PUBLIC :: errAbsReq,errRelReq
115 REAL(RFREAL),
DIMENSION(:),
ALLOCATABLE,
PUBLIC :: lowLim,errAbsEst, &
123 INTEGER,
PUBLIC :: nzLoc,nzSgn
124 INTEGER,
DIMENSION(3,3),
PARAMETER,
PUBLIC :: mapSurf2Vol2 = &
125 RESHAPE((/6,4,4,4,6,5,5,5,6/),(/3,3/))
126 INTEGER,
DIMENSION(3,6),
PARAMETER,
PUBLIC :: mapSurf2Vol3 = &
127 RESHAPE((/9,7,7,7,9,8,8,8,9,9,7,7,7,9,8,8,8,9/),(/3,6/))
128 INTEGER,
DIMENSION(3,3),
PARAMETER,
PUBLIC :: kd = &
129 RESHAPE((/1,0,0,0,1,0,0,0,1/),(/3,3/))
131 INTEGER,
PUBLIC :: mapFunNZ2FunCorr22(9),mapFunNZ2FunCorr32(9), &
132 mapFunNZ2FunCorr43(27),mapFunNZ2FunCorr44(81)
134 REAL(RFREAL),
PUBLIC :: nzMag,nzVal
135 REAL(RFREAL),
PARAMETER,
PUBLIC :: CONST_KOLMOGOROV = 2.0_RFREAL
155 TYPE(t_region
),
POINTER :: pregion
159 INTEGER :: errorflag,ncells,
nfaces
160 TYPE(t_grid),
POINTER :: pgrid
167 global => pregion%global
172 IF ( global%myProcid == masterproc .AND. &
173 global%verbLevel > verbose_none )
THEN
174 WRITE(stdout,
'(A,1X,A)') solver_name
175 WRITE(stdout,
'(A,1X,A)') solver_name,
'Creating optimal LES '// &
176 'stencils, weights, and mappings...'
183 pgrid => pregion%grid
193 ALLOCATE(pgrid%fsOLES(ncells,pgrid%nFaces),stat=errorflag)
194 global%error = errorflag
195 IF ( global%error /= err_none )
THEN
196 CALL
errorstop(global,err_allocate,__line__,
'region%grid%fsOLES')
199 pgrid%fsOLES(:,:) = 0
201 ALLOCATE(pgrid%intLimOLES(int_lim_low:int_lim_upp,xcoord:zcoord, &
202 pgrid%nCellsTot),stat=errorflag)
203 global%error = errorflag
204 IF ( global%error /= err_none )
THEN
205 CALL
errorstop(global,err_allocate,__line__,
'region%grid%intLimOLES')
208 pgrid%intLimOLES(int_lim_low,:,:) = huge(1.0_rfreal)
209 pgrid%intLimOLES(int_lim_upp,:,:) = -huge(1.0_rfreal)
211 ALLOCATE(pgrid%rhoOLES(pgrid%nFaces),stat=errorflag)
212 global%error = errorflag
213 IF ( global%error /= err_none )
THEN
214 CALL
errorstop(global,err_allocate,__line__,
'region%grid%intLimOLES')
217 pgrid%rhoOLES(:) = huge(1.0_rfreal)
219 ALLOCATE(pgrid%fp2fOLES(3),stat=errorflag)
220 global%error = errorflag
221 IF ( global%error /= err_none )
THEN
222 CALL
errorstop(global,err_allocate,__line__,
'region%grid%fp2fOLES')
225 ALLOCATE(pgrid%f2fpOLES(pgrid%nFaces),stat=errorflag)
226 global%error = errorflag
227 IF ( global%error /= err_none )
THEN
228 CALL
errorstop(global,err_allocate,__line__,
'region%grid%f2fpOLES')
237 ALLOCATE(pgrid%wtLinOLES(3,3,ncells,
nfaces),stat=errorflag)
238 global%error = errorflag
239 IF ( global%error /= err_none )
THEN
240 CALL
errorstop(global,err_allocate,__line__,
'region%grid%wtLinOLES')
243 ALLOCATE(pgrid%wtQuadOLES(3,3,3,ncells,ncells,
nfaces),stat=errorflag)
244 global%error = errorflag
245 IF ( global%error /= err_none )
THEN
246 CALL
errorstop(global,err_allocate,__line__,
'region%grid%wQuadOLES')
249 pgrid%wtLinOLES(:,:,:,:) =
REAL(crazy_value_int,kind=rfreal)
250 pgrid%wtQuadOLES(:,:,:,:,:,:) =
REAL(crazy_value_int,kind=rfreal)
256 ALLOCATE(symmapi45oles(9*ncells*ncells),stat=errorflag)
257 global%error = errorflag
258 IF ( global%error /= err_none )
THEN
259 CALL
errorstop(global,err_allocate,__line__,
'symMapI45OLES')
266 IF ( global%myProcid == masterproc .AND. &
267 global%verbLevel > verbose_none )
THEN
268 WRITE(stdout,
'(A,1X,A)') solver_name,
'Creating optimal LES '// &
269 'stencils, weights, and mappings done.'
289 TYPE(t_region
),
POINTER :: pregion
293 INTEGER :: errorflag,ncells,ncols,
nfaces,nrows
294 TYPE(t_grid),
POINTER :: pgrid
301 global => pregion%global
306 IF ( global%myProcid == masterproc .AND. &
307 global%verbLevel > verbose_none )
THEN
308 WRITE(stdout,
'(A,1X,A)') solver_name
309 WRITE(stdout,
'(A,1X,A)') solver_name,
'Creating optimal LES '// &
317 pgrid => pregion%grid
324 ncells =
SIZE(pgrid%fsOLES,1)
330 ALLOCATE(pgrid%int1OLES(3,
nfaces,3*ncells),stat=errorflag)
331 global%error = errorflag
332 IF ( global%error /= err_none )
THEN
333 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int1OLES')
336 pgrid%int1OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
342 ALLOCATE(pgrid%int20OLES(
nfaces,3*ncells,3*ncells),stat=errorflag)
343 global%error = errorflag
344 IF ( global%error /= err_none )
THEN
345 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int20OLES')
348 ALLOCATE(pgrid%int21OLES(
nfaces,3*ncells,3*ncells),stat=errorflag)
349 global%error = errorflag
350 IF ( global%error /= err_none )
THEN
351 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int21OLES')
354 pgrid%int20OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
355 pgrid%int21OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
362 ALLOCATE(pgrid%int31OLES(
nfaces,3*ncells,9*ncells*ncells), &
364 global%error = errorflag
365 IF ( global%error /= err_none )
THEN
366 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int31OLES')
369 ALLOCATE(pgrid%int32OLES(
nfaces,9*ncells*ncells,3*ncells), &
371 global%error = errorflag
372 IF ( global%error /= err_none )
THEN
373 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int32OLES')
376 pgrid%int31OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
377 pgrid%int32OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
383 ALLOCATE(pgrid%int40OLES(3,
nfaces,9*ncells*ncells),stat=errorflag)
384 global%error = errorflag
385 IF ( global%error /= err_none )
THEN
386 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int40OLES')
389 ALLOCATE(pgrid%int41OLES(3,
nfaces,9*ncells*ncells),stat=errorflag)
390 global%error = errorflag
391 IF ( global%error /= err_none )
THEN
392 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int41OLES')
395 ALLOCATE(pgrid%int42OLES(3,
nfaces,9*ncells*ncells),stat=errorflag)
396 global%error = errorflag
397 IF ( global%error /= err_none )
THEN
398 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int42OLES')
401 pgrid%int40OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
402 pgrid%int41OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
403 pgrid%int42OLES(:,:,:) =
REAL(CRAZY_VALUE_INT,KIND=RFREAL)
409 ALLOCATE(pgrid%int50OLES(
nfaces,9*ncells*ncells,9*ncells*ncells), &
411 global%error = errorflag
412 IF ( global%error /= err_none )
THEN
413 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int50OLES')
416 ALLOCATE(pgrid%int51OLES(
nfaces,9*ncells*ncells,9*ncells*ncells), &
418 global%error = errorflag
419 IF ( global%error /= err_none )
THEN
420 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int51OLES')
423 ALLOCATE(pgrid%int52OLES(
nfaces,9*ncells*ncells,9*ncells*ncells), &
425 global%error = errorflag
426 IF ( global%error /= err_none )
THEN
427 CALL
errorstop(global,err_allocate,__line__,
'region%grid%int52OLES')
430 pgrid%int50OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
431 pgrid%int51OLES(:,:,:) =
REAL(crazy_value_int,kind=rfreal)
432 pgrid%int52OLES(:,:,:) =
REAL(CRAZY_VALUE_INT,KIND=RFREAL)
438 nrows = 3*ncells*(1 + 3*ncells)
441 ALLOCATE(pgrid%lhsOLES(nrows,ncols),stat=errorflag)
442 global%error = errorflag
443 IF ( global%error /= err_none )
THEN
444 CALL
errorstop(global,err_allocate,__line__,
'region%grid%lhsOLES')
447 ALLOCATE(pgrid%lhsInvOLES(ncols,nrows),stat=errorflag)
448 global%error = errorflag
449 IF ( global%error /= err_none )
THEN
450 CALL
errorstop(global,err_allocate,__line__,
'region%grid%lhsInvOLES')
453 ALLOCATE(pgrid%rhsOLES(nrows),stat=errorflag)
454 global%error = errorflag
455 IF ( global%error /= err_none )
THEN
456 CALL
errorstop(global,err_allocate,__line__,
'region%grid%rhsOLES')
459 pgrid%lhsOLES(:,:) =
REAL(CRAZY_VALUE_INT,KIND=RFREAL)
460 pgrid%rhsOLES(:) =
REAL(crazy_value_int,kind=rfreal)
466 IF ( global%myProcid == masterproc .AND. &
467 global%verbLevel > verbose_none )
THEN
468 WRITE(stdout,
'(A,1X,A)') solver_name,
'Creating optimal LES '// &
489 TYPE(t_region
),
POINTER :: pregion
493 INTEGER :: errorflag,
ic,ifc,is,loc,locoffset1,locoffset2,stencilsize, &
495 INTEGER,
DIMENSION(:),
ALLOCATABLE :: stenciltemp
498 REAL(RFREAL) :: dummy(1),vec(3)
499 REAL(RFREAL),
DIMENSION(:),
ALLOCATABLE ::
dist
500 TYPE(t_grid),
POINTER :: pgrid
507 global => pregion%global
512 IF ( global%myProcid == masterproc .AND. &
513 global%verbLevel > verbose_none )
THEN
514 WRITE(stdout,
'(A)') solver_name
515 WRITE(stdout,
'(A,1X,A)') solver_name,
'Building optimal LES stencils...'
522 pgrid => pregion%grid
524 delfrac = 0.01_rfreal
530 stencilsize =
SIZE(pgrid%fsOLES,1)
532 IF ( global%myProcid == masterproc .AND. &
533 global%verbLevel > verbose_none )
THEN
534 WRITE(stdout,
'(A,3X,A)') solver_name,
'Building face stencil support...'
535 WRITE(stdout,
'(A,5X,A,1X,I2)') solver_name,
'Stencil width:',stencilsize
542 IF ( stencilsize == 2 )
THEN
543 DO ifc = 1,pgrid%nFaces
544 pgrid%fsOLES(1,ifc) = pgrid%f2c(1,ifc)
545 pgrid%fsOLES(2,ifc) = pgrid%f2c(2,ifc)
552 ELSE IF ( stencilsize > 2 )
THEN
553 IF ( stencilsize == 4 )
THEN
555 ELSE IF ( stencilsize == 6 )
THEN
556 stencilsizetemp = 102
557 ELSE IF ( stencilsize == 8 )
THEN
558 stencilsizetemp = 296
560 CALL
errorstop(global,err_reached_default,__line__)
565 ALLOCATE(stenciltemp(stencilsizetemp),stat=errorflag)
566 global%error = errorflag
567 IF ( global%error /= err_none )
THEN
568 CALL
errorstop(global,err_allocate,__line__,
'stencilTemp')
571 ALLOCATE(
dist(stencilsizetemp),stat=errorflag)
572 global%error = errorflag
573 IF ( global%error /= err_none )
THEN
574 CALL
errorstop(global,err_allocate,__line__,
'dist')
579 xmin = minval(pgrid%xyz(xcoord,1:pgrid%nVertTot))
580 xmax = maxval(pgrid%xyz(xcoord,1:pgrid%nVertTot))
581 ymin = minval(pgrid%xyz(ycoord,1:pgrid%nVertTot))
582 ymax = maxval(pgrid%xyz(ycoord,1:pgrid%nVertTot))
583 zmin = minval(pgrid%xyz(zcoord,1:pgrid%nVertTot))
584 zmax = maxval(pgrid%xyz(zcoord,1:pgrid%nVertTot))
601 pgrid%cofg(ycoord,1:pgrid%nCellsTot), &
602 pgrid%cofg(zcoord,1:pgrid%nCellsTot), &
607 DO ifc = 1,pgrid%nFaces
609 pgrid%fc(zcoord,ifc),stencilsizetemp, &
619 dummy = maxloc(abs(pgrid%fn(1:3,ifc)))
622 DO is = 1,stencilsizetemp
625 vec(:) = pgrid%cofg(:,
ic) - pgrid%fc(:,ifc)
626 vecm =
sqrt(vec(1)*vec(1) + vec(2)*vec(2) + vec(3)*vec(3))
629 dotp = vec(1)*pgrid%fn(1,ifc) &
630 + vec(2)*pgrid%fn(2,ifc) &
631 + vec(3)*pgrid%fn(3,ifc)
633 IF (
floatequal(abs(dotp),1.0_rfreal) .EQV. .true. )
THEN
634 dist(is) = pgrid%cofg(loc,
ic) - pgrid%fc(loc,ifc)
636 dist(is) = huge(1.0_rfreal)
643 stenciltemp(1:stencilsizetemp), &
649 IF ( pgrid%fn(loc,ifc) > 0.0_rfreal )
THEN
659 loc = stencilsize/2 + locoffset1
661 loc = stencilsize/2 + locoffset2
664 IF ( stenciltemp(loc) /= pgrid%f2c(
ic,ifc) )
THEN
665 CALL
errorstop(global,err_oles_stencil,__line__)
672 DO is = 1,stencilsize
674 CALL
errorstop(global,err_oles_stencil,__line__)
680 DO is = 1,stencilsize
681 pgrid%fsOLES(is,ifc) = stenciltemp(is)
689 DEALLOCATE(stenciltemp,stat=errorflag)
690 global%error = errorflag
691 IF ( global%error /= err_none )
THEN
692 CALL
errorstop(global,err_deallocate,__line__,
'stencilTemp')
695 DEALLOCATE(
dist,stat=errorflag)
696 global%error = errorflag
697 IF ( global%error /= err_none )
THEN
698 CALL
errorstop(global,err_deallocate,__line__,
'dist')
703 #ifdef CHECK_DATASTRUCT
705 WRITE(stdout,
'(A)') solver_name
706 WRITE(stdout,
'(A,1X,A)') solver_name,
'### START CHECK OUTPUT ###'
707 WRITE(stdout,
'(A,1X,A)') solver_name,
'Optimal LES face stencils'
708 IF ( stencilsize == 2 )
THEN
709 DO ifc = 1,pgrid%nFaces
710 WRITE(stdout,
'(A,3(1X,I6))') solver_name,ifc,pgrid%fsOLES(1:2,ifc)
712 ELSE IF ( stencilsize == 4 )
THEN
713 DO ifc = 1,pgrid%nFaces
714 WRITE(stdout,
'(A,5(1X,I6))') solver_name,ifc,pgrid%fsOLES(1:4,ifc)
717 WRITE(stdout,
'(A,1X,A)') solver_name,
'### END CHECK OUTPUT ###'
718 WRITE(stdout,
'(A)') solver_name
725 IF ( global%myProcid == masterproc .AND. &
726 global%verbLevel > verbose_none )
THEN
727 WRITE(stdout,
'(A,1X,A)') solver_name,
'Building optimal LES '// &
748 TYPE(t_region
),
POINTER :: pregion
752 INTEGER,
PARAMETER :: locsave_init = -1
753 INTEGER :: ifc,ifcp,loc,locsavecntr
754 INTEGER :: dummy(1),locsave(3)
755 TYPE(t_grid),
POINTER :: pgrid
762 global => pregion%global
767 IF ( global%myProcid == masterproc .AND. &
768 global%verbLevel > verbose_none )
THEN
769 WRITE(stdout,
'(A)') solver_name
770 WRITE(stdout,
'(A,1X,A)') solver_name,
'Finding optimal LES '// &
778 pgrid => pregion%grid
785 locsave(1:3) = locsave_init
791 IF ( global%myProcid == masterproc .AND. &
792 global%verbLevel > verbose_none )
THEN
793 WRITE(stdout,
'(A,3X,A)') solver_name,
'Finding prototype faces...'
796 DO ifc = 1,pgrid%nFaces
797 dummy = maxloc(abs(pgrid%fn(1:3,ifc)))
800 IF ( locsave(loc) == locsave_init )
THEN
802 locsavecntr = locsavecntr + 1
803 pgrid%fp2fOLES(loc) = ifc
806 IF ( locsavecntr == 3 )
THEN
811 #ifdef CHECK_DATASTRUCT
813 WRITE(stdout,
'(A)') solver_name
814 WRITE(stdout,
'(A,1X,A)') solver_name,
'### START CHECK OUTPUT ###'
815 WRITE(stdout,
'(A,1X,A)') solver_name,
'Prototype faces:'
817 ifc = pgrid%fp2fOLES(ifcp)
818 WRITE(stdout,
'(A,2(1X,I6),3(1X,E18.9))') solver_name,ifcp,ifc, &
821 WRITE(stdout,
'(A,1X,A)') solver_name,
'### END CHECK OUTPUT ###'
822 WRITE(stdout,
'(A)') solver_name
829 IF ( global%myProcid == masterproc .AND. &
830 global%verbLevel > verbose_none )
THEN
831 WRITE(stdout,
'(A,3X,A)') solver_name,
'Mapping faces to '// &
835 DO ifc = 1,pgrid%nFaces
836 dummy = maxloc(abs(pgrid%fn(1:3,ifc)))
839 pgrid%f2fpOLES(ifc) = loc
842 #ifdef CHECK_DATASTRUCT
844 WRITE(stdout,
'(A)') solver_name
845 WRITE(stdout,
'(A,1X,A)') solver_name,
'### START CHECK OUTPUT ###'
846 WRITE(stdout,
'(A,1X,A)') solver_name,
'Prototype faces:'
847 DO ifc = 1,pgrid%nFaces
848 ifcp = pgrid%f2fpOLES(ifc)
849 WRITE(stdout,
'(A,2(1X,I6),3(1X,E18.9))') solver_name,ifc,ifcp, &
852 WRITE(stdout,
'(A,1X,A)') solver_name,
'### END CHECK OUTPUT ###'
853 WRITE(stdout,
'(A)') solver_name
860 IF ( global%myProcid == masterproc .AND. &
861 global%verbLevel > verbose_none )
THEN
862 WRITE(stdout,
'(A,1X,A)') solver_name,
'Finding optimal LES '// &
863 'prototype faces done.'
887 TYPE(t_region
),
POINTER :: pregion
891 INTEGER ::
ic,icl,icg,ifc,ip,c1,c2,loc,ncells
894 REAL(RFREAL) :: fc(xcoord:zcoord)
895 REAL(RFREAL) :: xyz(int_lim_low:int_lim_upp,xcoord:zcoord)
896 TYPE(t_grid),
POINTER :: pgrid
897 TYPE(t_patch),
POINTER :: ppatch
900 #ifdef CHECK_DATASTRUCT
908 global => pregion%global
913 IF ( global%myProcid == masterproc .AND. &
914 global%verbLevel > verbose_none )
THEN
915 WRITE(stdout,
'(A)') solver_name
916 WRITE(stdout,
'(A,1X,A)') solver_name,
'Computing optimal LES '// &
924 pgrid => pregion%grid
930 IF ( global%myProcid == masterproc .AND. &
931 global%verbLevel > verbose_none )
THEN
932 WRITE(stdout,
'(A,3X,A)') solver_name,
'Computing cell integration '// &
934 IF ( global%verbLevel > verbose_low )
THEN
935 WRITE(stdout,
'(A,5X,A)') solver_name,
'Interior faces...'
939 DO ifc = 1,pgrid%nFacesTot
940 c1 = pgrid%f2c(1,ifc)
941 c2 = pgrid%f2c(2,ifc)
943 dummy = maxloc(abs(pgrid%fn(1:3,ifc)))
946 fc(:) = abs(pgrid%fn(loc,ifc))*pgrid%fc(:,ifc)
948 IF ( c2 /= f2c_init )
THEN
949 IF ( pgrid%fn(loc,ifc) > 0.0_rfreal )
THEN
950 pgrid%intLimOLES(int_lim_upp,loc,c1) = fc(loc)
951 pgrid%intLimOLES(int_lim_low,loc,c2) = fc(loc)
953 pgrid%intLimOLES(int_lim_low,loc,c1) = fc(loc)
954 pgrid%intLimOLES(int_lim_upp,loc,c2) = fc(loc)
957 IF ( pgrid%fn(loc,ifc) > 0.0_rfreal )
THEN
958 pgrid%intLimOLES(int_lim_upp,loc,c1) = fc(loc)
960 pgrid%intLimOLES(int_lim_low,loc,c1) = fc(loc)
965 IF ( global%myProcid == masterproc .AND. &
966 global%verbLevel > verbose_low )
THEN
967 WRITE(stdout,
'(A,5X,A)') solver_name,
'Patches...'
970 DO ip = 1,pgrid%nPatches
971 ppatch => pregion%patches(ip)
973 IF ( global%myProcid == masterproc .AND. &
974 global%verbLevel > verbose_low )
THEN
975 WRITE(stdout,
'(A,7X,A,I4)') solver_name,
'Patch: ',ip
978 DO ifc = 1,ppatch%nBFaces
979 c1 = ppatch%bf2c(ifc)
981 dummy = maxloc(abs(ppatch%fn(1:3,ifc)))
984 fc(:) = abs(ppatch%fn(loc,ifc))*ppatch%fc(:,ifc)
986 IF ( ppatch%fn(loc,ifc) > 0.0_rfreal )
THEN
987 pgrid%intLimOLES(int_lim_upp,loc,c1) = fc(loc)
989 pgrid%intLimOLES(int_lim_low,loc,c1) = fc(loc)
995 #ifdef CHECK_DATASTRUCT
997 WRITE(stdout,
'(A)') solver_name
998 WRITE(stdout,
'(A,1X,A)') solver_name,
'### START CHECK OUTPUT ###'
999 WRITE(stdout,
'(A,1X,A)') solver_name,
'Optimal LES cell integration limits'
1000 DO ic = 1,pgrid%nCellsTot
1001 WRITE(stdout,
'(A,1X,I6,6(1X,E18.9))') solver_name,
ic, &
1002 ((pgrid%intLimOLES(
i,
j,
ic),
i=int_lim_low,int_lim_upp),
j=xcoord,zcoord)
1004 WRITE(stdout,
'(A,1X,A)') solver_name,
'### END CHECK OUTPUT ###'
1005 WRITE(stdout,
'(A)') solver_name
1012 IF ( global%myProcid == masterproc .AND. &
1013 global%verbLevel > verbose_none )
THEN
1014 WRITE(stdout,
'(A,3X,A)') solver_name,
'Computing smallest sphere '// &
1018 DO ifc = 1,pgrid%nFaces
1019 ncells =
SIZE(pgrid%fsOLES,1)
1021 xyz(int_lim_low,xcoord:zcoord) = huge(1.0_rfreal)
1022 xyz(int_lim_upp,xcoord:zcoord) = -huge(1.0_rfreal)
1025 icg = pgrid%fsOLES(icl,ifc)
1027 xyz(int_lim_low,1:3) =
min(pgrid%intLimOLES(int_lim_low,1:3,icg), &
1028 xyz(int_lim_low,1:3))
1029 xyz(int_lim_upp,1:3) =
max(pgrid%intLimOLES(int_lim_upp,1:3,icg), &
1030 xyz(int_lim_upp,1:3))
1035 pgrid%rhoOLES(ifc) =
min(pgrid%rhoOLES(ifc), &
1036 xyz(int_lim_upp,
ic)-xyz(int_lim_low,
ic))
1052 #ifdef CHECK_DATASTRUCT
1054 WRITE(stdout,
'(A)') solver_name
1055 WRITE(stdout,
'(A,1X,A)') solver_name,
'### START CHECK OUTPUT ###'
1056 WRITE(stdout,
'(A,1X,A)') solver_name,
'Optimal LES smallest stencil sphere'
1057 DO ifc = 1,pgrid%nFaces
1058 WRITE(stdout,
'(A,1X,I6,1X,E18.9)') solver_name,ifc,pgrid%rhoOLES(ifc)
1060 WRITE(stdout,
'(A,1X,A)') solver_name,
'### END CHECK OUTPUT ###'
1061 WRITE(stdout,
'(A)') solver_name
1068 IF ( global%myProcid == masterproc .AND. &
1069 global%verbLevel > verbose_none )
THEN
1070 WRITE(stdout,
'(A,3X,A)') solver_name,
'Computing filter width...'
1073 pgrid%deltaOLES = pgrid%vol(1)**(1.0_rfreal/3.0_rfreal)
1075 #ifdef CHECK_DATASTRUCT
1077 WRITE(stdout,
'(A)') solver_name
1078 WRITE(stdout,
'(A,1X,A)') solver_name,
'### START CHECK OUTPUT ###'
1079 WRITE(stdout,
'(A,1X,A)') solver_name,
'Optimal LES filter width'
1080 WRITE(stdout,
'(A,1X,E18.9)') solver_name,pgrid%deltaOLES
1081 WRITE(stdout,
'(A,1X,A)') solver_name,
'### END CHECK OUTPUT ###'
1082 WRITE(stdout,
'(A)') solver_name
1089 IF ( global%myProcid == masterproc .AND. &
1090 global%verbLevel > verbose_none )
THEN
1091 WRITE(stdout,
'(A,1X,A)') solver_name,
'Computing optimal LES '// &
1092 'geometric terms done.'
1112 TYPE(t_region
),
POINTER :: pregion
1116 INTEGER ::
b,
g,
j,
k,ncells,pos,possym
1123 global => pregion%global
1128 IF ( global%myProcid == masterproc .AND. &
1129 global%verbLevel > verbose_none )
THEN
1130 WRITE(stdout,
'(A)') solver_name
1131 WRITE(stdout,
'(A,1X,A)') solver_name,
'Building optimal LES '// &
1139 ncells =
SIZE(pregion%grid%fsOLES,1)
1148 IF ( possym < pos )
THEN
1149 symmapi45oles(pos) = possym
1151 symmapi45oles(pos) = 0
1162 IF ( global%myProcid == masterproc .AND. &
1163 global%verbLevel > verbose_none )
THEN
1164 WRITE(stdout,
'(A,1X,A)') solver_name,
'Building optimal LES '// &
1165 'symmetry maps done.'
1185 TYPE(t_region
),
POINTER :: pregion
1189 INTEGER :: dloc,ifcp,hloc,ncells,vloc
1196 global => pregion%global
1201 IF ( global%myProcid == masterproc .AND. &
1202 global%verbLevel > verbose_none )
THEN
1203 WRITE(stdout,
'(A)') solver_name
1204 WRITE(stdout,
'(A,1X,A)') solver_name,
'Enforcing optimal LES '// &
1205 'integral symmetry...'
1212 pgrid => pregion%grid
1214 ncells =
SIZE(pgrid%fsOLES,1)
1224 IF ( global%myProcid == masterproc .AND. &
1225 global%verbLevel > verbose_none )
THEN
1226 WRITE(stdout,
'(A,3X,A)') solver_name,
'Integral 4...'
1230 DO vloc = 1,9*ncells*ncells
1231 IF ( symmapi45oles(vloc) /= 0 )
THEN
1232 pgrid%int40OLES(:,ifcp,vloc) = &
1233 pgrid%int40OLES(:,ifcp,symmapi45oles(vloc))
1234 pgrid%int41OLES(:,ifcp,vloc) = &
1235 pgrid%int41OLES(:,ifcp,symmapi45oles(vloc))
1236 pgrid%int42OLES(:,ifcp,vloc) = &
1237 pgrid%int42OLES(:,ifcp,symmapi45oles(vloc))
1246 IF ( global%myProcid == masterproc .AND. &
1247 global%verbLevel > verbose_none )
THEN
1248 WRITE(stdout,
'(A,3X,A)') solver_name,
'Integral 5...'
1252 DO vloc = 1,9*ncells*ncells
1253 IF ( symmapi45oles(vloc) /= 0 )
THEN
1254 pgrid%int50OLES(ifcp,vloc,:) = &
1255 pgrid%int50OLES(ifcp,symmapi45oles(vloc),:)
1256 pgrid%int51OLES(ifcp,vloc,:) = &
1257 pgrid%int51OLES(ifcp,symmapi45oles(vloc),:)
1258 pgrid%int52OLES(ifcp,vloc,:) = &
1259 pgrid%int52OLES(ifcp,symmapi45oles(vloc),:)
1283 IF ( global%myProcid == masterproc .AND. &
1284 global%verbLevel > verbose_none )
THEN
1285 WRITE(stdout,
'(A,1X,A)') solver_name,
'Enforcing optimal LES '// &
1286 'integral symmetry done.'
1308 INTEGER,
INTENT(IN) :: ndim,nfunnz
1309 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1310 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1314 INTEGER :: ifun,ifunnz,
j,l
1318 DO ifunnz = 1,nfunnz
1319 ifun = mapfunnz2funcorr22(ifunnz)
1337 INTEGER,
INTENT(IN) :: ndim,nfunnz
1338 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1339 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1343 INTEGER :: ifun,ifunnz,
j,l
1344 DOUBLE PRECISION :: fact,rm2,rm23,rm2i
1348 rm2 = (
z(4)-
z(1))**2 + (
z(5)-
z(2))**2 + (
z(6)-
z(3))**2
1349 rm23 = rm2**(1.0d0/3.0d0)
1352 DO ifunnz = 1,nfunnz
1353 ifun = mapfunnz2funcorr22(ifunnz)
1356 f(ifunnz) = rm23*(rm2i*(
z(l+3)-
z(l))*(
z(
j+3)-
z(
j)) - 4.0d0*kd(l,
j))
1373 INTEGER,
INTENT(IN) :: ndim,nfunnz
1374 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1375 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1379 INTEGER ::
i,ifun,ifunnz,l,
n
1380 DOUBLE PRECISION :: term1,term2,term3
1381 DOUBLE PRECISION :: zd(ndim+1)
1389 zd(1:ndim) =
z(1:ndim)
1394 DO ifunnz = 1,nfunnz
1395 ifun = mapfunnz2funcorr32(ifunnz)
1398 term1 = kd(
i,
n)*(zd(l)-zd(mapsurf2vol2(
n,l)))
1399 term2 = kd(
i,l)*(zd(
n)-zd(mapsurf2vol2(
n,
n)))
1400 term3 = kd(
n,l)*(zd(
i)-zd(mapsurf2vol2(
n,
i)))
1402 f(ifunnz) = nzsgn*(term1 - 1.5d0*(term2 + term3))
1419 INTEGER,
INTENT(IN) :: ndim,nfunnz
1420 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1421 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1425 INTEGER ::
i,ifun,ifunnz,l,
m,
n
1426 DOUBLE PRECISION :: term1,term2,term3
1434 DO ifunnz = 1,nfunnz
1435 ifun = mapfunnz2funcorr43(ifunnz)
1438 f(ifunnz) = nzsgn*(kd(l,
m)*kd(
i,
n) + kd(l,
i)*kd(
m,
n) + kd(l,
n)*kd(
m,
i))
1454 INTEGER,
INTENT(IN) :: ndim,nfunnz
1455 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1456 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1460 INTEGER ::
i,ifun,ifunnz,
j,
k,l,
m
1461 DOUBLE PRECISION :: r1m2,r1m23,r1m2i,r2m2,r2m23,r2m2i,r3m2,r3m23,r3m2i, &
1462 r4m2,r4m23,r4m2i,r5m2,r5m23,r5m2i,term1,term2,term3, &
1464 DOUBLE PRECISION :: zd(ndim+1)
1472 zd(1:ndim) =
z(1:ndim)
1477 r1m2 = (zd(1) - zd(4))**2 &
1478 + (zd(2) - zd(5))**2 &
1479 + (zd(3) - zd(6))**2
1480 r2m2 = (zd(1) - zd(mapsurf2vol3(
j,1)))**2 &
1481 + (zd(2) - zd(mapsurf2vol3(
j,2)))**2 &
1482 + (zd(3) - zd(mapsurf2vol3(
j,3)))**2
1484 r4m2 = (zd(4) - zd(mapsurf2vol3(
j,4)))**2 &
1485 + (zd(5) - zd(mapsurf2vol3(
j,5)))**2 &
1486 + (zd(6) - zd(mapsurf2vol3(
j,6)))**2
1489 r1m23 = r1m2**(1.0d0/3.0d0)
1490 r2m23 = r2m2**(1.0d0/3.0d0)
1492 r4m23 = r4m2**(1.0d0/3.0d0)
1501 DO ifunnz = 1,nfunnz
1502 ifun = mapfunnz2funcorr43(ifunnz)
1505 term1 = kd(
i,
j)*r1m23*( r1m2i*(zd(l )-zd(l+3)) &
1509 term2 = kd(l,
i)*r5m23*( r5m2i*(zd(
m+3)-zd(mapsurf2vol3(
j,
m))) &
1510 *(zd(
j+3)-zd(mapsurf2vol3(
j,
j))) &
1513 term3 = kd(
m,
j)*r2m23*( r2m2i*(zd(l )-zd(mapsurf2vol3(
j,l))) &
1514 *(zd(
i )-zd(mapsurf2vol3(
j,
i))) &
1517 term4 = kd(l,
j)*r4m23*( r4m2i*(zd(
m+3)-zd(mapsurf2vol3(
j,
m))) &
1518 *(zd(
i+3)-zd(mapsurf2vol3(
j,
i))) &
1521 term5 = kd(
m,
i)*r3m23*( r3m2i*(zd(l )-zd(mapsurf2vol3(
j,l))) &
1522 *(zd(
j )-zd(mapsurf2vol3(
j,
j))) &
1524 f(ifunnz) = nzsgn*(term1 + term2 + term3 + term4 + term5)
1540 INTEGER,
INTENT(IN) :: ndim,nfunnz
1541 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1542 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1546 INTEGER ::
i,ifun,ifunnz,
j,
k,l,
m
1547 DOUBLE PRECISION :: r2m2,r2m23,r2m2i,r3m2,r3m23,r3m2i,r4m2,r4m23,r4m2i, &
1548 r5m2,r5m23,r5m2i,term1,term2
1549 DOUBLE PRECISION :: zd(ndim+1)
1557 zd(1:ndim) =
z(1:ndim)
1562 r2m2 = (zd(1) - zd(mapsurf2vol3(
j,1)))**2 &
1563 + (zd(2) - zd(mapsurf2vol3(
j,2)))**2 &
1564 + (zd(3) - zd(mapsurf2vol3(
j,3)))**2
1566 r4m2 = (zd(4) - zd(mapsurf2vol3(
j,4)))**2 &
1567 + (zd(5) - zd(mapsurf2vol3(
j,5)))**2 &
1568 + (zd(6) - zd(mapsurf2vol3(
j,6)))**2
1571 r2m23 = r2m2**(1.0d0/3.0d0)
1573 r4m23 = r4m2**(1.0d0/3.0d0)
1581 DO ifunnz = 1,nfunnz
1582 ifun = mapfunnz2funcorr43(ifunnz)
1586 r2m23*r5m23*(r2m2i*(zd(l ) - zd(mapsurf2vol3(
j,l))) &
1587 *(zd(
i ) - zd(mapsurf2vol3(
j,
i))) - 4.0d0*kd(l,
i)) &
1588 *(r5m2i*(zd(
m+3) - zd(mapsurf2vol3(
j,
m))) &
1589 *(zd(
j+3) - zd(mapsurf2vol3(
j,
j))) - 4.0d0*kd(
m,
j))
1592 r3m23*r4m23*(r3m2i*(zd(l ) - zd(mapsurf2vol3(
j,l))) &
1593 *(zd(
j ) - zd(mapsurf2vol3(
j,
j))) - 4.0d0*kd(l,
j)) &
1594 *(r4m2i*(zd(
m+3) - zd(mapsurf2vol3(
j,
m))) &
1595 *(zd(
i+3) - zd(mapsurf2vol3(
j,
i))) - 4.0d0*kd(
m,
i))
1597 f(ifunnz) = nzsgn*(term1 + term2)
1616 INTEGER,
INTENT(IN) :: ndim,nfunnz
1617 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1618 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1622 INTEGER :: ifun,ifunnz,
j,l,
k,
m
1623 DOUBLE PRECISION :: term1,term2,term3
1627 DO ifunnz = 1,nfunnz
1628 ifun = mapfunnz2funcorr44(ifunnz)
1631 f(ifunnz) = kd(l,
m)*kd(
j,
k) + kd(l,
j)*kd(
m,
k) + kd(l,
k)*kd(
m,
j)
1648 INTEGER,
INTENT(IN) :: ndim,nfunnz
1649 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1650 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1654 INTEGER :: ifun,ifunnz,
j,
k,l,
m
1655 DOUBLE PRECISION :: r1m2,r1m23,r1m2i,r2m2,r2m23,r2m2i,r3m2,r3m23,r3m2i, &
1656 r4m2,r4m23,r4m2i,r5m2,r5m23,r5m2i,r6m2,r6m23,r6m2i, &
1657 term1,term2,term3,term4,term5,term6
1661 r1m2 = (
z(1) -
z( 4))**2 &
1662 + (
z(2) -
z( 5))**2 &
1664 r2m2 = (
z(1) -
z( 7))**2 &
1665 + (
z(2) -
z( 8))**2 &
1667 r3m2 = (
z(1) -
z(10))**2 &
1668 + (
z(2) -
z(11))**2 &
1670 r4m2 = (
z(4) -
z( 7))**2 &
1671 + (
z(5) -
z( 8))**2 &
1673 r5m2 = (
z(4) -
z(10))**2 &
1674 + (
z(5) -
z(11))**2 &
1676 r6m2 = (
z(7) -
z(10))**2 &
1677 + (
z(8) -
z(11))**2 &
1680 r1m23 = r1m2**(1.0d0/3.0d0)
1681 r2m23 = r2m2**(1.0d0/3.0d0)
1682 r3m23 = r3m2**(1.0d0/3.0d0)
1683 r4m23 = r4m2**(1.0d0/3.0d0)
1684 r5m23 = r5m2**(1.0d0/3.0d0)
1685 r6m23 = r6m2**(1.0d0/3.0d0)
1694 DO ifunnz = 1,nfunnz
1695 ifun = mapfunnz2funcorr44(ifunnz)
1698 term1 = r6m23*kd(l,
m)*(r6m2i*(
z(
j+6) -
z(
j+9)) &
1699 *(
z(
k+6) -
z(
k+9)) - 4.0d0*kd(
j,
k))
1700 term2 = r1m23*kd(
j,
k)*(r1m2i*(
z(l ) -
z(l+3)) &
1701 *(
z(
m ) -
z(
m+3)) - 4.0d0*kd(l,
m))
1702 term3 = r5m23*kd(l,
j)*(r5m2i*(
z(
m+3) -
z(
m+9)) &
1703 *(
z(
k+3) -
z(
k+9)) - 4.0d0*kd(
m,
k))
1704 term4 = r2m23*kd(
m,
k)*(r2m2i*(
z(l ) -
z(l+6)) &
1705 *(
z(
j ) -
z(
j+6)) - 4.0d0*kd(l,
j))
1706 term5 = r4m23*kd(l,
k)*(r4m2i*(
z(
m+3) -
z(
m+6)) &
1707 *(
z(
j+3) -
z(
j+6)) - 4.0d0*kd(
m,
j))
1708 term6 = r3m23*kd(
m,
j)*(r3m2i*(
z(l ) -
z(l+9)) &
1709 *(
z(
k ) -
z(
k+9)) - 4.0d0*kd(l,
k))
1711 f(ifunnz) = term1 + term2 + term3 + term4 + term5 + term6
1728 INTEGER,
INTENT(IN) :: ndim,nfunnz
1729 DOUBLE PRECISION,
INTENT(IN) ::
z(ndim)
1730 DOUBLE PRECISION,
INTENT(INOUT) :: f(nfunnz)
1734 INTEGER :: ifun,ifunnz,
j,
k,l,
m
1735 DOUBLE PRECISION :: r1m2,r1m23,r1m2i,r2m2,r2m23,r2m2i,r3m2,r3m23,r3m2i, &
1736 r4m2,r4m23,r4m2i,r5m2,r5m23,r5m2i,r6m2,r6m23,r6m2i, &
1741 r1m2 = (
z(1) -
z( 4))**2 &
1742 + (
z(2) -
z( 5))**2 &
1744 r2m2 = (
z(1) -
z( 7))**2 &
1745 + (
z(2) -
z( 8))**2 &
1747 r3m2 = (
z(1) -
z(10))**2 &
1748 + (
z(2) -
z(11))**2 &
1750 r4m2 = (
z(4) -
z( 7))**2 &
1751 + (
z(5) -
z( 8))**2 &
1753 r5m2 = (
z(4) -
z(10))**2 &
1754 + (
z(5) -
z(11))**2 &
1756 r6m2 = (
z(7) -
z(10))**2 &
1757 + (
z(8) -
z(11))**2 &
1760 r1m23 = r1m2**(1.0d0/3.0d0)
1761 r2m23 = r2m2**(1.0d0/3.0d0)
1762 r3m23 = r3m2**(1.0d0/3.0d0)
1763 r4m23 = r4m2**(1.0d0/3.0d0)
1764 r5m23 = r5m2**(1.0d0/3.0d0)
1765 r6m23 = r6m2**(1.0d0/3.0d0)
1774 DO ifunnz = 1,nfunnz
1775 ifun = mapfunnz2funcorr44(ifunnz)
1779 r1m23*r6m23*(r1m2i*(
z(l ) -
z(l+3)) &
1780 *(
z(
m ) -
z(
m+3)) - 4.0d0*kd(l,
m)) &
1781 *(r6m2i*(
z(
j+6) -
z(
j+9)) &
1782 *(
z(
k+6) -
z(
k+9)) - 4.0d0*kd(
j,
k))
1784 r2m23*r5m23*(r2m2i*(
z(l ) -
z(l+6)) &
1785 *(
z(
j ) -
z(
j+6)) - 4.0d0*kd(l,
j)) &
1786 *(r5m2i*(
z(
m+3) -
z(
m+9)) &
1787 *(
z(
k+3) -
z(
k+9)) - 4.0d0*kd(
m,
k))
1789 r3m23*r4m23*(r3m2i*(
z(l ) -
z(l+9)) &
1790 *(
z(
k ) -
z(
k+9)) - 4.0d0*kd(l,
k)) &
1791 *(r4m2i*(
z(
m+3) -
z(
m+6)) &
1792 *(
z(
j+3) -
z(
j+6)) - 4.0d0*kd(
m,
j))
1794 f(ifunnz) = term1 + term2 + term3
1814 INTEGER,
INTENT(IN) ::
k
1815 INTEGER,
INTENT(OUT) ::
i,
j
1835 INTEGER,
INTENT(IN) :: l
1836 INTEGER,
INTENT(OUT) ::
i,
j,
k
1847 i = l - 3*(
j-1) - 9*(
k-1)
1862 INTEGER,
INTENT(IN) ::
m
1863 INTEGER,
INTENT(OUT) ::
i,
j,
k,l
1878 i =
m - 27*(l-1) - 9*(
k-1) - 3*(
j-1)
1894 INTEGER,
INTENT(IN) ::
d,l
1913 INTEGER,
INTENT(IN) ::
d,e,l,
m,ncells
1933 INTEGER,
INTENT(IN) ::
a,
j
1952 INTEGER,
INTENT(IN) :: loc
1953 INTEGER,
INTENT(OUT) ::
a,
j
1974 INTEGER,
INTENT(IN) ::
b,
g,
j,
k,ncells
1993 INTEGER,
INTENT(IN) :: loc,ncells
1994 INTEGER,
INTENT(OUT) ::
b,
g,
j,
k
1998 j = mod((loc+2)/3,3)
2003 g = mod((loc+8)/9,ncells)
2008 b = (loc+9*ncells-1)/(9*ncells)
2010 k = loc - 3*(
j-1) - 9*(
g-1) - 9*ncells*(
b-1)
2030 TYPE(t_region
),
POINTER :: pregion
2034 INTEGER :: errorflag
2035 TYPE(t_grid),
POINTER :: pgrid
2042 global => pregion%global
2047 IF ( global%myProcid == masterproc .AND. &
2048 global%verbLevel > verbose_none )
THEN
2049 WRITE(stdout,
'(A)') solver_name
2050 WRITE(stdout,
'(A,1X,A)') solver_name,
'Destroying optimal LES '// &
2051 'stencils and weights...'
2058 pgrid => pregion%grid
2064 DEALLOCATE(pgrid%fsOLES,stat=errorflag)
2065 global%error = errorflag
2066 IF ( global%error /= err_none )
THEN
2067 CALL
errorstop(global,err_deallocate,__line__,
'region%grid%fsOLES')
2070 DEALLOCATE(pgrid%intLimOLES,stat=errorflag)
2071 global%error = errorflag
2072 IF ( global%error /= err_none )
THEN
2073 CALL
errorstop(global,err_deallocate,__line__,
'region%grid%intLimOLES')
2080 IF ( global%myProcid == masterproc .AND. &
2081 global%verbLevel > verbose_none )
THEN
2082 WRITE(stdout,
'(A,1X,A)') solver_name,
'Destroying optimal LES '// &
2083 'stencils and weights done.'
2103 INTEGER,
INTENT(IN) :: ndim,nfunnz,nfun
2108 INTEGER :: errorflag
2121 ALLOCATE(lowlim(ndim),stat=errorflag)
2122 global%error = errorflag
2123 IF ( global%error /= err_none )
THEN
2124 CALL
errorstop(global,err_allocate,__line__,
'lowLim')
2127 ALLOCATE(upplim(ndim),stat=errorflag)
2128 global%error = errorflag
2129 IF ( global%error /= err_none )
THEN
2130 CALL
errorstop(global,err_allocate,__line__,
'uppLim')
2133 ALLOCATE(errabsest(nfun),stat=errorflag)
2134 global%error = errorflag
2135 IF ( global%error /= err_none )
THEN
2136 CALL
errorstop(global,err_allocate,__line__,
'errAbsEst')
2139 ALLOCATE(integralnz(nfunnz),stat=errorflag)
2140 global%error = errorflag
2141 IF ( global%error /= err_none )
THEN
2142 CALL
errorstop(global,err_allocate,__line__,
'integralNZ')
2171 INTEGER :: errorflag
2184 DEALLOCATE(lowlim,stat=errorflag)
2185 global%error = errorflag
2186 IF ( global%error /= err_none )
THEN
2187 CALL
errorstop(global,err_deallocate,__line__,
'lowLim')
2190 DEALLOCATE(upplim,stat=errorflag)
2191 global%error = errorflag
2192 IF ( global%error /= err_none )
THEN
2193 CALL
errorstop(global,err_deallocate,__line__,
'uppLim')
2196 DEALLOCATE(errabsest,stat=errorflag)
2197 global%error = errorflag
2198 IF ( global%error /= err_none )
THEN
2199 CALL
errorstop(global,err_deallocate,__line__,
'errAbsEst')
2202 DEALLOCATE(integralnz,stat=errorflag)
2203 global%error = errorflag
2204 IF ( global%error /= err_none )
THEN
2205 CALL
errorstop(global,err_deallocate,__line__,
'integralNZ')
2227 INTEGER,
INTENT(IN) :: nfunnz
2231 INTEGER :: ifun,ifunnz,
j,l
2232 INTEGER,
PARAMETER :: nfun = 9
2238 IF ( nfunnz /= nfun )
THEN
2244 mapfunnz2funcorr22(ifunnz) = ifun
2248 mapfunnz2funcorr22(ifunnz+1:nfun) = crazy_value_int
2252 mapfunnz2funcorr22(ifunnz) = ifun
2270 INTEGER,
INTENT(IN) :: nfunnz
2274 INTEGER ::
i,ifun,ifunnz,l
2275 INTEGER,
PARAMETER :: nfun = 9
2281 IF ( nfunnz /= nfun )
THEN
2287 mapfunnz2funcorr32(ifunnz) = ifun
2291 mapfunnz2funcorr32(ifunnz+1:nfun) = crazy_value_int
2295 mapfunnz2funcorr32(ifunnz) = ifun
2314 INTEGER,
INTENT(IN) :: nfunnz
2318 INTEGER ::
i,ifun,ifunnz,l,
m,
s
2319 INTEGER,
PARAMETER :: nfun = 27
2320 REAL(RFREAL) ::
term
2328 IF ( nfunnz /= nfun )
THEN
2334 IF ( nint(
term) /= 0 )
THEN
2336 mapfunnz2funcorr43(ifunnz) = ifun
2340 mapfunnz2funcorr43(ifunnz+1:nfun) = crazy_value_int
2344 mapfunnz2funcorr43(ifunnz) = ifun
2363 INTEGER,
INTENT(IN) :: nfunnz
2367 INTEGER :: ifun,ifunnz,
j,
k,l,
m
2368 INTEGER,
PARAMETER :: nfun = 81
2369 REAL(RFREAL) ::
term
2375 IF ( nfunnz /= nfun )
THEN
2381 IF ( nint(
term) /= 0 )
THEN
2383 mapfunnz2funcorr44(ifunnz) = ifun
2387 mapfunnz2funcorr44(ifunnz+1:nfun) = crazy_value_int
2391 mapfunnz2funcorr44(ifunnz) = ifun
subroutine, public rflu_definecorrelation221(nDim, z, nFunNZ, f)
subroutine, public rflu_computegeometrictermsoles(pRegion)
subroutine, public rflu_queryoctree(XPT, YPT, ZPT, NUMP, NEIGHP)
subroutine, public rflu_definecorrelation432(nDim, z, nFunNZ, f)
subroutine, public rflu_definecorrelation430(nDim, z, nFunNZ, f)
Vector_n max(const Array_n_const &v1, const Array_n_const &v2)
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 ic
subroutine, public rflu_buildoctree(XI, YI, ZI, XLOW, XUPP, YLOW, YUPP, ZLOW, ZUPP)
INTEGER function, public rflu_geti1posoles(l, d)
subroutine, public rflu_getqposinvoles(loc, nCells, j, k, b, g)
subroutine, public rflu_setmapfunnz2funcorr32(nFunNZ)
subroutine rflu_allocatedcuhrearrays(nDim, nFunNZ, nFun)
subroutine, public rflu_findprototypefacesoles(pRegion)
subroutine, public rflu_setmapfunnz2funcorr44(nFunNZ)
INTEGER function, public rflu_getlposoles(j, a)
subroutine, public rflu_getlposinvoles(loc, j, a)
subroutine, public rflu_definecorrelation542(nDim, z, nFunNZ, f)
subroutine, public rflu_definecorrelation431(nDim, z, nFunNZ, f)
subroutine, public rflu_enforcesymmetryoles(pRegion)
void int int int REAL REAL REAL * z
subroutine, public rflu_mapk2ij(k, i, j)
subroutine, public rflu_destroyoctree(global)
subroutine, public rflu_definecorrelation32(nDim, z, nFunNZ, f)
subroutine, public rflu_createintegralsoles(pRegion)
subroutine, public rflu_definecorrelation540(nDim, z, nFunNZ, f)
subroutine, public rflu_setmapfunnz2funcorr22(nFunNZ)
subroutine, public rflu_mapm2ijkl(m, i, j, k, l)
subroutine rflu_deallocatedcuhrearrays
subroutine, public rflu_definecorrelation541(nDim, z, nFunNZ, f)
subroutine quicksortrfrealinteger(a, b, n)
Vector_n min(const Array_n_const &v1, const Array_n_const &v2)
INTEGER function, public rflu_geti4posoles(l, m, d, e, nCells)
subroutine, public rflu_definecorrelation220(nDim, z, nFunNZ, f)
subroutine, public rflu_buildsymmetrymapsoles(pRegion)
subroutine errorstop(global, errorCode, errorLine, addMessage)
subroutine, public rflu_buildstencilsoles(pRegion)
long double dist(long double *coord1, long double *coord2, int size)
subroutine, public rflu_mapl2ijk(l, i, j, k)
INTEGER function, public rflu_getqposoles(j, k, b, g, nCells)
subroutine deregisterfunction(global)
subroutine, public rflu_createoctree(global, nPoints)
subroutine, public rflu_destroystencilsweightsoles(pRegion)
subroutine, public rflu_createstencilsweightsoles(pRegion)
subroutine, public rflu_setmapfunnz2funcorr43(nFunNZ)