y_eq_y_plus_sx.F


c**********************************************************************
#include "author.inc"
c*    $Id: y_eq_y_plus_sx.F,v 1.5 1995/07/30 17:49:41 turner Exp $
c*
c*    Computes y = y + s*x.
c*
c*    <PARAMETER LIST>
c*
c*     Input:
c*      n - number of elements
c*      x - x-vector
c*
c*     In/Out: 
c*      y - y-vector
c*
c*     Output:
c*      status - return status
c*
#include "copyright.inc"
c**********************************************************************
      subroutine JT_y_eq_y_plus_sx (n, s, x, y, status)
      implicit none
c
c ... Input:
      integer n
      real s, x(n)
c
c ... In/Out:
      real y(n)
c
c ... Output:
      integer status
c
#ifdef use_blas
      call SAXPY (n, s, x, 1, y, 1)
#else
c ... Local:
      integer i
c
      do i=1,n
       y(i) = y(i) + s*x(i)
      enddo
#endif
c
      status = 0
      return
      end