diff options
Diffstat (limited to 'linear.c')
-rw-r--r-- | linear.c | 40 |
1 files changed, 40 insertions, 0 deletions
@@ -18,6 +18,46 @@ ** matrix). */ +/* +** DEFINES +*/ + +#define LUARRAYROWS 101L +#define LUARRAYCOLS 101L + +/* +** TYPEDEFS +*/ +typedef struct +{ union + { double *p; + double (*ap)[][LUARRAYCOLS]; + } ptrs; +} LUdblptr; + +/* +** GLOBALS +*/ +double *LUtempvv; + +/* +** PROTOTYPES +*/ +static void LUFreeMem(double *a, double *b, + double *abase, double *bbase); +static unsigned long DoLUIteration(double *a, double *b, + double *abase, double *bbase, + unsigned long numarrays); +static void build_problem( double a[][LUARRAYCOLS], + int n, double b[LUARRAYROWS]); +static int ludcmp(double a[][LUARRAYCOLS], + int n, int indx[], int *d); +static void lubksb(double a[][LUARRAYCOLS], + int n, int indx[LUARRAYROWS], + double b[LUARRAYROWS]); +static int lusolve(double a[][LUARRAYCOLS], + int n, double b[LUARRAYROWS]); + /********* ** DoLU ** ********** |