New users can only take two links? wtf.
Issue to support incompressible multiphase: [#127]
Issue for the adapter changes: [#138]
preCICE version: 2.1.0
openfoam-adapter git commit: [c49b862]
OpenFOAM version: v2006
I try to setup an learning example to run an OpenFOAM heater case with three phases (air, water, vapor) with solid heating regions.
Solver for Fluid: icoReactingMultiphaseInterFoam
Solver for Heater[i]: laplacianFoam
I had setup an example case an pulished it under: cloud.thomas-enzinger.de
(Currently I’m not 100% sure if solid case is setup correctly. Fluid case works and create that problem bevor any solid case is running in preCICE)
Problem:
If I want to execute the fluid solver, the executions runs in a problem by the heat-flux initialisation.
---[preciceAdapter] [DEBUG] Creating interfaces...
---[preciceAdapter] [DEBUG] Number of face centres: 0
---[preciceAdapter] [DEBUG] Interface created on mesh Fluid-Mesh
---[preciceAdapter] [DEBUG] Adding coupling data writers...
---[preciceAdapter] [DEBUG] Added writer: Temperature.
---[preciceAdapter] [DEBUG] Adding coupling data readers...
--> FOAM Warning :
From void adapterInfo(std::string, std::string)
in file Utilities.C at line 50
e[31mError (deferred - will exit later) in the preCICE adapter: e[0m
lookup of turbulenceProperties from objectRegistry region0 successful
but it is not a compressibleTurbulenceModel, it is a kEpsilon
The error is produced by OpenFOAM in the adapter file KappaEffective.c, Line 17
mesh.lookupObject<compressible::turbulenceModel>(turbulenceModel::propertiesName)
Question
May be I do an wrong configuration in the prece-config.xml. Is someone here to take an look and do an check to all is configured correctly?
Discussion / Solution
Currently I’m not so deep in preCICE and OpenFOAM code base, but my basic thinking about the job of preCICE is to communicate with different solvers and transfer data between them.
The openfoam-adapter do also calculation steps, is interessted to turbulence models, … and so on. But why? I think it is not the job of preCICE and there adapters. Maybe to implement missing thinks, ok. But for generall purpose? I would say no as long as the solver also has possibilites to setup and calculate thinks.
For my problem OpenFOAM can calculate the wallHeatFlux out of the box.
[config file], [header] and [source]
So, the code should do the job on all offical shiped solvers with heat transfer support.
If I want to use this OpenFOAM feature, I need an general data field reader / writer
The implementation of an general data reader could be easy like the [CHT/Temperature] code. In preciceDict should also be possible to set up an mapping between openfoam fields and precice-data.
Expand precice-config.xml to introduce an type entry to data (–> clean code)
<data:scalar name="myShitNameForNothing" type="none|Temperature|Heat Flux|..." />
New module general in preCICEDict? Like
modules (GENERAL);
GENERAL
{
mapping
(
("data:name", "field name:OpenFOAM")
);
}
Could be this way possible?
By the way
The mpi initialisation in the ubuntu container (podman) looks strange. It’s all correct?
---[preciceAdapter] [DEBUG] Creating the preCICE solver interface...
---[preciceAdapter] [DEBUG] Number of processes: 10
---[preciceAdapter] [DEBUG] MPI rank: 0
---[precice] e[0m 1
---[precice] e[0m 1
---[precice] e[0m 1
---[precice] e[0m 1
---[precice] e[0m 0
---[precice] e[0m This is preCICE version 2.1.0
---[precice] e[0m Revision info: no-info [Git failed/Not a repository]
---[precice] e[0m Configuring preCICE with configu(https://github.com/precice/openfoam-adapter/commit/c49b862aab4845ae79b8b7257a20e15ba5a0019c)ration "precice-config.xml"
---[precice] e[0m I am participant "Fluid"
---[precice] e[0m Connecting Master to 9 Slaves