00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #ifndef PROFILE_TIMESERIES_H
00032 #define PROFILE_TIMESERIES_H
00033
00034 #include <iostream>
00035 #include <fstream>
00036 #include <ctime>
00037 #include "refractive_atmosphere.h"
00038 #include "time_val.h"
00039
00040 namespace Arroyo {
00041
00042 class profile_timeseries {
00043
00044 protected:
00045
00046 std::vector<time_t> profile_timestamps;
00047 std::vector<std::vector<double> > layer_heights_meters;
00048 std::vector<std::vector<double> > layer_Cn2_coeffs;
00049
00050 public:
00051
00054 profile_timeseries(){};
00055
00058 profile_timeseries(const profile_timeseries & pts) {
00059 this->operator=(pts);
00060 };
00061
00064 profile_timeseries(const std::vector<time_t> & profile_timestamps,
00065 const std::vector<std::vector<double> > & layer_heights_meters,
00066 const std::vector<std::vector<double> > & layer_Cn2_coeffs);
00067
00070 profile_timeseries(const char * dimm_filename,
00071 const char * mass_filename);
00072
00075 ~profile_timeseries(){};
00076
00079 profile_timeseries & operator=(const profile_timeseries & pts);
00080
00083 void print(std::ostream & os, const char * prefix = "") const;
00084
00087 int get_nprofiles() const {
00088 return(this->profile_timestamps.size());
00089 };
00090
00093 time_t get_timestamp(int index) const;
00094
00097 refractive_atmospheric_model get_refractive_atmospheric_model(const time_t & timestamp) const;
00098
00101 refractive_atmospheric_model get_refractive_atmospheric_model(int index) const;
00102
00114 refractive_atmospheric_model get_refractive_atmospheric_model(const time_t & start,
00115 const time_t & end,
00116 int & nprofiles_in_average) const;
00117
00118 };
00119 }
00120 #endif