SMS:Editing 2D Meshes: Difference between revisions
Line 22: | Line 22: | ||
==Editing Node Coordinates== | ==Editing Node Coordinates== | ||
The coordinates of a 2D Mesh node can be edited by selecting the mesh node and entering the new coordinates in the edit boxes in the Edit Window. It is also possible to drag an existing node to a new location by clicking on the node and moving the mouse with the button held down until the node is in the desired position. | The coordinates of a 2D Mesh node can be edited by selecting the mesh node and entering the new coordinates in the edit boxes in the ''Edit Window''. It is also possible to drag an existing node to a new location by clicking on the node and moving the mouse with the button held down until the node is in the desired position. | ||
If the snap to grid option in the Drawing Grid Options dialog is set, the node will move in increments corresponding to the drawing grid. If the node being dragged is connected to one or more elements, SMS will not allow the node to be dragged to a position where one of the surrounding elements would become ill-formed. | If the snap to grid option in the ''Drawing Grid Options'' dialog is set, the node will move in increments corresponding to the drawing grid. If the node being dragged is connected to one or more elements, SMS will not allow the node to be dragged to a position where one of the surrounding elements would become ill-formed. | ||
Since it is possible to accidentally drag points, nodes can be "locked" to prevent them from being dragged by selecting the Lock All Nodes item from the Nodes menu. The nodes can be unlocked by unselecting Lock All Nodes from the Nodes menu. | Since it is possible to accidentally drag points, nodes can be "locked" to prevent them from being dragged by selecting the '''Lock All Nodes''' item from the ''Nodes'' menu. The nodes can be unlocked by unselecting '''Lock All Nodes''' from the ''Nodes'' menu. | ||
==Merging Triangles== | ==Merging Triangles== |
Revision as of 15:15, 28 March 2013
2D Mesh nodes can be inserted, deleted, or moved.
2D Mesh elements can be edited in the following ways:
- Elements can be converted between linear and quadratic.
- The type of element can be changed from a 3 node element to a 4 node element by merging triangles.
- A 4 node element can be converted to a 3 node element by splitting the 4 node element.
- Elements can be refined automatically.
- The material assigned to an element can be changed.
- Poorly shaped boundary triangles can be automatically selected for deletion.
- Breaklines can be inserted into the mesh
Deleting Nodes
A set of selected nodes can be deleted by hitting the Delete key or selecting the Delete command from the Edit menu. Elements attached to the nodes are also deleted.
If the Retriangulate voids when deleting option is turned on, the void created when a node and the elements surrounding the node are deleted is re-triangulated or filled in with triangles. This feature makes it possible to selectively "unrefine" a region of the mesh or reduce the density of the nodes in a region of the mesh without having to completely recreate all of the elements in the region.
If the Retriangulate voids when deleting item in the Node Options dialog is not set, the selected node and the elements surrounding the node are simply deleted and the resulting void is not filled in with triangles.
If the Confirm Deletions option in the Edit menu is active, GMS will prompt the user to confirm each deletion. This feature is helpful in preventing accidental deletions. The Confirm Deletions item is toggled by selecting it from the menu.
Editing Node Coordinates
The coordinates of a 2D Mesh node can be edited by selecting the mesh node and entering the new coordinates in the edit boxes in the Edit Window. It is also possible to drag an existing node to a new location by clicking on the node and moving the mouse with the button held down until the node is in the desired position.
If the snap to grid option in the Drawing Grid Options dialog is set, the node will move in increments corresponding to the drawing grid. If the node being dragged is connected to one or more elements, SMS will not allow the node to be dragged to a position where one of the surrounding elements would become ill-formed.
Since it is possible to accidentally drag points, nodes can be "locked" to prevent them from being dragged by selecting the Lock All Nodes item from the Nodes menu. The nodes can be unlocked by unselecting Lock All Nodes from the Nodes menu.
Merging Triangles
The triangulate operation creates a mesh composed entirely of triangles. In some cases it is desirable to have the mesh composed primarily of quadrilateral elements. Quadrilateral elements result in less elements which leads to faster solutions, and quadrilateral elements are often more stable numerically. To address this need, two options are provided for converting triangular elements to quadrilateral elements:
The Merge Triangles Command
The Merge Triangles command in the Elements menu can be used to automatically merge pairs of adjacent triangular elements into quadrilateral elements. Upon selecting the Merge Triangles command, the user is prompted to input a minimum interior angle. This angle should be between 0 and 90 degrees. If no elements are selected, all of the triangular elements in the mesh are then processed. If some elements have been selected, only the selected elements are processed.
The conversion process works as follows:
- The set of elements to be processed is traversed one element at a time. Each triangular element that is found is compared with each of its three adjacent elements. If the adjacent element is a triangle, the trapezoid formed by the triangle and the adjacent triangle is checked.
- Each of the four interior angles of the trapezoid is computed and compared to a minimum interior angle. If all of the angles are greater than the user-specified minimum interior angle, then the two triangles are merged into a single quadrilateral element.
This process is repeated for all of the elements. The merging scheme will not always result in a mesh composed entirely of quadrilateral elements. Some triangular elements are often necessary in highly irregular meshes to provide transitions from one region to the next.
The Merge/Split Tool
The other option for merging triangles involves the use of the Merge/Split tool in the Tool Palette. This tool can be used to manually merge triangles one pair at a time rather than using the automatic scheme described above. The manual method is also useful to edit or override the results of the automatic merging scheme in selected areas. The Merge/Split tool can also be used to undo a merge. A quadrilateral element can be split into two triangles by clicking anywhere in the interior of the element. This tool is useful if a pair of triangles is inadvertently merged.
Splitting Quadrilaterals
Occasionally it is necessary to split quadrilateral elements into triangular elements. For example, in order for new nodes to be automatically inserted into a mesh, the elements in the region where the node is inserted must be triangular. Also, in order to process a breakline, the elements in the region of the breakline must be triangular. In such situations, it may be necessary to split a group of quadrilateral elements into triangular elements. Two options are provided for splitting quadrilateral elements:
The Split Quads Command
The Split Quads command in the Mesh menu can be used to split a group of quadrilateral elements into triangular elements. If no elements are selected, all of the quadrilateral elements in the mesh are split. If some elements have been selected, only the selected quadrilateral elements are split.
The Merge/Split Tool
The other option for splitting quadrilateral elements involves the use of the Merge/Split tool in the Tool Palette. If the Merge/Split tool is selected, clicking anywhere in the interior of a quadrilateral element with the mouse cursor will cause the element to be split into two triangles. The shortest diagonal through the quadrilateral is chosen as the common edge of the two new triangular elements.
Mesh Subset Edit Mode
When working with large meshes, it can be useful to work on only a small portion of the mesh. The user can select elements on which to work on and enter subset edit mode either through the select element tool's right click menu or the right click menu on the mesh tree item. The geometry of the mesh inside the selected area can then be changed. Datasets other than the depth/elevation dataset are deleted upon entering mesh subset edit.
Prohibited Actions While in Subset Edit Mode
- Making changes on the border of the mesh subset
- Making changes outside of the mesh subset
- Reading in meshes from file
- Creating meshes from feature map or scatter data
- Running models
- Changing attributes such as boundary conditions on nodes, nodestrings, and elements
- Renumbering node/nodestring/element ids
Commit Mesh
The user can merge the changes made to the subset of the mesh with the rest of the mesh by selecting Commit mesh from the right click menu of either the mesh tree item or the select element tool. Commit mesh will exit subset edit mode.
Revert Mesh
The user can revert to how the mesh was upon entering mesh subset edit mode by selecting Revert mesh from the right click menu of either the mesh tree item or the select element tool. Revert mesh will exit subset edit mode.
Related Topics
SMS – Surface-water Modeling System | ||
---|---|---|
Modules: | 1D Grid • Cartesian Grid • Curvilinear Grid • GIS • Map • Mesh • Particle • Quadtree • Raster • Scatter • UGrid | |
General Models: | 3D Structure • FVCOM • Generic • PTM | |
Coastal Models: | ADCIRC • BOUSS-2D • CGWAVE • CMS-Flow • CMS-Wave • GenCade • STWAVE • WAM | |
Riverine/Estuarine Models: | AdH • HEC-RAS • HYDRO AS-2D • RMA2 • RMA4 • SRH-2D • TUFLOW • TUFLOW FV | |
Aquaveo • SMS Tutorials • SMS Workflows |