ERIS Pipeline Reference Manual 1.8.15
Data Structures | Macros | Typedefs | Enumerations | Functions
sc_basic.h File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <math.h>
#include <float.h>
#include <errno.h>
#include <unistd.h>
#include <assert.h>
#include <sys/dir.h>
#include <sys/stat.h>
#include <sys/wait.h>
#include <cpl.h>
#include <mpfit.h>

Go to the source code of this file.

Data Structures

struct  _scpar_
 

Macros

#define SC_MIN(a, b)   ((a) > (b) ? (b) : (a))
 
#define SC_MAX(a, b)   ((a) < (b) ? (b) : (a))
 
#define SC_LENLINE   160
 
#define SC_MAXLEN   1024
 
#define SC_TOL   1e-7
 
#define SC_MAXPAR   21
 
#define SC_THERMIRLIM   2.31
 
#define SC_DEFLAMCOL   "LAMBDA"
 
#define SC_DEFFLUXCOL   "FLUX"
 
#define SC_DEFDFLUXCOL   "DFLUX"
 
#define SC_DEFMASKCOL   "MASK"
 
#define SC_SINCRAD_PRECOMP   6.0
 
#define SC_SINCNBIN   10000
 
#define SC_SINCDAMP   3.25
 

Typedefs

typedef enum _sc_error_code_ sc_error_code
 
typedef struct _scpar_ scpar
 

Enumerations

enum  _sc_error_code_
 

Functions

cpl_error_code sc_basic_readline (FILE *stream, scpar par[], int *npar)
 
double sc_basic_mjd2fracyear (double mjd)
 
double sc_basic_fracyear2date (int *year, int *month, int *day, int *hh, int *mm, double *ss, const double *fracyear)
 
cpl_error_code sc_basic_rebin (cpl_table *outspec, const char *outlam, const char *outflux, const cpl_table *inspec, const char *inlam, const char *influx)
 
cpl_error_code sc_basic_convolve (cpl_table *spec, const char *colname, const cpl_array *kernel)
 
cpl_error_code sc_basic_convolvewindow (cpl_array *convflux, const cpl_array *flux, const int range[2], const cpl_array *kernel)
 
cpl_error_code sc_basic_filtermedian (cpl_table *spec, const char *colname, const int npix)
 
cpl_error_code sc_basic_linecount (long *n_lines, FILE *fp)
 
cpl_error_code sc_basic_rhum2ppmv_old (const cpl_array *temp, const cpl_array *pres, const cpl_array *rhum, cpl_array *ppmv)
 
void sc_basic_rhum2ppmv (double *ppmv, const double *tem, const double *p, const double *hum)
 
cpl_error_code sc_basic_planck (cpl_array *bb, const cpl_array *wavelength, const double temp)
 
void sc_basic_dirslash (char *dir)
 
void sc_basic_abspath (char *out, const char *dir, const char *cwd)
 
cpl_error_code sc_basic_access (const char *pathname, const int mode)
 
cpl_error_code sc_basic_greg2jd (long *jd, const int year, const int month, const int day)
 
cpl_error_code sc_basic_jd2greg (int *year, int *month, int *day, const long jd)
 
cpl_error_code sc_basic_clipmean (double *mean, double *rms, cpl_array *arr, const cpl_boolean clip)
 
cpl_error_code sc_basic_col2arr (cpl_array *arr, const cpl_table *tab, const char *colname)
 
cpl_error_code sc_basic_arr2col (cpl_table *tab, const char *colname, const cpl_array *arr)
 
cpl_error_code sc_basic_sortarr (cpl_array *arr, cpl_type type)
 
cpl_error_code sc_basic_copytable_content (cpl_table *outtab, const cpl_table *intab)
 
cpl_error_code sc_basic_copytable_full (cpl_table *outtab, const cpl_table *intab)
 
void sc_basic_initstring (char *str, const long n)
 
void sc_basic_terminatestring (char *str)
 
char * sc_basic_strtrim (char *str)
 
void sc_basic_strtrim_inplace (char *str)
 
cpl_boolean sc_basic_isnumber (char *str)
 
cpl_boolean sc_basic_isinteger (char *str)
 
cpl_error_code sc_basic_interpollin (const double *x_out, double *y_out, const long n_out, const double *x_ref, const double *y_ref, const long n_ref, const int extrapolate)
 
int sc_basic_gaussfunc (double *fgauss, const double *xgauss, const int n_data, const double *par)
 
cpl_error_code sc_basic_getfilename (char *dir, char *filename, char *suffix, const char *path)
 
cpl_error_code sc_basic_getmaskval_vector (double maskval[2], const cpl_vector *vector)
 
cpl_error_code sc_basic_getmaskval_image (double maskval[2], const cpl_image *image)
 
cpl_error_code sc_basic_calcsinc (cpl_vector *sinc)
 

Detailed Description

Basic header for sky correction code

Author
Stefan Noll & ESO In-Kind Team Innsbruck
Since
15 Feb 2011
Date
12 Jun 2014

Definition in file sc_basic.h.