MESH toolbox  0.1
Matlab/Octave mesh utils
 All Files Functions Groups Pages
refine_valid1.m
Go to the documentation of this file.
1 function refine_valid1(varargin)
2 % function refine_valid1(varargin)
3 % validation function using refine mesh tools and mesh plot command.
4 %
5 % Parameters:
6 % save : set to true to save figures in image directory.
7 % percent : set resize percent png images
8 %
9 % Examples:
10 % - Mesh file : \'disque4-1-3\'
11 % \image html images/refine_disque4-1-31.png "figure : Mesh before refinement"
12 % \image html images/refine_disque4-1-32.png "figure : Mesh after refinement : sort=false"
13 % \image html images/refine_disque4-1-33.png "figure : Mesh after refinement : sort=true"
14 % - Mesh file : \'disk_hole2\'
15 % \image html images/refine_disk_hole21.png "figure : Mesh before refinement"
16 % \image html images/refine_disk_hole22.png "figure : Mesh after refinement : sort=false"
17 % \image html images/refine_disk_hole23.png "figure : Mesh after refinement : sort=true"
18 % - Mesh file : \'disk_hole_A2\'
19 % \image html images/refine_disk_hole_A21.png "figure : Mesh before refinement"
20 % \image html images/refine_disk_hole_A22.png "figure : Mesh after refinement : sort=false"
21 % \image html images/refine_disk_hole_A23.png "figure : Mesh after refinement : sort=true"
22 % - Mesh file : \'disk_hole_B2\'
23 % \image html images/refine_disk_hole_B21.png "figure : Mesh before refinement"
24 % \image html images/refine_disk_hole_B22.png "figure : Mesh after refinement : sort=false"
25 % \image html images/refine_disk_hole_B23.png "figure : Mesh after refinement : sort=true"
26 % - Mesh file : \'disk_hole_C1\'
27 % \image html images/refine_disk_hole_C11.png "figure : Mesh before refinement"
28 % \image html images/refine_disk_hole_C12.png "figure : Mesh after refinement : sort=false"
29 % \image html images/refine_disk_hole_C13.png "figure : Mesh after refinement : sort=true"
30 %
31 % See also:
32 % #refine_demo1
33 p = inputParser;
34 %
35 p.addParamValue('save', false, @islogical );
36 p.addParamValue('percent', 50 , @(t) ((t>0)&&(t<=100)) );
37 p.parse(varargin{:});
38 close all
39 
40 FileNames={'disque4-1-3','disk_hole2','disk_hole_A2','disk_hole_B2','disk_hole_C1'};
41 addpath('base');
42 addpath('graphic');
43 addpath('refine');
44 
45 for i=1:length(FileNames)
46  refine_demo1('meshfile',sprintf('mesh%s%s.msh',filesep,FileNames{i}), ...
47  'save',p.Results.save,'savename',sprintf('refine_%s',FileNames{i}), ...
48  'percent',p.Results.percent)
49  if ~p.Results.save
50  fprintf('Pause [%d/%d]... Press a key to continue!\n',i,length(FileNames))
51  pause
52  end
53 end