CLASS MANUAL
output.h
Go to the documentation of this file.
1 
3 #ifndef __OUTPUT__
4 #define __OUTPUT__
5 
6 #include "common.h"
7 #include "lensing.h"
8 
14 #define _Z_PK_NUM_MAX_ 100
15 
22 struct output {
23 
25 
26  FileName root;
29 
33 
34  int z_pk_num;
35  double z_pk[_Z_PK_NUM_MAX_];
38 
42 
43  short write_header;
53 
57 
60  ErrorMsg error_message;
63 };
64 
65 /*************************************************************************************************************/
66 /* @cond INCLUDE_WITH_DOXYGEN */
67 /*
68  * Boilerplate for C++
69  */
70 #ifdef __cplusplus
71 extern "C" {
72 #endif
73 
74  int output_total_cl_at_l(
75  struct spectra * psp,
76  struct lensing * ple,
77  struct output * pop,
78  int l,
79  double * cl
80  );
81 
82  int output_init(
83  struct background * pba,
84  struct thermo * pth,
85  struct perturbs * ppt,
86  struct primordial * ppm,
87  struct transfers * ptr,
88  struct spectra * psp,
89  struct nonlinear * pnl,
90  struct lensing * ple,
91  struct output * pop
92  );
93 
94  int output_cl(
95  struct background * pba,
96  struct perturbs * ppt,
97  struct spectra * psp,
98  struct lensing * ple,
99  struct output * pop
100  );
101 
102  int output_pk(
103  struct background * pba,
104  struct perturbs * ppt,
105  struct spectra * psp,
106  struct output * pop
107  );
108 
109  int output_pk_nl(
110  struct background * pba,
111  struct perturbs * ppt,
112  struct spectra * psp,
113  struct output * pop
114  );
115 
116  int output_tk(
117  struct background * pba,
118  struct perturbs * ppt,
119  struct spectra * psp,
120  struct output * pop
121  );
122 
123  int output_background(
124  struct background * pba,
125  struct output * pop
126  );
127 
128  int output_thermodynamics(
129  struct background * pba,
130  struct thermo * pth,
131  struct output * pop
132  );
133 
134  int output_perturbations(
135  struct background * pba,
136  struct perturbs * ppt,
137  struct output * pop
138  );
139 
140  int output_primordial(
141  struct perturbs * ppt,
142  struct primordial * ppm,
143  struct output * pop
144  );
145 
146  int output_print_data(FILE *out,
147  char titles[_MAXTITLESTRINGLENGTH_],
148  double *dataptr,
149  int tau_size);
151  struct spectra * psp,
152  struct output * pop,
153  FILE ** clfile,
154  FileName filename,
155  char * first_line,
156  int lmax
157  );
158 
160  struct background * pba,
161  struct spectra * psp,
162  struct output * pop,
163  FILE * clfile,
164  double l,
165  double * cl,
166  int ct_size
167  );
168 
170  struct background * pba,
171  struct spectra * psp,
172  struct output * pop,
173  FILE ** pkfile,
174  FileName filename,
175  char * first_line,
176  double z
177  );
178 
180  FILE * tkfile,
181  double one_k,
182  double one_pk
183  );
184 
185  int output_open_pk_nl_file(
186  struct background * pba,
187  struct nonlinear * pnl,
188  struct output * pop,
189  FILE ** pkfile,
190  FileName filename,
191  char * first_line,
192  double z,
193  int k_size
194  );
195 
196 
197 #ifdef __cplusplus
198 }
199 #endif
200 
201 #endif
202 /* @endcond */
Definition: background.h:25
int output_init(struct background *pba, struct thermo *pth, struct perturbs *ppt, struct primordial *ppm, struct transfers *ptr, struct spectra *psp, struct nonlinear *pnl, struct lensing *ple, struct output *pop)
Definition: output.c:108
int output_tk(struct background *pba, struct perturbs *ppt, struct spectra *psp, struct output *pop)
Definition: output.c:1017
Definition: lensing.h:17
int output_cl(struct background *pba, struct perturbs *ppt, struct spectra *psp, struct lensing *ple, struct output *pop)
Definition: output.c:221
int output_open_pk_file(struct background *pba, struct spectra *psp, struct output *pop, FILE **pkfile, FileName filename, char *first_line, double z)
Definition: output.c:1622
Definition: spectra.h:17
int output_one_line_of_cl(struct background *pba, struct spectra *psp, struct output *pop, FILE *clfile, double l, double *cl, int ct_size)
Definition: output.c:1542
Definition: nonlinear.h:20
Definition: perturbations.h:95
int output_print_data(FILE *out, char titles[_MAXTITLESTRINGLENGTH_], double *dataptr, int size_dataptr)
Definition: output.c:1364
Definition: thermodynamics.h:57
short output_verbose
Definition: output.h:58
int z_pk_num
Definition: output.h:34
int output_open_cl_file(struct spectra *psp, struct output *pop, FILE **clfile, FileName filename, char *first_line, int lmax)
Definition: output.c:1414
short write_perturbations
Definition: output.h:49
enum file_format output_format
Definition: output.h:45
Definition: output.h:22
Definition: transfer.h:38
ErrorMsg error_message
Definition: output.h:60
short write_thermodynamics
Definition: output.h:48
file_format
Definition: common.h:337
#define _Z_PK_NUM_MAX_
Definition: output.h:14
int output_pk_nl(struct background *pba, struct perturbs *ppt, struct spectra *psp, struct output *pop)
Definition: output.c:906
int output_pk(struct background *pba, struct perturbs *ppt, struct spectra *psp, struct output *pop)
Definition: output.c:601
short write_primordial
Definition: output.h:50
double z_pk[_Z_PK_NUM_MAX_]
Definition: output.h:35
short write_background
Definition: output.h:47
Definition: primordial.h:79
short write_header
Definition: output.h:43
int output_one_line_of_pk(FILE *pkfile, double one_k, double one_pk)
Definition: output.c:1661
FileName root
Definition: output.h:26