NAME
intersect_hulls - Finds the intersection of convex hulls.
SYNOPSIS
#include "h/h_intersect.h"
Example compile flags (system dependent):
-DLINUX_X86_64 -DLINUX_X86_64_OPTERON -DGNU_COMPILER
-I/home/kobus/include
-L/home/kobus/misc/load/linux_x86_64_opteron -L/usr/lib/x86_64-linux-gnu
-lKJB -lfftw3 -lgsl -lgslcblas -ljpeg -lSVM -lstdc++ -lpthread -lSLATEC -lg2c -lacml -lacml_mv -lblas -lg2c -lncursesw
int intersect_hulls
(
Queue_element *hull_list_head,
unsigned long options,
Hull **result_hp_ptr
);
DESCRIPTION
This routine finds the intersection of a list of convex hulls and returns
the result as a convex hull.
The first argument "hull_list_head" is the address of the queue containing
the list of convex hulls to process. Only lists of 2-D or 3-D hulls are
currently supported.
The second argument "options" contains the flags controlling the data
returned in the output hull structure. For most circumstances, the value of
DEFAULT_HULL_OPTIONS will suffice. See the man page for "find_convex_hull"
for a description of the option flags.
The method of hull intersection is under user control via the option
hull-intersection-method. One method "a" is a discrete approximationl. A
faster, more accurate method is the dual space method "d". In the case of the
discrete approximation, the resolution of the descrete space is user settable
with the "hir" option, provided that the KJB library options are made
available to the user (recommended!). The dual space method also makes use of
the resolution when finding an intial point inside the hull. The dual space
method normally returns an answer independent of the resolution, but the
resolution does set the smallest amount that hulls can intersect, and still
be recognized as intersecting (with all methods).
RETURNS
NO_ERROR on success, with the address of the result in "result_hp_ptr",
NO_SOLUTION if the intersection in empty, and ERROR if there are more
serious problems.
RELATED
create_hull, find_convex_hull, Hull, Queue_element
DISCLAIMER
This software is not adequatedly tested. It is recomended that
results are checked independantly where appropriate.
AUTHOR
Kobus Barnard
DOCUMENTER
Lindsay Martin and Kobus Barnard
SEE ALSO
intersect_positive_hulls