Adapt code to dune-cornerpoint -> opm-grid renaming.

This commit is contained in:
Atgeirr Flø Rasmussen 2016-04-05 15:17:17 +02:00
parent 6f1cec4eec
commit 37c4bd16b1
14 changed files with 30 additions and 30 deletions

View File

@ -87,7 +87,7 @@ macro (prereqs_hook)
endmacro (prereqs_hook)
macro (sources_hook)
if(DUNE_CORNERPOINT_FOUND OR dune-cornerpoint_FOUND)
if(OPM_GRID_FOUND OR opm-grid_FOUND)
list (APPEND examples_SOURCES
${PROJECT_SOURCE_DIR}/examples/flow_mpi.cpp
${PROJECT_SOURCE_DIR}/examples/flow_multisegment_mpi.cpp

View File

@ -54,7 +54,7 @@ namespace Opm
init_rock);
}
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
/// Constructor wrapping an opm-core black oil interface.
BlackoilPropsAdFromDeck::BlackoilPropsAdFromDeck(Opm::DeckConstPtr deck,
Opm::EclipseStateConstPtr eclState,
@ -95,7 +95,7 @@ namespace Opm
init_rock);
}
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
/// Constructor wrapping an opm-core black oil interface.
BlackoilPropsAdFromDeck::BlackoilPropsAdFromDeck(Opm::DeckConstPtr deck,
Opm::EclipseStateConstPtr eclState,

View File

@ -42,7 +42,7 @@
#include <array>
#include <vector>
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
#include <opm/common/utility/platform_dependent/disable_warnings.h>
#include <dune/grid/CpGrid.hpp>
#include <opm/common/utility/platform_dependent/reenable_warnings.h>
@ -91,7 +91,7 @@ namespace Opm
const UnstructuredGrid& grid,
const bool init_rock = true );
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
/// Constructor to create a blackoil properties from an ECL deck.
///
/// The materialLawManager parameter represents the object from opm-material
@ -125,7 +125,7 @@ namespace Opm
const UnstructuredGrid& grid,
const bool init_rock = true );
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
/// Constructor to create a blackoil properties from an ECL deck.
///
/// \param deck The unprocessed ECL deck from opm-parser

View File

@ -24,7 +24,7 @@
#include <dune/common/shared_ptr.hh>
namespace Opm
{
#if defined(HAVE_DUNE_CORNERPOINT)
#if defined(HAVE_OPM_GRID)
#if defined(HAVE_MPI) && defined(HAVE_DUNE_ISTL) && DUNE_VERSION_NEWER(DUNE_GRID, 2, 3)
// Extracts the information about the data decomposition from the grid for dune-istl
void extractParallelGridInformationToISTL(const Dune::CpGrid& grid, boost::any& anyComm)
@ -45,5 +45,5 @@ void extractParallelGridInformationToISTL(const Dune::CpGrid& grid, boost::any&
void extractParallelGridInformationToISTL(const Dune::CpGrid&, boost::any&)
{}
#endif //defined(HAVE_MPI) && defined(HAVE_DUNE_ISTL) && DUNE_VERSION_NEWER(DUNE_GRID, 2, 3)
#endif //defined(HAVE_DUNE_CORNERPOINT)
#endif //defined(HAVE_OPM_GRID)
} // end namespace Opm

View File

@ -19,7 +19,7 @@
*/
#ifndef OPM_EXTRACTPARALLELGRIDINFORMATIONTOISTL_HEADER_INCLUDED
#define OPM_EXTRACTPARALLELGRIDINFORMATIONTOISTL_HEADER_INCLUDED
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
#include<dune/grid/CpGrid.hpp>
#include<boost/any.hpp>
@ -40,5 +40,5 @@ namespace Opm
void extractParallelGridInformationToISTL(const Dune::CpGrid& grid, boost::any& anyComm);
} // end namespace Opm
#endif //defined(HAVE_DUNE_CORNERPOINT)
#endif //defined(HAVE_OPM_GRID)
#endif // OPM_EXTRACTPARALLELGRIDINFORMATIONTOISTL_HEADER_INCLUDED

View File

@ -36,7 +36,7 @@
#include <Eigen/Eigen>
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
#include <dune/common/version.hh>
#include <dune/grid/CpGrid.hpp>
#include <dune/grid/common/mcmgmapper.hh>
@ -432,7 +432,7 @@ namespace Opm
const int dim = Opm::UgGridHelpers::dimensions(grid);
const double* faceNormal = Opm::UgGridHelpers::faceNormal(grid, faceIdx);
#if HAVE_DUNE_CORNERPOINT
#if HAVE_OPM_GRID
assert( dim <= 3 );
Dune::FieldVector< double, 3 > scaledFaceNormal( 0 );
for (int indx = 0; indx < dim; ++indx) {

View File

@ -77,7 +77,7 @@ void extractInternalFaces(const UnstructuredGrid& grid,
}
} // end namespace AutoDiffGrid
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
namespace AutoDiffGrid
{
@ -131,5 +131,5 @@ void extractInternalFaces(const Dune::CpGrid& grid,
}
} // end namespace AutoDiffGrid
#endif // HAVE_DUNE_CORNERPOINT
#endif // HAVE_OPM_GRID
} // end namespace Opm

