See section 12.13.6 for checking for collinearity in three-dimensional geometry.
The is_collinear command is a Boolean function which takes as argument a list or sequence of points.
is_collinear returns 1 if the points are collinear
and returns 0 otherwise.
Input:
Output:
Input:
Output: