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
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
89c46ec3
Commit
89c46ec3
authored
8 years ago
by
PA Beaufort
Browse files
Options
Downloads
Patches
Plain Diff
PA: and the missing file ...
parent
ae2d245b
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Geo/discreteDiskFace.h
+10
-16
10 additions, 16 deletions
Geo/discreteDiskFace.h
with
10 additions
and
16 deletions
Geo/discreteDiskFace.h
+
10
−
16
View file @
89c46ec3
...
@@ -56,40 +56,39 @@ class ANNkd_tree;
...
@@ -56,40 +56,39 @@ class ANNkd_tree;
class
Octree
;
class
Octree
;
class
GRbf
;
class
GRbf
;
// compute dummy attributes of any conformal (linear~straighted-sided) triangulation
class
triangulation
{
class
triangulation
{
public:
public:
// attributes
// attributes
int
idNum
;
// number of identification, for hashing purposes
int
idNum
,
iter
;
// number of identification, for hashing purposes
std
::
vector
<
MElement
*>
tri
;
// trianglse
std
::
vector
<
MElement
*>
tri
;
// trianglse
GFace
*
gf
;
GFace
*
gf
;
double
maxD
;
double
maxD
;
double
area
;
bool
seamPoint
;
bool
seamPoint
;
std
::
set
<
MVertex
*>
vert
;
// nodes
std
::
set
<
MVertex
*>
vert
;
// nodes
// edge to 1 or 2 triangle(s), their num into the vector of MElement*
// edge to 1 or 2 triangle(s), their num into the vector of MElement*
std
::
map
<
MEdge
,
std
::
vector
<
int
>
,
Less_Edge
>
ed2tri
;
std
::
map
<
MEdge
,
std
::
vector
<
int
>
,
Less_Edge
>
ed2tri
;
std
::
map
<
double
,
std
::
vector
<
MVertex
*>
>
bord
;
//border(s)
std
::
map
<
double
,
std
::
vector
<
MVertex
*>
>
bord
;
//border(s)
#todo |-> std::vector
std
::
set
<
MEdge
,
Less_Edge
>
borderEdg
;
// border edges
std
::
set
<
MEdge
,
Less_Edge
>
borderEdg
;
// border edges
#todo |-> std::vector
std
::
list
<
GEdge
*>
my_GEdges
;
std
::
list
<
GEdge
*>
my_GEdges
;
std
::
set
<
int
>
fillingHoles
;
std
::
set
<
int
>
fillingHoles
;
// obsolete ? /!\ used within discreteDiskFace class
//---- methods
//---- methods
double
geodesicDistance
();
double
geodesicDistance
();
// prototype here
double
aspectRatio
()
double
aspectRatio
()
{
{
double
L
=
bord
.
rbegin
()
->
first
;
double
L
=
bord
.
rbegin
()
->
first
;
if
(
L
==
0.0
)
return
1.e22
;
if
(
L
==
0.0
)
return
1.e22
;
// #mark shoudn't we throw instead ?
if
(
maxD
<
0
)
maxD
=
geodesicDistance
();
if
(
maxD
<
0
)
maxD
=
geodesicDistance
();
// printf("%12.5E %12.5E\n",L,maxD);
return
maxD
/
L
;
return
maxD
/
L
;
}
}
int
genus
()
int
genus
()
// dummy formula for Chi
{
{
return
(
ed2tri
.
size
()
-
vert
.
size
()
-
tri
.
size
()
+
2
-
bord
.
size
()
)
/
2
;
return
(
ed2tri
.
size
()
-
vert
.
size
()
-
tri
.
size
()
+
2
-
bord
.
size
()
)
/
2
;
}
}
...
@@ -106,8 +105,6 @@ class triangulation {
...
@@ -106,8 +105,6 @@ class triangulation {
std
::
set
<
MVertex
*>::
iterator
it
=
vert
.
find
(
tv
);
std
::
set
<
MVertex
*>::
iterator
it
=
vert
.
find
(
tv
);
if
(
it
==
vert
.
end
())
vert
.
insert
(
tv
);
if
(
it
==
vert
.
end
())
vert
.
insert
(
tv
);
}
}
SVector3
N
(
crossprod
(
P
[
1
]
-
P
[
0
],
P
[
2
]
-
P
[
0
]));
area
+=
N
.
norm
();
}
}
}
}
...
@@ -185,7 +182,6 @@ class triangulation {
...
@@ -185,7 +182,6 @@ class triangulation {
void
assign
()
void
assign
()
{
{
area
=
0.
;
seamPoint
=
false
;
seamPoint
=
false
;
assignVert
();
assignVert
();
assignEd2tri
();
assignEd2tri
();
...
@@ -211,8 +207,7 @@ class triangulation {
...
@@ -211,8 +207,7 @@ class triangulation {
// triangles in the physical space xyz, with their parametric coordinates
// triangles in the physical space xyz, with their parametric coordinates
class
discreteDiskFaceTriangle
{
class
discreteDiskFaceTriangle
{
public:
public:
std
::
vector
<
SPoint3
>
p
;
// vertices in (u;v) #improveme std::vector instead
std
::
vector
<
SPoint3
>
p
;
// vertices in (u;v)
//SPoint2 gfp[6]; // CAD model
GFace
*
gf
;
// GFace tag
GFace
*
gf
;
// GFace tag
MElement
*
tri
;
// mesh triangle in (x;y;z)
MElement
*
tri
;
// mesh triangle in (x;y;z)
discreteDiskFaceTriangle
()
:
gf
(
0
),
tri
(
0
)
{}
discreteDiskFaceTriangle
()
:
gf
(
0
),
tri
(
0
)
{}
...
@@ -221,8 +216,7 @@ class discreteDiskFaceTriangle {
...
@@ -221,8 +216,7 @@ class discreteDiskFaceTriangle {
class
discreteDiskFace
:
public
GFace
{
class
discreteDiskFace
:
public
GFace
{
GFace
*
_parent
;
GFace
*
_parent
;
void
buildOct
(
std
::
vector
<
GFace
*>
*
CAD
=
NULL
)
const
;
void
buildOct
(
std
::
vector
<
GFace
*>
*
CAD
=
NULL
)
const
;
bool
parametrize
();
// const;
bool
parametrize
()
const
;
void
checklsys
(
linearSystemCSR
<
double
>*
,
dofManager
<
double
>*
,
int
);
bool
checkOrientationUV
();
bool
checkOrientationUV
();
void
optimize
();
void
optimize
();
...
...
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