In this con figuration as follows, we have a nice formula:

$$cos(\varphi)=\frac{OF.OE+OB.OC}{OF.OB+OE.OC}$$

Is the formua known? and can we generalized for higher dimentions?

[![enter image description here][1]][1]


  [1]: https://i.sstatic.net/5la9npHO.png