22874: [CEA 1425] Performance SMESH Module

some optimization of Publish...() + doc imp
This commit is contained in:
eap 2015-02-25 20:07:02 +03:00
parent 44d75c1021
commit fd1943809d
19 changed files with 526 additions and 350 deletions

BIN
doc/salome/gui/SMESH/images/b-flection1d.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.1 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

View File

@ -2,18 +2,39 @@
\page a1d_meshing_hypo_page 1D Meshing Hypotheses
<br>
Basic 1D hypothesis specifies:
<ul>
<li>\ref adaptive_1d_anchor "Adaptive"</li>
<li>\ref arithmetic_1d_anchor "Arithmetic 1D"</li>
<li>\ref geometric_1d_anchor "Geometric Progression"</li>
<li>\ref average_length_anchor "Local Length"</li>
<li>\ref max_length_anchor "Max Size"</li>
<li>\ref deflection_1d_anchor "Deflection 1D"</li>
<li>\ref number_of_segments_anchor "Number of segments"</li>
<li>\ref start_and_end_length_anchor "Start and end length"</li>
<li>\ref automatic_length_anchor "Automatic Length"</li>
<li>\ref fixed_points_1d_anchor "Fixed points 1D"</li>
<li>how \ref a1d_algos_anchor "Wire Discretization" should divide the edge;</li>
<li>how \ref a1d_algos_anchor "Composite Side Discretization" should divide the group of C1-continues edges.</li>
</ul>
By type of nodes distribution the 1D hypotheses can be categorized as follows:
<ul>
<li>Uniform distribution
<ul>
<li>\ref average_length_anchor "Local Length"</li>
<li>\ref max_length_anchor "Max Size"</li>
<li>\ref number_of_segments_anchor "Number of segments" with Equidistant distribution</li>
<li>\ref automatic_length_anchor "Automatic Length"</li>
</ul></li>
<li>Constantly increasing or decreasing length of segments
<ul>
<li>\ref arithmetic_1d_anchor "Arithmetic 1D"</li>
<li>\ref geometric_1d_anchor "Geometric Progression"</li>
<li>\ref start_and_end_length_anchor "Start and end length"</li>
<li>\ref number_of_segments_anchor "Number of segments" with Scale distribution</li>
</ul></li>
<li>Distribution depending on curvature
<ul>
<li>\ref adaptive_1d_anchor "Adaptive"</li>
<li>\ref deflection_1d_anchor "Deflection 1D"</li>
</ul></li>
<li>Arbitrary distribution
<ul>
<li>\ref fixed_points_1d_anchor "Fixed points 1D"</li>
<li>\ref number_of_segments_anchor "Number of segments" with
\ref analyticdensity_anchor "Analytic Density Distribution" or Table Density Distribution</li>
</ul></li>
</ul>
<br>
@ -91,13 +112,14 @@ Add button to add the selected edges to the list.
<h2>Deflection 1D hypothesis</h2>
<b>Deflection 1D</b> hypothesis can be applied for meshing curvilinear edges
composing your geometrical object. It uses only one parameter: the
value of deflection.
\n A geometrical edge is divided into equal segments. The maximum
distance between a point on the edge within a segment and the line
connecting the ends of the segment should not exceed the specified
value of deflection . Then mesh nodes are constructed at end segment
locations and 1D mesh elements are constructed on segments.
composing your geometrical object. It defines only one parameter: the
value of deflection (or chord error).
A geometrical edge is divided into segments of length depending on
edge curvature. The more curved the edge, the shorter the
segment. Nodes on the edge are placed so that the maximum distance
between the edge and a segment approximating a part of edge between
two nodes should not exceed the value of deflection.
\image html a-deflection1d.png
@ -112,25 +134,21 @@ locations and 1D mesh elements are constructed on segments.
<b>Local Length</b> hypothesis can be applied for meshing of edges
composing your geometrical object. Definition of this hypothesis
consists of setting the \b length of segments, which will split these
edges, and the \b precision of rounding. The points on the edges
generated by these segments will represent nodes of your mesh.
Later these nodes will be used for meshing of the faces abutting to
these edges.
consists of setting the \b length of segments, which will approximate these
edges, and the \b precision of rounding.
The \b precision parameter is used to allow rounding a number of
segments, calculated from the edge length and average length of
segment, to the lower integer, if this value outstands from it in
bounds of the precision. Otherwise, the number of segments is rounded
to the higher integer. Use value 0.5 to provide rounding to the
nearest integer, 1.0 for the lower integer, 0.0 for the higher
The \b precision parameter is used to round a number of segments,
calculated by dividing the edge length by the specified \b length of
segment, to the higher integer if the remainder exceeds the precision
and to the lower integer otherwise. Use value 0.5 to provide rounding
to the nearest integer, 1.0 for the lower integer, 0.0 for the higher
integer. Default value is 1e-07.
\image html image41.gif
\image html a-averagelength.png
\image html b-erage_length.png "Local Length hypothesis - all 1D mesh elements are roughly equal"
\image html b-erage_length.png "Local Length hypothesis - all 1D mesh segments are equal"
<b>See Also</b> a sample TUI Script of a
\ref tui_average_length "Defining Local Length" hypothesis
@ -141,7 +159,7 @@ operation.
<b>Max Size</b> hypothesis allows splitting geometrical edges into
segments not longer than the given length. Definition of this hypothesis
consists of setting the maximal allowed \b length of segments.
<b>Use preestimated length</b> check box lets you specify \b length
<b>Use preestimated length</b> check box lets you use \b length
automatically calculated basing on size of your geometrical object,
namely as diagonal of bounding box divided by ten. The divider can be
changed via "Ratio Bounding Box Diagonal / Max Size"
@ -155,14 +173,9 @@ geometrical object has been selected before hypothesis definition.
\anchor number_of_segments_anchor
<h2>Number of segments hypothesis</h2>
<b>Number of segments</b> hypothesis can be applied for meshing of edges
composing your geometrical object. Definition of this hypothesis
consists of setting the number of segments, which will split these
edges. In other words your edges will be split into a definite number
of segments with approximately the same length. The points on the
edges generated by these segments will represent nodes of your
mesh. Later these nodes will be used for meshing of the faces abutting
to these edges.
<b>Number of segments</b> hypothesis can be applied for approximating
edges by a definite number of mesh segments with length depending on
the selected type of distribution of nodes.
The direction of the splitting is defined by the orientation of the
underlying geometrical edge. <b>"Reverse Edges"</b> list box allows to
@ -175,7 +188,7 @@ Object Browser.
\image html image46.gif
You can set the type of distribution for this hypothesis in the
You can set the type of node distribution for this hypothesis in the
<b>Hypothesis Construction</b> dialog bog :
\image html a-nbsegments1.png
@ -232,9 +245,7 @@ operation.
<b>Start and End Length</b> hypothesis allows to divide a geometrical edge
into segments so that the first and the last segments have a specified
length. The length of medium segments changes with automatically chosen
geometric progression. Then mesh nodes are
constructed at segment ends location and 1D mesh elements are
constructed on them.
geometric progression.
The direction of the splitting is defined by the orientation of the
underlying geometrical edge. <b>"Reverse Edges"</b> list box allows to
@ -259,25 +270,25 @@ hypothesis operation.
The dialog box prompts you to define the quality of the future mesh by
only one parameter, which is \b Fineness, ranging from 0 (coarse mesh,
low number of elements) to 1 (extremely fine mesh, great number of
elements).
low number of segments) to 1 (extremely fine mesh, great number of
segments).
\image html automaticlength.png
Compare one and the same object (sphere) meshed with
minimum and maximum value of this parameter.
\image html image147.gif "Example of a very rough mesh. Automatic Length works for 0."
\image html image147.gif "Example of a rough mesh at Automatic Length Fineness of 0."
\image html image148.gif "Example of a very fine mesh. Automatic Length works for 1."
\image html image148.gif "Example of a fine mesh at Automatic Length Fineness of 1."
<br>
\anchor fixed_points_1d_anchor
<h2>Fixed points 1D hypothesis</h2>
<b>Fixed points 1D</b> hypothesis allows splitting edges through a
set of points parameterized on the edge (from 1 to 0) and a number of segments for each
interval limited by the points.
set of points parametrized on the edge (from 1 to 0) and a number of
segments for each interval limited by the points.
\image html hypo_fixedpnt_dlg.png
@ -293,7 +304,7 @@ possible to select the edges to be reversed either directly picking them in
the 3D viewer or selecting the edges or groups of edges in the
Object Browser.
\image html mesh_fixedpnt.png "Example of a submesh on the edge built using Fixed points 1D hypothesis"
\image html mesh_fixedpnt.png "Example of a sub-mesh on the edge built using Fixed points 1D hypothesis"
<b>See Also</b> a sample TUI Script of a
\ref tui_fixed_points "Defining Fixed Points" hypothesis operation.

