34#include <grass/interpf.h>
43 static double *A =
NULL;
101 for (k = 1; k <= n_points; k++) {
110 for (k = 1; k <= n_points; k++) {
114 if (params->
rsm < 0.) {
115 A[
i1] = -points[k - 1].
sm;
124 for (
l =
k2;
l <= n_points;
l++) {
125 xx = points[k - 1].
x - points[
l - 1].
x;
126 yy = points[k - 1].
y - points[
l - 1].
y;
145 k - 1, points[k - 1].
x,
l - 1, points[
l - 1].
x, k - 1,
146 points[k - 1].y,
l - 1, points[
l - 1].y);
156 for (k = 1; k <= n1; k++) {
159 for (
l =
k2;
l <= n1;
l++) {
160 m = (
l - 1) * n1 + k;
166 for (i = 0; i <= n_points; i++) {
167 for (
j = 0;
j <= n_points;
j++) {
173 G_debug(3,
"calling G_ludcmp() n=%d indx=%d", n_points, *
indx);
176 fprintf(
stderr,
"G_ludcmp() failed! n=%d d=%.2f\n", n_points, d);
int G_debug(int, const char *,...) __attribute__((format(printf
int G_ludcmp(double **, int, int *, double *)
LU decomposition.
double * G_alloc_vector(size_t)
Vector matrix memory allocation.
double amax1(double, double)
int IL_matrix_create_alloc(struct interp_params *params, struct triple *points, int n_points, double **matrix, int *indx, double *A)
Creates system of linear equations from interpolated points.
int IL_matrix_create(struct interp_params *params, struct triple *points, int n_points, double **matrix, int *indx)