Mercurial > repos > public > sbplib
comparison +grid/Cartesian.m @ 684:fcf004066ea9 feature/poroelastic
Add property lim to grid/Cartesian to make periodic discr easier.
author | Martin Almquist <malmquist@stanford.edu> |
---|---|
date | Thu, 08 Feb 2018 16:40:48 -0800 |
parents | 3da69d57e684 |
children | 0ef96fcdc028 |
comparison
equal
deleted
inserted
replaced
683:50e77b15d841 | 684:fcf004066ea9 |
---|---|
3 n % Number of points in the grid | 3 n % Number of points in the grid |
4 d % Number of dimensions | 4 d % Number of dimensions |
5 m % Number of points in each direction | 5 m % Number of points in each direction |
6 x % Cell array of vectors with node placement for each dimension. | 6 x % Cell array of vectors with node placement for each dimension. |
7 h % Spacing/Scaling | 7 h % Spacing/Scaling |
8 lim % Cell array of left and right boundaries for each dimension. | |
8 end | 9 end |
9 | 10 |
10 % General d dimensional grid with n points | 11 % General d dimensional grid with n points |
11 methods | 12 methods |
12 % Creates a cartesian grid given vectors conatining the coordinates | 13 % Creates a cartesian grid given vectors conatining the coordinates |
25 if obj.n == 0 | 26 if obj.n == 0 |
26 error('grid:Cartesian:EmptyGrid','Input parameter gives an empty grid.') | 27 error('grid:Cartesian:EmptyGrid','Input parameter gives an empty grid.') |
27 end | 28 end |
28 | 29 |
29 obj.h = []; | 30 obj.h = []; |
31 obj.lim = []; | |
30 end | 32 end |
31 % n returns the number of points in the grid | 33 % n returns the number of points in the grid |
32 function o = N(obj) | 34 function o = N(obj) |
33 o = obj.n; | 35 o = obj.n; |
34 end | 36 end |