I'm trying to solve a larger problem but first I decided to check I understood the basics, so I created a simple problem, as a launching point.
Unfortunately I can get the simple problem to work.
Let's start with a simple equilateral triangle with points A (0,0), B(100,0) and C (50,86.6).
The gradient of AB is 0, the gradient of BC is -1.732051, and the gradient of CA is 1.732051.
Now I know the formula for the angle between 2 lines is
When I plug in the numbers I should, given it's an equilateral triangle, get each angle being 60 degrees.
However, for the apex of the triangle (angle BCA) I must be doing something wrong as I don't get the correct answer.
The maths I have is:
tanθ=(-1.73205-1.73205) / (1+173205⋅1⋅73205)
tanθ=-3.4641 / (1+3)
tanθ=-3.4641 / 4
tanθ=-0.8660
And hence θ = 40.8934 degrees.
This is clearly wrong but I can't see where I've made my mistake.
Can anyone help and point out where I went wrong?
Thanks in appreciation.
Unfortunately I can get the simple problem to work.
Let's start with a simple equilateral triangle with points A (0,0), B(100,0) and C (50,86.6).
The gradient of AB is 0, the gradient of BC is -1.732051, and the gradient of CA is 1.732051.
Now I know the formula for the angle between 2 lines is
When I plug in the numbers I should, given it's an equilateral triangle, get each angle being 60 degrees.
However, for the apex of the triangle (angle BCA) I must be doing something wrong as I don't get the correct answer.
The maths I have is:
tanθ=(-1.73205-1.73205) / (1+173205⋅1⋅73205)
tanθ=-3.4641 / (1+3)
tanθ=-3.4641 / 4
tanθ=-0.8660
And hence θ = 40.8934 degrees.
This is clearly wrong but I can't see where I've made my mistake.
Can anyone help and point out where I went wrong?
Thanks in appreciation.