[Nek5000-users] Planar average in z-direction problem (image updated)

nek5000-users at lists.mcs.anl.gov nek5000-users at lists.mcs.anl.gov
Tue Jul 24 01:34:14 CDT 2018


Hi, NeksI wonder why planar_average_z in navier5.f shows wrong result.here I attached 2 images.1, https://drive.google.com/file/d/1Kng9HZfQW-TGTFwmFcXzbrcvhRYrQSdc/view?usp=sharing2.https://drive.google.com/file/d/1FN3i5mE6VSoPeehG5evjC33WrD3J4lB5/view?usp=sharingFirst image shows the z-directional grids points from zm1(I wrote a code to extract z coordinate at y = 0 as follows:======================================================insnum = nidinsuni = insnum + 1000WRITE(insnam,98) 'inst_field_', insnumOPEN(unit=insuni,file=insnam   insnum = nid   insuni = insnum + 1000   WRITE(insnam,98) 'inst_field_', insnum   Open(unit=insuni,file=insnam)   do i = 1,n   if (ym1(i,1,1,1).eq.0.0)then   WRITE(insuni,5) xm1(i,1,1,1)  %         , zm1(i,1,1,1)  %         , vx(i,1,1,1)  %         , vy(i,1,1,1)  %         , vz(i,1,1,1)  %         , phig(i,1,1,1)   endif   enddo   CLOSE(insuni)======================================================​Then, I can collect lots of field data from each processor and sort data with ascending order using matlab.So, I got the result as 1st image.But when I use plannar_average_zI got the result as shown in 2nd image.1. I really want to modify the problems, so could you give me your idea on this problem?2. Additionally, could you explain 'zgm1' and 'area'?I noticed that, planar_average_r or s ... in turbChannel case has also 'area' but, those case are used to calculate ondifferent direction.But they used same input parameters.What I understand about area is, surface area of element.But I thought that different direction needs different indexing=======================================================   subroutine planar_average_z(ua,u,w1,w2)cc  Compute r-s planar average of quantity u()c   include 'SIZE'   include 'GEOM'   include 'PARALLEL'   include 'WZ'   include 'ZPER'c   real ua(lz1,nelz),u(lx1*ly1,lz1,nelv),w1(lz1,nelz),w2(lz1,nelz)   integer e,eg,ezc   melxy = nelx*nelyc   nz = lz1*nelz   call rzero(ua,nz)   call rzero(w1,nz)c   do e=1,neltc        eg = lglel(e)c    ez = 1 + (eg-1)/melxy    call get_exyz(ex,ey,ez,eg,nelx,nely,nelz)c    do k=1,lz1    do i=1,lx1*ly1      zz = (1.-zgm1(k,3))/2. ! = 1 for k=1, = 0 for k=lz1      aa = zz*area(i,1,5,e) + (1-zz)*area(i,1,6,e) ! wgtd jacobian      w1(k,ez) = w1(k,ez) + aa      ua(k,ez) = ua(k,ez) + aa*u(i,k,e)    enddo    enddo   enddoc   call gop(ua,w2,'+ ',nz)   call gop(w1,w2,'+ ',nz)c   do i=1,nz    ua(i,1) = ua(i,1) / w1(i,1) ! Normalize   enddoc   return   end======================================================Regards,Hyunduk.​

------------------------------<wbr style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 14px; background-color: rgb(255, 255, 255);">------------------------------------------------------------------------------------
HyundukSeo(Mr.)
IntegratedPh.D.course,Schoo<wbr style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 14px; background-color: rgb(255, 255, 255);">PusanNationalUniversity​
ExperimentalThermo-FluidsMec<wbr style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 14px; background-color: rgb(255, 255, 255);">ENsys)Laboratory
http://fluid.pusan.ac.kr
T.:+82-51-510-1536M.:+82-10<wbr style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 14px; background-color: rgb(255, 255, 255);">-2964-0994

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/nek5000-users/attachments/20180724/6e8b3451/attachment-0001.html>


More information about the Nek5000-users mailing list