View File

@ -11,7 +11,7 @@
<b>Max Element Area</b> hypothesis is applied for meshing of faces
composing your geometrical object. Definition of this hypothesis
consists of setting the <b>maximum area</b> of mesh elements,
consists of setting the <b>maximum area</b> of mesh faces,
which will compose the mesh of these faces.
\image html a-maxelarea.png
@ -26,9 +26,9 @@ which will compose the mesh of these faces.
\anchor length_from_edges_anchor
<h2>Length from Edges</h2>
<b>Length from edges</b> hypothesis builds 2D mesh elements having a
maximum linear size calculated as an average segment length for a wire
of a given face.
<b>Length from edges</b> hypothesis defines maximum linear size of
mesh faces as an average length of mesh edges approximating a boundary
of a face being meshed.
<b>See Also</b> a sample TUI Script of a
\ref tui_length_from_edges "Length from Edges" hypothesis operation.
@ -41,7 +41,7 @@ of a given face.
<b>Quadrangle parameters</b> is a hypothesis for Quadrangle (Mapping) algorithm.
<b>Transition</b> tab is used to define the algorithm of transition
between opposite sides of faces with a different number of
between opposite sides of the face with a different number of
segments on them. The following types of transition
algorithms are available:
@ -54,7 +54,7 @@ algorithms are available:
- <b>Quadrangle preference</b> forces building only quadrangles in the
transition area along the finer meshed sides. This hypothesis has a
restriction: the total quantity of segments on all
four sides of the face must be even (divisible by 2).
four face sides must be even (divisible by 2).
\note This type corresponds to <b>Quadrangle Preference</b> additional hypothesis,
which is obsolete now.
- <b>Quadrangle preference (reversed)</b> works in the same way and
@ -63,9 +63,9 @@ algorithms are available:
- <b>Reduced</b> type forces building only quadrangles and the transition
between the sides is made gradually, layer by layer. This type has
a limitation on the number of segments: one pair of opposite sides must have
the same number of segments, the other pair must have an even difference
between the numbers of segments on the sides. In addition, the number
of rows between sides with different discretization
the same number of segments, the other pair must have an even total
number of segments. In addition, the number of rows
between sides with different discretization
should be enough for the transition. Following the fastest transition
pattern, three segments become one (see the image below), hence
the least number of face rows needed to reduce from Nmax segments
@ -77,8 +77,8 @@ algorithms are available:
<b>Base vertex</b> tab allows using Quadrangle (Mapping)
algorithm for meshing of trilateral faces. In this case it is
necessary to select the vertex, which will be used as the fourth edge
(degenerated).
necessary to select the vertex, which will be used as the forth
degenerated side of quadrangle.
\image html hypo_quad_params_dialog_vert.png "Quadrangle parameters: Base Vertex"

View File

@ -7,7 +7,7 @@ specific condition or a set of conditions. Filters can be used to create
or edit mesh groups, remove elements from the mesh object, control
mesh quality by different parameters, etc.
Several filters can be combined together by using logical operators \a
Several criteria can be combined together by using logical operators \a
AND and \a OR. In addition, applied filter criterion can be reverted
using logical operator \a NOT.
@ -19,12 +19,12 @@ modes:
- In GUI, filters are available in some dialog boxes via an additional
"Set Filters" button, clicking on which opens the dialog box
allowing to specify the list of filter criterions to be applied to the
allowing to specify the list of filter criteria to be applied to the
current selection. See \subpage selection_filter_library_page page to learn more
about selection filters and their usage in GUI.
- In Python scripts, filters can be used to choose only some mesh
entities (nodes and/or elements) for the operations, which require the
entities (nodes or elements) for the operations, which require the
list of entities as input parameter (create/modify group, remove
nodes/elements, etc). The page \ref tui_filters_page provides
examples of the filters usage in Python scripts.

View File

@ -3,12 +3,12 @@
\page about_hypo_page About Hypotheses
\b Hypotheses represent boundary conditions which will be taken into
account at calculations of meshes or sub-meshes.
These hypotheses allow you to manage the level of detail of
the resulting meshes or sub-meshes: when applying different hypotheses
account by meshing algorithms.
The hypotheses allow you to manage the level of detail of
the resulting mesh: when applying different hypotheses
with different parameters you can preset the quantity or size of
elements which will compose your mesh. So, it will be possible to
generate a coarse or a more refined mesh or sub-mesh.
generate a coarse or a more refined mesh.
In \b MESH there are the following Basic Hypotheses:
<ul>
@ -20,10 +20,11 @@ In \b MESH there are the following Basic Hypotheses:
<li>\ref max_length_anchor "Max Size"</li>
<li>\ref adaptive_1d_anchor "Adaptive"</li>
<li>\ref arithmetic_1d_anchor "Arithmetic 1D"</li>
<li>\ref geometric_1d_anchor "Geometric 1D"</li>
<li>\ref geometric_1d_anchor "Geometric Progression"</li>
<li>\ref start_and_end_length_anchor "Start and end length"</li>
<li>\ref deflection_1d_anchor "Deflection 1D"</li>
<li>\ref automatic_length_anchor "Automatic Length"</li>
<li>\ref fixed_points_1d_anchor "Fixed points 1D"</li>
</ul>
<li>\subpage a2d_meshing_hypo_page "2D Hypotheses" (for meshing of <b>faces</b>):</li>
<ul>
@ -37,22 +38,17 @@ In \b MESH there are the following Basic Hypotheses:
</ul>
</ul>
There also exist
\subpage additional_hypo_page "Additional Hypotheses" used together
with other hypotheses:
There also exist
\subpage additional_hypo_page "Additional Hypotheses" that can be used together
with main hypotheses:
<ul>
<li>\ref propagation_anchor "Propagation of 1D Hypothesis on opposite edges"</li>
<li>\ref propagofdistribution_anchor "Propagation of Node Distribution on Opposite Edges"</li>
<li>\ref viscous_layers_anchor "Viscous layers"</li>
<li>\ref quadratic_mesh_anchor "Quadratic mesh"</li>
<li>\ref non_conform_allowed_anchor "Non conform mesh allowed"</li>
<li>\ref quadrangle_preference_anchor "Quadrangle preference"</li>
</ul>
The choice of a hypothesis depends on:
<ul>
<li>the algorithm, which will be selected for meshing of this geometrical object (shape)</li>
<li>the geometrical object (shape) which will be meshed</li>
</ul>
The choice of a hypothesis depends on the selected algorithm.
*/

View File

