Fluid solver mesh - How to link a solid mesh with a fluid mesh

Hi,
having implemented a structure solver with the python interface of preCICE,
I am now planning to couple a OpenFOAM fluid solver with preCICE.
In the documentation the implementation doesn’t seem to be very difficult but looking at the mesh,
I am wondering how I set up the correct mesh for the fluid solver.

Current status:
I have set up a mesh for the moving points of my rigid body in the solid solver.

Plan:

  • Implementation of the fluid solver → First coupling to a solverdummy

  • If necessary: Creation of a new mesh for the fluid solver.

For the fluid solver I will need the points of the rigid body transfered to cells and in addition I will need the cells of the farfield around the moving body.

Question:
Is there a way in preCICE to link specific cells (of the fluid mesh) to points (of the solid mesh) or do I have to add the farfield cells around my rigid body (transformed to points) to the solid mesh?
For the solid mesh, I have simplified the case to just a few points, but looking at the fluid solver, it seems to get a huge work, or am I missing an easy way to link solid an fluid mesh?

My first step would be to couple my current fluid simulation (mesh with many cells) with a solverdummy, but I don’t know how to create the mesh there.

Hi @JulianSchl,

I’m not sure if I unserstand your problem correct.

I guess you have already seen our OpenFOAM tutorials?

Is there any special reason to implement a fluid solver yourself? Why not using an OpenFOAM solver?

Why do you need the far-field cells? Do you really talk about cells or cell-faces? For me, it sound a bit like volume coupling instead of surface coupling? May I ask you to explain this a bit more in detail?

The ‘link’ is essentially the mapping in preCICE. If you really want to connect cells and points in a user-defined arbitrary fashion- that’s currently not possible. However, if you want to link cells and points in a clear and debug-able way you could select a nearest-neighbor mapping in your preCICE configuration. As the name suggests, the nearest-neighbor mapping links the nearest neighbors on your coupling interface. Still, I’m not sure if this is really what you were asking for. Usually, you don’t need to exchange far-field cells for standard FSI applications.

I am sorry, I expressed myself wrong, I do not want to implement a solver, but use the existing displacementLaplacian solver.

The farfield case is already created. It seems, that I didn’t express myself properly. Working some time with the OpenFOAM-Adapter, I have achieved a successful coupling and now understand, that I don’t have to map from cell to cell, but from mesh to mesh, which gets interpolated by preCICE.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.