45 ERRMSG(
"Give parameters: <ctl> <gps.nc> <map.tab>");
48 z = scan_ctl(argc, argv,
"Z", -1,
"20", NULL);
54 printf(
"Write map data: %s\n", argv[3]);
55 if (!(out = fopen(argv[3],
"w")))
56 ERRMSG(
"Cannot create file!");
61 "# $2 = altitude [km]\n"
62 "# $3 = longitude [deg]\n"
63 "# $4 = latitude [deg]\n"
64 "# $5 = pressure [hPa]\n"
65 "# $6 = temperature [K]\n"
66 "# $7 = water vapor vmr [ppm]\n"
67 "# $8 = temperature perturbation [K]\n"
68 "# $9 = tropopause height [km]\n\n");
71 for (ids = 0; ids < gps->
nds; ids++)
72 for (iz = 0; iz < gps->
nz[ids]; iz++)
73 if (fabs(gps->
z[ids][iz] - z) < 0.01) {
74 fprintf(out,
"%.2f %g %g %g %g %g %g %g %g\n",
75 gps->
time[ids], gps->
z[ids][iz], gps->
lon[ids][iz],
76 gps->
lat[ids][iz], gps->
p[ids][iz], gps->
t[ids][iz],
77 gps->
wv[ids][iz], gps->
pt[ids][iz], gps->
th[ids]);
void read_gps(char *filename, gps_t *gps)
Read GPS-RO data file.
GPS Code Collection library declarations.
int main(int argc, char *argv[])
double time[NDS]
Time (seconds since 2000-01-01T00:00Z).
double pt[NDS][NZ]
Temperature perturbation [K].
double t[NDS][NZ]
Temperature [K].
double wv[NDS][NZ]
Water vapor volume mixing ratio [ppm].
int nz[NDS]
Number of altitudes per profile.
double lon[NDS][NZ]
Longitude [deg].
int nds
Number of profiles.
double p[NDS][NZ]
Pressure [hPa].
double th[NDS]
Tropopause height [km].
double z[NDS][NZ]
Altitude [km].
double lat[NDS][NZ]
Latitude [deg].