@ -2,66 +2,100 @@
\page about_meshes_page About meshes
\n \b MESH represents a discretization of a geometrical CAD model into
a set of entities with a simple topology.
\n \b MESH represents a discrete approximation of a subset of the
three-dimensional space by \ref mesh_entities "elementary geometrical elements".
It is possible to \subpage constructing_meshes_page "construct meshes"
on the basis of geometrical shapes produced in the GEOM module.
Construction of \subpage constructing_submeshes_page "sub-meshes"
allows to mesh parts of the geometrical object, for example a face,
with different meshing parameters or using another meshing algorithm
than other parts.
Mesh module provides several ways to create the mesh:
<ul>
<li>The main way is to \subpage constructing_meshes_page "construct the mesh"
on the basis of the geometrical shape produced in the Geometry
module. This way implies selection of
- a geometrical object (<em> main shape</em>) and
- <em>meshing parameters</em> (\ref
basic_meshing_algos_page "meshing algorithms" and
characteristics (e.g. element size) of a
required mesh encapsulated in \ref about_hypo_page "hypothesis"
objects).
3D mesh can be generated basing on a 2D closed mesh.
Several created meshes can be \subpage building_compounds_page "combined into another mesh".
The whole mesh or its part can be \subpage copy_mesh_page "copied" into another mesh.
Meshing parameters of meshes and sub-meshes can be
\subpage editing_meshes_page "edited", then only the mesh part
depending on the changed parameters will be re-computed.
Construction of \subpage constructing_submeshes_page "sub-meshes"
allows to mesh some sub-shapes of the main shape, for example a face,
using different meshing parameters than other sub-shapes.<br>
Meshing parameters of meshes and sub-meshes can be
\subpage editing_meshes_page "edited". (Upon edition only mesh entities
generated using changed meshing parameters are removed and will be
re-computed).<br>
\note Algorithms and hypotheses used at mesh level are referred as
\a global ones and those used at sub-mesh level are referred as \a
local ones.
</li>
<li>Bottom-up way, using \ref modifying_meshes_page "mesh modification"
operations, especially \ref extrusion_page "extrusion" and \ref
revolution_page "revolution". To create an empty mesh not based on
geometry, use the same dialog as to \ref constructing_meshes_page
"construct the mesh on geometry" but do not specify any geometry
nor meshing algorithm.
</li>
<li>The mesh can be \ref importing_exporting_meshes_page "imported" from
(and exported to) the file in MED, UNV, STL, CGNS, DAT, GMF and
SAUVE formats.
</li>
<li>The 3D mesh can be generated from the 2D mesh, \ref
importing_exporting_meshes_page "imported" or manually created. To
setup the meshing parameters of a mesh not based on geometry, just
invoke \ref editing_meshes_page "Edit mesh / sub-mesh" command on
your 3D mesh.
</li>
<li>Several meshes can be \subpage building_compounds_page "combined"
into a new mesh.
</li>
<li>The whole mesh or its part (sub-mesh or group) can be
\subpage copy_mesh_page "copied" into a new mesh.
</li>
</ul>
Meshes can be edited using the MESH functions destined for
\ref modifying_meshes_page "modification" of generated meshes.
\ref modifying_meshes_page "modification" of meshes.
Meshes are stored in DAT, MED, UNV, STL, CGNS, GMF and SAUVE formats and can be
\subpage importing_exporting_meshes_page "imported from and exported to"
the file in these formats.
The \b topology of a mesh is described by the relationships between its
entities including:
The \b structure of a SALOME mesh is described by nodes and elements based on
these nodes. Geometry of the element is defined by the sequence of
nodes constituting it and
the <a href="http://www.code-aster.org/outils/med/html/connectivites.html">
connectivity convention </a> (adopted from MED library). Definition of
the element basing on elements of lower dimension is NOT supported.
\anchor mesh_entities
The mesh can include the following entities:
<ul>
<li>\b Node &mdash; 0D object of a mesh presented by a point with coordinates (x, y, z).</li>
<li>\b Node &mdash; an entity of a mesh defining a position in 3D
space with coordinates (x, y, z).</li>
<li>\b Edge (or segment) &mdash; 1D element of a mesh linking two nodes.</li>
<li>\b Face &mdash; 2D element of a mesh representing a part of
surface bound by links between face nodes. A face can be a
triangle, quadrangle or polygon.</li>
<li>\b Volume &mdash; 3D element of a mesh representing a part of 3D
space bound by volume facets. Nodes of a volume describing each
facet are defined by
the <a href="http://www.code-aster.org/outils/med/html/connectivites.html">
MED connectivity convention.</a> A volume can be a tetrahedron, hexahedron,
pentahedron, pyramid, hexagonal prism or polyhedron.</li>
<li>\b 0D element &mdash; element of a mesh defined by one node.</li>
<li>\b Edge &mdash; 1D element of a mesh defined by two nodes.</li>
<li>\b Face &mdash; 2D element of a mesh defined by three or four edges (closed contour).</li>
<li>\b Volume &mdash; 3D element of a mesh defined by several faces.</li>
<li>\b Ball element &mdash; discrete element of a mesh defined by a node and a diameter.</li>
<li>\b Ball element &mdash; discrete element of a mesh defined by a
node and a diameter.</li>
</ul>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;These entities are
considered as topological entities and they don't
imply any geometric representation. Only \b Nodes reference geometric
representations of points with definite coordinates. The node entity
contains additional information about its position in the space
and its relations with the meshed CAD model. Its position could be
described in the following way:
Every mesh entity has an attribute associating it to a sub-shape it is
generated on (if any). The node generated on the geometrical edge or
surface in addition stores its position in parametric space of the
associated geometrical entity.
<ul>
<li><b>3D position</b>. It characterizes the position of a node in a
solid geometry and is defined by three coordinates x,y and z and a
reference to the solid geometrical entity. </li>
<li><b>Surface position</b>. It characterizes the position of a node on a
geometric surface and is defined by the u,v position in the parametric
space of the corresponding surface.</li>
<li><b>Line position</b>. It characterizes the position of a node on a
geometric curve and is defined by the u parameter and the
corresponding curve.</li>
<li><b>Vertex position</b>. It characterizes the position of a node on a
geometric point of the meshed CAD model and is defined by the x,y,z
coordinates of the corresponding vertex.</li>
</ul>
SALOME supports elements of second order, without central node
(quadratic triangle, quadrangle, tetrahedron, hexahedron, pentahedron
and pyramid) and with central nodes (bi-quadratic triangle and
quadrangle and tri-quadratic hexahedron).<br>
Quadratic mesh can be obtained in two ways:
- Using a global \ref quadratic_mesh_anchor "Quadratic Mesh"
hypothesis. (Elements with the central node are not generated in this way).
- Using \ref convert_to_from_quadratic_mesh_page operation.
*/

View File

