Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-functions-debug
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
Container registry
Model registry
Operate
Environments
Monitor
Incidents
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
graeser
dune-functions-debug
Commits
dbf48424
Commit
dbf48424
authored
7 years ago
by
oliver.sander_at_tu-dresden.de
Browse files
Options
Downloads
Patches
Plain Diff
Separate unit test for LagrangeDGBasis
parent
d0068101
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dune/functions/functionspacebases/test/CMakeLists.txt
+2
-0
2 additions, 0 deletions
dune/functions/functionspacebases/test/CMakeLists.txt
dune/functions/functionspacebases/test/lagrangedgbasistest.cc
+56
-0
56 additions, 0 deletions
.../functions/functionspacebases/test/lagrangedgbasistest.cc
with
58 additions
and
0 deletions
dune/functions/functionspacebases/test/CMakeLists.txt
+
2
−
0
View file @
dbf48424
...
@@ -7,6 +7,8 @@ dune_add_test(SOURCES brezzidouglasmarinibasistest.cc)
...
@@ -7,6 +7,8 @@ dune_add_test(SOURCES brezzidouglasmarinibasistest.cc)
dune_add_test
(
SOURCES gridviewfunctionspacebasistest.cc
)
dune_add_test
(
SOURCES gridviewfunctionspacebasistest.cc
)
dune_add_test
(
SOURCES lagrangedgbasistest.cc
)
dune_add_test
(
SOURCES pq1nodalbasistest.cc
)
dune_add_test
(
SOURCES pq1nodalbasistest.cc
)
dune_add_test
(
SOURCES taylorhoodbasistest.cc
)
dune_add_test
(
SOURCES taylorhoodbasistest.cc
)
...
...
This diff is collapsed.
Click to expand it.
dune/functions/functionspacebases/test/lagrangedgbasistest.cc
0 → 100644
+
56
−
0
View file @
dbf48424
// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
// vi: set et ts=4 sw=2 sts=2:
#include
<config.h>
#include
<iostream>
#include
<dune/common/exceptions.hh>
#include
<dune/common/parallel/mpihelper.hh>
#include
<dune/grid/yaspgrid.hh>
#include
<dune/functions/functionspacebases/lagrangedgbasis.hh>
#include
<dune/functions/functionspacebases/test/basistest.hh>
using
namespace
Dune
;
using
namespace
Dune
::
Functions
;
int
main
(
int
argc
,
char
*
argv
[])
{
Dune
::
MPIHelper
::
instance
(
argc
,
argv
);
Dune
::
TestSuite
test
;
// Generate grid for testing
const
int
dim
=
2
;
typedef
YaspGrid
<
dim
>
GridType
;
FieldVector
<
double
,
dim
>
l
(
1
);
std
::
array
<
int
,
dim
>
elements
=
{{
10
,
10
}};
GridType
grid
(
l
,
elements
);
// check LagrangeDGBasis created 'manually'
{
typedef
GridType
::
LeafGridView
GridView
;
const
GridView
&
gridView
=
grid
.
leafGridView
();
LagrangeDGBasis
<
GridView
,
2
>
basis
(
gridView
);
test
.
subTest
(
checkBasis
(
basis
));
}
// check LagrangeDGBasis created using basis builder mechanism
{
using
namespace
Functions
::
BasisBuilder
;
auto
basis
=
makeBasis
(
grid
.
leafGridView
(),
lagrangeDG
<
2
>
());
test
.
subTest
(
checkBasis
(
basis
));
}
return
test
.
exit
();
}
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