A question of docs of "couple your code"

Hi,everyone

Recently I read the step 3 of “couple your code”, and I notice that in the example code of coupling meshes and access coupling data,

int displacementsDim = precice.getDataDimensions("Displacements")

this line shows a API of getting dimension of displacement data, but I find the corresponding API in the Participant.hpp,

 int getDataDimensions(::precice::string_view meshName, ::precice::string_view dataName) const;

it need meshName also, so I wonder if the parameter is ignored by some reason?

p.s. The line ‘int forcesDim = precice.getDataDimensions(“FluidMesh”, "Forces)’ is missing the quotes for ‘Forces’

Definitely a typo, thank you for reporting! :hugs: I suggested an edit: Fix typos in code example of couple-your-code step 3 by MakisH · Pull Request #349 · precice/precice.github.io · GitHub

Let us know if you spot more such typos, or directly fix them (click “Edit” on the website).

The documentation is maintained by hand, the code examples are not compiled, so this can happen.

1 Like

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