@ -5,37 +5,44 @@
\n <b>Additional Hypotheses</b> can be applied as a supplement to the
main hypotheses, introducing additional concepts to mesh creation.
To define an <b>Additional Hypothesis</b> simply select it in
<b>Create Mesh</b> menu. These hypotheses are actually changes in the
rules of mesh creation and as such don't possess adjustable values.
An <b>Additional Hypothesis</b> can be defined in the same way as any
main hypothesis in \ref create_mesh_anchor "Create Mesh" or
\ref constructing_submeshes_page "Create Sub-Mesh" dialog.
\anchor non_conform_allowed_anchor
<h2>Non Conform mesh allowed hypothesis</h2>
The following additional hypothesis are available:
<ul>
<li>\ref propagation_anchor "Propagation of 1D Hypothesis on opposite edges"
and \ref propagofdistribution_anchor "Propagation of Node Distribution on Opposite Edges"
hypotheses are useful for creation of quadrangle and hexahedral
meshes.</li>
<li>\ref viscous_layers_anchor "Viscous Layers" and
\ref viscous_layers_anchor "Viscous Layers 2D"
hypotheses allow creation of layers of highly stretched
elements near mesh boundary, which is beneficial for high quality
viscous computations.</li>
<li>\ref quadratic_mesh_anchor "Quadratic Mesh" hypothesis allows
generation of second order meshes.</li>
<li>\ref quadrangle_preference_anchor "Quadrangle Preference"
enables generation of quadrangles.</li>
</ul>
<b>Non Conform mesh allowed</b> hypothesis allows to generate non-conform
meshes (that is, meshes having some edges ending on an edge or face of
adjacent elements).
\anchor quadratic_mesh_anchor
<h2>Quadratic Mesh</h2>
Quadratic Mesh hypothesis allows to build a quadratic mesh (whose
edges are not straight but curved lines and can be defined by three
points: first, middle and last instead of an ordinary two).
See \ref adding_quadratic_elements_page
for more information about quadratic meshes.
\anchor propagation_anchor
<h2>Propagation of 1D Hypothesis on opposite edges</h2>
<b>Propagation of 1D Hypothesis on opposite edges</b> allows to propagate a
hypothesis onto an opposite edge. If a local hypothesis and
propagation are defined on an edge of a quadrangular face, the
opposite edge will have the same hypothesis, unless another hypothesis
has been locally defined on the opposite edge.
<br><b>See Also</b> a sample TUI Script of a
<b>Propagation of 1D Hypothesis on opposite edges</b> allows to mesh
opposite sides of a quadrangle face, and of other adjacent quadrangles,
using the same hypothesis assigned to one edge only.<br>
Thus you define a sub-mesh on an edge where you define 1D meshing
parameters and a \b Propagation hypothesis. These local meshing
parameters will be propagated via opposite sides of quadrangles to the
whole geometry, or till an edge with other local meshing parameters.
This hypothesis can be taken into account by
\ref a1d_algos_anchor "Wire Discretization" and
\ref a1d_algos_anchor "Composite Side Discretization" algorithms.
<b>See Also</b> a sample TUI Script of a
\ref tui_propagation "Propagation hypothesis" operation
\anchor propagofdistribution_anchor
@ -48,25 +55,18 @@ opposite edge will have the same number of nodes and the same
relations between segment lengths, unless another hypothesis
has been locally defined on the opposite edge.
<br><b>See Also</b> a sample TUI Script of a
This hypothesis can be taken into account by
\ref a1d_algos_anchor "Wire Discretization" and
\ref a1d_algos_anchor "Composite Side Discretization" algorithms.
<b>See Also</b> a sample TUI Script of a
\ref tui_propagation "Propagation hypothesis" operation
\anchor quadrangle_preference_anchor
<h2>Quadrangle Preference</h2>
This additional hypothesis can be used together with 2D triangulation algorithms.
It allows 2D triangulation algorithms to build quadrangular meshes.
When used with "Quadrangle (Mapping)" meshing algorithm, that is obsolete
since introducing \ref hypo_quad_params_anchor "Quadrangle parameters"
hypothesis, this hypothesis has one restriction on its work: the total quantity of
segments on all four sides of the face must be even (divisible by 2).
\anchor viscous_layers_anchor
<h2>Viscous Layers and Viscous Layers 2D</h2>
<b>Viscous Layers</b> and <b>Viscous Layers 2D </b> additional
hypotheses can be used together with either some 3D algorithms, for example
hypotheses can be used by several 3D algorithms, for example
Hexahedron(i,j,k), or 2D algorithms, for example Triangle
(MEFISTO), correspondingly. These hypotheses allow creation of layers
of highly stretched elements, prisms in 3D and quadrilaterals in 2D,
@ -144,4 +144,33 @@ computations.
<br><b>See also</b> a sample TUI script of a \ref tui_viscous_layers
"Viscous layers construction".
\anchor quadratic_mesh_anchor
<h2>Quadratic Mesh</h2>
Quadratic Mesh hypothesis allows to build a quadratic mesh (in which
links between element nodes are not straight but curved lines due to
presence of an additional midside node).
This 1D hypothesis can be taken into account by
\ref a1d_algos_anchor "Wire Discretization" and
\ref a1d_algos_anchor "Composite Side Discretization" algorithms. To
make a quadratic mesh assign this hypothesis at
\ref constructing_meshes_page "mesh construction".
See \ref adding_quadratic_elements_page
for more information about quadratic meshes.
\anchor quadrangle_preference_anchor
<h2>Quadrangle Preference</h2>
This additional hypothesis can be used together with 2D triangulation algorithms.
It allows 2D triangulation algorithms to build quadrangular meshes.
When used with "Quadrangle (Mapping)" meshing algorithm, that is obsolete
since introducing \ref hypo_quad_params_anchor "Quadrangle parameters"
hypothesis, this hypothesis has one restriction on its work: the total quantity of
segments on all four sides of the face must be even (divisible by 2).
*/

View File

@ -3,27 +3,33 @@
\page basic_meshing_algos_page Basic meshing algorithms
\n The MESH module contains a set of meshing algorithms, which are
used for meshing entities (1D, 2D, 3D) composing geometrical objects.
used for meshing entities (1D, 2D, 3D sub-shapes) composing
geometrical objects.
An algorithm represents either an implementation of a certain meshing
technique or a interface to a whole meshing program generating elements
of several dimensions.
<ul>
<li>For meshing of 1D entities (<b>edges</b>):</li>
\anchor a1d_algos_anchor
<ul>
<li>Wire Discretization meshing algorithm - splits an edge into a
number of mesh segments following an 1D hypothesis.</li>
<li>Composite Side Discretization algorithm - allows to apply an 1D
hypothesis to a whole side of a geometrical face even if it is
composed of several edges provided that they form C1 curve, have the
same hypotheses assigned and form one side in all faces of the main
shape of a mesh.</li>
<li><em>Wire Discretization</em> meshing algorithm - splits an edge into a
number of mesh segments following an 1D hypothesis.
</li>
<li><em>Composite Side Discretization</em> algorithm - allows to apply an 1D
hypothesis to a whole side of a geometrical face even if it is
composed of several edges provided that they form C1 curve and form
one side in all faces of the main shape.</li>
</ul>
<li>For meshing of 2D entities (<b>faces</b>):</li>
<ul>
<li>Triangle meshing algorithms (Mefisto) - Faces are split into triangular elements.</li>
<li>Quadrangle meshing algorithm (Mapping) - quadrilateral Faces are split into
quadrangular elements.</li>
<li><em>Triangle (Mefisto)</em> meshing algorithm - splits faces
into triangular elements.</li>
<li><em>Quadrangle (Mapping)</em> meshing algorithm - splits faces
into quadrangular elements.</li>
</ul>
\image html image123.gif "Example of a triangular 2D mesh"
@ -33,12 +39,12 @@ quadrangular elements.</li>
<li>For meshing of 3D entities (<b>solid objects</b>):</li>
<ul>
<li>Hexahedron meshing algorithm (i,j,k) - 6-sided Solids are split into
hexahedral (cubic) elements.</li>
<li>\subpage cartesian_algo_page</li>
- internal parts of Solids are split into hexahedral elements forming a
Cartesian grid; polyhedra and other types of elements are generated
where the geometrical boundary intersects Cartesian cells.</li>
<li><em>Hexahedron (i,j,k)</em>meshing algorithm - 6-sided solids are
split into hexahedral (cuboid) elements.</li>
<li>\subpage cartesian_algo_page "Body Fitting" meshing
algorithm - solids are split into hexahedral elements forming
a Cartesian grid; polyhedra and other types of elements are generated
where the geometrical boundary intersects Cartesian cells.</li>
</ul>
\image html image125.gif "Example of a tetrahedral 3D mesh"
@ -47,8 +53,8 @@ where the geometrical boundary intersects Cartesian cells.</li>
</ul>
Some 3D meshing algorithms, such as Hexahedron(i,j,k) and some
commercial ones, also can generate 3D meshes from 2D meshes, working without
geometrical objects.
commercial ones, also can generate 3D meshes from 2D meshes, working
without geometrical objects.
There is also a number of more specific algorithms:
<ul>

View File

