How to determine if an object in space is pointing at (oriented toward) another object?

36 Views Asked by At

QUESTION: You know the position of two objects in space (one also has an orientation). How do you determine when the object is pointing/oriented at the other object?

Hopefully this question makes sense! Thank you!

1

There are 1 best solutions below

0
On

Let $P_1$ be the coordinates of the first object and $P_2$ be the coordinates of the second object. Let $v$ be the vector that represents the “orientation” of the first object.

If and only if a non-negative number $\alpha$ that fulfills $P_2=P_1+\alpha v$ exists, then object $P_1$ is pointing at object $P_2$.