[Dune] question about getting vertex data
Timo Koch
timo.koch at iws.uni-stuttgart.de
Mon Dec 18 23:44:21 CET 2017
Dear Ilya,
for any 1d grid in any world dimension you will get the local vertex index (in local numbering of the inside element (entity of codimension 0)) by intersection.indexInInside() member function.
You can then use a mapper like Dune::MultipleCodimMultipleGeomTypeMapper (with a VertexLayout) to get the vertex index on the gridview using the subIndex() member function.
In total the call could look something like this
auto vertexIndex = vertexMapper.subIndex(element, intersection.indexInInside(), /*codimension=*/ 1);
I’m happy you are using Dune::FoamGrid and hope you find it useful. Do you mind sharing for what application / in which field you are using it?
Best wishes
Timo
> On 18. Dec 2017, at 23:13, Ponomarev, Ilya <ilya.ponomarev at phystech.edu> wrote:
>
> Good evening.
>
> I have FoamGrid mesh 1d in 3d world and data, that stored in massive.
> This data are associated with vertex (first massive) and cells (second massive).
> When I iterate over cells and work with intersections in FV method, how can I get the index of vertex, which coincides with intersection?
>
> Best regards,
> Ilya Ponomarev.
> _______________________________________________
> Dune mailing list
> Dune at lists.dune-project.org
> http://lists.dune-project.org/mailman/listinfo/dune
More information about the Dune
mailing list