c----------------------------------------------------------------------- c c c----------------------------------------------------------------------- subroutine uservp (ix,iy,iz,ieg) include 'SIZE' include 'TOTAL' include 'NEKUSE' c udiff = 0 c utrans = 0 return end c----------------------------------------------------------------------- subroutine userf (ix,iy,iz,ieg) include 'SIZE' include 'TOTAL' include 'NEKUSE' ffx = 0. ffy = 0. return end c----------------------------------------------------------------------- subroutine userq (ix,iy,iz,ieg) include 'SIZE' include 'TOTAL' include 'NEKUSE' c qvol = 0.0 c source = 0.0 return end c----------------------------------------------------------------------- subroutine userbc (ix,iy,iz,iside,ieg) include 'SIZE' include 'TSTEP' include 'INPUT' include 'NEKUSE' if (x .lt. -1.1) then ux=1 uy=0. else call my_mesh_velocity endif return end c----------------------------------------------------------------------- subroutine useric (ix,iy,iz,ieg) include 'SIZE' include 'TOTAL' include 'NEKUSE' ux=0.0 uy=0.0 uz=0.0 if (param(33) .eq. 0.0) then param(33) = 1.0 endif if (param(34) .eq. 0.0) then param(34) = 1.0e-2 endif return end c----------------------------------------------------------------------- subroutine usrdat return end c----------------------------------------------------------------------- subroutine usrdat3 return end c----------------------------------------------------------------------- subroutine usrdat2 include 'SIZE' include 'TOTAL' c param(59) = 1 ! all elements deformed c param(66) = 4 c param(67) = 4 ifxyo = .true. ifusermv = .true. !define our own mesh velocity return end c----------------------------------------------------------------------- subroutine userchk include 'SIZE' include 'TOTAL' include 'RESTART' parameter (lt=lx1*ly1*lz1*lelv) common /scrns/ vort(lt,3), w1(lt), w2(lt) integer iOutputCount save iOutputCount data iOutputCount /0/ if (istep.eq.0) call opzero(wx,wy,wz) if(time .ge. param(14)*iOutputCount) then call comp_vort3(vort, w1, w2, vx, vy, vz) call outpost(vx, vy, vz, pr, vort(1,1), 'vrt') iOutputCount = iOutputCount + 1 write (*,*) 'time = ', time write (*,*) 'iotime = ', iotime*iOutputCount write (*,*) 'params(33) = ', iOutputCount write (*,*) 'iotime = ', param(14) endif c ifreguo = .true. ! dump on regular (uniform) grid instead of GLL c nrg = 128 ! dimension of regular grid (nrg**ndim) c c ! read file-list c if (nid.eq.0) then c open(unit=199,file='file.list',form='formatted',status='old') c read(199,*) nfiles c read(199,'(A80)') (filename(i),i=1,nfiles) c close(199) c endif c call bcast(nfiles,isize) c call bcast(filename,nfiles*80) c c do i = 1,nfiles c call load_fld(filename(i)) c call comp_vort3(vort, w1, w2, vx, vy, vz) c call outpost(vx, vy, vz, pr, vort(1,1), 'vrt') c param(33) = param(33) + 1 c write (*,*) 'time = ', time c write (*,*) 'iotime = ', iotime*param(33) c write (*,*) 'params(33) = ', param(33) c write (*,*) 'iotime = ', param(14) c call prepost(.true.,'his') c enddo c c ! we're done c call exitt return end c----------------------------------------------------------------------- subroutine my_mesh_velocity include 'SIZE' include 'TOTAL' include 'NEKUSE' common /vmsh/ xo(lx1,ly1,lz1,lelt),yo(lx1,ly1,lz1,lelt) $ ,zo(lx1,ly1,lz1,lelt) frequency = param(33) amplitude = param(34) c call u_meshv(ux,uy,uz,x,y,z,time, frequency, amplitude) if (istep.eq.0) call opcopy(xo,yo,zo,xm1,ym1,zm1) n = nx1*ny1*nz1*nelv do i=1,n x = xo(i,1,1,1) y = yo(i,1,1,1) z = zo(i,1,1,1) call u_meshv(ux,uy,uz,x,y,z,time, frequency, amplitude) wx(i,1,1,1) = ux wy(i,1,1,1) = uy wz(i,1,1,1) = uz enddo return end c----------------------------------------------------------------------- subroutine u_meshv(ux,uy,uz,x,y,z,time, frequency, amplitude) one = 1.0 pi = 4.0*atan(one) c frequency = param(33) c amplitude = param(34) omega = frequency*2*pi ux = 0.0 uy = amplitude * omega * cos(omega*time) uz = 0.0 return end c-----------------------------------------------------------------------