mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Merge pull request #2327 from akva2/bump_dune
Bump required dune version to 2.6
This commit is contained in:
@@ -306,13 +306,8 @@ public:
|
||||
typedef typename Vanguard::GridView LocalGridView;
|
||||
const LocalGridView localGridView = vanguard.gridView();
|
||||
|
||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<LocalGridView> ElementMapper;
|
||||
ElementMapper elemMapper(localGridView, Dune::mcmgElementLayout());
|
||||
#else
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<LocalGridView, Dune::MCMGElementLayout> ElementMapper;
|
||||
ElementMapper elemMapper(localGridView);
|
||||
#endif
|
||||
|
||||
localIdxToGlobalIdx_.resize(localGridView.size(0), -1);
|
||||
|
||||
@@ -325,13 +320,8 @@ public:
|
||||
globalCartesianIndex_.resize(globalSize, -1);
|
||||
const EquilGridView equilGridView = vanguard.equilGrid().leafGridView();
|
||||
|
||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<EquilGridView> EquilElementMapper;
|
||||
EquilElementMapper equilElemMapper(equilGridView, Dune::mcmgElementLayout());
|
||||
#else
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<EquilGridView, Dune::MCMGElementLayout> EquilElementMapper;
|
||||
EquilElementMapper equilElemMapper(equilGridView);
|
||||
#endif
|
||||
|
||||
// Scatter the global index to local index for lookup during restart
|
||||
ElementIndexScatterHandle<EquilElementMapper,ElementMapper> handle(equilElemMapper, elemMapper, localIdxToGlobalIdx_);
|
||||
|
||||
@@ -162,11 +162,7 @@ public:
|
||||
const auto& gridView = grid_->leafGridView();
|
||||
unsigned numFaces = grid_->numFaces();
|
||||
std::vector<double> faceTrans(numFaces, 0.0);
|
||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||
ElementMapper elemMapper(this->gridView(), Dune::mcmgElementLayout());
|
||||
#else
|
||||
ElementMapper elemMapper(this->gridView());
|
||||
#endif
|
||||
auto elemIt = gridView.template begin</*codim=*/0>();
|
||||
const auto& elemEndIt = gridView.template end</*codim=*/0>();
|
||||
for (; elemIt != elemEndIt; ++ elemIt) {
|
||||
|
||||
@@ -414,11 +414,7 @@ protected:
|
||||
typedef Dune::BiCGSTABSolver<TracerVector> TracerSolver;
|
||||
typedef Dune::MatrixAdapter<TracerMatrix, TracerVector , TracerVector > TracerOperator;
|
||||
typedef Dune::SeqScalarProduct< TracerVector > TracerScalarProduct ;
|
||||
#if DUNE_VERSION_NEWER(DUNE_ISTL, 2,6)
|
||||
typedef Dune::SeqILU< TracerMatrix, TracerVector, TracerVector > TracerPreconditioner;
|
||||
#else
|
||||
typedef Dune::SeqILUn< TracerMatrix, TracerVector, TracerVector > TracerPreconditioner;
|
||||
#endif
|
||||
|
||||
TracerOperator tracerOperator(M);
|
||||
TracerScalarProduct tracerScalarProduct;
|
||||
|
||||
@@ -133,11 +133,7 @@ public:
|
||||
const auto& eclGrid = eclState.getInputGrid();
|
||||
const auto& cartDims = cartMapper.cartesianDimensions();
|
||||
auto& transMult = eclState.getTransMult();
|
||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||
ElementMapper elemMapper(gridView, Dune::mcmgElementLayout());
|
||||
#else
|
||||
ElementMapper elemMapper(gridView);
|
||||
#endif
|
||||
|
||||
// get the ntg values, the ntg values are modified for the cells merged with minpv
|
||||
std::vector<double> ntg;
|
||||
@@ -491,11 +487,7 @@ private:
|
||||
const auto& gridView = vanguard_.gridView();
|
||||
const auto& cartMapper = vanguard_.cartesianIndexMapper();
|
||||
const auto& cartDims = cartMapper.cartesianDimensions();
|
||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||
ElementMapper elemMapper(gridView, Dune::mcmgElementLayout());
|
||||
#else
|
||||
ElementMapper elemMapper(gridView);
|
||||
#endif
|
||||
|
||||
const auto& fp = vanguard_.eclState().fieldProps();
|
||||
const auto& inputTranxData = fp.get_global_double("TRANX");
|
||||
|
||||
@@ -496,13 +496,8 @@ private:
|
||||
|
||||
typedef typename EquilGrid :: LeafGridView GlobalGridView;
|
||||
const GlobalGridView& globalGridView = globalGrid().leafGridView();
|
||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GlobalGridView> ElementMapper;
|
||||
ElementMapper globalElemMapper(globalGridView, Dune::mcmgElementLayout());
|
||||
#else
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GlobalGridView, Dune::MCMGElementLayout> ElementMapper;
|
||||
ElementMapper globalElemMapper(globalGridView);
|
||||
#endif
|
||||
|
||||
const EclTransmissibility<TypeTag>* globalTrans;
|
||||
|
||||
@@ -603,15 +598,9 @@ private:
|
||||
|
||||
typedef typename EquilGrid :: LeafGridView GlobalGridView;
|
||||
const GlobalGridView& globalGridView = globalGrid().leafGridView();
|
||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GlobalGridView> ElementMapper;
|
||||
ElementMapper globalElemMapper(globalGridView, Dune::mcmgElementLayout());
|
||||
|
||||
#else
|
||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GlobalGridView, Dune::MCMGElementLayout> ElementMapper;
|
||||
ElementMapper globalElemMapper(globalGridView);
|
||||
#endif
|
||||
|
||||
const EclTransmissibility<TypeTag>* globalTrans;
|
||||
if (!collectToIORank_.isParallel()) {
|
||||
// in the sequential case we must use the transmissibilites defined by
|
||||
|
||||
@@ -49,21 +49,6 @@ class EntityPointer;
|
||||
// specialization of dune-fem compatiblity functions for CpGrid, since CpGrid does not use the interface classes.
|
||||
namespace Fem {
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// make_entity for CpGrid entities
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
#if ! DUNE_VERSION_NEWER(DUNE_GRID, 2, 6)
|
||||
template <int codim>
|
||||
inline Dune::cpgrid::Entity<codim> make_entity(const Dune::cpgrid::EntityPointer<codim>& entityPointer)
|
||||
{ return *entityPointer; }
|
||||
|
||||
template <int codim>
|
||||
inline Dune::cpgrid::Entity<codim> make_entity(Dune::cpgrid::Entity<codim> entity)
|
||||
{ return std::move(entity); }
|
||||
#endif
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// GridEntityAccess for CpGrid entities
|
||||
|
||||
Reference in New Issue
Block a user