diff --git a/Adapter.C b/Adapter.C index 518cd45a..61981018 100644 --- a/Adapter.C +++ b/Adapter.C @@ -789,6 +789,7 @@ void preciceAdapter::Adapter::reloadMeshPoints() // TODO // Switch oldpoints on for pure physics. (is this required?). Switch off for better mesh deformation capabilities? // const_cast(mesh_.points()) = oldMeshPoints_; + const_cast(mesh_).move(); const_cast(mesh_).movePoints(meshPoints_); DEBUG(adapterInfo("Moved mesh points to their previous locations.")); @@ -834,21 +835,27 @@ void preciceAdapter::Adapter::setupMeshVolCheckpointing() DEBUG(adapterInfo("Creating a list of the mesh volume checkpointed fields...")); // Add the V0 and the V00 to the list of checkpointed fields. // For V0 - addVolCheckpointField( - const_cast( - mesh_.V0())); + if (mesh_.foundObject("V0")) + { + addVolCheckpointField( + const_cast( + mesh_.V0())); #ifdef ADAPTER_DEBUG_MODE - adapterInfo( - "Added " + mesh_.V0().name() + " in the list of checkpointed fields."); + adapterInfo( + "Added " + mesh_.V0().name() + " in the list of checkpointed fields."); #endif + } // For V00 - addVolCheckpointField( - const_cast( - mesh_.V00())); + if (mesh_.foundObject("V00")) + { + addVolCheckpointField( + const_cast( + mesh_.V00())); #ifdef ADAPTER_DEBUG_MODE - adapterInfo( - "Added " + mesh_.V00().name() + " in the list of checkpointed fields."); + adapterInfo( + "Added " + mesh_.V00().name() + " in the list of checkpointed fields."); #endif + } // Also add the buffer fields. // TODO For V0 @@ -858,23 +865,24 @@ void preciceAdapter::Adapter::setupMeshVolCheckpointing() ( mesh_.V0() ) - ); */ + ); #ifdef ADAPTER_DEBUG_MODE adapterInfo( "Added " + mesh_.V0().name() + " in the list of buffer checkpointed fields."); #endif // TODO For V00 - /* addVolCheckpointFieldBuffer + addVolCheckpointFieldBuffer ( const_cast ( mesh_.V00() ) - );*/ + ); #ifdef ADAPTER_DEBUG_MODE adapterInfo( "Added " + mesh_.V00().name() + " in the list of buffer checkpointed fields."); #endif + */ } diff --git a/FSI/ForceBase.C b/FSI/ForceBase.C index 2b4514e7..2c5c583e 100644 --- a/FSI/ForceBase.C +++ b/FSI/ForceBase.C @@ -95,10 +95,10 @@ Foam::tmp preciceAdapter::FSI::ForceBase::mu() const { if (solverType_.compare("incompressible") == 0) { - if (mesh_.foundObject(basicThermo::dictName)) + if (mesh_.foundObject(physicalProperties::typeName)) { const fluidThermo& thermo = - mesh_.lookupObject(basicThermo::dictName); + mesh_.lookupObject(physicalProperties::typeName); return thermo.mu(); } diff --git a/FSI/ForceBase.H b/FSI/ForceBase.H index 58b50928..75107f46 100644 --- a/FSI/ForceBase.H +++ b/FSI/ForceBase.H @@ -9,7 +9,7 @@ #include "pointFields.H" #include "vectorField.H" #include "compressibleMomentumTransportModel.H" -#include "kinematicMomentumTransportModel.H" +#include "incompressibleMomentumTransportModel.H" namespace preciceAdapter { diff --git a/Make/options b/Make/options index 35ec8e4f..fc31eb84 100644 --- a/Make/options +++ b/Make/options @@ -1,13 +1,13 @@ EXE_INC = \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(LIB_SRC)/meshTools/lnInclude \ - -I$(LIB_SRC)/transportModels/ \ + -I$(LIB_SRC)/physicalProperties/lnInclude \ -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \ -I$(LIB_SRC)/ThermophysicalTransportModels/lnInclude \ + -I$(LIB_SRC)/physicalProperties/lnInclude \ -I$(LIB_SRC)/MomentumTransportModels/momentumTransportModels/lnInclude \ -I$(LIB_SRC)/MomentumTransportModels/compressible/lnInclude \ -I$(LIB_SRC)/MomentumTransportModels/incompressible/lnInclude \ - -I$(LIB_SRC)/transportModels/lnInclude \ -I$(LIB_SRC)/triSurface/lnInclude \ $(ADAPTER_PKG_CONFIG_CFLAGS) \ -I../ \ @@ -16,7 +16,7 @@ EXE_INC = \ LIB_LIBS = \ -lfiniteVolume \ -lmeshTools \ - -ltransportModels \ + -lphysicalProperties \ -lmomentumTransportModels \ -lincompressibleMomentumTransportModels \ -lcompressibleMomentumTransportModels \ diff --git a/preciceAdapterFunctionObject.H b/preciceAdapterFunctionObject.H index 0e29e3c2..d3eda1e7 100644 --- a/preciceAdapterFunctionObject.H +++ b/preciceAdapterFunctionObject.H @@ -133,6 +133,13 @@ public: //- Write the preciceAdapterFunctionObject bool write() final; + //- Return the list of fields required + // (pure virtual since OpenFOAM 10) + virtual wordList fields() const + { + return wordList::null(); + } + /* // NOTE: If you add a new module that needs to execute methods // whenever the mesh is updated or its points moved,