provide algorithm to determine whether a point is inside the polyhedron
Will be used in BornAgain, bornagain#353.
There exist well known, simple and elegant algorithms.
For reference, the 2D case:
The 3D case:
- Simply shooting rays, https://www.codefull.net/2016/03/cgal-point-in-polyhedron-algorithm
- Lane et al 1984, https://www.sciencedirect.com/science/article/abs/pii/0734189X84901336
- Said & Parker 1996, https://www.geog.leeds.ac.uk/groups/geocomp/1996/abs081.htm
Using oriented solid angle:
Edited by Wuttke, Joachim