View File

@ -33,7 +33,7 @@
#include <boost/range/iterator_range.hpp>
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
#include <dune/grid/CpGrid.hpp>
#include <dune/grid/cpgrid/GridHelpers.hpp>
#include <dune/grid/polyhedralgrid.hh>
@ -78,7 +78,7 @@ void extractInternalFaces(const UnstructuredGrid& grid,
} // end namespace AutoDiffGrid
} // end namespace Opm
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
namespace Opm
{
@ -144,7 +144,7 @@ struct ADFaceCellTraits<UnstructuredGrid>
typedef Eigen::Array<int, Eigen::Dynamic, 2, Eigen::RowMajor> Type;
};
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
// specialization for PolyhedralGrid as a fallback to UnstructuredGrid
template< int dim, int dimworld >
struct ADFaceCellTraits< Dune::PolyhedralGrid< dim, dimworld > >

View File

@ -24,7 +24,7 @@
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
#include <opm/core/grid/GridManager.hpp>
#if HAVE_DUNE_CORNERPOINT
#if HAVE_OPM_GRID
#include <dune/grid/CpGrid.hpp>
#endif
@ -67,7 +67,7 @@ namespace Opm
};
#if HAVE_DUNE_CORNERPOINT
#if HAVE_OPM_GRID
/// Specialization for CpGrid.
template <>
class GridInit<Dune::CpGrid>
@ -86,7 +86,7 @@ namespace Opm
private:
Dune::CpGrid grid_;
};
#endif // HAVE_DUNE_CORNERPOINT
#endif // HAVE_OPM_GRID
} // namespace Opm

View File

@ -29,7 +29,7 @@
#include <opm/autodiff/WellStateFullyImplicitBlackoil.hpp>
#include <opm/autodiff/WellStateFullyImplicitBlackoil.hpp>
#if HAVE_DUNE_CORNERPOINT
#if HAVE_OPM_GRID
#include <dune/grid/common/p2pcommunicator.hh>
#endif
@ -91,7 +91,7 @@ namespace Opm
virtual const int* globalCell() const { return grid_.global_cell; }
};
#if HAVE_DUNE_CORNERPOINT
#if HAVE_OPM_GRID
template <>
class ParallelDebugOutput< Dune::CpGrid> : public ParallelDebugOutputInterface
{
@ -583,7 +583,7 @@ namespace Opm
// true if we are on I/O rank
const bool isIORank_;
};
#endif // #if HAVE_DUNE_CORNERPOINT
#endif // #if HAVE_OPM_GRID
} // end namespace Opm
#endif

View File

@ -46,7 +46,7 @@ inline void distributeGridAndData( Grid& ,
{
}
#if HAVE_DUNE_CORNERPOINT && HAVE_MPI
#if HAVE_OPM_GRID && HAVE_MPI
/// \brief a data handle to distribute the threshold pressures
class ThresholdPressureDataHandle
{

View File

@ -41,7 +41,7 @@
#include <boost/filesystem.hpp>
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
#include <opm/common/utility/platform_dependent/disable_warnings.h>
#include <dune/common/version.hh>
#include <dune/grid/io/file/vtk/vtkwriter.hh>
@ -203,7 +203,7 @@ namespace Opm
}
#endif
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
void outputStateVtk(const Dune::CpGrid& grid,
const Opm::SimulationDataContainer& state,
const int step,

View File

@ -46,7 +46,7 @@
#include <boost/filesystem.hpp>
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
#include <dune/grid/CpGrid.hpp>
#endif
namespace Opm
@ -69,7 +69,7 @@ namespace Opm
void outputWellStateMatlab(const Opm::WellState& well_state,
const int step,
const std::string& output_dir);
#ifdef HAVE_DUNE_CORNERPOINT
#ifdef HAVE_OPM_GRID
void outputStateVtk(const Dune::CpGrid& grid,
const Opm::SimulationDataContainer& state,
const int step,

View File

@ -35,7 +35,7 @@
#include <opm/parser/eclipse/Deck/Deck.hpp>
#include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
#if HAVE_DUNE_CORNERPOINT
#if HAVE_OPM_GRID
#include <dune/common/version.hh>
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,3)
#include <dune/common/parallel/mpihelper.hh>
@ -261,7 +261,7 @@ void checkTransmissibilityValues(const G& grid,
}
}
#if HAVE_DUNE_CORNERPOINT
#if HAVE_OPM_GRID
BOOST_AUTO_TEST_CASE(TransmissibilityMultipliersCpGrid)
{
int argc = 1;