mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
use dune-alugrid instead of the old version from dune-grid if the module is available
This commit is contained in:
parent
9e39939e15
commit
6d6640fc9d
@ -23,11 +23,6 @@
|
||||
*/
|
||||
#include "config.h"
|
||||
|
||||
#if !HAVE_ALUGRID
|
||||
#warning "The ALUGrid Dune grid manager is required for this test."
|
||||
int main(int argc, char **argv)
|
||||
{}
|
||||
#else
|
||||
#include <ewoms/common/start.hh>
|
||||
#include "problems/fractureproblem.hh"
|
||||
|
||||
@ -36,5 +31,3 @@ int main(int argc, char **argv)
|
||||
typedef TTAG(FractureProblem) ProblemTypeTag;
|
||||
return Ewoms::start<ProblemTypeTag>(argc, argv);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@ -28,7 +28,12 @@
|
||||
#include <opm/core/utility/PropertySystem.hpp>
|
||||
#include <ewoms/common/parametersystem.hh>
|
||||
|
||||
#if HAVE_DUNE_ALUGRID
|
||||
#include <dune/alugrid/grid.hh>
|
||||
#else
|
||||
#include <dune/grid/alugrid.hh>
|
||||
#endif
|
||||
|
||||
#include <dune/common/fvector.hh>
|
||||
#include <dune/common/version.hh>
|
||||
|
||||
|
@ -25,7 +25,12 @@
|
||||
#define EWOMS_FRACTURE_PROBLEM_HH
|
||||
|
||||
#include <ewoms/parallel/mpihelper.hh>
|
||||
|
||||
#if HAVE_DUNE_ALUGRID
|
||||
#include <dune/alugrid/grid.hh>
|
||||
#else
|
||||
#include <dune/grid/alugrid.hh>
|
||||
#endif
|
||||
|
||||
#include <opm/material/fluidmatrixinteractions/RegularizedBrooksCorey.hpp>
|
||||
#include <opm/material/fluidmatrixinteractions/RegularizedVanGenuchten.hpp>
|
||||
|
@ -30,7 +30,12 @@
|
||||
#include <opm/material/fluidsystems/GasPhase.hpp>
|
||||
#include <opm/material/components/N2.hpp>
|
||||
|
||||
#if HAVE_DUNE_ALUGRID
|
||||
#include <dune/alugrid/grid.hh>
|
||||
#include <dune/alugrid/dgf.hh>
|
||||
#else
|
||||
#include <dune/grid/alugrid/2d/alugrid.hh>
|
||||
#endif
|
||||
|
||||
#include <dune/common/version.hh>
|
||||
#include <dune/common/fvector.hh>
|
||||
|
@ -27,7 +27,9 @@
|
||||
#include <dune/grid/yaspgrid.hh>
|
||||
#include <dune/grid/io/file/vtk/vtkwriter.hh>
|
||||
|
||||
#if HAVE_ALUGRID
|
||||
#if HAVE_DUNE_ALUGRID
|
||||
#include <dune/alugrid/grid.hh>
|
||||
#elif HAVE_ALUGRID
|
||||
#include <dune/grid/alugrid.hh>
|
||||
#endif // HAVE_ALUGRID
|
||||
|
||||
@ -99,7 +101,7 @@ void testIdenityMapping()
|
||||
template <class Grid>
|
||||
void writeTetrahedronSubControlVolumes(const Grid &grid)
|
||||
{
|
||||
#if HAVE_ALUGRID
|
||||
#if HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
typedef typename Grid::LeafGridView GridView;
|
||||
|
||||
typedef Dune::ALUGrid<dim, dim, Dune::cube, Dune::nonconforming> Grid2;
|
||||
@ -148,12 +150,12 @@ void writeTetrahedronSubControlVolumes(const Grid &grid)
|
||||
typedef Dune::VTKWriter<GridView2> VtkWriter;
|
||||
VtkWriter writer(grid2.leafView(), Dune::VTK::conforming);
|
||||
writer.write("tetrahedron-scvs", Dune::VTK::ascii);
|
||||
#endif // HAVE_ALUGRID
|
||||
#endif // HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
}
|
||||
|
||||
void testTetrahedron()
|
||||
{
|
||||
#if HAVE_ALUGRID
|
||||
#if HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
typedef Dune::ALUGrid<dim, dim, Dune::simplex, Dune::nonconforming> Grid;
|
||||
typedef Dune::GridFactory<Grid> GridFactory;
|
||||
GridFactory gf;
|
||||
@ -173,13 +175,13 @@ void testTetrahedron()
|
||||
writeTetrahedronSubControlVolumes(*grid);
|
||||
|
||||
delete grid;
|
||||
#endif // HAVE_ALUGRID
|
||||
#endif // HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
}
|
||||
|
||||
template <class Grid>
|
||||
void writeCubeSubControlVolumes(const Grid &grid)
|
||||
{
|
||||
#if HAVE_ALUGRID
|
||||
#if HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
typedef typename Grid::LeafGridView GridView;
|
||||
|
||||
typedef Dune::ALUGrid<dim, dim, Dune::cube, Dune::nonconforming> Grid2;
|
||||
@ -227,12 +229,12 @@ void writeCubeSubControlVolumes(const Grid &grid)
|
||||
typedef Dune::VTKWriter<GridView2> VtkWriter;
|
||||
VtkWriter writer(grid2.leafView(), Dune::VTK::conforming);
|
||||
writer.write("cube-scvs", Dune::VTK::ascii);
|
||||
#endif // HAVE_ALUGRID
|
||||
#endif // HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
}
|
||||
|
||||
void testCube()
|
||||
{
|
||||
#if HAVE_ALUGRID
|
||||
#if HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
typedef Dune::ALUGrid<dim, dim, Dune::cube, Dune::nonconforming> Grid;
|
||||
typedef Dune::GridFactory<Grid> GridFactory;
|
||||
GridFactory gf;
|
||||
@ -259,7 +261,7 @@ void testCube()
|
||||
writeCubeSubControlVolumes(*grid);
|
||||
|
||||
delete grid;
|
||||
#endif // HAVE_ALUGRID
|
||||
#endif // HAVE_DUNE_ALUGRID || HAVE_ALUGRID
|
||||
}
|
||||
|
||||
void testQuadrature()
|
||||
|
Loading…
Reference in New Issue
Block a user