Question: Law of cosines with a procedure, help!

So, i'm using Maple 13 in my school, and our homework was to make two procedures which could calculate something.

 

I'm interested in making a procedure which can calculate out the angles of my triangle with the law of cosines, and this is how my procedure looks so far:

 

findA := proc (a, b, c)

local solA;

solA := arccos((b^2+c^2-a^2)/(2*b+2*c));

return evalf(solA);

end proc

 

findA(67, 50, 34)

 

This is very simple, but it sadly doesn't work :(

I doesn't actually calculate out the degrees of the angle, i just get this number: 3.141592654-2.283889363*I

I heard it's something about maple having trouble calculating degrees, but have also heard a lot of people talking about solutions to this, i have not been able to find any solution that i could use in a procedure, is there anyone who might have an idea, how to fix this?

 

TLDR; I can't calculate degrees correctly using my law of cosines procedure, how do i fix it? 

 

Would like a response as quickly as possible, since this has to be done for tonight, sadly. I hope someone will be able to help me.

 

If you have any further questions, dont hesitate to ask me!

Please Wait...