Consider the fact that if P(x,y) is the unknown point, then when you apply rotation around that point, the point P1(x1, y1) goes to (gets mapped to) P2(x2,y2). From this you can construct equations and solve them to get the x and y. Just lookup the formulas for rotation in the 2D plane. The rotation angles are nice in both cases: 90 and 60 degrees. If you do this, you should get the answers you have posted here. Say you rotate the point (x1,y1) around the point (a,b) on an angle of $\theta$. Then the point (x1,y1) gets mapped to (x2, y2) where: $x_2 = (x_1-a) * cos(\theta) - (y_1-b) * sin(\theta) + a$ $y_2 = (x_1-a) * sin(\theta) + (y_1-b) * cos(\theta) + b$ In your case you don't know the $a$ and $b$, you want to find them. The $\theta$ is $\pm \pi/2$ and $\pm \pi/3$ respectively. The $x_1, y_1, x_2, y_2$ - these you know. Here is how one can solve the case: $\pi/3$. You have 3 more cases to solve. See also: Rotation An equilateral triangle has vertices (3,4) and (-2,3). Find the third vertex. Concept: Let A (x1, y1) and B (x2, y2)
Given: Two vertices of an equilateral triangle are (0, 0) and (3, √3). Let the third vertex of the equilateral triangle be (x, y) Distance between (0, 0) and (x, y) = Distance between (0, 0) and (3, √3) = Distance between (x, y) and (3, √3) \(\sqrt {{{\left( {x - 0} \right)}^2} + \;{{\left( {y - 0} \right)}^2}} = \;\sqrt {{{\left( {3 - 0} \right)}^2} + \;{{\left( {\sqrt 3 - 0} \right)}^2}} = \;\sqrt {{{\left( {x - 3} \right)}^2} + \;{{\left( {y - \sqrt 3 } \right)}^2}} \) \(\Rightarrow \sqrt {{x^2} + \;{y^2}} = \;\sqrt {12} = \;\sqrt {{{\left( {x - 3} \right)}^2} + \;{{\left( {y - \sqrt 3 } \right)}^2}} \) Squaring both sides, we get ⇒ x2 + y2 = 12 = (x – 3)2 + (y - √3)2 Now, x2 + y2 = 12 …. (1) x2 + 9 - 6x + y2 + 3 - 2√3y = 12 …. (2) Solving equations 1 and 2, x2 + 9 - 6x + y2 + 3 - 2√3y = x2 + y2 ⇒ - 6x - 2√3y + 12 = 0 ⇒ 3x + √3y = 6 ⇒ x = (6 - √3y) / 3 Now, substituting the value of x in equation 1, we get \(\Rightarrow \;{\left( {\frac{{6 - \sqrt 3 y}}{3}} \right)^2} + \;{y^2} = 12\) \(\Rightarrow \frac{{36 + 3{y^2} - 12\sqrt 3 y}}{9} + \;{y^2} = 12\) ⇒ 36 + 3y2 - 12√3y + 9y2 = 108 ⇒ - 12√3y + 12y2 - 72 = 0 ⇒ y2 - √3y - 6 = 0 ⇒ (y - 2√3) (y + √3) = 0 ⇒ y = 2√3 or - √3 If y = 2√3, x = (6 - 6) / 3 = 0 If y = -√3, x = (6 + 3) / 3 = 3 So, the third vertex of the equilateral triangle = (0, 2√3) or (3, -√3). |