AcouSTO  version 2.0

◆ vec_cross()

vec_cross ( struct vector vdest,
const struct vector  v1,
const struct vector  v2 
)

Returns the cross of two vectors in the first parameter. $ \vec{vdest} = \vec{v1} \times \vec{v2} $

struct vector vdest;
vec_cross(&vdest, v1,v2);
Parameters
[out]vdestSum vector = v1 + v2.
[in]v1vector.
[in]v2vector.
92  {
93 
94 
95  vdest->x = v1.y*v2.z -v1.z*v2.y;
96  vdest->y = v1.z*v2.x -v1.x*v2.z;
97  vdest->z = v1.x*v2.y -v1.y*v2.x;
98 
99 }
DOUBLE z
Definition: structs.h:35
DOUBLE x
Definition: structs.h:31
DOUBLE y
Definition: structs.h:33