Fix the PR that said it activated AMG.

Actually, it did not as it did set the define eith wrong
or the wrong locations. This commit fixes this and finally
makes AMG available.
This commit is contained in:
Markus Blatt 2017-05-22 19:35:38 +02:00
parent bf0937fae1
commit 59ca0b4424
5 changed files with 11 additions and 4 deletions

View File

@ -24,11 +24,13 @@
#include "config.h"
#endif // HAVE_CONFIG_H
// Include of opm/autodiff/FlowMainEbos.hpp has to come first
#include <opm/autodiff/FlowMainEbos.hpp>
#include <opm/material/densead/Evaluation.hpp>
#include <opm/autodiff/DuneMatrix.hpp>
#include <dune/grid/CpGrid.hpp>
#include <opm/autodiff/SimulatorFullyImplicitBlackoilEbos.hpp>
#include <opm/autodiff/FlowMainEbos.hpp>
// ----------------- Main program -----------------

View File

@ -24,7 +24,7 @@
#define OPM_FLOW_MAIN_EBOS_HEADER_INCLUDED
// Define making clear that the simulator supports AMG
#define FLOW_SUPPORT_AMG
#define FLOW_SUPPORT_AMG 1
#include <sys/utsname.h>
@ -40,6 +40,7 @@
#include <opm/autodiff/moduleVersion.hpp>
#include <opm/autodiff/ExtractParallelGridInformationToISTL.hpp>
#include <opm/autodiff/RedistributeDataHandles.hpp>
#include <opm/autodiff/SimulatorFullyImplicitBlackoilEbos.hpp>
#include <opm/core/props/satfunc/RelpermDiagnostics.hpp>

View File

@ -317,7 +317,7 @@ namespace Opm
void
constructAMGPrecond(LinearOperator& /* linearOperator */, const POrComm& comm, std::unique_ptr< AMG >& amg, std::unique_ptr< MatrixOperator >& opA, const double relax ) const
{
ISTLUtility::createAMGPreconditionerPointer<pressureIndex>( *opA, relax, comm, amg );
ISTLUtility::template createAMGPreconditionerPointer<MatrixOperator,POrComm,AMG,pressureIndex>( *opA, relax, comm, amg );
}
@ -325,7 +325,7 @@ namespace Opm
void
constructAMGPrecond(MatrixOperator& opA, const POrComm& comm, std::unique_ptr< AMG >& amg, std::unique_ptr< MatrixOperator >&, const double relax ) const
{
ISTLUtility::createAMGPreconditionerPointer<pressureIndex>( opA, relax, comm, amg );
ISTLUtility::template createAMGPreconditionerPointer<MatrixOperator,POrComm,AMG,pressureIndex>( opA, relax, comm, amg );
}
/// \brief Solve the system using the given preconditioner and scalar product.

View File

@ -23,6 +23,9 @@
#include <config.h>
// Define making clear that the simulator supports AMG
#define FLOW_SUPPORT_AMG !defined(HAVE_UMFPACK)
#include <opm/autodiff/DuneMatrix.hpp>
#include <opm/autodiff/AdditionalObjectDeleter.hpp>
#include <opm/autodiff/CPRPreconditioner.hpp>

View File

@ -37,6 +37,7 @@
#include <opm/core/wells.h>
#include <opm/core/wells/DynamicListEconLimited.hpp>
#include <opm/core/wells/WellCollection.hpp>
#include <opm/core/simulator/SimulatorReport.hpp>
#include <opm/autodiff/VFPProperties.hpp>
#include <opm/autodiff/VFPInjProperties.hpp>
#include <opm/autodiff/VFPProdProperties.hpp>