regular_square_mesh
regular_square_mesh(gs)
Triangle mesh of a square
Generates a regular triangylar mesh of a one by one by one cube by dividing each grid square into two triangle
Parameters:
Name | Type | Description | Default |
---|---|---|---|
gs |
int
|
Number of vertices on each side |
required |
Returns:
Name | Type | Description |
---|---|---|
V |
numpy double array
|
Matrix of triangle mesh vertex coordinates |
T |
numpy int array
|
Matrix of triangle vertex indices into V |
See Also
regular_cube_mesh.
Notes
The ordering of the vertices is increasing by rows and then columns, so [0,0], [h,0], [2h,0],...,[h,h],[2h,h],...,[1-h,1],[1,1]
Examples:
TODO
Source code in src/gpytoolbox/regular_square_mesh.py
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
|