@ -2,13 +2,16 @@
\page building_compounds_page Building Compounds
\n Compound Mesh is a combination of several meshes.
\n Compound Mesh is a combination of several meshes. All elements and
groups present in input meshes are present in the compound
mesh. Neither geometry nor hypotheses of initial meshes are used by
the compound mesh.
<em>To Build a compound:</em>
\par
From the \b Mesh menu select <b>Build Compound</b> or click <em>"Build
Compound Mesh"</em> button in the toolbar.
Compound Mesh"</em> button in the toolbar.
\image html image161.png
<center><em>"Build Compound Mesh" button</em></center>
@ -20,33 +23,33 @@ The following dialog box will appear:
\par
<ul>
<li>\b Name - allows selecting the name of the resulting \b Compound.</li>
<li>\b Meshes - allows selecting the meshes which will be
concatenated. They can be chosen in the Object Browser while holding
<li>\b Name - allows selecting the name of the resulting \b Compound mesh.</li>
<li>\b Meshes - allows selecting the meshes which will be
concatenated. They can be chosen in the Object Browser while holding
\b Ctrl button.</li>
<li><b>Processing identical groups</b> - allows selecting the method
of processing the namesake existing on the united meshes.
<li><b>Processing identical groups</b> - allows selecting the method
of processing the namesake groups existing in the united meshes.
\n They can be either</li>
<ul>
<li>\b United - all elements of Group1 on Mesh_1 and Group1 on Mesh_2
become the elements of Group1 on the Compound_Mesh, or</li>
<li>\b Renamed - Group1 on Mesh_1 becomes Group1_1 and Group1 on Mesh_2
becomes Group1_2. See \ref grouping_elements_page "Creating Groups"
for more information about groups.</li>
</ul>
<li><b>Create common groups for initial meshes</b> checkbox permits to
automatically create groups of all elements of the same type
(nodes, edges, faces and volumes) for the resulting mesh from the
elements
of the initial meshes.
</li>
<li>You can simply unite meshes or choose to <b>Merge coincident nodes
and elements</b>, in which case it is possible to define the \b Tolerance
for this operation.</li>
<ul>
<li>\b United - all elements of Group1 of Mesh_1 and Group1 of Mesh_2
become the elements of Group1 of the Compound_Mesh, or</li>
<li>\b Renamed - Group1 of Mesh_1 becomes Group1_1 and Group1 of Mesh_2
becomes Group1_2.</li>
</ul>
See \ref grouping_elements_page "Creating Groups" for more information
about groups.
<li><b>Create common groups for initial meshes</b> check-box permits to
automatically create groups corresponding to every initial mesh.
</li>
<li>You can choose to additionally
\ref merging_nodes_page "Merge coincident nodes"
\ref merging_elements_page "and elements" in the compound mesh, in
which case it is possible to define the \b Tolerance for this
operation.</li>
</ul>
\image html image160.gif "Example of a compound of two meshed cubes"
<b>See Also</b> a sample
<b>See Also</b> a sample
\ref tui_building_compound "TUI Example of building compounds."
*/

View File

