PostGIS  2.5.7dev-r@@SVN_REVISION@@
lwgeom_median.c File Reference
#include <assert.h>
#include <float.h>
#include "liblwgeom_internal.h"
#include "lwgeom_log.h"
Include dependency graph for lwgeom_median.c:

Go to the source code of this file.

Functions

static double calc_weighted_distances_3d (const POINT3D *curr, const POINT4D *points, uint32_t npoints, double *distances)
 
static uint32_t iterate_4d (POINT3D *curr, const POINT4D *points, const uint32_t npoints, const uint32_t max_iter, const double tol)
 
static POINT3D init_guess (const POINT4D *points, uint32_t npoints)
 
POINT4Dlwmpoint_extract_points_4d (const LWMPOINT *g, uint32_t *npoints, int *input_empty)
 
LWPOINTlwmpoint_median (const LWMPOINT *g, double tol, uint32_t max_iter, char fail_if_not_converged)
 
LWPOINTlwgeom_median (const LWGEOM *g, double tol, uint32_t max_iter, char fail_if_not_converged)