Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
dumux-repositories
dumux
Commits
38418d52
Commit
38418d52
authored
Dec 06, 2017
by
Timo Koch
Browse files
[box][scv] Return references instead of values saving unnecessary copies
parent
92b4b7be
Changes
1
Hide whitespace changes
Inline
Side-by-side
dumux/discretization/box/subcontrolvolume.hh
View file @
38418d52
...
...
@@ -70,7 +70,7 @@ public:
}
//! The center of the sub control volume
GlobalPosition
center
()
const
const
GlobalPosition
&
center
()
const
{
return
center_
;
}
...
...
@@ -105,10 +105,10 @@ public:
}
// The position of the dof this scv is embedded in
GlobalPosition
dofPosition
()
const
const
GlobalPosition
&
dofPosition
()
const
{
// The corner list is defined such that the first entry is the vertex itself
return
corner
(
0
)
;
return
corner
s_
[
0
]
;
}
//! The global index of the element this scv is embedded in
...
...
@@ -118,7 +118,7 @@ public:
}
//! Return the corner for the given local index
GlobalPosition
corner
(
LocalIndexType
localIdx
)
const
const
GlobalPosition
&
corner
(
LocalIndexType
localIdx
)
const
{
assert
(
localIdx
<
corners_
.
size
()
&&
"provided index exceeds the number of corners"
);
return
corners_
[
localIdx
];
...
...
Write
Preview
Supports
Markdown
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