ocssw V2020
nrutil.h
Go to the documentation of this file.
1 #ifndef _NR_UTILS_H_
2 #define _NR_UTILS_H_
3 
4 #define SQR(a) ((sqrarg=(a)) == 0.0 ? 0.0 : sqrarg*sqrarg)
5 
6 #define DSQR(a) ((dsqrarg=(a)) == 0.0 ? 0.0 : dsqrarg*dsqrarg)
7 
8 #define DMAX(a,b) ((dmaxarg1=(a),dmaxarg2=(b), (dmaxarg1) > (dmaxarg2) ?\
9 (dmaxarg1) : (dmaxarg2))
10 
11 #define DMIN(a,b) ((dminarg1=(a),dminarg2=(b), (dminarg1) < (dminarg2) ?\
12 (dminarg1) : (dminarg2))
13 
14 #define FMAX(a,b) ((maxarg1=(a),maxarg2=(b), (maxarg1) > (maxarg2) ?\
15 (maxarg1) : (maxarg2))
16 
17 #define FMIN(a,b) ((minarg1=(a),minarg2=(b), (minarg1) < (minarg2) ?\
18 (minarg1) : (minarg2))
19 
20 #define LMAX(a,b) ((lmaxarg1=(a),lmaxarg2=(b), (lmaxarg1) > (lmaxarg2) ?\
21 (lmaxarg1) : (lmaxarg2))
22 
23 #define LMIN(a,b) ((lminarg1=(a),lminarg2=(b), (lminarg1) < (lminarg2) ?\
24 (lminarg1) : (lminarg2))
25 
26 #define IMAX(a,b) ((imaxarg1=(a),imaxarg2=(b), (imaxarg1) > (imaxarg2) ?\
27 (imaxarg1) : (imaxarg2))
28 
29 #define IMIN(a,b) ((iminarg1=(a),iminarg2=(b), (iminarg1) < (iminarg2) ?\
30 (iminarg1) : (iminarg2))
31 
32 #define SIGN(a,b) ((b) > 0.0 ? fabs(a) : -fabs(a))
33 
34 #if defined (__STDC__) || defined(ANSI) || defined(NRANSI)
35 
36 void nrerror(char error_text[]);
37 float *vector(long nl, long nh);
38 int *ivector(long nl, long nh);
39 unsigned char *cvector(long nl, long nh);
40 unsigned long *lvector(long nl, long nh);
41 double *dvector(long nl, long nh);
42 float **matrix(long nrl, long nrh, long ncl, long nch);
43 double **dmatrix(long nrl, long nrh, long ncl, long nch);
44 int **imatrix(long nrl, long nrh, long ncl, long nch);
45 float **submatrix(float **a, long oldrl, long oldrh, long oldcl, long oldch,
46  long newrl, long newcl);
47 float **convert_matrix(float *a, long nrl, long nrh, long ncl, long nch);
48 float ***f3tensor(long nrl, long nrh, long ncl, long nch, long ndl, long ndh);
49 void free_vector(float *v, long nl, long nh);
50 void free_ivector(int *v, long nl, long nh);
51 void free_cvector(unsigned char *v, long nl, long nh);
52 void free_lvector(unsigned long *v, long nl, long nh);
53 void free_dvector(double *v, long nl, long nh);
54 void free_matrix(float **m, long nrl, long nrh, long ncl, long nch);
55 void free_dmatrix(double **m, long nrl, long nrh, long ncl, long nch);
56 void free_imatrix(int **m, long nrl, long nrh, long ncl, long nch);
57 void free_submatrix(float **b, long nrl, long nrh, long ncl, long nch);
58 void free_convert_matrix(float **b, long nrl, long nrh, long ncl, long nch);
59 void free_f3tensor(float ***t, long nrl, long nrh, long ncl, long nch,
60  long ndl, long ndh);
61 
62 #else
63 
64 void nrerror();
65 float *vector();
66 int *ivector();
67 unsigned char *cvector();
68 unsigned long *lvector();
69 double *dvector();
70 float **matrix();
71 double **dmatrix();
72 int **imatrix();
73 float **submatrix();
74 float **convert_matrix();
75 float ***f3tensor();
76 void free_vector();
77 void free_ivector();
78 void free_cvector();
79 void free_lvector();
80 void free_dvector();
81 void free_matrix();
82 void free_dmatrix();
83 void free_imatrix();
84 void free_submatrix();
85 void free_convert_matrix();
86 void free_f3tensor();
87 
88 #endif
89 
90 #endif
91 
int ** imatrix()
data_t t[NROOTS+1]
Definition: decode_rs.h:77
unsigned char * cvector()
void free_ivector()
float ** matrix()
void free_imatrix()
void free_cvector()
float m
Definition: mie_kernal.py:30
int32_t nl
Definition: atrem_corl1.h:132
void free_dmatrix()
float *** f3tensor()
void free_vector()
unsigned long * lvector()
void nrerror()
void free_f3tensor()
int * ivector()
double * dvector()
float ** submatrix()
data_t b[NROOTS+1]
Definition: decode_rs.h:77
float * vector()
double ** dmatrix()
void free_matrix()
void free_dvector()
void free_submatrix()
float ** convert_matrix()
void free_lvector()
void free_convert_matrix()
PGE01 indicating that PGE02 PGE01 V6 for and PGE01 V2 for MOD03 were used to produce the granule By convention adopted in all MODIS Terra PGE02 code versions are The fourth digit of the PGE02 version denotes the LUT version used to produce the granule The source of the metadata environment variable ProcessingCenter was changed from a QA LUT value to the Process Configuration A sign used in error in the second order term was changed to a
Definition: HISTORY.txt:424