Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ sdsdot(3dxml) — Extended Math Library 3.4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

SDSDOT(3dxml)  —  Subroutines

Name

sdsdot − Product of scaled vector and vector

FORMAT

SDSDOT (n, alpha, x, incx, y, incy)

Function Value

dotpr: real∗4
The dot product of the two vectors x and y.

If n<=0, dotpr returns the value 0.0. 

Arguments

ninteger∗4
On entry, the number of elements in the vectors x and y.
On exit, n is unchanged.

alphareal∗4 | real∗8
On entry, the scalar multiplier (alpha) for the elements of the vector x.
On exit, alpha is unchanged.

xreal∗4 | real∗8
On entry, a one-dimensional array X of length at least (1+(n-1)∗|incx|), containing the elements of the vector x.
On exit, x is unchanged.

incxinteger∗4
On entry, the increment for the array X.
If incx >= 0, vector x is stored forward in the array, so that x(i) is stored in location X(1+(i-1)∗incx).
If incx < 0, vector x is stored backward in the array, so that x(i) is stored in location X(1+(n-i)∗|incx|).
On exit, incx is unchanged.

yreal∗4 | real∗8
On entry, a one-dimensional array Y of length at least (1+(n-1)∗|incx|), containing the elements of the vector y.
On exit, y is unchanged.

incyinteger∗4
On entry, the increment for the array Y.
If incy >= 0, vector y is stored forward in the array, so that y(i) is stored in location Y(1+(i-1)∗incy).
If incy < 0, vector y is stored backward in the array, so that y(i) is stored in location Y(1+(n-i)∗|incy|).
On exit, incy is unchanged.

Description

SDSDOT scales the elements of a real vector, x, by the value of alpha and then computes the dot product of the resultant vector and another real vector, y.  SDSDOT returns the result in single precision. 

Example

INTEGER∗4 INCX,INCY
REAL∗8 X(20),Y(20),alpha
REAL∗4 DOTPR
INCX = 1
INCY = 1
alpha = 0.4
N = 20
DOTPR = SDSDOT(N,alpha,X,INCX,Y,INCY)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026