Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
8e711a38
Commit
8e711a38
authored
22 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
better wording
parent
b12d3cfd
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tutorial/t5.geo
+12
-11
12 additions, 11 deletions
tutorial/t5.geo
with
12 additions
and
11 deletions
tutorial/t5.geo
+
12
−
11
View file @
8e711a38
...
@@ -27,9 +27,10 @@ lcar3 = .055;
...
@@ -27,9 +27,10 @@ lcar3 = .055;
// > gmsh t5 -clscale 0.2
// > gmsh t5 -clscale 0.2
//
//
// (i.e. with all characteristic lengths divided by 5), the mesh
// (i.e. with all characteristic lengths divided by 5), the mesh
// counts approximately 170,000 nodes and one million tetrahedra.
// counts approximately 170,000 nodes and one million tetrahedra (and
// the computation takes 16 minutes on the same machine).
// Let us proceed by defining some elementary entities
,
describing a
// Let us proceed by defining some elementary entities describing a
// truncated cube:
// truncated cube:
Point
(
1
)
=
{
0.5
,
0.5
,
0.5
,
lcar2
};
Point
(
2
)
=
{
0.5
,
0.5
,
0
,
lcar1
};
Point
(
1
)
=
{
0.5
,
0.5
,
0.5
,
lcar2
};
Point
(
2
)
=
{
0.5
,
0.5
,
0
,
lcar1
};
...
@@ -66,10 +67,10 @@ Function CheeseHole
...
@@ -66,10 +67,10 @@ Function CheeseHole
// In the following commands we use the reserved variable name
// In the following commands we use the reserved variable name
// `newp', which automatically selects a new point number. This
// `newp', which automatically selects a new point number. This
// number is chosen as the highest current point number, plus
// number is chosen as the highest current point number, plus
// one. (Note that, analogously to `newp', the
re also exists
// one. (Note that, analogously to `newp', the
variables `newc',
//
variables `newc',
`news', `newv' and `newreg'
which
select the
// `news', `newv' and `newreg' select the
highest number amongst
//
highest number of amongst
curves, surfaces, volumes
or
//
currently defined
curves, surfaces, volumes
and `any entities
//
any entities
other than points, respectively.)
// other than points
'
, respectively.)
p1
=
newp
;
Point
(
p1
)
=
{
x
,
y
,
z
,
lcar3
}
;
p1
=
newp
;
Point
(
p1
)
=
{
x
,
y
,
z
,
lcar3
}
;
p2
=
newp
;
Point
(
p2
)
=
{
x
+
r
,
y
,
z
,
lcar3
}
;
p2
=
newp
;
Point
(
p2
)
=
{
x
+
r
,
y
,
z
,
lcar3
}
;
...
@@ -94,7 +95,7 @@ Function CheeseHole
...
@@ -94,7 +95,7 @@ Function CheeseHole
// We need non-plane surfaces to define the spherical cheese
// We need non-plane surfaces to define the spherical cheese
// holes. Here we use ruled surfaces, which can have 3 or 4
// holes. Here we use ruled surfaces, which can have 3 or 4
//
bor
de
r
s:
//
si
des:
l1
=
newreg
;
Line
Loop
(
l1
)
=
{
c5
,
c10
,
c4
};
Ruled
Surface
(
newreg
)
=
{
l1
};
l1
=
newreg
;
Line
Loop
(
l1
)
=
{
c5
,
c10
,
c4
};
Ruled
Surface
(
newreg
)
=
{
l1
};
l2
=
newreg
;
Line
Loop
(
l2
)
=
{
c9
,
-
c5
,
c1
};
Ruled
Surface
(
newreg
)
=
{
l2
};
l2
=
newreg
;
Line
Loop
(
l2
)
=
{
c9
,
-
c5
,
c1
};
Ruled
Surface
(
newreg
)
=
{
l2
};
...
@@ -107,10 +108,10 @@ Function CheeseHole
...
@@ -107,10 +108,10 @@ Function CheeseHole
// Please note that all surface meshes are generated by projecting a
// Please note that all surface meshes are generated by projecting a
// 2D planar mesh onto the surface, and that this method gives nice
// 2D planar mesh onto the surface, and that this method gives nice
// results only if the surface's curvature is
relatively enough.
// results only if the surface's curvature is
small enough. If not,
//
If not,
you will have to cut the surface in pieces.
// you will have to cut the surface in pieces.
// We then use an array of variables to store the surface loop
'
s
// We then use an array of variables to store the surface loops
// identification numbers for later reference (we will need these to
// identification numbers for later reference (we will need these to
// define the final volume):
// define the final volume):
...
@@ -135,7 +136,7 @@ For t In {1:5}
...
@@ -135,7 +136,7 @@ For t In {1:5}
Call
CheeseHole
;
Call
CheeseHole
;
// We define a physical volume for each
cheese
hole:
// We define a physical volume for each hole:
Physical
Volume
(
t
)
=
thehole
;
Physical
Volume
(
t
)
=
thehole
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment