OpenWAM
TFraccionMasicaCilindro.cpp
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 #include "TFraccionMasicaCilindro.h"
30 
31 //---------------------------------------------------------------------------
32 //---------------------------------------------------------------------------
33 
34 TFraccionMasicaCilindro::TFraccionMasicaCilindro() {
35 
36 }
37 
38 //---------------------------------------------------------------------------
39 //---------------------------------------------------------------------------
40 
41 TFraccionMasicaCilindro::~TFraccionMasicaCilindro() {
42 
43 }
44 
45 //---------------------------------------------------------------------------
46 //---------------------------------------------------------------------------
47 
48 void TFraccionMasicaCilindro::CalculaFraccionMasicaCilindro() {
49  try {
50 // En esta funcion u otras que puedas necesitar debes programar las acciones
51 // a realizar para imponer la composicion del gas de escape a la apertura de
52 // las valvulas de escape. Recuerda que:
53 
54 // 1.- Si realizas un calculo de especies simplificado sin transporte de la
55 // especie Combustible, el numero de especies es 2, siendo el orden del vector de
56 // fraccion masica el siguiente: [0] Gases quemados, [1] Aire fresco.
57 // 2.- Si se trata de transporte de especies simplificado, teniendo en cuenta el transporte
58 // de combustible, el orden del vector de fraccion masica es el siguiente:
59 // [0] Gases quemados, [1] Combustible, [2] Aire fresco.
60 // 3.- Si el transporte de especies quimicas es completo, sin transporte de combustible,
61 // el numero de especies transportadas es 8, en el siguiente orden:
62 // [0] O2, [1] CO2, [2] H2O, [3] HC, [4] Soot, [5] NOx, [6] CO, [7] N2
63 // 4.- Si el transporte de especies quimicas es completo con transporte de combustible,
64 // el orden del vector fraccion masica sera el siguiente:
65 // [0] O2, [1] CO2, [2] H2O, [3] HC, [4] Soot, [5] NOx, [6] CO, [7] Combustible, [8] N2
66 
67 // Recuerda que es la suma de fraccion masica total debe ser igual a la unidad.
68 
69  } catch(exception &N) {
70  std::cout << "ERROR: TFraccionMasicaCilindro::CalculaFraccionMasicaCilindro " << std::endl;
71  std::cout << "Tipo de error: " << N.what() << std::endl;
72  throw Exception(N.what());
73  }
74 }
75 
76 //---------------------------------------------------------------------------
77 //---------------------------------------------------------------------------
78 
79 #pragma package(smart_init)
80 
Exception
Custom exception class.
Definition: Exception.hpp:39