Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Backofen, Rainer
amdis
Commits
8e0d7493
Commit
8e0d7493
authored
May 05, 2009
by
Peter Gottschling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Unterschiedliche Blockgroessen.
parent
60ef1112
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
4 deletions
+8
-4
AMDiS/src/SolverMatrix.h
AMDiS/src/SolverMatrix.h
+8
-4
No files found.
AMDiS/src/SolverMatrix.h
View file @
8e0d7493
...
...
@@ -67,14 +67,18 @@ namespace AMDiS {
public
:
void
setMatrix
(
const
Matrix
<
DOFMatrix
*>&
A
)
{
int
ns
=
A
.
getSize
(),
size
=
A
[
0
][
0
]
->
getFESpace
()
->
getAdmin
()
->
getUsedSize
(),
new_size
=
ns
*
size
;
matrix
.
change_dim
(
new_size
,
new_size
);
int
ns
=
A
.
getSize
();
std
::
vector
<
int
>
block_starts
(
ns
+
1
);
block_starts
[
0
]
=
0
;
for
(
int
i
=
0
;
i
<
ns
;
++
i
)
block_starts
[
i
+
1
]
=
block_starts
[
i
]
+
A
[
i
][
i
]
->
getFESpace
()
->
getAdmin
()
->
getUsedSize
();
matrix
.
change_dim
(
block_starts
[
ns
],
block_starts
[
ns
]);
DOFMatrix
::
inserter_type
ins
(
matrix
);
for
(
int
rb
=
0
;
rb
<
ns
;
++
rb
)
for
(
int
cb
=
0
;
cb
<
ns
;
++
cb
)
if
(
A
[
rb
][
cb
])
ins
[
rb
*
size
][
cb
*
size
]
<<
A
[
rb
][
cb
]
->
getBaseMatrix
();
ins
[
block_starts
[
rb
]][
block_starts
[
cb
]
]
<<
A
[
rb
][
cb
]
->
getBaseMatrix
();
}
const
DOFMatrix
::
base_matrix_type
&
getMatrix
()
const
{
return
matrix
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment