Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-istl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
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
Core Modules
dune-istl
Commits
d0069aa6
Commit
d0069aa6
authored
9 years ago
by
Christian Engwer
Browse files
Options
Downloads
Patches
Plain Diff
[istl][multitype] constexpr only works if we can the method on the type and not on the object
parent
35a02846
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dune/istl/multitypeblockmatrix.hh
+8
-16
8 additions, 16 deletions
dune/istl/multitypeblockmatrix.hh
with
8 additions
and
16 deletions
dune/istl/multitypeblockmatrix.hh
+
8
−
16
View file @
d0069aa6
...
...
@@ -57,7 +57,7 @@ namespace Dune {
template
<
int
crow
,
int
remain_rows
,
int
ccol
,
typename
TMatrix
>
//specialization for remain_cols=0
class
MultiTypeBlockMatrix_Print
<
crow
,
remain_rows
,
ccol
,
0
,
TMatrix
>
{
public:
static
void
print
(
const
TMatrix
&
m
)
{
MultiTypeBlockMatrix_Print
<
crow
+
1
,
remain_rows
-
1
,
0
,
m
.
N
(),
TMatrix
>::
print
(
m
);
//next row
MultiTypeBlockMatrix_Print
<
crow
+
1
,
remain_rows
-
1
,
0
,
TMatrix
::
N
(),
TMatrix
>::
print
(
m
);
//next row
}
};
...
...
@@ -334,26 +334,18 @@ namespace Dune {
operator<< for printing out a MultiTypeBlockMatrix
*/
template
<
typename
T1
,
typename
T2
,
typename
T3
,
typename
T4
,
typename
T5
,
typename
T6
,
typename
T7
,
typename
T8
,
typename
T9
>
std
::
ostream
&
operator
<<
(
std
::
ostream
&
s
,
const
MultiTypeBlockMatrix
<
T1
,
T2
,
T3
,
T4
,
T5
,
T6
,
T7
,
T8
,
T9
>&
m
)
{
MultiTypeBlockMatrix_Print
<
0
,
m
.
N
(),
0
,
m
.
M
(),
MultiTypeBlockMatrix
<
T1
,
T2
,
T3
,
T4
,
T5
,
T6
,
T7
,
T8
,
T9
>
>::
print
(
m
);
template
<
typename
T1
,
typename
...
Args
>
std
::
ostream
&
operator
<<
(
std
::
ostream
&
s
,
const
MultiTypeBlockMatrix
<
T1
,
Args
...
>&
m
)
{
static
const
int
N
=
MultiTypeBlockMatrix
<
T1
,
Args
...
>::
N
();
static
const
int
M
=
MultiTypeBlockMatrix
<
T1
,
Args
...
>::
M
();
MultiTypeBlockMatrix_Print
<
0
,
N
,
0
,
M
,
MultiTypeBlockMatrix
<
T1
,
Args
...
>
>::
print
(
m
);
return
s
;
}
//make algmeta_itsteps known
template
<
int
I
>
template
<
int
I
,
typename
M
>
struct
algmeta_itsteps
;
/**
@brief part of solvers for MultiTypeBlockVector & MultiTypeBlockMatrix types
...
...
@@ -407,7 +399,7 @@ namespace Dune {
static
void
dbgs
(
const
TMatrix
&
A
,
TVector
&
x
,
TVector
&
v
,
const
TVector
&
b
,
const
K
&
w
)
{
auto
rhs
=
std
::
get
<
crow
>
(
b
);
MultiTypeBlockMatrix_Solver_Col
<
I
,
crow
,
0
,
A
.
M
()
>::
calc_rhs
(
A
,
x
,
v
,
rhs
,
w
);
// calculate right side of equation
MultiTypeBlockMatrix_Solver_Col
<
I
,
crow
,
0
,
TMatrix
::
M
()
>::
calc_rhs
(
A
,
x
,
v
,
rhs
,
w
);
// calculate right side of equation
//solve on blocklevel I-1
algmeta_itsteps
<
I
-
1
>::
dbgs
(
std
::
get
<
crow
>
(
std
::
get
<
crow
>
(
A
)),
std
::
get
<
crow
>
(
x
),
rhs
,
w
);
MultiTypeBlockMatrix_Solver
<
I
,
crow
+
1
,
remain_row
-
1
>::
dbgs
(
A
,
x
,
v
,
b
,
w
);
//next row
...
...
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