[Nek5000-users] Problem in TurbChannel example

nek5000-users at lists.mcs.anl.gov nek5000-users at lists.mcs.anl.gov
Mon Jun 8 11:53:39 CDT 2015


​Hi Neks,



I am trying to use standard Smagorinsky model to simulate the flow for my
case. For that, we have used comp_gije, comp_sije, mag_tensor_e, cmult,
set_grid_spacing subroutines from the turbChannel example to calculate
turbulent or eddy viscosity. (I have attached the subroutine here).



subroutine eddy_visc(ediff,e)

c

c     Compute eddy viscosity using dynamic smagorinsky model

c

      include 'SIZE'

      include 'TOTAL'

      include 'ZPER'



      real ediff(nx1*ny1*nz1,nelv),cs

      integer e



      common /dynsmg/ sij (lx1*ly1*lz1,ldim,ldim)

     $              , dg2 (lx1*ly1*lz1,lelv)

     $              , snrm(lx1*ly1*lz1,lelv)



      real sij,dg2,snrm



      parameter(lxyz=lx1*ly1*lz1)



      ntot = nx1*ny1*nz1



      call comp_gije(sij,vx(1,1,1,e),vy(1,1,1,e),vz(1,1,1,e),e)

      call comp_sije(sij)



      call mag_tensor_e(snrm(1,e),sij)

      call cmult(snrm(1,e),2.0,ntot)



      call set_grid_spacing(dg2)



      if (e.eq.nelv) then  ! planar avg and define nu_tau

         cs = 0.10

         ntot = nx1*ny1*nz1*nelv

         do i=1,ntot

             cstat = (cs**2.0)*dg2(i,1)

             ediff(i,1) = param(2) + cstat*snrm(i,1)

         enddo

      endif



      return

​   ​
   end



However, we faced some difficulties running our case. We found that when
the element distribution is not uniform between the processors (mod
(lelg,lp).ne.0) the code freezes in the set_grid_spacing subroutine when
Dsavg is called.

In order to debug this case we did some tests on TurbChannel example with
dynamic Smagorinsky model and we found that this problem also exists there.
Thus, it seems that we will be having this problem except from the cases
that (mod (lelg,lp).eq.0) and we do not understand the reason for that.

Therefore, could you please guide me so that I can deal with this problem?



Thanks,​

Mahzad


*PhD** Mechanical Engineering*
*Arizona State University*
*School for engineering of matter, transport and energy (SEMTE)*



Mahzad Khoshlessan


*PhD** Mechanical Engineering*
*Arizona State University*

*School for engineering of matter, transport and energy (SEMTE)*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/nek5000-users/attachments/20150608/03fc92b5/attachment.html>


More information about the Nek5000-users mailing list