# Find a point given two other points and an angle

I have the 3D coordinates for three points $A, B, C$. I can find the angle formed between the vectors $\vec {AB}$ and $\vec {BC}$ by using a dot product.

However, I want to move point $B$ to $B^{\prime}$ such that the new vectors $\vec {AB^{\prime}}$ and $\vec {B^{\prime}C}$ form an angle $\theta$. $B^{\prime}$ is constrained to lie in the same plane as $A, B, C$. In addition, the distance between $B^{\prime}$ and $C$ must remain the same as the distance between $B$ and $C$.

Is there a way for me to compute $B^{\prime}$ given $\theta$?

• Not completely. Except for $\theta = 0, \pi$, there is an entire circle of points $B'$ that satisfy your conditions. Are there any other constraints? If $B'$ is constrained to lie in the same plane as $A, B, C$, then there are exactly two solutions for each $\theta \ne 0, \pi$. – Paul Sinclair Oct 4 '15 at 3:04
• $B^{\prime}$ is constrained to lie in the same plane as $A, B, C$. – Bobby Oct 4 '15 at 3:19

Let $\vec n = \vec{BA} \times \vec{BC}$. Let $b = \|\vec{CB}\|$, and let $\vec a = \vec{CA}$. $\vec n$ is normal to the plane of $A, B, C$.

We want to define a vector $\vec v$ such that $B' = C + b\vec v$. Your first constraint requires $\|\vec v\| = 1$. The coplanar constraint requires $\vec n \cdot \vec v = 0$, and finally the angle condition requires $$(A - (C + b\vec v))\cdot(-b\vec v) = \|A -(C + b\vec v)\|b\cos \theta$$ That is: $$(\vec a - b\vec v)\cdot(-b\vec v) = \|\vec a - b\vec v\|b\cos\theta$$.

This gives you three equations in the three unknown coordinates of $v$. Solve them to find the two possible values of $\vec v$, then calculate $B' = C + b\vec v$.