void vlcom3_c ( SpiceDouble a,
ConstSpiceDouble v1 [3],
SpiceDouble b,
ConstSpiceDouble v2 [3],
SpiceDouble c,
ConstSpiceDouble v3 [3],
SpiceDouble sum[3] )
This subroutine computes the vector linear combination
a*v1 + b*v2 + c*v3 of double precision, 3-dimensional vectors.
None.
VECTOR
VARIABLE I/O DESCRIPTION
-------- --- --------------------------------------------------
a I Coefficient of v1
v1 I Vector in 3-space
b I Coefficient of v2
v2 I Vector in 3-space
c I Coefficient of v3
v3 I Vector in 3-space
sum O Linear Vector Combination a*v1 + b*v2 + c*v3
a is a double precision number.
v1 is a double precision 3-dimensional vector.
b is a double precision number.
v2 is a double precision 3-dimensional vector.
c is a double precision number.
v3 is a double precision 3-dimensional vector.
sum is a double precision 3-dimensional vector which contains
the linear combination a*v1 + b*v2 + c*v3
None.
Error free.
None.
For each index from 0 to 2, this routine implements in FORTRAN
code the expression:
sum[i] = a*v1[i] + b*v2[i] + c*v3[i]
No error checking is performed to guard against numeric overflow.
Often one has the components (a,b,c) of a vector in terms
of a basis v1, v2, v3. The vector represented by (a,b,c) can
be obtained immediately from the call
vlcom3_c ( a, v1, b, v2, c, v3, VECTOR )
None.
None.
W.L. Taber (JPL)
E.D. Wright (JPL)
-CSPICE Version 1.1.0, 22-OCT-1998 (NJB)
Made input vectors const.
-CSPICE Version 1.0.0, 08-FEB-1998 (EDW)
linear combination of three 3-dimensional vectors
Link to routine vlcom3_c source file vlcom3_c.c
|