Changeset 325 for trunk/SRC/ToBeReviewed/TRIANGULATION/definetri.pro
- Timestamp:
- 12/06/07 11:04:53 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SRC/ToBeReviewed/TRIANGULATION/definetri.pro
r297 r325 3 3 ; @file_comments 4 4 ; Define a triangulation array like <proidl>TRIANGULATE</proidl>. 5 ; But in a VERY SIMPLE CASE: 5 ; 6 ; But in a VERY SIMPLE CASE: 6 7 ; the points are regularly-gridded on nx*ny array. 7 8 ; Find a Delaunay triangulation for this set of points is easy: 8 9 ; Points define (nx-1)*(ny-1) rectangles which we can cut in 2 triangles. 10 ; 9 11 ; cf. figure above 10 12 ; 11 13 ; <fixe> 12 ; fixe13 14 ; ny-1*---*---*. . . . . .*---*---* 14 15 ; | +| +| | +| +| … … 41 42 ; Utilities 42 43 ; 43 ; @param NX{in}{required}44 ; @param nx {in}{required} 44 45 ; The x dimension array 45 46 ; 46 ; @param NY{in}{required}47 ; @param ny {in}{required} 47 48 ; The y dimension array 48 49 ; 49 ; @param DOWNWARD{in}{optional}50 ; When DOWNWARDis undefined all rectangles are cut in using the upward50 ; @param downward {in}{optional} 51 ; When downward is undefined all rectangles are cut in using the upward 51 52 ; diagonal. 52 ; DOWNWARDis a vector which contains the rectangles numbers which are cut in53 ; downward is a vector which contains the rectangles numbers which are cut in 53 54 ; using the downward diagonal. 54 55 ; The rectangle number is defined by the index (in a nx*ny vector) of the … … 62 63 ; 63 64 ; IDL> triangles=definetri(3,3,[1,3]) 65 ; 64 66 ; triangles will be this kind of triangulation: 65 67 ; 68 ; <fixe> 66 69 ; *---*---* 67 70 ; |+ | +| … … 74 77 ; *---*---* 75 78 ; 79 ; <fixe> 76 80 ; 77 81 ; @history … … 82 86 ; $Id$ 83 87 ;- 84 ;85 88 FUNCTION definetri, nx, ny, downward 86 89 ;
Note: See TracChangeset
for help on using the changeset viewer.