precice / micro-manager

A manager tool to facilitate two-scale coupling in multi-physics simulations using preCICE.
GNU Lesser General Public License v3.0
16 stars 11 forks source link

Handling of BoundingBox for Receiving Mesh compared to preCICE API #97

Closed steffenger closed 6 months ago

steffenger commented 7 months ago

In the couple your code section the Bounding Box is defined by two corners.

std::vector<double> boundingBox {
        0, 0, 0, // minimum corner
        1, 1, 1 // maximum corner
    };

While the macro domain bounds are defined that way

[xmin, xmax, ymin, ymax, zmin, zmax]

I was wondering why the two are not the same:D

uekerman commented 6 months ago

The Python API below. I guess there is some conversion happening.

https://github.com/precice/python-bindings/blob/461a6fadbebf4a74a7ee1fd3882b3d75d5eefcca/cyprecice/cyprecice.pyx#L957-L1011

IshaanDesai commented 6 months ago

The Python API below

Good point mentioning the Python API here. In the Micro Manager configuration, I would tend to remain consistent with the Python API of preCICE rather than the C++ API, as it is a tool which relies on the Python bindings.