31#include <grass/interpf.h>
40 static double *A =
NULL;
98 for (k = 1; k <= n_points; k++) {
107 for (k = 1; k <= n_points; k++) {
111 if (params->
rsm < 0.) {
112 A[
i1] = -points[k - 1].
sm;
121 for (
l =
k2;
l <= n_points;
l++) {
122 xx = points[k - 1].
x - points[
l - 1].
x;
123 yy = points[k - 1].
y - points[
l - 1].
y;
142 k - 1, points[k - 1].
x,
l - 1, points[
l - 1].
x, k - 1,
143 points[k - 1].y,
l - 1, points[
l - 1].y);
153 for (k = 1; k <= n1; k++) {
156 for (
l =
k2;
l <= n1;
l++) {
157 m = (
l - 1) * n1 + k;
163 for (i = 0; i <= n_points; i++) {
164 for (
j = 0;
j <= n_points;
j++) {
170 G_debug(3,
"calling G_ludcmp() n=%d indx=%d", n_points, *
indx);
173 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)