Salome HOME
Update PreCAD documentation
[modules/smesh.git] / doc / salome / gui / SMESH / input / blsurf_hypo.doc
index 03c0fc5946a986bff218a70739defc427d09856d..391c9a7b2e479b94bca983e93735f2d641199866 100644 (file)
@@ -4,6 +4,7 @@
 
 \n BLSURF Parameters hypothesis works only with <b>BLSURF</b> 2d
 algorithm. This algorithm is a commercial software.
+\n To get a licence, visit http://www.distene.com/corp/eval-distene.html
 
 <h1>General parameters</h1>
 
@@ -57,8 +58,14 @@ hyper-face.</li>
 
 <h1>Advanced parameters</h1>
 
+The notion of <i>diag</i> used in the descriptions means the diagonal of the bounding box of the 
+geometrical object to mesh.
+
 \image html blsurf_parameters_advanced.png
 
+<li><b>Verbosity level</b> - Defines the percentage of "verbosity" of
+BLSURF [0-100].</li>
+
 <li><b>Topology</b> - allows creation of a conform mesh on a shell of
 not sewed faces. 
 <ul>
@@ -67,37 +74,57 @@ not sewed faces.
   <li>"Pre-process" and "Pre-process++" allow the BLSURF software to
   pre-process the geometrical model to eventually produce a conform
   mesh. </li>
+  <li>"PreCAD" is an auxiliary CAD pre-processing module which has 
+  two main goals:
+  <ul>
+    <li> Complete missing or inadequate CAD-description.</li>
+    <li>Perform topology reconstruction and specific geometry 
+    enhancement for mesh generation.</li>
+  </ul>
+  This module requires a specific licence.
+  \n
+  The following PreCAD options are the most significant and important ones:
+  <ul>
+  <li><b>Merge Edges</b> - allows PreCAD to optimize the geometry by merging some
+  edges. Default is 0.</li>
+  <li><b>Remove nano edges</b> - allows PreCAD to optimize the geometry by removing 
+  the nano edges whenever possible. Default is 0.</li>
+  <li><b>Nano edge length</b> - gives the length below which an edge is considered as nano 
+  for the topology processing. See also the \b remove_nano_edges option. If unset, PreCAD
+  default value is \f$\mathrm{diag} \times 10^{-5}\f$.</li>
+  <li><b>Discard input topology</b> - computes the CAD topology from scratch, 
+  without considering the toplogical information contained in the original CAD
+  (Useful for iges files). Default is 0.</li>
+  </ul>
+  </li>
 </ul>
 
-<li><b>Verbosity level</b> - Defines the percentage of "verbosity" of
-BLSURF [0-100].</li>
+<li><b>ExportGMF</b> - saves the computed mesh into a GMF file (.mesh or .meshb).</li>
 
-<li><b>Add option</b> - provides the choice of multiple advanced
-options, which appear, if selected, in a table where it is possible to
-input the value of the option and to edit it later.</li>
+<li><b>Add option</b> - provides the choice of multiple PreCAD and BLSURF 
+advanced options, which appear, if selected, in a table where it is 
+possible to input the value of the option and to edit it later.</li>
 
-<li><b>Clear option</b> - removes the option selected in the table.
+<li><b>Clear option</b> - removes the option selected in the table.</li>
 
 </ul>
 
 \n
-The following options are commonly usable. The notion of <i>diag</i>
-used in the descriptions means
-the diagonal of the bounding box of the geometrical object to mesh.
+The following BLSURF options are commonly usable.
 
 <ul>
-<li><b>topo_eps1</b> (real) - is the tolerance level inside a CAD
-patch. By default is equal to <i>diag</i> � 10-4. This tolerance is used to
+<li>\b topo_eps1 (real) - is the tolerance level inside a CAD
+patch. By default is equal to \f$\mathrm{diag} \times 10^{-4}\f$. This tolerance is used to
 identify nodes to merge within one geometrical face when \b Topology
-option is to pre-process. Default is <i>diag</i>/10.0.</li>
+option is to pre-process.</li>
 
-<li><b>topo_eps2</b> (real) - is the tolerance level between two CAD
-patches. By default is equal to <i>diag</i> � 10-4. This tolerance is used to
+<li>\b topo_eps2 (real) - is the tolerance level between two CAD
+patches. By default is equal to \f$\mathrm{diag} \times 10^{-4}\f$. This tolerance is used to
 identify nodes to merge over different geometrical faces when
-\b Topology option is to pre-process. Default is <i>diag</i>/10.0.</li>
+\b Topology option is to pre-process.</li>
 
 <li>\b LSS (real) - is an abbreviation for "length of sub-segment". It is
-a maximal allowed length of a mesh edge. Default is 0.5.</li>
+a maximal allowed length of a mesh edge. Default is \f$0.5\f$.</li>
 
 <li>\b frontal (integer)
 <ul>
