# Thread: Get angle from coordinates of a corner?

1. ## Get angle from coordinates of a corner?

Hi, please bear with me as I have not taken trig in over 10 year.. I am PRETTY sure this is a trigonometry problem.

Here is an image that describes my problem:

Note: the lengths and angles indicated may not be 100% exact, but they should be close. I measured them as well as I was able. The lengths on the labelled sides ARE the same on all the shown triangles, and do not change. The values for X and Y ARE known, and X does not change either.

I need an expression that describes the value for Z in terms of X and Y.

Any help on this would be appreciated, I don't really even know where to start!

2. Originally Posted by Malkalypse
Hi, please bear with me as I have not taken trig in over 10 year.. I am PRETTY sure this is a trigonometry problem.

Here is an image that describes my problem:

Note: the lengths and angles indicated may not be 100% exact, but they should be close. I measured them as well as I was able. The lengths on the labelled sides ARE the same on all the shown triangles, and do not change. The values for X and Y ARE known, and X does not change either.

I need an expression that describes the value for Z in terms of X and Y.

Any help on this would be appreciated, I don't really even know where to start!
i don't see Z labeled on the actual figure, i have no idea what length or angle it is you want to find

3. Sorry if I was not clear about that.. Z here describes the angle that is labelled (where it says Z1, Z2, and Z3)

Basically, I need an expression for the angle of the indicated corner as shown in this link:
http://www.versatileartist.com/temp/pca_help.avi

to be more specifically clear about the original image: X is the distance directly right from the bottom corner of the triangle, Y is the distance directly up from it, and Z is the angle of the top corner. X does not change.

4. Hello, Malkalypse!

If I interpret the problem correctly, angle z = angle CBA.

I assume that the $14.776,\:14.967,\;x = 4.848$ are fixed
. . and that $y$ may vary.
Code:
                            B
*
*  *|
*  z * |
14.776    *      *  |
*        *   |
*          *    |
*            *     |
C *              *      |y
*            *       |
*          *_____   |
*        *√x²+y²   |
14.967  *      *          |
*   *            |
* *             |
*- - - - - - - *
A       x      O

In right triangle $AOB$, we have: . $x = AO,\:y = BO$
. . Hence: . $AB = \sqrt{x^2+y^2}$

From the Law of Cosines: . $\cos z \;=\;\frac{CB^2 + AB^2 - CA^2}{2\cdot CB\cdot AB}$

. . so we have: . $\cos z \;=\;\frac{14.776^2 + (\sqrt{x^2+y^2})^2 - 14.967^2}{2(14.776)(\sqrt{x^2+y^2})}$

Since $x = 4.848$

. . we have: . $\cos z \;=\;\frac{y^2 - 17.822191}{29.552\sqrt{y^2 + 23.503104}}$

5. Hm, doesn't seem to work for some reason.. maybe I'm doing it wrong.

Also, I realized that what I really need is angle CBO.. though I should be able to get that by adding CBA and ABO...

My distances were also inaccurate (I wanted to make sure all my information was correct so I checked again). AC is 14.9921 and CB is 14.8591.

However, even taking all this into account, I can tell that the answers I'm getting aren't even close.I don't know if it's maybe an order of operations issue, but I seem to be ending up with numbers less than 1, which isn't right.

---
You know what, I just realized that I am rustier than I even thought. When you say "cos z = ..." ... does that mean "the cosine of z = ..." or that "z as a cosine = ..." or just "z = ..." and is that answer in radians or degrees? :P
Sorry for asking stupid questions, but I really need to figure this out.

6. Originally Posted by Malkalypse
You know what, I just realized that I am rustier than I even thought. When you say "cos z = ..." ... does that mean "the cosine of z = ..." or that "z as a cosine = ..." or just "z = ..." and is that answer in radians or degrees? :P
Sorry for asking stupid questions, but I really need to figure this out.
it means the cosine of z

7. Okay, so how do I convert it to degrees?

Sorry if I seem like an idiot, but it really has been a long time since I have done anything like this. In the meantime, I'm trying to get a very stubborn program to use this information, and it would be a lot easier if I were sure that the the information I am putting in is correct :/

8. Originally Posted by Malkalypse
Okay, so how do I convert it to degrees?

Sorry if I seem like an idiot, but it really has been a long time since I have done anything like this. In the meantime, I'm trying to get a very stubborn program to use this information, and it would be a lot easier if I were sure that the the information I am putting in is correct :/
are you using a calculator? if so, just put it in degrees mode when doing the computations. if you're using some other program, well, i don't know. it depends on how the program works

9. Originally Posted by Malkalypse
Okay, so how do I convert it to degrees?
$\frac{180}{\pi} \cdot x$