Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-common
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Timo Koch
dune-common
Commits
f5f13f37
Commit
f5f13f37
authored
20 years ago
by
Robert Klöfkorn
Browse files
Options
Downloads
Patches
Plain Diff
Minor changes.
[[Imported from SVN: r795]]
parent
45e1d78a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
grid/albertgrid/albertextra.hh
+6
-3
6 additions, 3 deletions
grid/albertgrid/albertextra.hh
grid/albertgrid/albertgrid.cc
+34
-4
34 additions, 4 deletions
grid/albertgrid/albertgrid.cc
with
40 additions
and
7 deletions
grid/albertgrid/albertextra.hh
+
6
−
3
View file @
f5f13f37
...
...
@@ -21,12 +21,10 @@ namespace Albert {
(assert(drv != NULL); (vec = (drv)->vec); assert(vec != NULL));
//vec = (drv)->vec;
//#define _ALBERTA_
inline
void
fillMacroInfo
(
TRAVERSE_STACK
*
stack
,
const
MACRO_EL
*
mel
,
EL_INFO
*
elinfo
)
{
#ifdef _ALBERTA_
#ifdef _ALBERTA_
H_
/* Alberta version */
fill_macro_info
(
stack
->
traverse_mesh
,
mel
,
elinfo
);
#else
...
...
@@ -342,6 +340,8 @@ namespace AlbertHelp
static
const
int
tetraFace_2
[
3
]
=
{
0
,
3
,
1
};
static
const
int
tetraFace_3
[
3
]
=
{
0
,
1
,
2
};
static
const
int
tetraFace
[
4
][
3
]
=
{
{
3
,
2
,
1
},
{
2
,
3
,
0
}
,
{
0
,
3
,
1
}
,
{
0
,
1
,
2
}
};
static
const
int
*
localTetraFaceNumber
[
4
]
=
{
tetraFace_0
,
tetraFace_1
,
tetraFace_2
,
tetraFace_3
};
...
...
@@ -1193,7 +1193,10 @@ namespace AlbertHelp
elOwner
=
NULL
;
}
#ifndef _ALBERTA_H_
#include
"part.cc"
#endif
}
// end namespace AlbertHelp
#ifdef __ALBERTpp__
...
...
This diff is collapsed.
Click to expand it.
grid/albertgrid/albertgrid.cc
+
34
−
4
View file @
f5f13f37
...
...
@@ -1975,6 +1975,32 @@ namespace Dune
return
elInfo_
->
opp_vertex
[
neighborCount_
];
}
// setup neighbor element with the information of elInfo_
inline
void
AlbertGridIntersectionIterator
<
2
,
2
>::
setupVirtEn
()
{
enum
{
dim
=
2
};
enum
{
dimworld
=
2
};
// set the neighbor element as element
neighElInfo_
->
el
=
elInfo_
->
neigh
[
neighborCount_
];
int
vx
=
elInfo_
->
opp_vertex
[
neighborCount_
];
for
(
int
i
=
0
;
i
<
dimworld
;
i
++
)
neighElInfo_
->
coord
[
vx
][
i
]
=
elInfo_
->
opp_coord
[
neighborCount_
][
i
];
for
(
int
i
=
1
;
i
<
dim
+
1
;
i
++
)
{
int
nb
=
(((
neighborCount_
-
i
)
%
(
dim
+
1
))
+
dim
+
1
)
%
(
dim
+
1
);
for
(
int
j
=
0
;
j
<
dimworld
;
j
++
)
neighElInfo_
->
coord
[(
vx
+
i
)
%
(
dim
+
1
)][
j
]
=
elInfo_
->
coord
[
nb
][
j
];
}
/* works, tested many times */
virtualEntity_
->
setElInfo
(
neighElInfo_
);
builtNeigh_
=
true
;
}
// setup neighbor element with the information of elInfo_
template
<
int
dim
,
int
dimworld
>
inline
void
AlbertGridIntersectionIterator
<
dim
,
dimworld
>::
setupVirtEn
()
...
...
@@ -2016,9 +2042,12 @@ namespace Dune
for
(
int
i
=
0
;
i
<
dimworld
;
i
++
)
neighElInfo_
->
coord
[
vx
][
i
]
=
elInfo_
->
opp_coord
[
neighborCount_
][
i
];
//printf(" nb %d \n",neighborCount_);
for
(
int
i
=
1
;
i
<
dim
+
1
;
i
++
)
{
int
nb
=
(((
neighborCount_
-
i
)
%
(
dim
+
1
))
+
dim
+
1
)
%
(
dim
+
1
);
//int nb = AlbertHelp::tetraFace[neighborCount_][i];
for
(
int
j
=
0
;
j
<
dimworld
;
j
++
)
neighElInfo_
->
coord
[(
vx
+
i
)
%
(
dim
+
1
)][
j
]
=
elInfo_
->
coord
[
nb
][
j
];
}
...
...
@@ -3040,6 +3069,8 @@ namespace Dune
assert
(
dimworld
==
DIM_OF_WORLD
);
assert
(
dim
==
DIM
);
assert
(
dim
==
2
);
ALBERT
MESH
*
oldMesh
=
oldGrid
.
getMesh
();
vertexMarker_
=
new
AlbertMarkerVector
();
...
...
@@ -3074,7 +3105,7 @@ namespace Dune
assert
(
no
==
length
);
}
#if
0
#if
def _ALBERTA_H_
ALBERT
write_macro
(
oldMesh
,
fakename
);
ALBERT
read_macro
(
fakeMesh
,
fakename
,
ALBERT
AlbertHelp
::
initBoundary
);
#else
...
...
@@ -3099,7 +3130,7 @@ namespace Dune
{
#if
0
#if
def _ALBERTA_H_
ALBERT
write_macro
(
fakeMesh
,
fakename
);
ALBERT
read_macro
(
mesh_
,
fakename
,
ALBERT
AlbertHelp
::
initBoundary
);
#else
...
...
@@ -3842,8 +3873,7 @@ namespace Dune
{
a
.
resize
(
newNumberOfEntries
);
}
for
(
Array
<
int
>::
Iterator
it
=
a
.
begin
();
it
!=
a
.
end
();
++
it
)
(
*
it
)
=
-
1
;
for
(
int
i
=
0
;
i
<
a
.
size
();
i
++
)
a
[
i
]
=
-
1
;
}
template
<
int
dim
,
int
dimworld
>
template
<
int
codim
>
...
...
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