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
3c904c3e
Commit
3c904c3e
authored
19 years ago
by
Adrian Burri
Browse files
Options
Downloads
Patches
Plain Diff
Adapted for dimRange > 1
[[Imported from SVN: r3509]]
parent
171363ab
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
fem/common/basefunctionsets.cc
+10
-5
10 additions, 5 deletions
fem/common/basefunctionsets.cc
fem/common/basefunctionsets.hh
+14
-6
14 additions, 6 deletions
fem/common/basefunctionsets.hh
with
24 additions
and
11 deletions
fem/common/basefunctionsets.cc
+
10
−
5
View file @
3c904c3e
...
...
@@ -73,7 +73,8 @@ namespace Dune {
const
DomainType
&
xLocal
,
const
RangeType
&
factor
)
const
{
this
->
eval
(
util_
.
containedDof
(
baseFunct
),
xLocal
,
tmp_
);
baseFunctions_
[
util_
.
containedDof
(
baseFunct
)]
->
evaluate
(
diffVar0_
,
xLocal
,
tmp_
);
return
factor
[
util_
.
component
(
baseFunct
)]
*
tmp_
[
0
];
}
...
...
@@ -88,11 +89,15 @@ namespace Dune {
{
DomainType
gradScaled
(
0.
);
this
->
jacobian
(
util_
.
containedDof
(
baseFunct
),
xLocal
,
jTmp_
);
for
(
int
i
=
0
;
i
<
FunctionSpaceImp
::
DimDomain
;
++
i
)
{
diffVar1_
[
0
]
=
i
;
baseFunctions_
[
util_
.
containedDof
(
baseFunct
)]
->
evaluate
(
diffVar1_
,
xLocal
,
tmp_
);
jTmp_
[
i
]
=
tmp_
[
0
];
}
en
.
geometry
().
jacobianInverseTransposed
(
xLocal
).
umv
(
jTmp_
[
0
],
gradScaled
);
//! is this right?
//return factor[util_.component(baseFunct)]*jTmp[0];
umv
(
jTmp_
,
gradScaled
);
return
gradScaled
*
factor
[
util_
.
component
(
baseFunct
)];
}
...
...
This diff is collapsed.
Click to expand it.
fem/common/basefunctionsets.hh
+
14
−
6
View file @
3c904c3e
...
...
@@ -107,7 +107,11 @@ namespace Dune {
public:
VectorialBaseFunctionSet
(
const
FactoryType
&
factory
)
:
baseFunctions_
(),
util_
(
FunctionSpaceType
::
DimRange
)
util_
(
FunctionSpaceType
::
DimRange
),
diffVar0_
(),
diffVar1_
(
0
),
tmp_
(
0.
),
jTmp_
(
0.
)
{
for
(
int
i
=
0
;
i
<
factory
.
numBaseFunctions
();
++
i
)
{
baseFunctions_
.
push_back
(
factory
.
baseFunction
(
i
));
...
...
@@ -122,6 +126,8 @@ namespace Dune {
}
}
// * override other functions as well!!!!
int
numBaseFunctions
()
const
;
template
<
int
diffOrd
>
...
...
@@ -131,10 +137,10 @@ namespace Dune {
RangeType
&
phi
)
const
;
template
<
int
diffOrd
,
class
QuadratureType
>
void
evaluate
(
int
baseFunct
,
const
FieldVector
<
deriType
,
diffOrd
>
&
diffVariable
,
QuadratureType
&
quad
,
int
quadPoint
,
RangeType
&
phi
)
const
;
void
evaluate
(
int
baseFunct
,
const
FieldVector
<
deriType
,
diffOrd
>
&
diffVariable
,
QuadratureType
&
quad
,
int
quadPoint
,
RangeType
&
phi
)
const
;
// * add those methods with quadratures as well
DofType
evaluateSingle
(
int
baseFunct
,
...
...
@@ -151,8 +157,10 @@ namespace Dune {
std
::
vector
<
BaseFunctionType
*>
baseFunctions_
;
DofConversionUtility
<
PointBased
>
util_
;
mutable
FieldVector
<
int
,
0
>
diffVar0_
;
mutable
FieldVector
<
int
,
1
>
diffVar1_
;
mutable
ScalarRangeType
tmp_
;
mutable
ScalarJacobianRange
Type
jTmp_
;
mutable
Domain
Type
jTmp_
;
};
}
// end namespace Dune
...
...
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