mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-12-26 17:30:35 +05:00
PAL11200. Fix deflection example
This commit is contained in:
parent
00c8816937
commit
f11ae15a45
@ -284,57 +284,46 @@ else
|
|||||||
|
|
||||||
<p class="whs3"># create vertices</p>
|
<p class="whs3"># create vertices</p>
|
||||||
|
|
||||||
<p class="whs2">px =
|
<p class="whs2">px =geompy.MakeVertex(100., 0. ,0. )</p>
|
||||||
geompy.MakeVertex(100., 0. ,
|
|
||||||
0. )</p>
|
|
||||||
|
|
||||||
<p class="whs2">py =
|
<p class="whs2">py =geompy.MakeVertex(0. ,100., 0. )</p>
|
||||||
geompy.MakeVertex(0. ,
|
|
||||||
100., 0. )</p>
|
|
||||||
|
|
||||||
<p class="whs2">pz =
|
<p class="whs2">pz =geompy.MakeVertex(0. ,0. , 100.)</p>
|
||||||
geompy.MakeVertex(0. ,
|
|
||||||
0. , 100.)</p>
|
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># create a vector from
|
<p class="whs3"># create a vector from
|
||||||
two points</p>
|
two points</p>
|
||||||
|
|
||||||
<p class="whs2">vxy = geompy.MakeVector(px,
|
<p class="whs2">vxy = geompy.MakeVector(px,py)</p>
|
||||||
py)</p>
|
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># create an arc from
|
<p class="whs3"># create an arc from
|
||||||
three points</p>
|
three points</p>
|
||||||
|
|
||||||
<p class="whs2">arc = geompy.MakeArc(py,
|
<p class="whs2">arc = geompy.MakeArc(py, pz, px)</p>
|
||||||
pz, px)</p>
|
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># create a wire</p>
|
<p class="whs3"># create a wire</p>
|
||||||
|
|
||||||
<p class="whs2">wire = geompy.MakeWire([vxy,
|
<p class="whs2">wire = geompy.MakeWire([vxy,arc])</p>
|
||||||
arc])</p>
|
|
||||||
|
|
||||||
<p class="whs2">isPlanarFace = 1</p>
|
<p class="whs2">isPlanarFace = 1</p>
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># create a face from
|
<p class="whs3"># create a face from the wire</p>
|
||||||
the wire</p>
|
|
||||||
|
|
||||||
<p class="whs2">face1 = geompy.MakeFace(wire,
|
<p class="whs2">face1 = geompy.MakeFace(wire,isPlanarFace)</p>
|
||||||
isPlanarFace)</p>
|
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># add objects in the
|
<p class="whs3"># add objects in the study</p>
|
||||||
study</p>
|
|
||||||
|
|
||||||
<p class="whs2">id_face1 = geompy.addToStudy(face1,"Face1")</p>
|
<p class="whs2">id_face1 = geompy.addToStudy(face1,"Face1")</p>
|
||||||
|
<p class="whs2">id_arc = geompy.addToStudyInFather(arc,"Arc Edge")</p>
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
@ -350,44 +339,34 @@ else
|
|||||||
|
|
||||||
<p class="whs3"># create hexahedral mesh</p>
|
<p class="whs3"># create hexahedral mesh</p>
|
||||||
|
|
||||||
<p class="whs2">hexa = smesh.Mesh(face1,
|
<p class="whs2">hexa = smesh.Mesh(face1,"Face compound : hexahedrical mesh")</p>
|
||||||
"Face compound : hexahedrical mesh")</p>
|
|
||||||
|
|
||||||
<p class="whs2">algo = hexa.Triangle()</p>
|
<p class="whs2">algo = hexa.Triangle()</p>
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># define "MaxElementArea"
|
<p class="whs3"># define "MaxElementArea"hypothesis</p>
|
||||||
hypothesis to be applied to
|
|
||||||
each triangle</p>
|
|
||||||
|
|
||||||
<p class="whs2">algo.MaxElementArea(30)</p>
|
<p class="whs2">algo.MaxElementArea(30)</p>
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># create a quadrangle
|
<p class="whs3"># create a local hypothesis on the wire</p>
|
||||||
2D algorithm for faces</p>
|
|
||||||
|
|
||||||
<p class="whs2">hexa.Quadrangle()</p>
|
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
|
||||||
|
|
||||||
<p class="whs3"># create a local hypothesis</p>
|
|
||||||
|
|
||||||
<p class="whs2">algo = hexa.Segment(wire)</p>
|
<p class="whs2">algo = hexa.Segment(wire)</p>
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># define "NumberOfSegments"
|
<p class="whs3"># define "NumberOfSegments"hypothesis to cut
|
||||||
hypothesis to cut an edge in a fixed number of segments</p>
|
a straight edge in a fixed number of segments</p>
|
||||||
|
|
||||||
<p class="whs2">algo.NumberOfSegments(6)</p>
|
<p class="whs2">algo.NumberOfSegments(6)</p>
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
|
||||||
<p class="whs3"># define "Deflection1D"
|
<p class="whs3"># define a local "Deflection1D"hypothesis on the arc</p>
|
||||||
hypothesis</p>
|
|
||||||
|
|
||||||
|
<p class="whs2">algo = hexa.Segment(arc)</p>
|
||||||
<p class="whs2">algo.Deflection1D(1)</p>
|
<p class="whs2">algo.Deflection1D(1)</p>
|
||||||
|
|
||||||
<p class="whs2"> </p>
|
<p class="whs2"> </p>
|
||||||
|
Loading…
Reference in New Issue
Block a user