Return to Statement


Dot Product of Two Vectors Example

The following statements show the use of the DOTF function.

Statement

Assigned Value

NUMBER/A(3),B(3)

 

DATA/A,.7071,.7071,0

A(1)=.7071,A(2)=.7071,A(3)=0

DATA/B,.866,.5,0

B(1)=.866,B(2)=.5,B(3)=0

PROD=DOTF(A,B)

PROD=.9659