Oops! Sorry, I didn't read the function through before posting it. I should also have sent the DotProduct function. I'm sure you've already done your own version of this, but just for completeness here it is:
function DotProduct(x_1, y_1, x_2, y_2) { // finds the dot product of two vectors return ((x_1 * x_2) + (y_1 * y_2)); }
(no subject)
Date: 2011-03-31 07:36 am (UTC)function DotProduct(x_1, y_1, x_2, y_2)
{
// finds the dot product of two vectors
return ((x_1 * x_2) + (y_1 * y_2));
}