X-shooter Pipeline Reference Manual 3.8.15
xsh_data_spectralformat.h
Go to the documentation of this file.
1/* *
2 * This file is part of the ESO X-shooter Pipeline *
3 * Copyright (C) 2006 European Southern Observatory *
4 * *
5 * This library is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 2 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program; if not, write to the Free Software *
17 * Foundation, 51 Franklin St, Fifth Floor, Boston, MA 02111-1307 USA *
18 * */
19
20/*
21 * $Author: rhaigron $
22 * $Date: 2010-04-07 16:33:39 $
23 * $Revision: 1.13 $
24 */
25#ifndef XSH_DATA_SPECTRALFORMAT_H
26#define XSH_DATA_SPECTRALFORMAT_H
27
28#include <cpl.h>
29#include <xsh_data_instrument.h>
30#include <xsh_data_order.h>
31#include <xsh_data_wavesol.h>
32#include <xsh_model_kernel.h>
33
34#define XSH_SPECTRALFORMAT_TABLE_NB_UVB_ROWS 11
35#define XSH_SPECTRALFORMAT_TABLE_NB_VIS_ROWS 14
36#define XSH_SPECTRALFORMAT_TABLE_NB_NIR_ROWS 16
37
38#define XSH_SPECTRALFORMAT_TABLE_COLNAME_ORDER "ORDER"
39#define XSH_SPECTRALFORMAT_TABLE_COLNAME_LAMP "LAMP"
40#define XSH_SPECTRALFORMAT_TABLE_COLNAME_WLMINFUL "WLMINFUL"
41#define XSH_SPECTRALFORMAT_TABLE_COLNAME_WLMIN "WLMIN"
42#define XSH_SPECTRALFORMAT_TABLE_COLNAME_WLMAX "WLMAX"
43#define XSH_SPECTRALFORMAT_TABLE_COLNAME_WLMAXFUL "WLMAXFUL"
44
45#define XSH_SPECTRALFORMAT_TABLE_COLNAME_DISP_MIN "DISP_MIN"
46#define XSH_SPECTRALFORMAT_TABLE_COLNAME_DISP_MAX "DISP_MAX"
47#define XSH_SPECTRALFORMAT_TABLE_COLNAME_FLSR "LFSR"
48#define XSH_SPECTRALFORMAT_TABLE_COLNAME_UFSR "UFSR"
49
50#define XSH_SPECTRALFORMAT_TABLE_COLNAME_XMIN "XMIN"
51#define XSH_SPECTRALFORMAT_TABLE_COLNAME_XMAX "XMAX"
52
53#define XSH_SPECTRALFORMAT_TABLE_COLNAME_YMIN "YMIN"
54#define XSH_SPECTRALFORMAT_TABLE_COLNAME_YMAX "YMAX"
55
56typedef struct{
58 char lamp[8];
59 double lambda_min_full, lambda_max_full;
60 double lambda_min, lambda_max;
61 double flsr, ufsr;
62 double xmin, xmax;
63 double ymin, ymax;
65
66typedef struct{
67 int size;
71 cpl_propertylist * header;
73
74
75/*****************************************************************************/
77 xsh_instrument *instr);
78
80 xsh_instrument *instr);
81
83
85 const char* fname);
86
88 int absorder);
89
91 int absorder);
92
94 int absorder);
95
98
100 xsh_spectralformat_list* list, float lambda);
101
103
106 xsh_instrument *instr);
107
108#endif /* XSH_DATA_SPECTRALFORMAT_H */
cpl_propertylist * xsh_spectralformat_list_get_header(xsh_spectralformat_list *list)
Get header of the table.
void xsh_spectralformat_check_wlimit(xsh_spectralformat_list *list, xsh_order_list *order, xsh_wavesol *w, xsh_xs_3 *model, xsh_instrument *instr)
const char * xsh_spectralformat_list_get_lamp(xsh_spectralformat_list *list, int absorder)
void xsh_spectralformat_list_dump(xsh_spectralformat_list *list, const char *fname)
Dump main info about an order table (for each order of the list)
cpl_vector * xsh_spectralformat_list_get_orders(xsh_spectralformat_list *list, float lambda)
Returns list of absolute orders containing lambda.
xsh_spectralformat_list * xsh_spectralformat_list_create(int size, xsh_instrument *instr)
Create an empty spectralformat list.
xsh_spectralformat_list * xsh_spectralformat_list_load(cpl_frame *frame, xsh_instrument *instr)
Load a spectralformat list from a frame.
float xsh_spectralformat_list_get_lambda_max(xsh_spectralformat_list *list, int absorder)
float xsh_spectralformat_list_get_lambda_min(xsh_spectralformat_list *list, int absorder)
Returns lambda min for a given absolute order.
void xsh_spectralformat_list_free(xsh_spectralformat_list **list)
Free memory associated to an spactralformat_list.
int size
int xsh_spectralformat_list_get_dist_order(xsh_spectralformat_list *list)
int order
Definition: xsh_detmon_lg.c:80