logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

single_blas_level1 - real

Author

       Generated automatically by Doxygen for LAPACK from the source code.

Version 3.10.0                                   Wed Jan 12 2022                           single_blas_level1(3)

Detailed Description

       This is the group of real LEVEL 1 BLAS routines.

Function Documentation

realfunctionsasum(integerN,real,dimension(*)SX,integerINCX)SASUMPurpose:

               SASUM takes the sum of the absolute values.
               uses unrolled loops for increment equal to one.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 3/93 to return if incx .le. 0.
                modified 12/3/93, array(1) declarations changed to array(*)

   subroutinesaxpy(integerN,realSA,real,dimension(*)SX,integerINCX,real,dimension(*)SY,integerINCY)SAXPYPurpose:

               SAXPY constant times a vector plus a vector.
               uses unrolled loops for increments equal to one.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SA

                     SA is REAL
                      On entry, SA specifies the scalar alpha.

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

           SY

                     SY is REAL array, dimension ( 1 + ( N - 1 )*abs( INCY ) )

           INCY

                     INCY is INTEGER
                    storage spacing between elements of SY

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 12/3/93, array(1) declarations changed to array(*)

   realfunctionscabs1(complexZ)SCABS1Purpose:

            SCABS1 computes |Re(.)| + |Im(.)| of a complex number

       ParametersZ

                     Z is COMPLEX

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

   realfunctionscasum(integerN,complex,dimension(*)CX,integerINCX)SCASUMPurpose:

               SCASUM takes the sum of the (|Re(.)| + |Im(.)|)'s of a complex vector and
               returns a single precision result.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           CX

                     CX is COMPLEX array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 3/93 to return if incx .le. 0.
                modified 12/3/93, array(1) declarations changed to array(*)

   subroutinescopy(integerN,real,dimension(*)SX,integerINCX,real,dimension(*)SY,integerINCY)SCOPYPurpose:

               SCOPY copies a vector, x, to a vector, y.
               uses unrolled loops for increments equal to 1.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

           SY

                     SY is REAL array, dimension ( 1 + ( N - 1 )*abs( INCY ) )

           INCY

                     INCY is INTEGER
                    storage spacing between elements of SY

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 12/3/93, array(1) declarations changed to array(*)

   realfunctionsdot(integerN,real,dimension(*)SX,integerINCX,real,dimension(*)SY,integerINCY)SDOTPurpose:

               SDOT forms the dot product of two vectors.
               uses unrolled loops for increments equal to one.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

           SY

                     SY is REAL array, dimension ( 1 + ( N - 1 )*abs( INCY ) )

           INCY

                     INCY is INTEGER
                    storage spacing between elements of SY

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 12/3/93, array(1) declarations changed to array(*)

   realfunctionsdsdot(integerN,realSB,real,dimension(*)SX,integerINCX,real,dimension(*)SY,integerINCY)SDSDOTPurpose:

              Compute the inner product of two vectors with extended
              precision accumulation.

              Returns S.P. result with dot product accumulated in D.P.
              SDSDOT = SB + sum for I = 0 to N-1 of SX(LX+I*INCX)*SY(LY+I*INCY),
              where LX = 1 if INCX .GE. 0, else LX = 1+(1-N)*INCX, and LY is
              defined in a similar way using INCY.

       ParametersN

                     N is INTEGER
                     number of elements in input vector(s)

           SB

                     SB is REAL
                     single precision scalar to be added to inner product

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )
                     single precision vector with N elements

           INCX

                     INCX is INTEGER
                     storage spacing between elements of SX

           SY

                     SY is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )
                     single precision vector with N elements

           INCY

                     INCY is INTEGER
                     storage spacing between elements of SY

       Author
           Lawson, C. L., (JPL), Hanson, R. J., (SNLA),

           Kincaid, D. R., (U. of Texas), Krogh, F. T., (JPL)

           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

               REFERENCES

               C. L. Lawson, R. J. Hanson, D. R. Kincaid and F. T.
               Krogh, Basic linear algebra subprograms for Fortran
               usage, Algorithm No. 539, Transactions on Mathematical
               Software 5, 3 (September 1979), pp. 308-323.

               REVISION HISTORY  (YYMMDD)

               791001  DATE WRITTEN
               890531  Changed all specific intrinsics to generic.  (WRB)
               890831  Modified array declarations.  (WRB)
               890831  REVISION DATE from Version 3.2
               891214  Prologue converted to Version 4.0 format.  (BAB)
               920310  Corrected definition of LX in DESCRIPTION.  (WRB)
               920501  Reformatted the REFERENCES section.  (WRB)
               070118  Reformat to LAPACK coding style

   subroutinesrot(integerN,real,dimension(*)SX,integerINCX,real,dimension(*)SY,integerINCY,realC,realS)SROTPurpose:

               applies a plane rotation.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

           SY

                     SY is REAL array, dimension ( 1 + ( N - 1 )*abs( INCY ) )

           INCY

                     INCY is INTEGER
                    storage spacing between elements of SY

           C

                     C is REAL

           S

                     S is REAL

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 12/3/93, array(1) declarations changed to array(*)

   subroutinesrotm(integerN,real,dimension(*)SX,integerINCX,real,dimension(*)SY,integerINCY,real,dimension(5)SPARAM)SROTMPurpose:

               APPLY THE MODIFIED GIVENS TRANSFORMATION, H, TO THE 2 BY N MATRIX

               (SX**T) , WHERE **T INDICATES TRANSPOSE. THE ELEMENTS OF SX ARE IN
               (SX**T)

               SX(LX+I*INCX), I = 0 TO N-1, WHERE LX = 1 IF INCX .GE. 0, ELSE
               LX = (-INCX)*N, AND SIMILARLY FOR SY USING USING LY AND INCY.
               WITH SPARAM(1)=SFLAG, H HAS ONE OF THE FOLLOWING FORMS..

               SFLAG=-1.E0     SFLAG=0.E0        SFLAG=1.E0     SFLAG=-2.E0

                 (SH11  SH12)    (1.E0  SH12)    (SH11  1.E0)    (1.E0  0.E0)
               H=(          )    (          )    (          )    (          )
                 (SH21  SH22),   (SH21  1.E0),   (-1.E0 SH22),   (0.E0  1.E0).
               SEE  SROTMG FOR A DESCRIPTION OF DATA STORAGE IN SPARAM.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

           SY

                     SY is REAL array, dimension ( 1 + ( N - 1 )*abs( INCY ) )

           INCY

                     INCY is INTEGER
                    storage spacing between elements of SY

           SPARAM

                     SPARAM is REAL array, dimension (5)
                SPARAM(1)=SFLAG
                SPARAM(2)=SH11
                SPARAM(3)=SH21
                SPARAM(4)=SH12
                SPARAM(5)=SH22

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

   subroutinesrotmg(realSD1,realSD2,realSX1,realSY1,real,dimension(5)SPARAM)SROTMGPurpose:

               CONSTRUCT THE MODIFIED GIVENS TRANSFORMATION MATRIX H WHICH ZEROS
               THE SECOND COMPONENT OF THE 2-VECTOR  (SQRT(SD1)*SX1,SQRT(SD2)*>    SY2)**T.
               WITH SPARAM(1)=SFLAG, H HAS ONE OF THE FOLLOWING FORMS..

               SFLAG=-1.E0     SFLAG=0.E0        SFLAG=1.E0     SFLAG=-2.E0

                 (SH11  SH12)    (1.E0  SH12)    (SH11  1.E0)    (1.E0  0.E0)
               H=(          )    (          )    (          )    (          )
                 (SH21  SH22),   (SH21  1.E0),   (-1.E0 SH22),   (0.E0  1.E0).
               LOCATIONS 2-4 OF SPARAM CONTAIN SH11,SH21,SH12, AND SH22
               RESPECTIVELY. (VALUES OF 1.E0, -1.E0, OR 0.E0 IMPLIED BY THE
               VALUE OF SPARAM(1) ARE NOT STORED IN SPARAM.)

               THE VALUES OF GAMSQ AND RGAMSQ SET IN THE DATA STATEMENT MAY BE
               INEXACT.  THIS IS OK AS THEY ARE ONLY USED FOR TESTING THE SIZE
               OF SD1 AND SD2.  ALL ACTUAL SCALING OF DATA IS DONE USING GAM.

       ParametersSD1

                     SD1 is REAL

           SD2

                     SD2 is REAL

           SX1

                     SX1 is REAL

           SY1

                     SY1 is REAL

           SPARAM

                     SPARAM is REAL array, dimension (5)
                SPARAM(1)=SFLAG
                SPARAM(2)=SH11
                SPARAM(3)=SH21
                SPARAM(4)=SH12
                SPARAM(5)=SH22

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

   subroutinesscal(integerN,realSA,real,dimension(*)SX,integerINCX)SSCALPurpose:

               SSCAL scales a vector by a constant.
               uses unrolled loops for increment equal to 1.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SA

                     SA is REAL
                      On entry, SA specifies the scalar alpha.

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 3/93 to return if incx .le. 0.
                modified 12/3/93, array(1) declarations changed to array(*)

   subroutinesswap(integerN,real,dimension(*)SX,integerINCX,real,dimension(*)SY,integerINCY)SSWAPPurpose:

               SSWAP interchanges two vectors.
               uses unrolled loops for increments equal to 1.

       ParametersN

                     N is INTEGER
                    number of elements in input vector(s)

           SX

                     SX is REAL array, dimension ( 1 + ( N - 1 )*abs( INCX ) )

           INCX

                     INCX is INTEGER
                    storage spacing between elements of SX

           SY

                     SY is REAL array, dimension ( 1 + ( N - 1 )*abs( INCY ) )

           INCY

                     INCY is INTEGER
                    storage spacing between elements of SY

       Author
           Univ. of Tennessee

           Univ. of California Berkeley

           Univ. of Colorado Denver

           NAG Ltd.

       FurtherDetails:

                jack dongarra, linpack, 3/11/78.
                modified 12/3/93, array(1) declarations changed to array(*)

Name

       single_blas_level1 - real

Synopsis

Functions
       real function sasum (N, SX, INCX)
           SASUM
       subroutine saxpy (N, SA, SX, INCX, SY, INCY)
           SAXPY
       real function scabs1 (Z)
           SCABS1
       real function scasum (N, CX, INCX)
           SCASUM
       subroutine scopy (N, SX, INCX, SY, INCY)
           SCOPY
       real function sdot (N, SX, INCX, SY, INCY)
           SDOT
       real function sdsdot (N, SB, SX, INCX, SY, INCY)
           SDSDOT
       subroutine srot (N, SX, INCX, SY, INCY, C, S)
           SROT
       subroutine srotm (N, SX, INCX, SY, INCY, SPARAM)
           SROTM
       subroutine srotmg (SD1, SD2, SX1, SY1, SPARAM)
           SROTMG
       subroutine sscal (N, SA, SX, INCX)
           SSCAL
       subroutine sswap (N, SX, INCX, SY, INCY)
           SSWAP

See Also