3 <meta name="generator" content="groff -Thtml, see www.gnu.org">
4 <meta name="Content-Style" content="text/css">
5 <title>vec_magnitude_in_direction</title>
9 <h1 align=center>vec_magnitude_in_direction</h1>
10 <a href="#NAME">NAME</a><br>
11 <a href="#SYNOPSIS">SYNOPSIS</a><br>
12 <a href="#DESCRIPTION">DESCRIPTION</a><br>
13 <a href="#AUTHOR">AUTHOR</a><br>
14 <a href="#LICENSE">LICENSE</a><br>
15 <a href="#VERSION">VERSION</a><br>
16 <a href="#SEE ALSO">SEE ALSO</a><br>
19 <!-- Creator : groff version 1.17.2 -->
20 <!-- CreationDate: Fri May 3 14:58:48 2002 -->
23 <table width="100%" border=0 rules="none" frame="void"
24 cols="2" cellspacing="0" cellpadding="0">
25 <tr valign="top" align="left">
26 <td width="10%"></td><td width="90%">
27 vec_magnitude_in_direction - calculate relative direction of two vectors</td></table>
28 <a name="SYNOPSIS"></a>
31 <table width="100%" border=0 rules="none" frame="void"
32 cols="2" cellspacing="0" cellpadding="0">
33 <tr valign="top" align="left">
34 <td width="10%"></td><td width="90%">
35 <pre><b>#include <matvec.h>
37 float vec_magnitude_in_direction (const float *v1, const float *v2);
38 </b></pre></td></table>
39 <a name="DESCRIPTION"></a>
42 <table width="100%" border=0 rules="none" frame="void"
43 cols="2" cellspacing="0" cellpadding="0">
44 <tr valign="top" align="left">
45 <td width="10%"></td><td width="90%">
46 If <b>v1</b> and <b>v2</b> are parallel and point in the
47 same direction, then <b>vec_magnitude_in_direction</b>
48 returns +1. If <b>v1</b> and <b>v2</b> are perpendicular,
49 this returns 0. If <b>v1</b> and <b>v2</b> are parallel and
50 point in opposite directions to each other, this returns -1.
51 For other vectors, this function returns the cosine of the
52 angle between the vectors.</td></table>
56 <table width="100%" border=0 rules="none" frame="void"
57 cols="2" cellspacing="0" cellpadding="0">
58 <tr valign="top" align="left">
59 <td width="10%"></td><td width="90%">
60 Richard Jones <rich@annexia.org></td></table>
61 <a name="LICENSE"></a>
64 <table width="100%" border=0 rules="none" frame="void"
65 cols="2" cellspacing="0" cellpadding="0">
66 <tr valign="top" align="left">
67 <td width="10%"></td><td width="90%">
68 GNU LGPL (see http://www.gnu.org/)</td></table>
69 <a name="VERSION"></a>
72 <table width="100%" border=0 rules="none" frame="void"
73 cols="2" cellspacing="0" cellpadding="0">
74 <tr valign="top" align="left">
75 <td width="10%"></td><td width="90%">
76 c2lib-1.2.13</td></table>
77 <a name="SEE ALSO"></a>
80 <table width="100%" border=0 rules="none" frame="void"
81 cols="2" cellspacing="0" cellpadding="0">
82 <tr valign="top" align="left">
83 <td width="10%"></td><td width="90%">
84 <b>vec_dot_product(3)</b>,
85 <b>vec_angle_between(3)</b></td></table>