3 % This
function demonstrates the reduced basis approximation of the
4 % stationary Navier-Stokes equations (2-d CFD benchmark problem).
13 params.mesh_number = mesh_number;
20 model_data = gen_model_data(model);
22 % generate reduced basis
24 disp(
'-> generate radial basis interpolant for inf-sup constant approximation');
25 model_data.infsup_constant = stokes_infsup_rbf_interpolant(model, model_data);
27 disp(
'-> approximate continuity constant (sobolev embedding)');
28 model_data.rho_sqr = stokes_sobolev_embedding_constant(model, model_data);
30 disp(
'-> reduced basis greedy algorithm');
31 detailed_data = gen_detailed_data(model,model_data);
32 reduced_data = gen_reduced_data(model,detailed_data);
36 % specify functions to be plotted
37 %plot_params.modes = { ...
39 %
'velocity_xcomp', ...
40 %
'velocity_ycomp', ...
43 plot_params.modes = {
'pressure',
'velocity_abs'};
44 plot_params.subsampling_level = 0;
45 plot_params.vector_plot_distance = 0.02;
46 plot_params.no_lines=1;
48 plot_params.hide_N_ruler=1;
52 disp(
'Please call demo_rb_stokes_fem(3) for a better resolution');
54 model.descr.is_stationary = 1;
55 model.enable_error_estimator = 0;
56 model.descr.gridtype =
'triagrid';
57 model.N = get_rb_size(model,detailed_data);
59 demo_rb_gui(model,detailed_data,reduced_data,plot_params);
function demo_rb_gui(varargin)
reduced basis demo with sliders
function demo_rb_stokes_fem(mesh_number)
This function demonstrates the reduced basis approximation of the stationary Navier-Stokes equations ...
function demo()
small script demonstrating the possibilities of the rectgrid class.
function model = laminar_flow_model(params)
Model of laminar flow (steady Navier-Stokes) around cylinder in a pipe.
function p = plot(params)
plot of a rectgrid via plot_polygon_grid()