BG_Flood  0.8
Documentation (Work-in-progress)
Read_netcdf.h
Go to the documentation of this file.
1 
2 #ifndef READNETCDF_H
3 #define READNETCDF_H
4 
5 #include "General.h"
6 #include "Input.h"
7 #include "ReadInput.h"
8 #include "Write_txtlog.h"
9 #include "Write_netcdf.h"
10 #include "Util_CPU.h"
11 #include "GridManip.h"
12 #include "Forcing.h"
13 
14 
15 
16 inline int nc_get_var_T(int ncid, int varid, float * &zb);
17 inline int nc_get_var_T(int ncid, int varid, double * &zb);
18 
19 inline int nc_get_vara_T(int ncid, int varid, const size_t* startp, const size_t* countp, float * &zb);
20 inline int nc_get_vara_T(int ncid, int varid, const size_t* startp, const size_t* countp, double * &zb);
21 
22 inline int nc_get_var1_T(int ncid, int varid, const size_t* startp, float * zsa);
23 inline int nc_get_var1_T(int ncid, int varid, const size_t* startp, double * zsa);
24 
25 //template <class T> int readnczb(int nx, int ny, const std::string ncfile, T * &zb);
26 //int readnczb(int nx, int ny, const std::string ncfile, float*& zb);
27 //int readnczb(int nx, int ny, const std::string ncfile, double*& zb);
28 std::string checkncvarname(int ncid, std::string stringA, std::string stringB, std::string stringC, std::string stringD, std::string stringE);
29 
30 void readgridncsize(const std::string ncfilestr, const std::string varstr, int& nx, int& ny, int& nt, double& dx, double& xo, double& yo, double& to, double& xmax, double& ymax, double& tmax, bool& flipx, bool& flipy);
31 int readvarinfo(std::string filename, std::string Varname, size_t *&ddimU);
32 int readnctime(std::string filename, double * &time);
33 template <class T> int readncslev1(std::string filename, std::string varstr, size_t indx, size_t indy, size_t indt, bool checkhh, double eps, T * &zsa);
34 template <class T> int readvardata(std::string filename, std::string Varname, int step, T*& vardata, bool flipx, bool flipy);
35 //template <class T> int readhotstartfile(Param XParam, int * leftblk, int *rightblk, int * topblk, int* botblk, double * blockxo, double * blockyo, T * &zs, T * &zb, T * &hh, T *&uu, T * &vv);
36 
37 void readWNDstep(forcingmap WNDUmap, forcingmap WNDVmap, int steptoread, float *&Uo, float *&Vo);
38 void readATMstep(forcingmap ATMPmap, int steptoread, float *&Po);
39 
40 extern "C" void read3Dnc(int nx, int ny, int ntheta, char ncfile[], float*& ee);
41 extern "C" void read2Dnc(int nx, int ny, char ncfile[], float*& hh);
42 extern "C" void readnczb(int nx, int ny, std::string ncfile, float*& zb);
43 
44 
45 // End of global definition
46 #endif
void readATMstep(forcingmap ATMPmap, int steptoread, float *&Po)
Definition: Read_netcdf.cu:874
int nc_get_vara_T(int ncid, int varid, const size_t *startp, const size_t *countp, float *&zb)
Definition: Read_netcdf.cu:50
void readWNDstep(forcingmap WNDUmap, forcingmap WNDVmap, int steptoread, float *&Uo, float *&Vo)
Definition: Read_netcdf.cu:783
std::string checkncvarname(int ncid, std::string stringA, std::string stringB, std::string stringC, std::string stringD, std::string stringE)
Definition: Read_netcdf.cu:738
void readgridncsize(const std::string ncfilestr, const std::string varstr, int &nx, int &ny, int &nt, double &dx, double &xo, double &yo, double &to, double &xmax, double &ymax, double &tmax, bool &flipx, bool &flipy)
Definition: Read_netcdf.cu:80
int readncslev1(std::string filename, std::string varstr, size_t indx, size_t indy, size_t indt, bool checkhh, double eps, T *&zsa)
Definition: Read_netcdf.cu:386
void read3Dnc(int nx, int ny, int ntheta, char ncfile[], float *&ee)
Definition: Read_netcdf.cu:938
int readvardata(std::string filename, std::string Varname, int step, T *&vardata, bool flipx, bool flipy)
Definition: Read_netcdf.cu:552
void readnczb(int nx, int ny, std::string ncfile, float *&zb)
Definition: Read_netcdf.cu:962
int nc_get_var_T(int ncid, int varid, float *&zb)
Definition: Read_netcdf.cu:24
int readnctime(std::string filename, double *&time)
Definition: Read_netcdf.cu:344
int readvarinfo(std::string filename, std::string Varname, size_t *&ddimU)
Definition: Read_netcdf.cu:302
int nc_get_var1_T(int ncid, int varid, const size_t *startp, float *zsa)
Definition: Read_netcdf.cu:65
void read2Dnc(int nx, int ny, char ncfile[], float *&hh)
Definition: Read_netcdf.cu:950
Definition: Forcing.h:28