DAS  3.1.6 - 18/09/2017
NRUTIL.C
Go to the documentation of this file.
1 #if defined(__STDC__) || defined(ANSI) || defined(NRANSI) /* ANSI */
2 #include <stddef.h>
3 #include <stdlib.h>
4 #include <stdio.h>
5 #include <malloc.h>
6 #include <math.h>
7 
8 #define NR_END 1
9 #define FREE_ARG char*
10 
11 void nrerror(char error_text[])
12 /* Numerical Recipes standard error handler */
13 {
14  fprintf(stderr,"Numerical Recipes run-time error...\n");
15  fprintf(stderr,"%s\n",error_text);
16  fprintf(stderr,"...now exiting to system...\n");
17  exit(1);
18 }
19 
20 float *vector(long nl, long nh)
21 /* allocate a float vector with subscript range v[nl..nh] */
22 {
23  float *v;
24 
25  v=(float *)malloc((size_t) ((nh-nl+1+NR_END)*sizeof(float)));
26  if (!v) nrerror("allocation failure in vector()");
27  return v-nl+NR_END;
28 }
29 
30 int *ivector(long nl, long nh)
31 /* allocate an int vector with subscript range v[nl..nh] */
32 {
33  int *v;
34 
35  v=(int *)malloc((size_t) ((nh-nl+1+NR_END)*sizeof(int)));
36  if (!v) nrerror("allocation failure in ivector()");
37  return v-nl+NR_END;
38 }
39 
40 unsigned char *cvector(long nl, long nh)
41 /* allocate an unsigned char vector with subscript range v[nl..nh] */
42 {
43  unsigned char *v;
44 
45  v=(unsigned char *)malloc((size_t) ((nh-nl+1+NR_END)*sizeof(unsigned char)));
46  if (!v) nrerror("allocation failure in cvector()");
47  return v-nl+NR_END;
48 }
49 
50 unsigned long *lvector(long nl, long nh)
51 /* allocate an unsigned long vector with subscript range v[nl..nh] */
52 {
53  unsigned long *v;
54 
55  v=(unsigned long *)malloc((size_t) ((nh-nl+1+NR_END)*sizeof(long)));
56  if (!v) nrerror("allocation failure in lvector()");
57  return v-nl+NR_END;
58 }
59 
60 double *dvector(long nl, long nh)
61 /* allocate a double vector with subscript range v[nl..nh] */
62 {
63  double *v;
64 
65  v=(double *)malloc((size_t) ((nh-nl+1+NR_END)*sizeof(double)));
66  if (!v) nrerror("allocation failure in dvector()");
67  return v-nl+NR_END;
68 }
69 
70 float **matrix(long nrl, long nrh, long ncl, long nch)
71 /* allocate a float matrix with subscript range m[nrl..nrh][ncl..nch] */
72 {
73  long i, nrow=nrh-nrl+1,ncol=nch-ncl+1;
74  float **m;
75 
76  /* allocate pointers to rows */
77  m=(float **) malloc((size_t)((nrow+NR_END)*sizeof(float*)));
78  if (!m) nrerror("allocation failure 1 in matrix()");
79  m += NR_END;
80  m -= nrl;
81 
82  /* allocate rows and set pointers to them */
83  m[nrl]=(float *) malloc((size_t)((nrow*ncol+NR_END)*sizeof(float)));
84  if (!m[nrl]) nrerror("allocation failure 2 in matrix()");
85  m[nrl] += NR_END;
86  m[nrl] -= ncl;
87 
88  for(i=nrl+1;i<=nrh;i++) m[i]=m[i-1]+ncol;
89 
90  /* return pointer to array of pointers to rows */
91  return m;
92 }
93 
94 double **dmatrix(long nrl, long nrh, long ncl, long nch)
95 /* allocate a double matrix with subscript range m[nrl..nrh][ncl..nch] */
96 {
97  long i, nrow=nrh-nrl+1,ncol=nch-ncl+1;
98  double **m;
99 
100  /* allocate pointers to rows */
101  m=(double **) malloc((size_t)((nrow+NR_END)*sizeof(double*)));
102  if (!m) nrerror("allocation failure 1 in matrix()");
103  m += NR_END;
104  m -= nrl;
105 
106  /* allocate rows and set pointers to them */
107  m[nrl]=(double *) malloc((size_t)((nrow*ncol+NR_END)*sizeof(double)));
108  if (!m[nrl]) nrerror("allocation failure 2 in matrix()");
109  m[nrl] += NR_END;
110  m[nrl] -= ncl;
111 
112  for(i=nrl+1;i<=nrh;i++) m[i]=m[i-1]+ncol;
113 
114  /* return pointer to array of pointers to rows */
115  return m;
116 }
117 
118 int **imatrix(long nrl, long nrh, long ncl, long nch)
119 /* allocate a int matrix with subscript range m[nrl..nrh][ncl..nch] */
120 {
121  long i, nrow=nrh-nrl+1,ncol=nch-ncl+1;
122  int **m;
123 
124  /* allocate pointers to rows */
125  m=(int **) malloc((size_t)((nrow+NR_END)*sizeof(int*)));
126  if (!m) nrerror("allocation failure 1 in matrix()");
127  m += NR_END;
128  m -= nrl;
129 
130 
131  /* allocate rows and set pointers to them */
132  m[nrl]=(int *) malloc((size_t)((nrow*ncol+NR_END)*sizeof(int)));
133  if (!m[nrl]) nrerror("allocation failure 2 in matrix()");
134  m[nrl] += NR_END;
135  m[nrl] -= ncl;
136 
137  for(i=nrl+1;i<=nrh;i++) m[i]=m[i-1]+ncol;
138 
139  /* return pointer to array of pointers to rows */
140  return m;
141 }
142 
143 float **submatrix(float **a, long oldrl, long oldrh, long oldcl, long oldch,
144  long newrl, long newcl)
145 /* point a submatrix [newrl..][newcl..] to a[oldrl..oldrh][oldcl..oldch] */
146 {
147  long i,j,nrow=oldrh-oldrl+1,ncol=oldcl-newcl;
148  float **m;
149 
150  /* allocate array of pointers to rows */
151  m=(float **) malloc((size_t) ((nrow+NR_END)*sizeof(float*)));
152  if (!m) nrerror("allocation failure in submatrix()");
153  m += NR_END;
154  m -= newrl;
155 
156  /* set pointers to rows */
157  for(i=oldrl,j=newrl;i<=oldrh;i++,j++) m[j]=a[i]+ncol;
158 
159  /* return pointer to array of pointers to rows */
160  return m;
161 }
162 
163 float **convert_matrix(float *a, long nrl, long nrh, long ncl, long nch)
164 /* allocate a float matrix m[nrl..nrh][ncl..nch] that points to the matrix
165 declared in the standard C manner as a[nrow][ncol], where nrow=nrh-nrl+1
166 and ncol=nch-ncl+1. The routine should be called with the address
167 &a[0][0] as the first argument. */
168 {
169  long i,j,nrow=nrh-nrl+1,ncol=nch-ncl+1;
170  float **m;
171 
172  /* allocate pointers to rows */
173  m=(float **) malloc((size_t) ((nrow+NR_END)*sizeof(float*)));
174  if (!m) nrerror("allocation failure in convert_matrix()");
175  m += NR_END;
176  m -= nrl;
177 
178  /* set pointers to rows */
179  m[nrl]=a-ncl;
180  for(i=1,j=nrl+1;i<nrow;i++,j++) m[j]=m[j-1]+ncol;
181  /* return pointer to array of pointers to rows */
182  return m;
183 }
184 
185 float ***f3tensor(long nrl, long nrh, long ncl, long nch, long ndl, long ndh)
186 /* allocate a float 3tensor with range t[nrl..nrh][ncl..nch][ndl..ndh] */
187 {
188  long i,j,nrow=nrh-nrl+1,ncol=nch-ncl+1,ndep=ndh-ndl+1;
189  float ***t;
190 
191  /* allocate pointers to pointers to rows */
192  t=(float ***) malloc((size_t)((nrow+NR_END)*sizeof(float**)));
193  if (!t) nrerror("allocation failure 1 in f3tensor()");
194  t += NR_END;
195  t -= nrl;
196 
197  /* allocate pointers to rows and set pointers to them */
198  t[nrl]=(float **) malloc((size_t)((nrow*ncol+NR_END)*sizeof(float*)));
199  if (!t[nrl]) nrerror("allocation failure 2 in f3tensor()");
200  t[nrl] += NR_END;
201  t[nrl] -= ncl;
202 
203  /* allocate rows and set pointers to them */
204  t[nrl][ncl]=(float *) malloc((size_t)((nrow*ncol*ndep+NR_END)*sizeof(float)));
205  if (!t[nrl][ncl]) nrerror("allocation failure 3 in f3tensor()");
206  t[nrl][ncl] += NR_END;
207  t[nrl][ncl] -= ndl;
208 
209  for(j=ncl+1;j<=nch;j++) t[nrl][j]=t[nrl][j-1]+ndep;
210  for(i=nrl+1;i<=nrh;i++) {
211  t[i]=t[i-1]+ncol;
212  t[i][ncl]=t[i-1][ncl]+ncol*ndep;
213  for(j=ncl+1;j<=nch;j++) t[i][j]=t[i][j-1]+ndep;
214  }
215 
216  /* return pointer to array of pointers to rows */
217  return t;
218 }
219 
220 void free_vector(float *v, long nl, long nh)
221 /* free a float vector allocated with vector() */
222 {
223  free((FREE_ARG) (v+nl-NR_END));
224 }
225 
226 void free_ivector(int *v, long nl, long nh)
227 /* free an int vector allocated with ivector() */
228 {
229  free((FREE_ARG) (v+nl-NR_END));
230 }
231 
232 void free_cvector(unsigned char *v, long nl, long nh)
233 /* free an unsigned char vector allocated with cvector() */
234 {
235  free((FREE_ARG) (v+nl-NR_END));
236 }
237 
238 void free_lvector(unsigned long *v, long nl, long nh)
239 /* free an unsigned long vector allocated with lvector() */
240 {
241  free((FREE_ARG) (v+nl-NR_END));
242 }
243 
244 void free_dvector(double *v, long nl, long nh)
245 /* free a double vector allocated with dvector() */
246 {
247  free((FREE_ARG) (v+nl-NR_END));
248 }
249 
250 void free_matrix(float **m, long nrl, long nrh, long ncl, long nch)
251 /* free a float matrix allocated by matrix() */
252 {
253  free((FREE_ARG) (m[nrl]+ncl-NR_END));
254  free((FREE_ARG) (m+nrl-NR_END));
255 }
256 
257 void free_dmatrix(double **m, long nrl, long nrh, long ncl, long nch)
258 /* free a double matrix allocated by dmatrix() */
259 {
260  free((FREE_ARG) (m[nrl]+ncl-NR_END));
261  free((FREE_ARG) (m+nrl-NR_END));
262 }
263 
264 void free_imatrix(int **m, long nrl, long nrh, long ncl, long nch)
265 /* free an int matrix allocated by imatrix() */
266 {
267  free((FREE_ARG) (m[nrl]+ncl-NR_END));
268  free((FREE_ARG) (m+nrl-NR_END));
269 }
270 
271 void free_submatrix(float **b, long nrl, long nrh, long ncl, long nch)
272 /* free a submatrix allocated by submatrix() */
273 {
274  free((FREE_ARG) (b+nrl-NR_END));
275 }
276 
277 void free_convert_matrix(float **b, long nrl, long nrh, long ncl, long nch)
278 /* free a matrix allocated by convert_matrix() */
279 {
280  free((FREE_ARG) (b+nrl-NR_END));
281 }
282 
283 void free_f3tensor(float ***t, long nrl, long nrh, long ncl, long nch,
284  long ndl, long ndh)
285 /* free a float f3tensor allocated by f3tensor() */
286 {
287  free((FREE_ARG) (t[nrl][ncl]+ndl-NR_END));
288  free((FREE_ARG) (t[nrl]+ncl-NR_END));
289  free((FREE_ARG) (t+nrl-NR_END));
290 }
291 
292 #else /* ANSI */
293 /* traditional - K&R */
294 
295 #include <stdio.h>
296 #include <stddef.h>
297 #include <stdlib.h>
298 #include <stdio.h>
299 #include <malloc.h>
300 #include <math.h>
301 
302 #define NR_END 1
303 #define FREE_ARG char*
304 
305 void nrerror(error_text)
306 char error_text[];
307 /* Numerical Recipes standard error handler */
308 {
309  void exit();
310 
311  fprintf(stderr,"Numerical Recipes run-time error...\n");
312  fprintf(stderr,"%s\n",error_text);
313  fprintf(stderr,"...now exiting to system...\n");
314  exit(1);
315 }
316 
317 float *vector(nl,nh)
318 long nh,nl;
319 /* allocate a float vector with subscript range v[nl..nh] */
320 {
321  float *v;
322 
323  v=(float *)malloc((unsigned int) ((nh-nl+1+NR_END)*sizeof(float)));
324  if (!v) nrerror("allocation failure in vector()");
325  return v-nl+NR_END;
326 }
327 
328 int *ivector(nl,nh)
329 long nh,nl;
330 /* allocate an int vector with subscript range v[nl..nh] */
331 {
332  int *v;
333 
334  v=(int *)malloc((unsigned int) ((nh-nl+1+NR_END)*sizeof(int)));
335  if (!v) nrerror("allocation failure in ivector()");
336  return v-nl+NR_END;
337 }
338 
339 unsigned char *cvector(nl,nh)
340 long nh,nl;
341 /* allocate an unsigned char vector with subscript range v[nl..nh] */
342 {
343  unsigned char *v;
344 
345  v=(unsigned char *)malloc((unsigned int) ((nh-nl+1+NR_END)*sizeof(unsigned char)));
346  if (!v) nrerror("allocation failure in cvector()");
347  return v-nl+NR_END;
348 }
349 
350 unsigned long *lvector(nl,nh)
351 long nh,nl;
352 /* allocate an unsigned long vector with subscript range v[nl..nh] */
353 {
354  unsigned long *v;
355 
356  v=(unsigned long *)malloc((unsigned int) ((nh-nl+1+NR_END)*sizeof(long)));
357  if (!v) nrerror("allocation failure in lvector()");
358  return v-nl+NR_END;
359 }
360 
361 double *dvector(nl,nh)
362 long nh,nl;
363 /* allocate a double vector with subscript range v[nl..nh] */
364 {
365  double *v;
366 
367  v=(double *)malloc((unsigned int) ((nh-nl+1+NR_END)*sizeof(double)));
368  if (!v) nrerror("allocation failure in dvector()");
369  return v-nl+NR_END;
370 }
371 
372 float **matrix(nrl,nrh,ncl,nch)
373 long nch,ncl,nrh,nrl;
374 /* allocate a float matrix with subscript range m[nrl..nrh][ncl..nch] */
375 {
376  long i, nrow=nrh-nrl+1,ncol=nch-ncl+1;
377  float **m;
378 
379  /* allocate pointers to rows */
380  m=(float **) malloc((unsigned int)((nrow+NR_END)*sizeof(float*)));
381  if (!m) nrerror("allocation failure 1 in matrix()");
382  m += NR_END;
383  m -= nrl;
384 
385  /* allocate rows and set pointers to them */
386  m[nrl]=(float *) malloc((unsigned int)((nrow*ncol+NR_END)*sizeof(float)));
387  if (!m[nrl]) nrerror("allocation failure 2 in matrix()");
388  m[nrl] += NR_END;
389  m[nrl] -= ncl;
390 
391  for(i=nrl+1;i<=nrh;i++) m[i]=m[i-1]+ncol;
392 
393  /* return pointer to array of pointers to rows */
394  return m;
395 }
396 
397 double **dmatrix(nrl,nrh,ncl,nch)
398 long nch,ncl,nrh,nrl;
399 /* allocate a double matrix with subscript range m[nrl..nrh][ncl..nch] */
400 {
401  long i, nrow=nrh-nrl+1,ncol=nch-ncl+1;
402  double **m;
403 
404  /* allocate pointers to rows */
405  m=(double **) malloc((unsigned int)((nrow+NR_END)*sizeof(double*)));
406  if (!m) nrerror("allocation failure 1 in matrix()");
407  m += NR_END;
408  m -= nrl;
409 
410  /* allocate rows and set pointers to them */
411  m[nrl]=(double *) malloc((unsigned int)((nrow*ncol+NR_END)*sizeof(double)));
412  if (!m[nrl]) nrerror("allocation failure 2 in matrix()");
413  m[nrl] += NR_END;
414  m[nrl] -= ncl;
415 
416  for(i=nrl+1;i<=nrh;i++) m[i]=m[i-1]+ncol;
417 
418  /* return pointer to array of pointers to rows */
419  return m;
420 }
421 
422 int **imatrix(nrl,nrh,ncl,nch)
423 long nch,ncl,nrh,nrl;
424 /* allocate a int matrix with subscript range m[nrl..nrh][ncl..nch] */
425 {
426  long i, nrow=nrh-nrl+1,ncol=nch-ncl+1;
427  int **m;
428 
429  /* allocate pointers to rows */
430  m=(int **) malloc((unsigned int)((nrow+NR_END)*sizeof(int*)));
431  if (!m) nrerror("allocation failure 1 in matrix()");
432  m += NR_END;
433  m -= nrl;
434 
435 
436  /* allocate rows and set pointers to them */
437  m[nrl]=(int *) malloc((unsigned int)((nrow*ncol+NR_END)*sizeof(int)));
438  if (!m[nrl]) nrerror("allocation failure 2 in matrix()");
439  m[nrl] += NR_END;
440  m[nrl] -= ncl;
441 
442  for(i=nrl+1;i<=nrh;i++) m[i]=m[i-1]+ncol;
443 
444  /* return pointer to array of pointers to rows */
445  return m;
446 }
447 
448 float **submatrix(a,oldrl,oldrh,oldcl,oldch,newrl,newcl)
449 float **a;
450 long newcl,newrl,oldch,oldcl,oldrh,oldrl;
451 /* point a submatrix [newrl..][newcl..] to a[oldrl..oldrh][oldcl..oldch] */
452 {
453  long i,j,nrow=oldrh-oldrl+1,ncol=oldcl-newcl;
454  float **m;
455 
456  /* allocate array of pointers to rows */
457  m=(float **) malloc((unsigned int) ((nrow+NR_END)*sizeof(float*)));
458  if (!m) nrerror("allocation failure in submatrix()");
459  m += NR_END;
460  m -= newrl;
461 
462  /* set pointers to rows */
463  for(i=oldrl,j=newrl;i<=oldrh;i++,j++) m[j]=a[i]+ncol;
464 
465  /* return pointer to array of pointers to rows */
466  return m;
467 }
468 
469 float **convert_matrix(a,nrl,nrh,ncl,nch)
470 float *a;
471 long nch,ncl,nrh,nrl;
472 /* allocate a float matrix m[nrl..nrh][ncl..nch] that points to the matrix
473 declared in the standard C manner as a[nrow][ncol], where nrow=nrh-nrl+1
474 and ncol=nch-ncl+1. The routine should be called with the address
475 &a[0][0] as the first argument. */
476 {
477  long i,j,nrow=nrh-nrl+1,ncol=nch-ncl+1;
478  float **m;
479 
480  /* allocate pointers to rows */
481  m=(float **) malloc((unsigned int) ((nrow+NR_END)*sizeof(float*)));
482  if (!m) nrerror("allocation failure in convert_matrix()");
483  m += NR_END;
484  m -= nrl;
485 
486  /* set pointers to rows */
487  m[nrl]=a-ncl;
488  for(i=1,j=nrl+1;i<nrow;i++,j++) m[j]=m[j-1]+ncol;
489  /* return pointer to array of pointers to rows */
490  return m;
491 }
492 
493 float ***f3tensor(nrl,nrh,ncl,nch,ndl,ndh)
494 long nch,ncl,ndh,ndl,nrh,nrl;
495 /* allocate a float 3tensor with range t[nrl..nrh][ncl..nch][ndl..ndh] */
496 {
497  long i,j,nrow=nrh-nrl+1,ncol=nch-ncl+1,ndep=ndh-ndl+1;
498  float ***t;
499 
500  /* allocate pointers to pointers to rows */
501  t=(float ***) malloc((unsigned int)((nrow+NR_END)*sizeof(float**)));
502  if (!t) nrerror("allocation failure 1 in f3tensor()");
503  t += NR_END;
504  t -= nrl;
505 
506  /* allocate pointers to rows and set pointers to them */
507  t[nrl]=(float **) malloc((unsigned int)((nrow*ncol+NR_END)*sizeof(float*)));
508  if (!t[nrl]) nrerror("allocation failure 2 in f3tensor()");
509  t[nrl] += NR_END;
510  t[nrl] -= ncl;
511 
512  /* allocate rows and set pointers to them */
513  t[nrl][ncl]=(float *) malloc((unsigned int)((nrow*ncol*ndep+NR_END)*sizeof(float)));
514  if (!t[nrl][ncl]) nrerror("allocation failure 3 in f3tensor()");
515  t[nrl][ncl] += NR_END;
516  t[nrl][ncl] -= ndl;
517 
518  for(j=ncl+1;j<=nch;j++) t[nrl][j]=t[nrl][j-1]+ndep;
519  for(i=nrl+1;i<=nrh;i++) {
520  t[i]=t[i-1]+ncol;
521  t[i][ncl]=t[i-1][ncl]+ncol*ndep;
522  for(j=ncl+1;j<=nch;j++) t[i][j]=t[i][j-1]+ndep;
523  }
524 
525  /* return pointer to array of pointers to rows */
526  return t;
527 }
528 
529 void free_vector(v,nl,nh)
530 float *v;
531 long nh,nl;
532 /* free a float vector allocated with vector() */
533 {
534  free((FREE_ARG) (v+nl-NR_END));
535 }
536 
537 void free_ivector(v,nl,nh)
538 int *v;
539 long nh,nl;
540 /* free an int vector allocated with ivector() */
541 {
542  free((FREE_ARG) (v+nl-NR_END));
543 }
544 
545 void free_cvector(v,nl,nh)
546 long nh,nl;
547 unsigned char *v;
548 /* free an unsigned char vector allocated with cvector() */
549 {
550  free((FREE_ARG) (v+nl-NR_END));
551 }
552 
553 void free_lvector(v,nl,nh)
554 long nh,nl;
555 unsigned long *v;
556 /* free an unsigned long vector allocated with lvector() */
557 {
558  free((FREE_ARG) (v+nl-NR_END));
559 }
560 
561 void free_dvector(v,nl,nh)
562 double *v;
563 long nh,nl;
564 /* free a double vector allocated with dvector() */
565 {
566  free((FREE_ARG) (v+nl-NR_END));
567 }
568 
569 void free_matrix(m,nrl,nrh,ncl,nch)
570 float **m;
571 long nch,ncl,nrh,nrl;
572 /* free a float matrix allocated by matrix() */
573 {
574  free((FREE_ARG) (m[nrl]+ncl-NR_END));
575  free((FREE_ARG) (m+nrl-NR_END));
576 }
577 
578 void free_dmatrix(m,nrl,nrh,ncl,nch)
579 double **m;
580 long nch,ncl,nrh,nrl;
581 /* free a double matrix allocated by dmatrix() */
582 {
583  free((FREE_ARG) (m[nrl]+ncl-NR_END));
584  free((FREE_ARG) (m+nrl-NR_END));
585 }
586 
587 void free_imatrix(m,nrl,nrh,ncl,nch)
588 int **m;
589 long nch,ncl,nrh,nrl;
590 /* free an int matrix allocated by imatrix() */
591 {
592  free((FREE_ARG) (m[nrl]+ncl-NR_END));
593  free((FREE_ARG) (m+nrl-NR_END));
594 }
595 
596 void free_submatrix(b,nrl,nrh,ncl,nch)
597 float **b;
598 long nch,ncl,nrh,nrl;
599 /* free a submatrix allocated by submatrix() */
600 {
601  free((FREE_ARG) (b+nrl-NR_END));
602 }
603 
604 void free_convert_matrix(b,nrl,nrh,ncl,nch)
605 float **b;
606 long nch,ncl,nrh,nrl;
607 /* free a matrix allocated by convert_matrix() */
608 {
609  free((FREE_ARG) (b+nrl-NR_END));
610 }
611 
612 void free_f3tensor(t,nrl,nrh,ncl,nch,ndl,ndh)
613 float ***t;
614 long nch,ncl,ndh,ndl,nrh,nrl;
615 /* free a float f3tensor allocated by f3tensor() */
616 {
617  free((FREE_ARG) (t[nrl][ncl]+ndl-NR_END));
618  free((FREE_ARG) (t[nrl]+ncl-NR_END));
619  free((FREE_ARG) (t+nrl-NR_END));
620 }
621 
622 #endif /* ANSI */
void free_submatrix(float **b, long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:596
float *** f3tensor(long nrl, long nrh, long ncl, long nch, long ndl, long ndh)
Definition: NRUTIL.C:493
void free_imatrix(int **m, long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:587
int ** imatrix(long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:422
float ** submatrix(float **a, long oldrl, long oldrh, long oldcl, long oldch, long newrl, long newcl)
Definition: NRUTIL.C:448
void free_lvector(unsigned long *v, long nl, long nh)
Definition: NRUTIL.C:553
void free_ivector(int *v, long nl, long nh)
Definition: NRUTIL.C:537
unsigned long * lvector(long nl, long nh)
Definition: NRUTIL.C:350
double ** dmatrix(long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:397
float * vector(long nl, long nh)
Definition: NRUTIL.C:317
#define FREE_ARG
Definition: NRUTIL.C:303
void free_dvector(double *v, long nl, long nh)
Definition: NRUTIL.C:561
void nrerror(error_text)
Definition: NRUTIL.C:305
int * ivector(long nl, long nh)
Definition: NRUTIL.C:328
void free_matrix(float **m, long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:569
float ** matrix(long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:372
void free_vector(float *v, long nl, long nh)
Definition: NRUTIL.C:529
#define NR_END
Definition: NRUTIL.C:302
void free_convert_matrix(float **b, long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:604
void free_dmatrix(double **m, long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:578
void free_f3tensor(float ***t, long nrl, long nrh, long ncl, long nch, long ndl, long ndh)
Definition: NRUTIL.C:612
float ** convert_matrix(float *a, long nrl, long nrh, long ncl, long nch)
Definition: NRUTIL.C:469
double * dvector(long nl, long nh)
Definition: NRUTIL.C:361
unsigned char * cvector(long nl, long nh)
Definition: NRUTIL.C:339
void free_cvector(unsigned char *v, long nl, long nh)
Definition: NRUTIL.C:545
______________________________________________________________________________________
Generated on Mon Sep 18 2017 11:44:09 for DAS - Rel. 3.1.6 - 18/09/2017.