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
649184dd
Commit
649184dd
authored
13 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
fix compile without solver module
parent
74e4b11b
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
Geo/GRbf.cpp
+128
-119
128 additions, 119 deletions
Geo/GRbf.cpp
Geo/GRbf.h
+27
-24
27 additions, 24 deletions
Geo/GRbf.h
with
155 additions
and
143 deletions
Geo/GRbf.cpp
+
128
−
119
View file @
649184dd
...
@@ -5,6 +5,7 @@
...
@@ -5,6 +5,7 @@
//
//
// Contributed by Cecile Piret
// Contributed by Cecile Piret
#include
"GmshConfig.h"
#include
"GRbf.h"
#include
"GRbf.h"
#include
<math.h>
#include
<math.h>
#include
<vector>
#include
<vector>
...
@@ -16,7 +17,10 @@
...
@@ -16,7 +17,10 @@
#include
"OS.h"
#include
"OS.h"
#include
"MVertex.h"
#include
"MVertex.h"
#include
"MVertexPositionSet.h"
#include
"MVertexPositionSet.h"
#if defined(HAVE_SOLVER)
#include
"linearSystem.h"
#include
"linearSystem.h"
#endif
#if defined(HAVE_ANN)
#if defined(HAVE_ANN)
#include
<ANN/ANN.h>
#include
<ANN/ANN.h>
...
@@ -589,8 +593,10 @@ void GRbf::RbfLapSurface_local_CPM(bool isLow,
...
@@ -589,8 +593,10 @@ void GRbf::RbfLapSurface_local_CPM(bool isLow,
void
GRbf
::
RbfLapSurface_local_CPM_sparse
(
std
::
vector
<
MVertex
*>
&
bndVertices
,
bool
isLow
,
void
GRbf
::
RbfLapSurface_local_CPM_sparse
(
std
::
vector
<
MVertex
*>
&
bndVertices
,
bool
isLow
,
const
fullMatrix
<
double
>
&
cntrs
,
const
fullMatrix
<
double
>
&
cntrs
,
const
fullMatrix
<
double
>
&
normals
,
linearSystem
<
double
>
&
sys
)
const
fullMatrix
<
double
>
&
normals
,
linearSystem
<
double
>
&
sys
)
{
{
#if defined(HAVE_SOLVER)
std
::
set
<
int
>
bndIndices
;
std
::
set
<
int
>
bndIndices
;
for
(
size_t
i
=
0
;
i
<
bndVertices
.
size
();
++
i
)
{
for
(
size_t
i
=
0
;
i
<
bndVertices
.
size
();
++
i
)
{
bndIndices
.
insert
(
_mapV
[
bndVertices
[
i
]]);
bndIndices
.
insert
(
_mapV
[
bndVertices
[
i
]]);
...
@@ -660,6 +666,7 @@ void GRbf::RbfLapSurface_local_CPM_sparse(std::vector<MVertex*> &bndVertices, bo
...
@@ -660,6 +666,7 @@ void GRbf::RbfLapSurface_local_CPM_sparse(std::vector<MVertex*> &bndVertices, bo
sys
.
addToMatrix
(
i
+
2
*
numNodes
,
pts
[
j
]
+
2
*
numNodes
,
LocalOper
(
2
*
nbp
,
j
+
2
*
nbp
));
sys
.
addToMatrix
(
i
+
2
*
numNodes
,
pts
[
j
]
+
2
*
numNodes
,
LocalOper
(
2
*
nbp
,
j
+
2
*
nbp
));
}
}
}
}
#endif
}
}
// NEW METHOD #1 CPM GLOBAL HIGH
// NEW METHOD #1 CPM GLOBAL HIGH
...
@@ -840,6 +847,7 @@ void GRbf::solveHarmonicMap_sparse(linearSystem<double> &sys, int numNodes,
...
@@ -840,6 +847,7 @@ void GRbf::solveHarmonicMap_sparse(linearSystem<double> &sys, int numNodes,
const
std
::
vector
<
double
>
&
coords
,
const
std
::
vector
<
double
>
&
coords
,
std
::
map
<
MVertex
*
,
SPoint3
>
&
rbf_param
)
std
::
map
<
MVertex
*
,
SPoint3
>
&
rbf_param
)
{
{
#if defined(HAVE_SOLVER)
Msg
::
Info
(
"*** RBF ... solving map"
);
Msg
::
Info
(
"*** RBF ... solving map"
);
int
nb
=
numNodes
*
3
;
int
nb
=
numNodes
*
3
;
UV
.
resize
(
nb
,
2
);
UV
.
resize
(
nb
,
2
);
...
@@ -930,6 +938,7 @@ void GRbf::solveHarmonicMap_sparse(linearSystem<double> &sys, int numNodes,
...
@@ -930,6 +938,7 @@ void GRbf::solveHarmonicMap_sparse(linearSystem<double> &sys, int numNodes,
Msg
::
Info
(
"*** RBF solved map"
);
Msg
::
Info
(
"*** RBF solved map"
);
exportParametrizedMesh
(
UV
,
nbNodes
);
exportParametrizedMesh
(
UV
,
nbNodes
);
#endif
}
}
void
GRbf
::
solveHarmonicMap
(
fullMatrix
<
double
>
Oper
,
void
GRbf
::
solveHarmonicMap
(
fullMatrix
<
double
>
Oper
,
...
...
This diff is collapsed.
Click to expand it.
Geo/GRbf.h
+
27
−
24
View file @
649184dd
...
@@ -16,8 +16,8 @@
...
@@ -16,8 +16,8 @@
#include
"MVertex.h"
#include
"MVertex.h"
#include
"Context.h"
#include
"Context.h"
template
<
class
t
>
template
<
class
t
>
class
linearSystem
;
class
linearSystem
;
#if defined(HAVE_ANN)
#if defined(HAVE_ANN)
class
ANNkd_tree
;
class
ANNkd_tree
;
#endif
#endif
...
@@ -131,7 +131,8 @@ class GRbf {
...
@@ -131,7 +131,8 @@ class GRbf {
void
RbfLapSurface_local_CPM_sparse
(
std
::
vector
<
MVertex
*>
&
bndVertices
,
bool
isLow
,
void
RbfLapSurface_local_CPM_sparse
(
std
::
vector
<
MVertex
*>
&
bndVertices
,
bool
isLow
,
const
fullMatrix
<
double
>
&
cntrs
,
const
fullMatrix
<
double
>
&
cntrs
,
const
fullMatrix
<
double
>
&
normals
,
linearSystem
<
double
>
&
sys
);
const
fullMatrix
<
double
>
&
normals
,
linearSystem
<
double
>
&
sys
);
// Finds global surface differentiation matrix (method CPML)
// Finds global surface differentiation matrix (method CPML)
void
RbfLapSurface_global_CPM_low
(
const
fullMatrix
<
double
>
&
cntrs
,
void
RbfLapSurface_global_CPM_low
(
const
fullMatrix
<
double
>
&
cntrs
,
...
@@ -166,8 +167,10 @@ class GRbf {
...
@@ -166,8 +167,10 @@ class GRbf {
void
solveHarmonicMap
(
fullMatrix
<
double
>
Oper
,
std
::
vector
<
MVertex
*>
ordered
,
void
solveHarmonicMap
(
fullMatrix
<
double
>
Oper
,
std
::
vector
<
MVertex
*>
ordered
,
std
::
vector
<
double
>
coords
,
std
::
map
<
MVertex
*
,
SPoint3
>
&
rbf_param
);
std
::
vector
<
double
>
coords
,
std
::
map
<
MVertex
*
,
SPoint3
>
&
rbf_param
);
void
solveHarmonicMap_sparse
(
linearSystem
<
double
>
&
sys
,
int
numNodes
,
const
std
::
vector
<
MVertex
*>
&
ordered
,
void
solveHarmonicMap_sparse
(
linearSystem
<
double
>
&
sys
,
int
numNodes
,
const
std
::
vector
<
double
>
&
coords
,
std
::
map
<
MVertex
*
,
SPoint3
>
&
rbf_param
);
const
std
::
vector
<
MVertex
*>
&
ordered
,
const
std
::
vector
<
double
>
&
coords
,
std
::
map
<
MVertex
*
,
SPoint3
>
&
rbf_param
);
inline
const
fullMatrix
<
double
>
getUV
()
{
return
UV
;};
inline
const
fullMatrix
<
double
>
getUV
()
{
return
UV
;};
inline
const
fullMatrix
<
double
>
getXYZ
()
{
return
centers
;};
inline
const
fullMatrix
<
double
>
getXYZ
()
{
return
centers
;};
...
...
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