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

Port the adapter to preCICE v3 #285

Merged
merged 9 commits into from
Aug 4, 2023
Merged

Conversation

davidscn
Copy link
Member

@davidscn davidscn commented Mar 20, 2023

This PR includes most of the changes required to port the adapter to use the upcoming preCICE v3.

Depends on #266 and implements precice/precice#1471

Follow-up regarding connectivity: #297.

Related to #235.

TODO list:

  • I updated the documentation in docs/
  • I added a changelog entry in changelog-entries/ (create directory if missing)

Copy link
Member

@MakisH MakisH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice, thanks for all the effort!

Can we now make this PR the central/single PR that ports the adapter to v3? This means changing the title and description. It is currently a bit lost like this.

The only thing missing seems to be the connectivity: (#258)

Interface.C: In member function ‘void preciceAdapter::Interface::configureMesh(const Foam::fvMesh&, const string&, const string&)’:
Interface.C:306:26: error: ‘class precice::Participant’ has no member named ‘getMeshVertexIDsFromPositions’
  306 |                 precice_.getMeshVertexIDsFromPositions(meshID_, faceField.size() * (triaPerQuad * nodesPerTria), triCoords, triVertIDs);
      |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Interface.C:313:30: error: ‘class precice::Participant’ has no member named ‘setMeshTriangleWithEdges’; did you mean ‘setMeshTriangles’?
  313 |                     precice_.setMeshTriangleWithEdges(meshID_, triVertIDs[facei * nodesPerTria], triVertIDs[facei * nodesPerTria + 1], triVertIDs[facei * nodesPerTria + 2]);
      |                              ^~~~~~~~~~~~~~~~~~~~~~~~
      |                              setMeshTriangles

Adapter.C Show resolved Hide resolved
Adapter.H Outdated Show resolved Hide resolved
docs/changelog-entries/262.md Outdated Show resolved Hide resolved
@MakisH
Copy link
Member

MakisH commented Jul 24, 2023

Since other projects depend on porting the OpenFOAM adapter to develop (@ezonta, @tirgendetwas), we can also temporarily work around the issue by removing the calls to the removed methods (which means that the tutorials relying on nearest-projection mapping would give different results). The workaround-connectivity-v3 branch compiles with preCICE develop. The flow-over-heated-plate tutorial (with config updates) completes.

@davidscn
Copy link
Member Author

Since other projects depend on porting the OpenFOAM adapter to develop (@ezonta, @tirgendetwas), we can also temporarily work around the issue by removing the calls to the removed methods (which means that the tutorials relying on nearest-projection mapping would give different results)

Yes. Right now, the nearest-projection configuration in the adapter has a mediocre usability at a debatable feature gain, so I would consider it rather low priority.

@MakisH MakisH mentioned this pull request Jul 25, 2023
1 task
@MakisH MakisH changed the title Port data and mesh IDs to actual names Port the adapter to preCICE v3 Jul 27, 2023
@MakisH MakisH mentioned this pull request Jul 27, 2023
7 tasks
@MakisH MakisH marked this pull request as ready for review July 27, 2023 09:14
Copy link
Member

@MakisH MakisH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@davidscn I would suggest that we merge this already, so that we rebase and move on with #297 and #298. Feel free to merge this one if you feel it is ready.

The CI currently fails because it is using preCICE v2.5.0. Let's fix this in a separate PR.

@davidscn davidscn merged commit 9e41eef into precice:develop Aug 4, 2023
@davidscn davidscn deleted the ids-names branch August 4, 2023 14:25
@MakisH MakisH mentioned this pull request Aug 8, 2023
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants