      parallel do me = 0, p-1
        lo = me * (n/p) + 1
        hi = lo + (n/p) - 1
        do i = lo, hi
          x(i) = 1.0
        enddo
        if (me .eq. 0) x(0) = 0.0
        if (me .eq. p-1) x(n+1) = 0.0
        do k = 1, NoIters
          call barrier()
          do i = lo , hi
            newx(i) = .5 * (x(i-1) + x(i+1) - dx2 * x(i))
          enddo
          call barrier()
          do i = lo , hi
            x(i) = newx(i)
          enddo
        enddo
      end parallel do 
