Example_SHOCK_POLAR_R.m#

 1% -------------------------------------------------------------------------
 2% EXAMPLE: SHOCK_POLAR_REFLECTED
 3%
 4% Compute shock polar plots at standard conditions, a set of 39 species
 5% considered, an initial shock front Mach numbers = 6, and a deflection 
 6% angle theta = 25;
 7%    
 8% Air_ions == {'O2','N2','O','O3','N','NO','NO2','NO3','N2O','N2O3',...
 9%              'N2O4','N3','eminus','Nminus','Nplus','NOplus','NO2minus',...
10%              'NO3minus','N2plus','N2minus','N2Oplus','Oplus','Ominus',...
11%              'O2plus', 'O2minus,'CO2','CO','COplus','C','Cplus',...
12%              'Cminus','CN','CNplus','CNminus','CNN','NCO','NCN','Ar',...
13%              'Arplus'}
14%   
15% See wiki or list_species() for more predefined sets of species
16%
17% @author: Alberto Cuadra Lara
18%          PhD Candidate - Group Fluid Mechanics
19%          Universidad Carlos III de Madrid
20%                  
21% Last update July 22 2022
22% -------------------------------------------------------------------------
23
24%% INITIALIZE
25self = App('Air_ions');
26%% INITIAL CONDITIONS
27self = set_prop(self, 'TR', 300, 'pR', 1 * 1.01325);
28self.PD.S_Oxidizer = {'N2', 'O2', 'Ar', 'CO2'};
29self.PD.N_Oxidizer = [78.084, 20.9476, 0.9365, 0.0319] ./ 20.9476;
30%% ADDITIONAL INPUTS (DEPENDS OF THE PROBLEM SELECTED)
31Mach_number = 6;
32self = set_prop(self, 'u1', 301.8203 * Mach_number, 'theta', 25);
33%% SOLVE PROBLEM
34self = solve_problem(self, 'SHOCK_POLAR_R');
35%% DISPLAY RESULTS (PLOTS)
36post_results(self);