@@ -112,12 +139,11 @@ Default is 0.</li>
 interpolated value <i>v</i> between two points <i>P1</i> and <i>P2</i> on a
 curve. Let <i>h1</i> be the value at point <i>P1,</i> <i>h2</i> be the value at point
 <i>P2,</i> and <i>t</i> be a parameter varying from 0 to 1 when moving from <i>P1
-to</i> <i>P2</i> . 
+to</i> <i>P2</i>.
 <ul>
-<li>0 - the interpolation is linear: <i>v = h1 + t (h2 - h1 )</i></li>
-<li>1 - the interpolation is geometric: <i>v = h1 * pow( h2/h1, t)</i></li>
-<li>2 - the interpolation is sinusoidal: <i>v = (h1+h2)/2 +
-(h1-h2)/2*cos(PI*t)</i></li>
+<li>0 - the interpolation is linear: \f$v = h1 + t (h2 - h1 )\f$</li>
+<li>1 - the interpolation is geometric: \f$v = h1 \times \left( \frac{h1}{h2} \right)^{t}\f$</li>
+<li>2 - the interpolation is sinusoidal: \f$v = \frac{h1+h2}{2} + \frac{h1-h2}{2 \cdot \cos(\pi \cdot t)}\f$</li>
 </ul>
 Default is 0.</li>
 
@@ -125,7 +151,7 @@ Default is 0.</li>
 <li>\b hmean_flag (integer) - determines the computation of the average of several
 values:<ul>
 <li>-1 - the minimum is computed.</li>
-<li>0 or 2 - the arithmetic average computed.
+<li>0 or 2 - the arithmetic average is computed.
 <li>1 - the geometric average is computed.</li>
 </ul>
 Default is 0.</li>
@@ -149,8 +175,8 @@ split into 20 edges. Default is 0.0.</li>
 
 <li>\b eps_ends (real) - is used to detect the curves whose lengths are very
 small, which sometimes constitutes an error. A message is printed
-if<i> fabs(P2-P1) < eps_ends</i>, where <i>P1</i> and <i>P2</i> are the
-extremities of a curve. Default is <i>diag</i>/500.0.</li>
+if \f$\left|P2-P1\right| < eps\_ends\f$, where <i>P1</i> and <i>P2</i> are the
+extremities of a curve. Default is \f$\frac{\mathrm{diag}}{500.0}\f$.</li>
 
 <li>\b prefix (char) - is a prefix of the files generated by
 BLSURF. Default is "x".</li>
@@ -159,6 +185,35 @@ BLSURF. Default is "x".</li>
 files. Default is 1.</li>
 </ul>
 
