add.f 972 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
c---------------------------------------------------------------------
c---------------------------------------------------------------------

      subroutine  add

c---------------------------------------------------------------------
c---------------------------------------------------------------------

c---------------------------------------------------------------------
c     addition of update to the vector u
c---------------------------------------------------------------------

      include 'header.h'

      integer  c, i, j, k, m

      do     c = 1, ncells
         do     k = start(3,c), cell_size(3,c)-end(3,c)-1
            do     j = start(2,c), cell_size(2,c)-end(2,c)-1
               do     i = start(1,c), cell_size(1,c)-end(1,c)-1
                  do    m = 1, 5
                     u(m,i,j,k,c) = u(m,i,j,k,c) + rhs(m,i,j,k,c)
                  enddo
               enddo
            enddo
         enddo
      enddo

      return
      end