Hull - Convex hull type


#include "h/h_hull.h"

Example compile flags (system dependent):
   -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 

typedef struct Hull
	int dimension;
	int num_vertices;
	int num_facets;
	Matrix *vertex_mp;
	Matrix *normal_mp;
	Vector *b_value_vp;
	Matrix_vector *facets;
	Vector *facet_angles_vp;
	char *geom_view_geometry;
	int filled_resolution;
	double min_x;
	double min_y;
	double min_z;
	double max_x;
	double max_y;
	double max_z;
	double filled_scale_x;
	double filled_scale_y;
	double filled_scale_z;
	unsigned char **filled_2D_array;
	unsigned char ***filled_3D_array;


This type is the convex hull type for the KJB library. Most fields are self explanatory. The rows of the matri *vertex_mp contain the vertice vectors. Similarly, the normal vectors are the rows of the matrix *normal_mp. The values *b_value_vp derived values. For each facet, they are the dot products of the points on the facet with the normal. This dot product should be the same for each facet point -- the routine find_convex_hull computes the average of the values for each facet for improved accuracy. Each facet of the hull is a space constraint expressed as X.N <= b, where b is the value in the corresponding row of *b_value_vp. Each facet is a set of points forming the rows of a matrix in the matrix array facets. Finally, if the geovmiew geometry is used, it is stored in the string geom_view_geometry. This field is rarely used, as the geomview program did not turn out to be that useful (we don't currently have a version on any comonly used platform, as none were available when I was interested, perhaps one is now)


This software is not adequatedly tested. It is recomended that results are checked independantly where appropriate.


Kobus Barnard


Kobus Barnard