[Nek5000-users] Monitor points, location probe

nek5000-users at lists.mcs.anl.gov nek5000-users at lists.mcs.anl.gov
Mon Jun 16 10:28:23 CDT 2014


 Thank you!                      
Works great after a little change 
real   work1(lt), work2(lt), work3(lt)
 
Van

6/15/2014 4:13:03 PM пользователь (nek5000-users at lists.mcs.anl.gov) написал:

Hi,You can make it much simpler! Simply do for instance:
real work1(lx1,ly1,lz1,lelt), work2(lx1,ly1,lz1,lelt), work3(lx1,ly1,lz1,lelt)
... compute your dtdx dtdy dtdz
call opcopy(work1,work2,work3,vx,vy,vz)    ! Save vx vy vz for later
call opcopy(vx,vy,vz,dtdx,dtdy,dtdz)           ! Save dtdx into vx for the hpts output
call hpts
call opcopy(vx,vy,vz,work1,work2,work3)    ! Restore vx vy vz
That should do the trick I guess.
Cheers,
JC

2014-06-15 9:07 GMT+02:00 <nek5000-users at lists.mcs.anl.gov>:

 I need to monitor scalar gradient (scalar is modelled with temperature as in examples.pdf).
 So I have inserted in USERCHK
      parameter (lt=lx1*ly1*lz1*lelt)
      common /ilgrad/ dtdx(lt),dtdy(lt),dtdz(lt)
      if ((mod(istep,iostep).eq.0).and.(istep.ge.iostep)) then
      call gradm1(dtdx,dtdy,dtdz,t)
      endif
      call hpts()
 
 Next there are two options to monitor a quantity
 1. in .rea file like
  ***** HISTORY AND INTEGRAL DATA *****
 001   POINTS.  Hcode, I,J,H,IEL
 UV PT    H      3    3    1    1
 
 But I dont know how to tell it that I want instead of UV, and also I don't know how to calculate number of element IEL from physical location.
 
 2. hpts.in file
 you can input physical coordinates of a location, but in hpts.out only the following variables # time  vx  vy  [vz]  pr  T  PS1  PS2  ...
 are being stored.
 
 So I tried to modify nek5000/branches/mvmesh/postpro.f in the following way:
 first I put      parameter (lt=lx1*ly1*lz1*lelt)
      common /ilgrad/ dtdx(lt),dtdy(lt),dtdz(lt)
 in the beginning of subroutine hpts
 
 and later in this routine changed the code:
 
 
      ! pack working array
      nflds = 0
      if(ifvo) then
        call copy(wrk(1,1),vx,ntot)
        call copy(wrk(1,2),vy,ntot)
        if(if3d) call copy(wrk(1,3),vz,ntot)
        nflds = ndim
      endif
      if(ifpo) then
        nflds = nflds + 1
        call copy(wrk(1,nflds),pm1,ntot)
      endif
      if(ifto) then
        nflds = nflds + 1
        call copy(wrk(1,nflds),t,ntot)
      endif
        nflds = nflds + 1                        !!!!!!!!!inserted
        call copy(wrk(1,nflds),dtdx,ntot)        !!!!!!!!!inserted
        nflds = nflds + 1                        !!!!!!!!!inserted
        call copy(wrk(1,nflds),dtdy,ntot)        !!!!!!!!!inserted
      do i = 1,ldimt
         if(ifpsco(i)) then
           nflds = nflds + 1
           call copy(wrk(1,nflds),T(1,1,1,1,i+1),ntot)
         endif
      enddo
      It was compiled without problem, but running the program yielded no change in hpts.out,
 as before there are only 5 columns
 # time  vx  vy  [vz]  pr  T  
 Please help
 
 
 _______________________________________________
 Nek5000-users mailing list
 Nek5000-users at lists.mcs.anl.gov
 https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users

-- 
Jean-Christophe Loiseau
Homepage



More information about the Nek5000-users mailing list