Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build for OpenFOAM v11 #310

Open
wants to merge 5 commits into
base: OpenFOAMdev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions Adapter.H
Original file line number Diff line number Diff line change
Expand Up @@ -316,53 +316,53 @@ private:

// Add mesh checkpoint fields, depending on the type
//- Add a surfaceScalarField mesh field
void addMeshCheckpointField(surfaceScalarField& field);
void addMeshCheckpointField(Foam::surfaceScalarField& field);

//- Add a surfaceVectorField mesh field
void addMeshCheckpointField(surfaceVectorField& field);
void addMeshCheckpointField(Foam::surfaceVectorField& field);

//- Add a volVectorField mesh field
void addMeshCheckpointField(volVectorField& field);
void addMeshCheckpointField(Foam::volVectorField& field);

// TODO V0 and V00 checkpointed field.
//- Add the V0 and V00 checkpoint fields
void addVolCheckpointField(volScalarField::Internal& field);
void addVolCheckpointField(Foam::volScalarField::Internal& field);
// void addVolCheckpointFieldBuffer(volScalarField::Internal & field);

// Add checkpoint fields, depending on the type

//- Add a volScalarField to checkpoint
void addCheckpointField(volScalarField* field);
void addCheckpointField(Foam::volScalarField* field);

//- Add a volVectorField to checkpoint
void addCheckpointField(volVectorField* field);
void addCheckpointField(Foam::volVectorField* field);

//- Add a surfaceScalarField to checkpoint
void addCheckpointField(surfaceScalarField* field);
void addCheckpointField(Foam::surfaceScalarField* field);

//- Add a surfaceVectorField to checkpoint
void addCheckpointField(surfaceVectorField* field);
void addCheckpointField(Foam::surfaceVectorField* field);

//- Add a pointScalarField to checkpoint
void addCheckpointField(pointScalarField* field);
void addCheckpointField(Foam::pointScalarField* field);

//- Add a pointVectorField to checkpoint
void addCheckpointField(pointVectorField* field);
void addCheckpointField(Foam::pointVectorField* field);

// NOTE: Add here methods to add other object types to checkpoint,
// if needed.

//- Add a volTensorField to checkpoint
void addCheckpointField(volTensorField* field);
void addCheckpointField(Foam::volTensorField* field);

//- Add a surfaceTensorField to checkpoint
void addCheckpointField(surfaceTensorField* field);
void addCheckpointField(Foam::surfaceTensorField* field);

//- Add a pointTensorField to checkpoint
void addCheckpointField(pointTensorField* field);
void addCheckpointField(Foam::pointTensorField* field);

//- Add a volSymmTensorField to checkpoint
void addCheckpointField(volSymmTensorField* field);
void addCheckpointField(Foam::volSymmTensorField* field);

//- Read the checkpoint - restore the mesh fields and time
void readMeshCheckpoint();
Expand Down
6 changes: 2 additions & 4 deletions CHT/CHT.H
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
#include "CHT/SinkTemperature.H"
#include "CHT/HeatTransferCoefficient.H"

#include "fvCFD.H"

