[Nek5000-users] Gradients in an object : Few queries for parallel setting.

nek5000-users at lists.mcs.anl.gov nek5000-users at lists.mcs.anl.gov
Fri Jun 11 11:55:50 CDT 2010


Paul,

Thanks for the suggestions. Just a brief description of what I am doing : I
am running LES in a turbine passage and this subroutine is to see if the
resolution close to the blade is ok. I would be modifying it during
production runs.

I implemented the changes you mentioned, but I get the following error from
usrchk routine :

done :: set initial conditions

 call userchk
Signal 15 received.
Signal 15 received.
.
.

When I comment the call gop( ) routine the program runs but I have the same
problem that only a part of the object is written out. The modified code is
pasted below. Thanks for any suggestions.

<code>

       common /scrns/         pm1(lx1,ly1,lz1,lelv)
     $,vxx(lx1,ly1,lz1,lelv),vxy(lx1,ly1,lz1,lelv),vxz(lx1,ly1,lz1,lelv)
     $,vyx(lx1,ly1,lz1,lelv),vyy(lx1,ly1,lz1,lelv),vyz(lx1,ly1,lz1,lelv)
       common /scruz/
     $ vzx(lx1,ly1,lz1,lelv),vzy(lx1,ly1,lz1,lelv),vzz(lx1,ly1,lz1,lelv)
     $,temp(4,ly1**2),work(4,ly1**2)

        if (istep.eq.0) call set_obj ! obj for surface integrals.

        if (nid.eq.0.and. istep.eq.0) then ! ONLY NODE 0 opens file

        open(unit=103,file='coord.txt')
        open(unit=104,file='elenos.txt')
        endif

        call gradm1(vxx,vxy,vxz,vx)

       DO 100 II=1,NHIS

         IF (HCODE(10,II).NE.'I') GOTO 100
         IOBJ   = LOCHIS(1,II)
         MEMTOT = NMEMBER(IOBJ)

         IF (HCODE(1,II).NE.' ' .OR. HCODE(2,II).NE.' ' .OR.
     $       HCODE(3,II).NE.' ' ) THEN
            IFIELD = 1

            DO 50 MEM=1,MEMTOT
               ISK   = 0
               IEG   = OBJECT(IOBJ,MEM,1)
               IFC   = OBJECT(IOBJ,MEM,2)
               if (nid.eq.0) write(104,*) ieg,gllel(ieg),gllnid(ieg)

               call rzero(temp,4*ly1*ly1)

        IF (gllnid(ieg).eq.nid) then ! this processor has a contribution
           ie = gllel(ieg)

      CALL DSSET(NX1,NY1,NZ1)
      IFACE  = EFACE1(IFC)
      JS1    = SKPDAT(1,IFACE)
      JF1    = SKPDAT(2,IFACE)
      JSKIP1 = SKPDAT(3,IFACE)
      JS2    = SKPDAT(4,IFACE)
      JF2    = SKPDAT(5,IFACE)
      JSKIP2 = SKPDAT(6,IFACE)

      I = 0
      DO 110 J2=JS2,JF2,JSKIP2
      DO 110 J1=JS1,JF1,JSKIP1
         I = I+1
          temp(1,i) = xm1(j1,j2,1,ie)
          temp(2,i) = ym1(j1,j2,1,ie)
          temp(3,i) = zm1(j1,j2,1,ie)
          temp(4,i) = vxy(j1,j2,1,ie)
  110 CONTINUE
           ENDIF
          call gop(temp,work,'+  ',4*ly1*ly1)  ! gather results onto rank 0
          IF (nid.eq.0) write(103,18) ((temp(k,i),k=1,4),i=1,ly1*ly1)
   18  format(1p4e15.7)

   50 CONTINUE
      ENDIF
  100 CONTINUE

</code>


Regards
Shriram Jagannathan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/nek5000-users/attachments/20100611/cf859ad4/attachment.html>


More information about the Nek5000-users mailing list