@ -2,14 +2,67 @@
\page constructing_meshes_page Constructing meshes
\n Construction of a mesh on some geometry consists of:
To create a mesh on geometry, at first you create a mesh object by choosing
- a geometrical shape produced in the Geometry module (<em>main shape</em>);
- <em>meshing parameters</em>, including
- \ref basic_meshing_algos_page "meshing algorithms" and
- \ref about_hypo_page "hypotheses" specifying constraints to be
taken into account by chosen meshing algorithms.
Then you already can launch mesh generation by invoking \ref
compute_anchor "Compute" command.
\note Sometimes \a hypotheses term is used to refer to both algorithms
and hypotheses.
Generation of the mesh on the geometry is performed in the bottom-up
flow: nodes on vertices are created first, then edges are divided into
segments using nodes on vertices; the segments of the edges is then
used while meshing faces; then the mesh of the faces is used while meshing
solids. This automatically assures the conformity of the mesh.
You are to choose a meshing algorithm for every dimension of
sub-shapes up to the highest dimension you desire to generate. Note
that some algorithms generate elements of several dimensions while
others, of only one. But it's not necessary to define meshing
parameters for all dimensions at once; you can start from 1D
meshing parameters only, compute the 1D mesh, then define 2D meshing
parameters and compute the 2D mesh (note that 1D mesh won't be
re-computed).
An algorithm of a certain dimension chosen at mesh creation is applied
to discretize every sub-shape of this dimension. But you can
specify a different algorithm or hypothesis to be applied to one or
a group of sub-shapes by creating a \ref constructing_submeshes_page
"sub-mesh". You can specify no algorithms at all at mesh object
creation and specify the meshing parameters on sub-meshes only; then
only sub-shapes for which you defined an algorithm and a needed
hypothesis (if any) will be discretized.
\n Construction of a mesh on some geometry includes at least two (mesh
creation and computing) of the following steps:
<ul>
<li> \ref create_mesh_anchor "Creating of a mesh object"</li>
<li> \ref evaluate_anchor "Evaluating mesh size" (optional)</li>
<li> \ref preview_anchor "Previewing the mesh" (optional)</li>
<li> \ref submesh_order_anchor "Changing sub-mesh priority" (optional)</li>
<li> \ref compute_anchor "Computing the mesh"</li>
<li> \ref edit_anchor "Editing the mesh" (optional)</li>
<li> \ref create_mesh_anchor "Creation of a mesh object" where you
can specify meshing parameters to apply to all sub-shapes of the
main shape.</li>
<li> \ref constructing_submeshes_page "Creation of sub-meshes"
(optional) where you can specify meshing parameters to apply to
selected sub-shapes.</li>
<li> \ref evaluate_anchor "Evaluating mesh size" (optional) can be
used to know approximate number of elements before actual generation
of them.</li>
<li> \ref preview_anchor "Previewing the mesh" (optional) can be
used to generate mesh of only lower dimension(s) in order to
visually estimate it before full mesh generation, which can be much
longer.</li>
<li> \ref submesh_order_anchor "Changing sub-mesh priority"
(optional) can be useful if there are concurrent sub-meshes
defined.</li>
<li> \ref compute_anchor "Computing the mesh" uses defined meshing
parameters to generate mesh elements.</li>
<li> \ref edit_anchor "Editing the mesh" (optional) can be used to
\ref modifying_meshes_page "modify" mesh of lower dimension before
\ref compute_anchor "computing" elements of upper dimension.</li>
</ul>
\anchor create_mesh_anchor
@ -44,41 +97,48 @@
"Create mesh" dialog box contains several tab pages titled \b 3D,
\b 2D, \b 1D and \b 0D. The title of each page reflects the
dimension of the CAD model (geometry) the algorithms listed on
dimension of the sub-shapes the algorithms listed on
this page affect and the maximal dimension of elements the algorithms
generate. For example, \b 3D page lists the algorithms that affect
3D geometrical objects (solids) and generate 3D mesh elements
3D sub-shapes (solids) and generate 3D mesh elements
(tetrahedra, hexahedra etc.)
As soon as you have selected an algorithm, you can create (or
select already created) a hypothesis. A set of accessible
hypotheses includes only hypotheses the selected algorithm can take
into account.
\note
- Some page(s) can be disabled if the source geometrical
- Some page(s) can be disabled if the geometrical
object does not include shapes (sub-shapes) of the corresponding
dimension(s). For example, if the input object is a geometrical face,
\b 3D page is disabled.
- Some algorithms affect the geometry of several dimensions,
i.e. "1D-2D" or "1D-2D-3D". If such an algorithm is selected by the
user, the dialog box pages related to the corresponding lower level
dimensions are disabled.
i.e. 1D+2D or 1D+2D+3D. If such an algorithm is selected, the
dialog box pages related to the corresponding lower dimensions are
disabled.
- \b 0D page does not refer to the 0D elements, but to 0D
geometry (vertices). Mesh module does not provide algorithms that
produce 0D elements. Currently \b 0D page provides only one
algorithm "Segments around vertex" that allows specyfying the required
algorithm "Segments around vertex" that allows specifying the required
size of mesh edges about the selected vertex (or vertices).
For example, you need to mesh a 3D object.
First, type the name of your mesh in the \b Name box, by default,
it is "Mesh_1". Then select the geometrical object you wish to
mesh in the Object Browser and click "Select" button near \b Geometry
field (if the name of the object has not yet appeared in \b Geometry field).
First, you can change a default name of your mesh in the \b Name
box. Then check that a selected geometrical object, whose name is
shown in \b Geometry field, is that you wish to mesh; if not, click
the right object in the Object Browser. Click "Select" button
near \b Geometry field if the name of the object has not yet
appeared in \b Geometry field.
<center>
\image html image120.png
<em>"Select" button</em>
</center>
Now you can define 3D Algorithm and 3D Hypotheses, which will be
applied to the solids of your geometrical object. Click the <em>"Add
Hypothesis"</em> button to add a hypothesis.
applied to discretize the solids of your geometrical object using
3D elements. Click the <em>"Add Hypothesis"</em> button to add a hypothesis.
<center>
\image html image121.png
<em>"Add Hypothesis" button</em>
@ -117,8 +177,8 @@
choice of hypotheses and lower dimension algorithms depends on
the higher dimension algorithm.
If you wish you can select different algorithms and/or hypotheses
for meshing some parts of your CAD model by \ref constructing_submeshes_page.
If you wish you can select other algorithms and/or hypotheses
for meshing some sub-shapes of your CAD model by \ref constructing_submeshes_page.
Some algorithms generate mesh of several dimensions, while others
produce mesh of only one dimension. In the latter case there must
@ -141,30 +201,35 @@
<li>a reference to the geometrical object on the basis of
which the mesh has been constructed (\a mechanic);</li>
<li><b>Applied hypotheses</b> folder containing the references
to the hypotheses applied at the construction of the mesh;</li>
to the hypotheses chosen at the construction of the mesh;</li>
<li><b>Applied algorithms</b> folder containing the references
to the algorithms applied at the construction of the mesh.</li>
to the algorithms chosen at the construction of the mesh.</li>
</ul>
There is an alternative way to assign Algorithms and Hypotheses by
clicking <b>Assign a set of hypotheses</b> button and selecting among
pre-defined sets of hypotheses. In addition to the standard
pre-defined sets of algorithms and hypotheses. In addition to the built-in
sets of hypotheses, it is possible to create custom sets by editing
CustomMeshers.xml file located in the home directory. CustomMeshers.xml
file must describe sets of hypotheses in the
same way as ${SMESH_ROOT_DIR}/share/salome/resources/smesh/StdMeshers.xml
file does (sets of hypotheses are enclosed between <hypotheses-set-group>
tags).
<center>
\image html hypo_sets.png
List of sets of hypotheses. Tag <em>[custom]</em> is
automatically added to the sets defined by the user.
\note \a "Automatic" in the names of predefined sets of
hypotheses came from previous versions of SALOME where
\ref automatic_length_anchor "Automatic Length" hypothesis
was included in these sets, and not that these sets are suitable for
meshing any geometry.
</center>
\note
- \a "Automatic" in the names of predefined sets of
hypotheses came from previous versions of SALOME where
\ref automatic_length_anchor "Automatic Length" hypothesis
was included in these sets, and not that these sets are suitable for
meshing any geometry.
- The list of sets of hypotheses can be shorter than in the
above image depending on the geometry dimension.
</li>
</ol>
@ -222,31 +287,31 @@ it is possible to change the priority of their computation, i.e. to
change the priority of applying algorithms to the shared sub-shapes of
the Mesh shape.
<em>To change submesh priority:</em>
<em>To change sub-mesh priority:</em>
Choose "Change submesh priority" from the Mesh menu or a pop-up
menu. The opened dialog shows a list of submeshes in the order of
Choose "Change sub-mesh priority" from the Mesh menu or a pop-up
menu. The opened dialog shows a list of sub-meshes in the order of
their priority.
There is an example of submesh order modifications taking a Mesh created on a Box
There is an example of sub-mesh order modifications taking a Mesh created on a Box
shape. The main Mesh object:
<ul>
<li><i>1D</i> <b>Wire discretisation</b> with <b>Number of Segments</b>=20</li>
<li><i>2D</i> <b>Triangle (Mefisto)</b> with Hypothesis<b>Max Element Area</b>
</li>
</ul>
The first submesh object <b>Submesh_1</b> created on <b>Face_1</b> is:
The first sub-mesh <b>Submesh_1</b> created on <b>Face_1</b> is:
<ul>
<li><i>1D</i> <b>Wire discretisation</b> with <b>Number of Segments</b>=4</li>
<li><i>2D</i> <b>Triangle (Mefisto)</b> with Hypothesis <b>MaxElementArea</b>=1200</li>
</ul>
The second submesh object <b>Submesh_2</b> created on <b>Face_2</b> is:
The second sub-mesh <b>Submesh_2</b> created on <b>Face_2</b> is:
<ul>
<li><i>1D</i> <b>Wire discretisation</b> with <b>Number of Segments</b>=8</li>
<li><i>2D</i> <b>Triangle (Mefisto)</b> with Hypothesis <b>MaxElementArea</b>=1200</li>
</ul>
And the last submesh object <b>Submesh_3</b> created on <b>Face_3</b> is:
And the last sub-mesh <b>Submesh_3</b> created on <b>Face_3</b> is:
<ul>
<li><i>1D</i> <b>Wire discretisation</b> with <b>Number of Segments</b>=12</li>
<li><i>2D</i> <b>Triangle (Mefisto)</b> with Hypothesis <b>MaxElementArea</b>=1200</li>
@ -254,7 +319,7 @@ And the last submesh object <b>Submesh_3</b> created on <b>Face_3</b> is:
The sub-meshes become concurrent if they share sub-shapes that can be
meshed with different algorithms (or different hypotheses). In the
example, we have three submeshes with concurrent algorithms, because
example, we have three sub-meshes with concurrent algorithms, because
they have different hypotheses.
The first mesh computation is made with:
@ -284,15 +349,15 @@ As we can see, each mesh computation has a different number of result
elements and a different mesh discretization on the shared edges (the edges
that are shared between <b>Face_1</b>, <b>Face_2</b> and <b>Face_3</b>)
Additionally, submesh priority (the order of applied algorithms) can
Additionally, sub-mesh priority (the order of applied algorithms) can
be modified not only in a separate dialog box, but also in
the <b>Preview</b>. This helps to preview different mesh results,
modifying the order of submeshes.
modifying the order of sub-meshes.
<center>
\image html mesh_order_preview.png
<em>"Preview with submesh priority list box"</em></center>
<em>"Preview with sub-mesh priority list box"</em></center>
If there are no concurrent submeshes under the Mesh object, the user
If there are no concurrent sub-meshes under the Mesh object, the user
will see the following information.
<center>
\image html mesh_order_no_concurrent.png
@ -315,7 +380,7 @@ click "Compute" button of the toolbar.
After the mesh computation finishes, the Mesh Computation information
box appears. If you close this box and click "Compute" button again,
without previously changing hypotheses and/or algorithms, the mesh is
without previously changing meshing parameters, the mesh is
NOT re-computed and the Mesh Computation information box with
the same contents is shown. (To fully re-compute the mesh, invoke \ref
clear_mesh_anchor "Clear Mesh Data" command before).
@ -325,12 +390,13 @@ of different types in the mesh.
\image html meshcomputationsucceed.png
\anchor meshing_failed_anchor
If the mesh computation failed, the information about the cause of the
failure is provided in \b Errors table.
\image html meshcomputationfail.png
After you select the error, <b>Show Sub-shape</b> button allows
After you select an error, <b>Show Sub-shape</b> button allows
visualizing in magenta the geometrical entity that causes the error.
\image html failed_computation.png
@ -338,8 +404,8 @@ visualizing in magenta the geometrical entity that causes the error.
Sub-shape</b> button</em>
<b>Publish Sub-shape</b> button publishes the sub-shape, whose meshing
has failed, in GEOM component as a child of the mesh geometry, which
allows analyzing the problem geometry and creating a submesh on it in
has failed, in the Geometry component as a child of the main shape, which
allows analyzing the problematic geometry and creating a sub-mesh on it in
order to locally tune the hypotheses.
If the failure is caused by an invalid input mesh and the algorithm has

View File

