MALOC 0.1

vpred.h
Go to the documentation of this file.
1
30#ifndef _VPRED_H_
31#define _VPRED_H_
32
33#include <maloc/maloc_base.h>
34
35/* random() prototype seems to be missing in <stdlib.h> */
36/*
37 * if !defined(VOSF1)
38 * extern long int random(void);
39 * endif
40 */
41
42/* On some machines, the exact arithmetic routines might be defeated by the */
43/* use of internal extended precision floating-point registers. Sometimes */
44/* this problem can be fixed by defining certain values to be volatile, */
45/* thus forcing them to be stored to memory and rounded off. This isn't */
46/* a great solution, though, as it slows the arithmetic down. */
47/* */
48/* To try this out, write "#define INEXACT volatile" below. Normally, */
49/* however, INEXACT should be defined to be nothing. ("#define INEXACT".) */
50
52#define INEXACT /* Nothing */
53/* #define INEXACT volatile */
54
56#define REAL double
57
59#define REALPRINT doubleprint
60
63#define REALRAND doublerand
64
67#define NARROWRAND narrowdoublerand
68
70#define UNIFORMRAND uniformdoublerand
71
84 void Vpred_exactinit(void);
85
97 REAL Vpred_orient2d(REAL *pa, REAL *pb, REAL *pc);
98
110 REAL Vpred_orient2dfast(REAL *pa, REAL *pb, REAL *pc);
111
123 REAL Vpred_orient2dexact(REAL *pa, REAL *pb, REAL *pc);
124
139 REAL Vpred_orient3d(REAL *pa, REAL *pb, REAL *pc, REAL *pd);
140
155 REAL Vpred_orient3dfast(REAL *pa, REAL *pb, REAL *pc, REAL *pd);
156
171 REAL Vpred_orient3dexact(REAL *pa, REAL *pb, REAL *pc, REAL *pd);
172
185 REAL Vpred_incircle(REAL *pa, REAL *pb, REAL *pc, REAL *pd);
186
199 REAL Vpred_incirclefast(REAL *pa, REAL *pb, REAL *pc, REAL *pd);
200
213 REAL Vpred_incircleexact(REAL *pa, REAL *pb, REAL *pc, REAL *pd);
214
228 REAL Vpred_insphere(REAL *pa, REAL *pb, REAL *pc, REAL *pd, REAL *pe);
229
243 REAL Vpred_inspherefast(REAL *pa, REAL *pb, REAL *pc, REAL *pd, REAL *pe);
244
258 REAL Vpred_insphereexact(REAL *pa, REAL *pb, REAL *pc, REAL *pd, REAL *pe);
259
260#endif /* _VPRED_H_ */
261
maloc_base.h
The base (or foundation) header for MALOC.
Vpred_orient2d
REAL Vpred_orient2d(REAL *pa, REAL *pb, REAL *pc)
Adaptive exact 2D orientation test. Robust.
Vpred_orient3dfast
REAL Vpred_orient3dfast(REAL *pa, REAL *pb, REAL *pc, REAL *pd)
Approximate 3D orientation test. Nonrobust.
REAL
#define REAL
float or double
Definition vpred.h:56
Vpred_orient3dexact
REAL Vpred_orient3dexact(REAL *pa, REAL *pb, REAL *pc, REAL *pd)
Exact 3D orientation test. Robust.
Vpred_inspherefast
REAL Vpred_inspherefast(REAL *pa, REAL *pb, REAL *pc, REAL *pd, REAL *pe)
Approximate 3D insphere test. Nonrobust.
Vpred_orient3d
REAL Vpred_orient3d(REAL *pa, REAL *pb, REAL *pc, REAL *pd)
Adaptive exact 3D orientation test. Robust.
Vpred_insphereexact
REAL Vpred_insphereexact(REAL *pa, REAL *pb, REAL *pc, REAL *pd, REAL *pe)
Exact 3D insphere test. Robust.
Vpred_exactinit
void Vpred_exactinit(void)
Initialize the variables used for exact arithmetic.
Vpred_incircleexact
REAL Vpred_incircleexact(REAL *pa, REAL *pb, REAL *pc, REAL *pd)
Exact 2D incircle test. Robust.
Vpred_insphere
REAL Vpred_insphere(REAL *pa, REAL *pb, REAL *pc, REAL *pd, REAL *pe)
Adaptive exact 3D insphere test. Robust.
Vpred_orient2dfast
REAL Vpred_orient2dfast(REAL *pa, REAL *pb, REAL *pc)
Approximate 2D orientation test. Nonrobust.
Vpred_orient2dexact
REAL Vpred_orient2dexact(REAL *pa, REAL *pb, REAL *pc)
Exact 2D orientation test. Robust.
Vpred_incircle
REAL Vpred_incircle(REAL *pa, REAL *pb, REAL *pc, REAL *pd)
Adaptive exact 2D incircle test. Robust.
Vpred_incirclefast
REAL Vpred_incirclefast(REAL *pa, REAL *pb, REAL *pc, REAL *pd)
Approximate 2D incircle test. Nonrobust.