+\n
+The following PreCAD options are commonly usable. 
+<ul>
+<li>\b closed_geometry (int) - describes whether the working geometry 
+should be closed or not. When activated, this option helps PreCAD to treat 
+the most dirtiest geometries. Default is 0.</li>
+<li>\b debug (int) - If debug = 1 PreCAD will be very verbose and will output 
+some intermediate files in the working directory. Default is 0.</li>
+<li>\b eps_nano_relative (real) -  Same as \b eps_nano but given in relatively to 
+the diagonal of the box bounding the geometry. Default is \f$10^{-5}\f$.</li>
+<li>\b eps_sewing (real) - tolerance of the assembly. It rarely requires to be tuned. 
+Default is \f$\mathrm{diag} \times 5 \cdot 10^{-4}\f$.</li>
+<li>\b eps_sewing_relative (real) -  Same as \b eps_nano but given in relatively to 
+the diagonal of the box bounding the geometry. Default is \f$5 \cdot 10^{-4}\f$.</li>
+<li>\b manifold_geometry (int) - describes whether the working geometry should be manifold or not.
+When activated, this option helps PreCAD to treat the most dirtiest geometries. Default is 0.</li>
+<li>\b create_tag_collision (int) - creates some new tags from original ones in case 
+of collision (entity merge or association for example). Default is 0.</li>
+<li>\b periodic_tolerance (real) - defines the maximum distance error accepted between 
+two sets of periodic entities. Default is \f$\mathrm{diag} \times 10^{-5}\f$.</li>
+<li>\b periodic_tolerance_relative (real) -  Same as \b periodic_tolerance but in relative
+unit. Default is \f$10^{-5}\f$.</li>
+<li>\b periodic_split_tolerance (real) - This periodicity processing related option defines 
+the minimum distance between a CAD point and an imprinted point. It allows to indirectly 
+control the number of points and small edges created. Default is \f$\mathrm{diag} \times 10^{-4}\f$.</li>
+<li>\b periodic_split_tolerance_relative (real -  Same as \b periodic_split_tolerance but in
+relative unit. Default is \f$10^{-4}\f$.</li>
+</ul>
+
 \n
 The following advanced options are not documented and you can use them
 at your own risk.
@@ -205,7 +260,7 @@ String variables:
 
 <h1>Custom size map</h1>
 
-\image html blsurf_parameters_sizemap.png
+\image html blsurf_parameters_sizemap1.png 
 
 User sizes can be defined on faces, edges or vertices.
 <ul>
@@ -224,8 +279,6 @@ object or to its sub-shapes (created using <b>Explode</b> command).</li>
 </ul></li>
 </ul>
 
-<br><b>See Also</b> a sample TUI Script of the \ref tui_blsurf "creation of a BLSurf hypothesis", including size map.
-
 \anchor blsurf_sizemap_computation
 <h2>Computation of the physical size</h2>
 \n
@@ -241,6 +294,67 @@ specification of the sizes. The computation depends on whether point P is intern
 </ul>
 In order to compute the mean of several values, the arithmetic mean is used by default, but this can be modified by the parameter \ref blsurf_hmean_flag "hmean flag". In the same way, in order to interpolate two values, a linear interpolation is used by default, but this can be modified by \ref blsurf_hinterpol_flag "hinterpol flag".
 
+\anchor blsurf_attractor
+<h2>Advanced maps</h2>
+\n
+\image html blsurf_parameters_sizemap2.png 
+\n
+More specific size maps can be defined on faces. 
+
+<ul>
+<li> <i> Attractors </i> allow to define the size of the mesh elements
+on a face so that the mesh is the finest on the attractor shape and
+becomes coarser when getting far from this shape.
+<ul> 
+<li> The selected attractor can be a Vertex, an Edge, a Wire or a
+Compound mixing several entities of those types.</li>
+<li> The attractor doesn't have to be a sub-shape of the shape to mesh.</li>
+<li> The size will grow exponentially (see the formula below) but is
+bounded by gradation, \n so if you want the formula to be strictly
+respected, you should set the <i>gradation</i> 
+to its maximum (2.5) in the <i>arguments</i> tab. 
+</ul>
+\n
+<li> Furthermore you can choose to <i> keep the size constant </i>
+until a certain distance from a shape. This option can be combined or
+not with an <i>attractor</i> size map described above. 
+<ul>
+<li> If the two options are combined the size will remain constant
+until the distance specified in "constant over" and grow then as
+prescribed by the attractor function.</li>
+<li> Else the growing is only controled by the standard arguments of
+BLSURF (gradation ...).</li>
+</ul>
+</ul>
+
+\image html blsurf_attractors2.png "Example of mesh created using
+attractors, the attractors here are the side edges and the size grows
+from the side of the surface towards the apex"
+\n
+\image html blsurf_const_size_near_shape2.png "Example of size map
+with constant size option, the size is kept constant on the left side
+of the surface until a certain distance"
+\n
+Remark : The validation of the hypothesis might take a few seconds if
+attractors are defined or the "constant size" option is used because a
+map of distances has to be built on the whole surface for each face
+where such a hypothesis has been defined.
+
+<br><b>See Also</b> a sample TUI Script of the \ref tui_blsurf "creation of a BLSurf hypothesis", including size map.
+
+\anchor blsurf_attractor_computation
+<h2>Computation of attractors</h2>
+\n
+The size grows exponentially following the equation : 
+\f$h(d) = \mathrm{User Size} + (\mathrm{h\_start} - \mathrm{User Size}) \times e ^ { - \left( \frac{d}{R} \right) ^ {2} }\f$
+\n
+Where :
+<ul>
+<li>h_start is the desired size on the given attractor shape</li>
+<li>d is the distance of the current point from the attractor
+shape. The distance is the geodesic distance (i.e. calculated by following the surface to be meshed) </li>
+<li>R is called the distance of influence and allows controlling the growth rate of the mesh </li>
+</ul>
 
 <h1>Custom enforced vertices</h1>
 
@@ -261,14 +375,6 @@ without creating any vertices by CAD algorithms.
 
 Currently BLSURF plugin has the following limitations.
 <ul>
-  <li>The created mesh will contain inverted elements if it is based on a shape,
-      consisting of more than one face (box, cone, torus...) and if
-      the option "Allow Quadrangles (Test)" has been checked before
-      computation.</li>
-
-  <li>SIGFPE exception is raised at the attempt to compute the mesh
-      based on a box when the option "Patch independent" is checked.</li>
-
   <li>BLSURF algorithm cannot be used as a local algorithm (on
       sub-meshes) or as a provider of a low-level
       mesh for some 3D algorithms, because the BLSURF mesher (and
@@ -277,10 +383,10 @@ Currently BLSURF plugin has the following limitations.
       following combinations of algorithms are impossible:
       <ul>
         <li> global MEFISTO or Quadrangle(mapping) + local BLSURF;</li>
-        <li> BLSUFR + Projection 2D from faces meshed by BLSURF;</li>
+        <li> BLSURF + Projection 2D from faces meshed by BLSURF;</li>
         <li> local BLSURF + Extrusion 3D;</li>
       </ul>
-      </li>
+  </li>
 </ul>
 
 */