OpenWAM
TMariposa.h
1 /*--------------------------------------------------------------------------------*\
2 ==========================|
3  \\ /\ /\ // O pen | OpenWAM: The Open Source 1D Gas-Dynamic Code
4  \\ | X | // W ave |
5  \\ \/_\/ // A ction | CMT-Motores Termicos / Universidad Politecnica Valencia
6  \\/ \// M odel |
7  ----------------------------------------------------------------------------------
8  License
9 
10  This file is part of OpenWAM.
11 
12  OpenWAM is free software: you can redistribute it and/or modify
13  it under the terms of the GNU General Public License as published by
14  the Free Software Foundation, either version 3 of the License, or
15  (at your option) any later version.
16 
17  OpenWAM is distributed in the hope that it will be useful,
18  but WITHOUT ANY WARRANTY; without even the implied warranty of
19  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  GNU General Public License for more details.
21 
22  You should have received a copy of the GNU General Public License
23  along with OpenWAM. If not, see <http://www.gnu.org/licenses/>.
24 
25 
26  \*--------------------------------------------------------------------------------*/
27 
28 //---------------------------------------------------------------------------
29 #ifndef TMariposaH
30 #define TMariposaH
31 
32 #include <cstdio>
33 #ifdef __BORLANDC__
34 #include <vcl.h>
35 #endif
36 #include <iostream>
37 
38 #include "TController.h"
39 
40 #include "TTipoValvula.h"
41 //---------------------------------------------------------------------------
42 
43 class TMariposa: public TTipoValvula {
44  private:
45 
46  int FNumLev;
47  dVector FLevantamiento;
48  dVector FDatosCDEntrada;
49  Hermite_interp *fun_CDin;
50  dVector FDatosCDSalida;
51  Hermite_interp *fun_CDout;
52  double FDiametroRef;
53  double FLevActual;
54  bool FLevControlled;
55  int FControllerID;
56 
57  TController *FController;
58 
59  public:
60 
61  TMariposa(TMariposa *Origen, int valv);
62 
63  TMariposa();
64 
65  ~TMariposa();
66 
67  void LeeDatosIniciales(const char *FileWAM, fpos_t &filepos, int norden, bool HayMotor, TBloqueMotor *Engine);
68 
69  void AsignaLevController(TController **Controller);
70 
71  void CalculaCD(double Time);
72 
73  void GetCDin(double Time);
74 
75  void GetCDout(double Time);
76 
77 };
78 
79 #endif
TController
Definition: TController.h:37
TTipoValvula
Definition: TTipoValvula.h:53
Hermite_interp
Definition: Math_wam.h:311
TMariposa
Definition: TMariposa.h:43
TBloqueMotor
Definition: TBloqueMotor.h:43
dVector
std::vector< double > dVector
Double vector.
Definition: Math_wam.h:70