[Nek5000-users] Computing aerodynamic coefficients

nek5000-users at lists.mcs.anl.gov nek5000-users at lists.mcs.anl.gov
Fri Feb 9 05:49:39 CST 2018


Dear Neks:

  I have a file containing the lift and drag coefficient for a wing that 
was computed
long back using NEK5000. The value of the aerodynamic coefficients look 
fine.
Since computations were carried out for a very specific set of 
parameters we do not
have any experimental or numerical result to check it against. The code 
that I am using
presently for computing aerodynamic coefficients is slightly different 
from the one
we used earlier. Can someone please take a look at the following snippet 
from earlier
version of the code and check if it computes the right aerodynamic 
coefficients?

Many thanks.

Best wishes,
NN.


subroutine set_obj  ! define objects for surface integrals
c
       include 'SIZE'
       include 'TOTAL'

       integer e,f,eg

       nobj = 1
       iobj = 0
       do ii=nhis+1,nhis+nobj
          iobj = iobj+1
          hcode(10,ii) = 'I'
          hcode( 1,ii) = 'F'
          hcode( 2,ii) = 'F'
          hcode( 3,ii) = 'F'
          lochis(1,ii) = iobj
       enddo
       nhis = nhis + nobj

       if (maxobj.lt.nobj) call exitti('increase maxobj in SIZE$',nobj)

       nxyz  = nx1*ny1*nz1
       nface = 2*ndim

       do e=1,nelv
       do f=1,nface
          if (cbc(f,e,1).eq.'W  ') then
             iobj  = 1
             if (iobj.gt.0) then
                nmember(iobj) = nmember(iobj) + 1
                mem = nmember(iobj)
                eg  = lglel(e)
                object(iobj,mem,1) = eg
                object(iobj,mem,2) = f
c              write(6,1) iobj,mem,f,eg,e,nid,' OBJ'
c   1          format(6i9,a4)

             endif
          endif
       enddo
       enddo

c     write(6,*) 'number',(nmember(k),k=1,4)
c
       return
       end




More information about the Nek5000-users mailing list