Example_SV.m#

 1% -------------------------------------------------------------------------
 2% EXAMPLE: SV
 3% Compute Isentropic compression/expansion and equilibrium composition at 
 4% a defined set of volume ratios (0.5, 2) for a lean CH4-air mixture at
 5% 700 K and 10 bar, a set of 24 species considered, and a equivalence
 6% ratio phi 0.5 [-]
 7%   
 8% Soot formation == {'CO2','CO','H2O','H2','O2','N2','Ar','Cbgrb',...
 9%                    'C2','C2H4','CH','CH3','CH4','CN','H',...
10%                    'HCN','HCO','N','NH','NH2','NH3','NO','O','OH'}
11%   
12% See wiki or list_species() for more predefined sets of species
13%
14% @author: Alberto Cuadra Lara
15%          PhD Candidate - Group Fluid Mechanics
16%          Universidad Carlos III de Madrid
17%                 
18% Last update July 22 2022
19% -------------------------------------------------------------------------
20
21%% INITIALIZE
22self = App('Soot formation');
23%% INITIAL CONDITIONS
24self = set_prop(self, 'TR', 700, 'pR', 10, 'phi', 0.5);
25self.PD.S_Fuel     = {'CH4'};
26self.PD.S_Oxidizer = {'N2', 'O2', 'Ar', 'CO2'};
27self.PD.ratio_oxidizers_O2 = [78.084, 20.9476, 0.9365, 0.0319] ./ 20.9476;
28%% ADDITIONAL INPUTS (DEPENDS OF THE PROBLEM SELECTED)
29self = set_prop(self, 'vP_vR', 0.5:0.01:2); 
30%% SOLVE PROBLEM
31self = solve_problem(self, 'SV');
32%% DISPLAY RESULTS (PLOTS)
33post_results(self);