namespace preciceAdapter
{
namespace CHT
Expand Down Expand Up @@ -50,14 +48,14 @@ protected:
std::string determineSolverType();

//- Read the CHT-related options from the adapter's configuration file
bool readConfig(const IOdictionary& adapterConfig);
bool readConfig(const Foam::IOdictionary& adapterConfig);

public:
//- Constructor
ConjugateHeatTransfer(const Foam::fvMesh& mesh);

//- Configure
bool configure(const IOdictionary& adapterConfig);
bool configure(const Foam::IOdictionary& adapterConfig);

//- Add coupling data writers
bool addWriters(std::string dataName, Interface* interface);
Expand Down
2 changes: 1 addition & 1 deletion CHT/HeatFlux.C
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "HeatFlux.H"
#include "primitivePatchInterpolation.H"

#include "fvCFD.H"
#include "constrainPressure.H"

using namespace Foam;

Expand Down
1 change: 0 additions & 1 deletion CHT/HeatTransferCoefficient.C
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#include "HeatTransferCoefficient.H"

#include "fvCFD.H"
#include "mixedFvPatchFields.H"
#include "primitivePatchInterpolation.H"

Expand Down
2 changes: 1 addition & 1 deletion CHT/SinkTemperature.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include "CouplingDataUser.H"
#include "mixedFvPatchFields.H"
#include "fvCFD.H"
#include "findRefCell.H"

namespace preciceAdapter
{
Expand Down
2 changes: 1 addition & 1 deletion CHT/Temperature.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "findRefCell.H"

namespace preciceAdapter
{
Expand Down
6 changes: 2 additions & 4 deletions FF/FF.H
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
#include "FF/PressureGradient.H"
#include "FF/VelocityGradient.H"

#include "fvCFD.H"

namespace preciceAdapter
{
namespace FF
Expand Down Expand Up @@ -37,14 +35,14 @@ protected:
std::string determineSolverType();

//- Read the FF-related options from the adapter's configuration file
bool readConfig(const IOdictionary& adapterConfig);
bool readConfig(const Foam::IOdictionary& adapterConfig);

public:
//- Constructor
FluidFluid(const Foam::fvMesh& mesh);

//- Configure
bool configure(const IOdictionary& adapterConfig);
bool configure(const Foam::IOdictionary& adapterConfig);

//- Add coupling data writers
bool addWriters(std::string dataName, Interface* interface);
Expand Down
2 changes: 1 addition & 1 deletion FF/Pressure.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "findRefCell.H"

namespace preciceAdapter
{
Expand Down
3 changes: 2 additions & 1 deletion FF/PressureGradient.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "findRefCell.H"
#include "constrainPressure.H"

namespace preciceAdapter
{
Expand Down
3 changes: 2 additions & 1 deletion FF/Velocity.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "findRefCell.H"
#include "constrainHbyA.H"

namespace preciceAdapter
{
Expand Down
4 changes: 3 additions & 1 deletion FF/VelocityGradient.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "findRefCell.H"
#include "constrainPressure.H"
#include "constrainHbyA.H"

namespace preciceAdapter
{
Expand Down
2 changes: 1 addition & 1 deletion FSI/Displacement.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "findRefCell.H"
#include "fixedValuePointPatchFields.H"
#include "primitivePatchInterpolation.H"

Expand Down
2 changes: 1 addition & 1 deletion FSI/DisplacementDelta.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "findRefCell.H"
#include "fixedValuePointPatchFields.H"
#include "primitivePatchInterpolation.H"

Expand Down
6 changes: 2 additions & 4 deletions FSI/FSI.H
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
#include "FSI/Force.H"
#include "FSI/Stress.H"

#include "fvCFD.H"

namespace preciceAdapter
{
namespace FSI
Expand Down Expand Up @@ -51,15 +49,15 @@ protected:
std::string determineSolverType();

//- Read the FSI-related options from the adapter's configuration file
bool readConfig(const IOdictionary& adapterConfig);
bool readConfig(const Foam::IOdictionary& adapterConfig);

public:
//- Constructor
// We need also the runTime to access the timeName and the deltaT
FluidStructureInteraction(const Foam::fvMesh& mesh, const Foam::Time& runTime);

//- Configure
bool configure(const IOdictionary& adapterConfig);
bool configure(const Foam::IOdictionary& adapterConfig);

//- Add coupling data writers
bool addWriters(std::string dataName, Interface* interface);
Expand Down
2 changes: 1 addition & 1 deletion FSI/ForceBase.H
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

#include "CouplingDataUser.H"

#include "fvCFD.H"
#include "fvcGrad.H"

#include "pointFields.H"
#include "vectorField.H"
Expand Down
5 changes: 4 additions & 1 deletion Interface.H
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@

#include <string>
#include <vector>
#include "fvCFD.H"
#include <array>
#include "argList.H"
#include "timeSelector.H"
#include "findRefCell.H"
#include "CouplingDataUser.H"
#include "precice/SolverInterface.hpp"

Expand Down
13 changes: 6 additions & 7 deletions Make/options
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
EXE_INC = \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
-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)/MomentumTransportModels/momentumTransportModels/lnInclude \
-I$(LIB_SRC)/physicalProperties/lnInclude \
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
-I$(LIB_SRC)/ThermophysicalTransportModels/thermophysicalTransportModel/lnInclude \
-I$(LIB_SRC)/triSurface/lnInclude \
$(ADAPTER_PKG_CONFIG_CFLAGS) \
-I../ \
Expand All @@ -20,7 +19,7 @@ LIB_LIBS = \
-lmomentumTransportModels \
-lincompressibleMomentumTransportModels \
-lcompressibleMomentumTransportModels \
-lthermophysicalTransportModels \
-limmiscibleIncompressibleTwoPhaseMixture \
-lthermophysicalTransportModel \
-lfluidThermophysicalModels \
$(ADAPTER_PKG_CONFIG_LIBS) \
-lprecice
7 changes: 0 additions & 7 deletions preciceAdapterFunctionObject.H
Original file line number Diff line number Diff line change
Expand Up @@ -140,13 +140,6 @@ public:
return wordList::null();
}

//- 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,
Expand Down
28 changes: 28 additions & 0 deletions primitivePatchInterpolation.H
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// copied from OpenFOAMv10 which is missing
// on newer versions

#ifndef primitivePatchInterpolation_H
#define primitivePatchInterpolation_H

#include "PrimitivePatchInterpolation.H"
#include "PrimitivePatch.H"
#include "face.H"
#include "SubList.H"
#include "pointField.H"

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

namespace Foam
{
typedef PrimitivePatchInterpolation
<
PrimitivePatch<SubList<face>, const pointField&>
>
primitivePatchInterpolation;
}

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

#endif

// ************************************************************************* //
Loading