@ -2,13 +2,20 @@
\page constructing_submeshes_page Constructing sub-meshes
Sub-mesh is a mesh on a geometrical sub-object (sub-shape) used to assign
different meshing algorithms and/or hypotheses than the algorithms and
hypotheses assigned to the parent mesh on the parent geometrical
object, that allows getting a local mesh refinement.
By purpose, the sub-mesh is an object used to assign to a sub-shape
different meshing parameters than those assigned to the main shape.
A sub-shape to create a sub-mesh on should be retrieved from the shape
of the parent mesh in one of the following ways: <ul>
Structurally, the sub-mesh is a mesh on a certain sub-shape, or a group of
sub-shapes, possibly generated using different meshing algorithms
and/or hypotheses than those used to generate the mesh on other
sub-shapes.
Creation of a sub-mesh allows to control individually meshing of a
certain sub-shape, thus allowing to get mesh locally coarser or finer, to get
elements of different types in the same mesh etc.
A sub-shape to create a sub-mesh on should be retrieved from the main shape
in one of the following ways: <ul>
<li> In Geometry module, via <em>New Entity > Explode</em> menu.</li>
<li> In Geometry module, by creation of a group (<em>New Entity >
Group > Create Group</em> menu).</li>
@ -16,33 +23,55 @@ of the parent mesh in one of the following ways: <ul>
\ref subshape_by_mesh_elem "selecting a mesh element" generated on a
sub-shape of interest. This way is accessible if the mesh is
already computed.</li>
<li> In Mesh module, by clicking <em>Publish Sub-shape</em> button in a
dialog showing \ref meshing_failed_anchor "meshing errors".</li>
</ul>
If a geometrical sub-object belongs to several geometrical objects
having different meshes or sub-meshes, it will be meshed with the
hypotheses of a sub-mesh of a lower dimension.<br>
For example, a face of a box is meshed with a sub-mesh using algorithms
and hypotheses other than the parent mesh on the whole box. The face
and the box share four edges, which will be meshed with algorithms and
hypotheses of the sub-mesh on the face, because the face is a 2D object
while the box is a 3D object. <br>
If the dimensions are the same, an arbitrary algorithm/hypothesis
will be used. This means that an edge shared by two faces each having
its own different sub-mesh, will be meshed using algorithms and
hypotheses of any of the two, chosen randomly. This indeterminacy can
be fixed by defining \ref submesh_order_anchor "Sub-mesh priority". The
default sub-meshes priority is such that multi-dimensional algorithms
are processed first.
<br>
Internally, definition of meshing parameters to apply for
discretization of a certain sub-shape, for example an edge of a
compound of solids, starts from searching an algorithm, 1D as for the
edge. The following sub-shapes are sequentially checked for presence
of a sub-mesh where 1D algorithm is assigned:
<ul>
<li> the \b edge it-self</li>
<li> <b>groups of edges</b> containing the edge, if any</li>
<li> \b wires sharing the edge</li>
<li> \b faces sharing the edge</li>
<li> <b>groups of faces</b> sharing the edge, if any</li>
<li> \b shells sharing the edge</li>
<li> \b solids sharing the edge</li>
<li> <b>groups of solids</b> sharing the edge, if any</li>
<li> the <b>main shape</b></li>
</ul>
(This sequence of sub-shapes defines priority of sub-meshes. Thus more
local, i.e. assigned to sub-shape of lower dimension, algorithms and
hypotheses have higher priority during the search of hypotheses to
apply.)
As soon as an 1D algorithm is found the search stops and the same
sequence of sub-shapes is checked to find a main and additional 1D
hypotheses the found 1D algorithm can take into account.
The multi-dimensional algorithms have higher priority than
uni-dimensional algorithms if they are assigned to sub-meshes of the
same priority.
If meshing parameters are defined on sub-meshes of the same priority,
for example different 1D hypotheses are assigned to two faces sharing
an edge, an arbitrary algorithm/hypothesis will be used for
meshing. This indeterminacy can be fixed by
\ref submesh_order_anchor "Changing" mutual priority of such
concurrent sub-meshes.
\n Construction of a sub-mesh consists of:
<ul>
<li>Selecting a mesh which will encapsulate your sub-mesh</li>
<li>Selecting a geometrical object for meshing</li>
<li>Applying one or several previously described
<li>Selecting a sub-shape for meshing</li>
<li>Applying one or several
\ref about_hypo_page "hypotheses" and
\ref basic_meshing_algos_page "meshing algorithms" which will be used
at computation of this sub-mesh</li>
for discretization of this sub-shape.</li>
</ul>
<br><em>To construct a sub-mesh:</em>
@ -64,8 +93,8 @@ The following dialog box will appear:
\par
It allows to define the \b Name, the parent \b Mesh and the \b
Geometry (e.g. a face if the parent mesh has been built on box) of the
sub-mesh. You can select meshing algorithms and hypotheses in the same way as
in \ref constructing_meshes_page "Create mesh" menu.
sub-mesh. You can define meshing algorithms and hypotheses in the same way as
in \ref constructing_meshes_page "Create mesh" dialog.
\par
\anchor subshape_by_mesh_elem

View File

@ -4,24 +4,34 @@
\image html a-viewgeneral.png
\n \b MESH module of SALOME is destined for:
\n \b Mesh module of SALOME is destined for:
<ul>
<li>\subpage about_meshes_page "meshing geometrical models"
previously created or imported by the Geometry component; </li>
<li>\subpage about_meshes_page "creating meshes" in different ways:
- by meshing geometrical models previously created or imported by the
Geometry component;
- bottom-up, using \ref modifying_meshes_page "mesh edition"
operations, especially \ref extrusion_page "extrusion" and \ref
revolution_page "revolution";
- by generation of the 3D mesh from the 2D mesh (the latter can be
either \ref importing_exporting_meshes_page "imported" or manually
created);
</li>
<li>\ref importing_exporting_meshes_page "import and export of meshes in various formats";</li>
<li>\subpage viewing_meshes_overview_page "viewing created meshes" in
the VTK viewer;</li>
<li>\subpage grouping_elements_page "creating groups of mesh elements";</li>
<li>applying to meshes \subpage quality_page "Quality Controls",
allowing to highlight important elements;
<li>filtering sub-sets of mesh entities (nodes elements) using
\subpage filters_page "Filters" functionality;</li>
<li>\subpage modifying_meshes_page "modifying meshes" with a vast
array of dedicated operations;</li>
array of dedicated operations;</li>
<li>\subpage grouping_elements_page "creating groups of mesh elements";</li>
<li>filtering mesh entities (nodes or elements) using
\subpage filters_page "Filters" functionality for \ref
grouping_elements_page "creating groups" and applying \ref
modifying_meshes_page "mesh modifications";</li>
<li>\subpage viewing_meshes_overview_page "viewing meshes" in
the VTK viewer;</li>
<li>applying to meshes \subpage quality_page "Quality Controls",
allowing to highlight important elements;
<li>various \subpage measurements_page "measurements" of the mesh objects.
</ul>
It is possible to easily set parameters via the variables predefined in
When setting parameters of operations, it is possible to use the variables predefined in
\subpage using_notebook_mesh_page "Salome notebook".
Mesh module preferences are described in the \subpage mesh_preferences_page section of SALOME Mesh Help.

View File

@ -1870,6 +1870,18 @@ int SMESH_Mesh::NbSubMesh() const throw(SALOME_Exception)
return _myMeshDS->NbSubMesh();
}
//================================================================================
/*!
* \brief Returns number of meshes in the Study, that is supposed to be
* equal to SMESHDS_Document::NbMeshes()
*/
//================================================================================
int SMESH_Mesh::NbMeshes() const // nb meshes in the Study
{
return _myDocument->NbMeshes();
}
//=======================================================================
//function : IsNotConformAllowed
//purpose : check if a hypothesis alowing notconform mesh is present

View File

