Problem:
I want a function to compute the angles in a right triangle only knowing the length of all three sides (i don't know the angles).
I tried to solve this with the Math::Cephes module,
But the function tells me I have to pass an array reference to it. I've tried to pass it my X,Y points in several ways but no dice.
Anybody know a simple way to do this?
Here's the code from my last attempt with Cephes.
Code does NOT work. The module loads fine. My
error is:
"Must supply array references at C:/Perl/site/lib/Math/Cephes.pm line 107."
use Math::Cephes qw(:all);
# double p[3], q[3], vecang();$y = vecang( $p, $q );
# For two vectors p, q, the angle A between them is given by
my @p = ("0","0");
my @q = ("4","3");
my $ang = vecang(@p,@q);
print "ang=$ang\n";
thanks for readin,