Mercurial > repos > public > sbplib
comparison +multiblock/DefCurvilinear.m @ 797:5cf9fdf4c98f feature/poroelastic
Merge with feature/grids and bugfix bcSetup
author | Martin Almquist <malmquist@stanford.edu> |
---|---|
date | Thu, 26 Jul 2018 10:53:05 -0700 |
parents | e7a6744499fa |
children | 8aa0909125a4 7df63b17e078 |
comparison
equal
deleted
inserted
replaced
796:aa1ed37a1b56 | 797:5cf9fdf4c98f |
---|---|
46 end | 46 end |
47 | 47 |
48 g = multiblock.Grid(grids, obj.connections, obj.boundaryGroups); | 48 g = multiblock.Grid(grids, obj.connections, obj.boundaryGroups); |
49 end | 49 end |
50 | 50 |
51 function show(obj, label, gridLines, varargin) | 51 function h = show(obj, label, gridLines, varargin) |
52 default_arg('label', 'name') | 52 default_arg('label', 'name') |
53 default_arg('gridLines', false); | 53 default_arg('gridLines', false); |
54 | 54 |
55 h = []; | |
55 if isempty('label') && ~gridLines | 56 if isempty('label') && ~gridLines |
56 for i = 1:obj.nBlocks | 57 for i = 1:obj.nBlocks |
57 obj.blockMaps{i}.show(2,2); | 58 h = [h, obj.blockMaps{i}.show(2,2)]; |
58 end | 59 end |
59 axis equal | 60 axis equal |
60 return | 61 return |
61 end | 62 end |
62 | 63 |
63 if gridLines | 64 if gridLines |
64 ms = obj.getGridSizes(varargin{:}); | 65 ms = obj.getGridSizes(varargin{:}); |
65 for i = 1:obj.nBlocks | 66 for i = 1:obj.nBlocks |
66 obj.blockMaps{i}.show(ms{i}(1),ms{i}(2)); | 67 h = [h, obj.blockMaps{i}.show(ms{i}(1),ms{i}(2))]; |
67 end | 68 end |
68 end | 69 end |
69 | 70 |
70 | 71 |
71 switch label | 72 switch label |
74 case 'id' | 75 case 'id' |
75 labels = {}; | 76 labels = {}; |
76 for i = 1:obj.nBlocks | 77 for i = 1:obj.nBlocks |
77 labels{i} = num2str(i); | 78 labels{i} = num2str(i); |
78 end | 79 end |
79 otherwise | 80 case 'none' |
80 axis equal | 81 axis equal |
81 return | 82 return |
82 end | 83 end |
83 | 84 |
84 for i = 1:obj.nBlocks | 85 for i = 1:obj.nBlocks |