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
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
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
Tobias Leibner
dune-common
Commits
6d9e0143
Commit
6d9e0143
authored
20 years ago
by
Adrian Burri
Browse files
Options
Downloads
Patches
Plain Diff
Bugfix in init: use a flag to signal that the local function hasn't been initialised so far
[[Imported from SVN: r1596]]
parent
b3d01571
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
fem/dfadapt.hh
+3
-0
3 additions, 0 deletions
fem/dfadapt.hh
fem/discfuncarray.hh
+3
-0
3 additions, 0 deletions
fem/discfuncarray.hh
fem/discfuncarray/dfadapt.cc
+4
-2
4 additions, 2 deletions
fem/discfuncarray/dfadapt.cc
fem/discfuncarray/discfuncarray.cc
+4
-2
4 additions, 2 deletions
fem/discfuncarray/discfuncarray.cc
with
14 additions
and
4 deletions
fem/dfadapt.hh
+
3
−
0
View file @
6d9e0143
...
...
@@ -266,6 +266,9 @@ namespace Dune {
//! do we have the same base function set for all elements
bool
uniform_
;
//! is it initialised?
mutable
bool
init_
;
};
// end LocalFunctionAdapt
...
...
This diff is collapsed.
Click to expand it.
fem/discfuncarray.hh
+
3
−
0
View file @
6d9e0143
...
...
@@ -269,6 +269,9 @@ namespace Dune {
//! do we have the same base function set for all elements
bool
uniform_
;
//! is it initialised?
mutable
bool
init_
;
};
// end LocalFunctionArray
...
...
This diff is collapsed.
Click to expand it.
fem/discfuncarray/dfadapt.cc
+
4
−
2
View file @
6d9e0143
...
...
@@ -383,7 +383,7 @@ namespace Dune
LocalFunctionAdapt
(
const
DiscreteFunctionSpaceType
&
f
,
DofArrayType
&
dofVec
)
:
fSpace_
(
f
),
dofVec_
(
dofVec
)
,
uniform_
(
true
)
{}
,
uniform_
(
true
)
,
init_
(
false
)
{}
template
<
class
DiscreteFunctionSpaceType
>
inline
LocalFunctionAdapt
<
DiscreteFunctionSpaceType
>::~
LocalFunctionAdapt
()
...
...
@@ -496,7 +496,7 @@ namespace Dune
inline
bool
LocalFunctionAdapt
<
DiscreteFunctionSpaceType
>::
init
(
EntityType
&
en
)
const
{
if
(
!
uniform_
)
if
(
!
uniform_
||
!
init_
)
{
numOfDof_
=
fSpace_
.
getBaseFunctionSet
(
en
).
getNumberOfBaseFunctions
();
...
...
@@ -505,6 +505,8 @@ namespace Dune
if
(
numOfDof_
>
this
->
values_
.
size
())
this
->
values_
.
resize
(
numOfDof_
);
init_
=
true
;
}
for
(
int
i
=
0
;
i
<
numOfDof_
;
i
++
)
...
...
This diff is collapsed.
Click to expand it.
fem/discfuncarray/discfuncarray.cc
+
4
−
2
View file @
6d9e0143
...
...
@@ -418,7 +418,7 @@ namespace Dune
LocalFunctionArray
(
const
DiscreteFunctionSpaceType
&
f
,
Array
<
RangeFieldType
>
&
dofVec
)
:
fSpace_
(
f
),
dofVec_
(
dofVec
)
,
next_
(
0
)
,
uniform_
(
true
)
{}
,
uniform_
(
true
)
,
init_
(
false
)
{}
template
<
class
DiscreteFunctionSpaceType
>
inline
LocalFunctionArray
<
DiscreteFunctionSpaceType
>::~
LocalFunctionArray
()
...
...
@@ -520,7 +520,7 @@ namespace Dune
inline
bool
LocalFunctionArray
<
DiscreteFunctionSpaceType
>::
init
(
EntityType
&
en
)
const
{
if
(
!
uniform_
)
if
(
!
uniform_
||
!
init_
)
{
numOfDof_
=
fSpace_
.
getBaseFunctionSet
(
en
).
getNumberOfBaseFunctions
();
...
...
@@ -529,6 +529,8 @@ namespace Dune
if
(
numOfDof_
>
values_
.
size
())
values_
.
resize
(
numOfDof_
);
init_
=
true
;
}
for
(
int
i
=
0
;
i
<
numOfDof_
;
i
++
)
...
...
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