Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pacxx-projectseminar-2019
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
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
Code review analytics
Issue analytics
Insights
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
Vladyslav Kucher
pacxx-projectseminar-2019
Commits
f6c43db0
Commit
f6c43db0
authored
6 years ago
by
Jö Fahlke
Browse files
Options
Downloads
Patches
Plain Diff
constraints(): predicate only gets intersection
parent
a8d0d2ac
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/constraints.hh
+1
-4
1 addition, 4 deletions
src/constraints.hh
src/driver.hh
+5
-3
5 additions, 3 deletions
src/driver.hh
with
6 additions
and
7 deletions
src/constraints.hh
+
1
−
4
View file @
f6c43db0
...
...
@@ -31,11 +31,8 @@ namespace PPS {
{
if
(
intersection
.
boundary
())
{
// center of face
auto
testpoint
=
referenceElement
(
intersection
.
geometry
()).
position
(
0
,
0
);
// skip if this isn't a Dirichlet boundary
if
(
!
isDirichlet
(
intersection
,
testpoint
))
if
(
!
isDirichlet
(
intersection
))
continue
;
const
int
face
=
intersection
.
indexInInside
();
...
...
This diff is collapsed.
Click to expand it.
src/driver.hh
+
5
−
3
View file @
f6c43db0
...
...
@@ -53,10 +53,12 @@ void driver (const GV& gv, Dune::ParameterTree& ptree)
using
LFE
=
Dune
::
Q1LocalFiniteElement
<
DF
,
RF
,
dim
>
;
//== Exercise 2 {
#ifndef NITSCHE
auto
blambda
=
[
&
](
const
auto
&
i
,
const
auto
&
x
)
{
return
problem
.
b
(
i
,
x
);};
auto
isDirichlet
=
[
&
](
const
auto
&
intersection
)
{
auto
testpoint
=
referenceElement
(
intersection
.
geometry
()).
position
(
0
,
0
);
return
problem
.
b
(
intersection
,
testpoint
);
};
std
::
set
<
std
::
size_t
>
cc
;
PPS
::
constraints
(
blambda
,
gv
,
LFE
{},
cc
);
// assemble constraints
PPS
::
constraints
(
isDirichlet
,
gv
,
LFE
{},
cc
);
// assemble constraints
std
::
cout
<<
"constrained dofs="
<<
cc
.
size
()
<<
" of "
<<
gv
.
indexSet
().
size
(
gv
.
dimension
)
<<
std
::
endl
;
#endif
...
...
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