Marine systems simulation
propeller_reader.h
1#pragma once
2
3#include <sys/stat.h>
4
5#include <fstream>
6#include <iostream>
7#include <vector>
8#include <string>
9#include <sstream>
10#include <map>
11
13
15{
16public:
17
18 propeller_reader(void);
20
21 void Read(const char *_fname);
22 void Read( std::fstream &_fstr);
23
24 void WriteBinary( const char *_fname);
25 void WriteBinary( std::string &_str);
26 void ReadBinary( const char *_fname);
27 void ReadBinary( std::string &_str);
28
29 void Summary();
30
31 bool GetThrustTable(propeller_table_2d &table);
32
33 void PrintArray(double *_a, int s, int e);
34private:
35
36 double *m_PD;
37 double *m_Z;
38 double *m_EAR;
39
40 int *m_set_size;
41 int this_set_size;
42 int m_rec_size;
43 int m_num_sets;
44
45 double *m_beta;
46 double *m_ct;
47 double *m_cq;
48
49 void NewPropeller();
50 void FinishPropeller();
51
52 void AppendData(std::vector<std::string> _tokens);
53
54
55
56 static bool TokenizedLine(std::fstream &f, std::vector<std::string> &tok);
57
58
59};
Definition: propeller_reader.h:15
Definition: propeller_table_2d.h:15