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
8bf3b327
Commit
8bf3b327
authored
24 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
*** empty log message ***
parent
4b184d8f
No related branches found
No related tags found
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
Mesh/2D_DivAndConq.cpp
+2
-2
2 additions, 2 deletions
Mesh/2D_DivAndConq.cpp
Mesh/3D_Mesh.cpp
+8
-5
8 additions, 5 deletions
Mesh/3D_Mesh.cpp
Mesh/Simplex.cpp
+6
-6
6 additions, 6 deletions
Mesh/Simplex.cpp
demos/ex02.geo
+2
-0
2 additions, 0 deletions
demos/ex02.geo
with
18 additions
and
13 deletions
Mesh/2D_DivAndConq.cpp
+
2
−
2
View file @
8bf3b327
/* $Id: 2D_DivAndConq.cpp,v 1.
6
2000-11-28 1
1:28:31
geuzaine Exp $ */
/* $Id: 2D_DivAndConq.cpp,v 1.
7
2000-11-28 1
2:59:24
geuzaine Exp $ */
/*
A L G O R I T H M E D I V I D E A N D C O N Q U E R
...
...
@@ -341,7 +341,7 @@ int CircumCircle(double x1,double y1,double x2,double y2,double x3,double y3,
d
=
2.
*
(
double
)(
y1
*
(
x2
-
x3
)
+
y2
*
(
x3
-
x1
)
+
y3
*
(
x1
-
x2
));
if
(
d
==
0.0
){
Msg
(
WARNING
,
"
Points
Colinear in CircumCircle"
);
Msg
(
WARNING
,
"Colinear
Points
in CircumCircle"
);
*
xc
=
*
yc
=
-
99999.
;
return
(
0
);
}
...
...
This diff is collapsed.
Click to expand it.
Mesh/3D_Mesh.cpp
+
8
−
5
View file @
8bf3b327
/* $Id: 3D_Mesh.cpp,v 1.
8
2000-11-2
7
1
7:13:49
geuzaine Exp $ */
/* $Id: 3D_Mesh.cpp,v 1.
9
2000-11-2
8
1
2:59:24
geuzaine Exp $ */
/*
J-F Remacle 1995
...
...
@@ -158,7 +158,7 @@ int Pt_In_Circum (Simplex * s, Vertex * v){
eps
=
fabs
(
d1
-
d2
)
/
(
d1
+
d2
);
if
(
eps
<
1.e-12
){
return
(
0
);
/* c'etait 1! GEUZ ????*/
return
(
1
);
}
if
(
d2
<
d1
)
...
...
@@ -456,6 +456,7 @@ int recur_bowyer (Simplex * s){
}
else
{
if
(
s
->
iEnt
!=
s
->
S
[
i
]
->
iEnt
){
//Msg(WARNING, "Point Scabreux %d", s->S[i]->Num);
Alerte_Point_Scabreux
=
1
;
}
Tree_Insert
(
Sim_Sur_Le_Bord
,
&
s
->
S
[
i
]);
...
...
@@ -534,7 +535,7 @@ bool Bowyer_Watson (Mesh * m, Vertex * v, Simplex * S, int force){
List_Reset
(
Simplexes_New
);
Tree_Delete
(
Sim_Sur_Le_Bord
);
Tree_Delete
(
Tsd
);
//
printf("
%22.15E %22.15E
\n",volumeold,volumenew);
printf
(
"
Aie Aie Aie volume changed %g -> %g
\n
"
,
volumeold
,
volumenew
);
return
false
;
}
}
...
...
@@ -565,7 +566,7 @@ bool Bowyer_Watson (Mesh * m, Vertex * v, Simplex * S, int force){
}
double
rand_sign
(){
return
(
rand
()
%
2
==
0
)
?-
1.0
:
1.0
;
return
(
rand
()
/
RAND_MAX
<
0.5
)
?-
1.0
:
1.0
;
}
void
Convex_Hull_Mesh
(
List_T
*
Points
,
Mesh
*
m
){
...
...
@@ -613,6 +614,8 @@ void Convex_Hull_Mesh (List_T * Points, Mesh * m){
bool
ca_marche
=
Bowyer_Watson
(
m
,
THEV
,
THES
,
1
);
int
count
=
0
;
while
(
!
ca_marche
){
Msg
(
INFOS
,
"Unable to Add Point %d (%g,%g,%g)"
,
THEV
->
Num
,
THEV
->
Pos
.
X
,
THEV
->
Pos
.
Y
,
THEV
->
Pos
.
Z
);
count
++
;
double
dx
=
rand_sign
()
*
10
*
CTX
.
mesh
.
rand_factor
*
LC3D
*
rand
()
/
RAND_MAX
;
double
dy
=
rand_sign
()
*
10
*
CTX
.
mesh
.
rand_factor
*
LC3D
*
rand
()
/
RAND_MAX
;
...
...
This diff is collapsed.
Click to expand it.
Mesh/Simplex.cpp
+
6
−
6
View file @
8bf3b327
/* $Id: Simplex.cpp,v 1.
7
2000-11-2
6
1
5:43:47
geuzaine Exp $ */
/* $Id: Simplex.cpp,v 1.
8
2000-11-2
8
1
2:59:24
geuzaine Exp $ */
#include
"Gmsh.h"
#include
"Const.h"
...
...
@@ -161,8 +161,8 @@ void Simplex::center_tet (double X[4], double Y[4], double Z[4], double res[3]){
mat
[
2
][
1
]
=
Y
[
3
]
-
Y
[
2
];
mat
[
2
][
2
]
=
Z
[
3
]
-
Z
[
2
];
if
(
!
sys3x3
(
mat
,
b
,
res
,
&
dum
))
{
if
(
!
sys3x3
(
mat
,
b
,
res
,
&
dum
))
{
Msg
(
WARNING
,
"Coplanar Points in CircumCircle"
);
res
[
0
]
=
res
[
1
]
=
res
[
2
]
=
10.0e10
;
}
...
...
This diff is collapsed.
Click to expand it.
demos/ex02.geo
+
2
−
0
View file @
8bf3b327
...
...
@@ -6,6 +6,8 @@
All important comments are marked with "README"
*/
// -clscale 0.2 ==> 169932 Nodes, 1005779 Elements in 1095.95 s
lcar1
=
.1
;
lcar2
=
.0005
;
...
...
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