Hi,
____________(1)______________________
I am using some "Numerical Recipes in C" routines in my C code.
(I am using ludcmp() & lubksb().)
These are used to find inverse of a matrix.
After compiling my c code, I get following warning messages.
I have not understood them at all.
What is the meaning of these and why did they pop up and how to remove them?
Code:
nrutil.h:11: warning: 'sqrarg' defined but not used
nrutil.h:14: warning: 'dsqrarg' defined but not used
nrutil.h:17: warning: 'dmaxarg1' defined but not used
nrutil.h:17: warning: 'dmaxarg2' defined but not used
nrutil.h:21: warning: 'dminarg1' defined but not used
nrutil.h:21: warning: 'dminarg2' defined but not used
nrutil.h:25: warning: 'maxarg1' defined but not used
nrutil.h:25: warning: 'maxarg2' defined but not used
nrutil.h:29: warning: 'minarg1' defined but not used
nrutil.h:29: warning: 'minarg2' defined but not used
nrutil.h:33: warning: 'lmaxarg1' defined but not used
nrutil.h:33: warning: 'lmaxarg2' defined but not used
nrutil.h:37: warning: 'lminarg1' defined but not used
nrutil.h:37: warning: 'lminarg2' defined but not used
nrutil.h:41: warning: 'imaxarg1' defined but not used
nrutil.h:41: warning: 'imaxarg2' defined but not used
nrutil.h:45: warning: 'iminarg1' defined but not used
nrutil.h:45: warning: 'iminarg2' defined but not used
nrutil.h is a header file which contains #define statements (besides other things) like:
Code:
static float sqrarg;
#define SQR(a) ((sqrarg=(a)) == 0.0 ? 0.0 : sqrarg*sqrarg)
static double dsqrarg;
#define DSQR(a) ((dsqrarg=(a)) == 0.0 ? 0.0 : dsqrarg*dsqrarg)
_________________________(2)_____________
Also, for the same code, I get these warning messages:
In function `main':
warning: assignment from incompatible pointer type
warning: passing arg 1 of `free_vector' from incompatible pointer type
This is fragment of my code corresponding to these 2 warning messages:
Code:
int *indx;
indx =vector(1,100);
....
....
free_vector(indx,1,100);
Any help will be appreciated.
(I am not expert in C. I am just implementing these functions as said in the book.)
Regards,
smp