@ -295,6 +295,8 @@ class SMESH_EXPORT SMESH_Mesh
int NbGroup() const { return _mapGroup.size(); }
int NbMeshes() const; // nb meshes in the Study
SMESH_Group* AddGroup (const SMDSAbs_ElementType theType,
const char* theName,
int& theId,
@ -353,7 +355,6 @@ protected:
int _groupId; // id generator for group objects
int _nbSubShapes; // initial nb of subshapes in the shape to mesh
bool _isShapeToMesh;// set to true when a shape is given (only once)
//std::list <SMESH_subMesh*> _subMeshesUsingHypothesisList;
SMESHDS_Document * _myDocument;
SMESHDS_Mesh * _myMeshDS;
SMESH_Gen * _gen;

View File

@ -327,7 +327,7 @@ protected:
int _Id;
std::map < int, SMESH_subMesh * >_mapDepend;
bool _dependenceAnalysed;
bool _dependenceAnalysed;
std::vector< SMESH_subMesh * > _ancestors;
SMESH_Algo * _algo; // the algorithm found by last *StateEngine() call

View File

@ -474,8 +474,9 @@ SMESH::SMESH_Hypothesis_ptr SMESH_Gen_i::createHypothesis(const char* theHypName
myHypothesis_i = aCreator->Create(myPoa, GetCurrentStudyID(), &myGen);
if (myHypothesis_i)
{
myHypothesis_i->SetLibName(aPlatformLibName.c_str()); // for persistency assurance
myHypCreatorMap[ myHypothesis_i->GetName() ] = aCreator;
myHypothesis_i->SetLibName( aPlatformLibName.c_str() ); // for persistency assurance
CORBA::String_var hypName = myHypothesis_i->GetName();
myHypCreatorMap[ hypName.in() ] = aCreator;
// activate the CORBA servant of hypothesis
hypothesis_i = myHypothesis_i->_this();
@ -2399,7 +2400,6 @@ SMESH_Gen_i::ConcatenateCommon(const SMESH::mesh_array& theMeshesArray,
typedef map<int, int> TIDsMap;
typedef list<SMESH::SMESH_Group_var> TListOfNewGroups;
typedef map< pair<string, SMESH::ElementType>, TListOfNewGroups > TGroupsMap;
typedef std::set<SMESHDS_GroupBase*> TGroups;
TPythonDump* pPythonDump = new TPythonDump;
TPythonDump& aPythonDump = *pPythonDump; // prevent dump of called methods
@ -2416,7 +2416,7 @@ SMESH_Gen_i::ConcatenateCommon(const SMESH::mesh_array& theMeshesArray,
TGroupsMap aGroupsMap;
TListOfNewGroups aListOfNewGroups;
SMESH_MeshEditor aNewEditor = ::SMESH_MeshEditor(&aLocMesh);
::SMESH_MeshEditor aNewEditor(&aLocMesh);
SMESH::ListOfGroups_var aListOfGroups = new SMESH::ListOfGroups();
// loop on meshes
@ -2525,6 +2525,8 @@ SMESH_Gen_i::ConcatenateCommon(const SMESH::mesh_array& theMeshesArray,
}
} //elems loop
aNewEditor.CrearLastCreated(); // forget the history
// copy orphan nodes
SMDS_NodeIteratorPtr itNodes = anInitMeshDS->nodesIterator();
while ( itNodes->more() )

View File

@ -275,21 +275,16 @@ static SALOMEDS::SObject_ptr publish(SALOMEDS::Study_ptr theStudy,
SO = aStudyBuilder->NewObjectToTag( theFatherObject, theTag );
// define the next tag after given one in the data tree to insert SObject
std::string anEntry;
int last2Pnt_pos = -1;
int tagAfter = -1;
CORBA::String_var entry;
SALOMEDS::SObject_wrap curObj;
SALOMEDS::UseCaseIterator_wrap anUseCaseIter = useCaseBuilder->GetUseCaseIterator(theFatherObject);
for ( ; anUseCaseIter->More(); anUseCaseIter->Next() ) {
curObj = anUseCaseIter->Value();
entry = curObj->GetID();
anEntry = entry.in();
last2Pnt_pos = anEntry.rfind( ":" );
tagAfter = atoi( anEntry.substr( last2Pnt_pos+1 ).c_str() );
if ( tagAfter > theTag ) {
objAfter = curObj;
break;
if ( theFatherObject->GetLastChildTag() > theTag )
{
SALOMEDS::UseCaseIterator_wrap anUseCaseIter = useCaseBuilder->GetUseCaseIterator(theFatherObject);
for ( ; anUseCaseIter->More(); anUseCaseIter->Next() ) {
curObj = anUseCaseIter->Value();
if ( curObj->Tag() > theTag ) {
objAfter = curObj;
break;
}
}
}
}
@ -534,32 +529,6 @@ SALOMEDS::SComponent_ptr SMESH_Gen_i::PublishComponent(SALOMEDS::Study_ptr theSt
return father._retn();
}
//=============================================================================
/*!
* findMaxChildTag [ static internal ]
*
* Finds maximum child tag for the given object
*/
//=============================================================================
static long findMaxChildTag( SALOMEDS::SObject_ptr theSObject )
{
long aTag = 0;
if ( !theSObject->_is_nil() ) {
SALOMEDS::Study_var aStudy = theSObject->GetStudy();
if ( !aStudy->_is_nil() ) {
SALOMEDS::ChildIterator_wrap anIter = aStudy->NewChildIterator( theSObject );
for ( ; anIter->More(); anIter->Next() ) {
SALOMEDS::SObject_wrap anSO = anIter->Value();
long nTag = anSO->Tag();
if ( nTag > aTag )
aTag = nTag;
}
}
}
return aTag;
}
//=======================================================================
//function : PublishMesh
//purpose :
@ -584,7 +553,7 @@ SALOMEDS::SObject_ptr SMESH_Gen_i::PublishMesh (SALOMEDS::Study_ptr theStudy,
return aMeshSO._retn();
// Find correct free tag
long aTag = findMaxChildTag( father.in() );
long aTag = father->GetLastChildTag();
if ( aTag <= GetAlgorithmsRootTag() )
aTag = GetAlgorithmsRootTag() + 1;
else

View File

@ -161,6 +161,11 @@ SMESH_Mesh_i::~SMESH_Mesh_i()
}
_mapHypo.clear();
// clear cashed shapes if no more meshes remain; (the cash is blame,
// together with publishing, of spent time increasing in issue 22874)
if ( _impl->NbMeshes() == 1 )
_gen_i->GetShapeReader()->ClearClientBuffer();
delete _editor; _editor = NULL;
delete _previewEditor; _previewEditor = NULL;
delete _impl; _impl = NULL;

View File

@ -520,7 +520,8 @@ class smeshBuilder(object, SMESH._objref_SMESH_Gen):
#return self.IsEmbeddedMode()
return SMESH._objref_SMESH_Gen.IsEmbeddedMode(self)
## Sets the current study
## Sets the current study. Calling SetCurrentStudy( None ) allows to
# switch OFF automatic pubilishing in the Study of mesh objects.
# @ingroup l1_auxiliary
def SetCurrentStudy( self, theStudy, geompyD = None ):
#self.SetCurrentStudy(theStudy)
@ -601,14 +602,15 @@ class smeshBuilder(object, SMESH._objref_SMESH_Gen):
if error.comment: print "*** CreateMeshesFromGMF() errors:\n", error.comment
return Mesh(self, self.geompyD, aSmeshMesh), error
## Concatenate the given meshes into one mesh.
# @return an instance of Mesh class
## Concatenate the given meshes into one mesh. All groups of input meshes will be
# present in the new mesh.
# @param meshes the meshes to combine into one mesh
# @param uniteIdenticalGroups if true, groups with same names are united, else they are renamed
# @param mergeNodesAndElements if true, equal nodes and elements aremerged
# @param mergeNodesAndElements if true, equal nodes and elements are merged
# @param mergeTolerance tolerance for merging nodes
# @param allGroups forces creation of groups of all elements
# @param allGroups forces creation of groups corresponding to every input mesh
# @param name name of a new mesh
# @return an instance of Mesh class
def Concatenate( self, meshes, uniteIdenticalGroups,
mergeNodesAndElements = False, mergeTolerance = 1e-5, allGroups = False,
name = ""):
@ -1523,7 +1525,7 @@ class Mesh:
return self.mesh.SetMeshOrder(submeshes)
## Removes all nodes and elements
# @refresh if @c True, Object browser is automatically updated (when running in GUI)
# @param refresh if @c True, Object browser is automatically updated (when running in GUI)
# @ingroup l2_construct
def Clear(self, refresh=False):
self.mesh.Clear()
@ -1535,7 +1537,8 @@ class Mesh:
if refresh: salome.sg.updateObjBrowser(1)
## Removes all nodes and elements of indicated shape
# @refresh if @c True, Object browser is automatically updated (when running in GUI)
# @param refresh if @c True, Object browser is automatically updated (when running in GUI)
# @param geomId the ID of a sub-shape to remove elements on
# @ingroup l2_construct
def ClearSubMesh(self, geomId, refresh=False):
self.mesh.ClearSubMesh(geomId)