<div dir="ltr"><div><div>Dear Oliver and Jurgis,<br><br></div>Thank you very much for your replies and helps. The email from Jö seems to be helpful and I am currently working on it. I hope it solves the problem. I will update you as soon as I am finished with it.<br>
<br></div>Best regards and thanks,<br>Arya<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Jun 6, 2013 at 4:24 PM, Oliver Sander <span dir="ltr"><<a href="mailto:sander@igpm.rwth-aachen.de" target="_blank">sander@igpm.rwth-aachen.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Arya,<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
I am using .msh format produced by gmsh to prepare my grid and the tags attached to the entities. In a specific analysis, I need to find intersections with specific tags. These tags for any kind of<br>
elements are supported by .msh and also by dgf format and ALUGrid. What I need to do is to call the tags of intersections from dune. The same thing as what intersect->boundaryId() does is needed.<br>
However, boundaryId() gives the tags if and only if the intersection is of boundary type i.e. intersect->boundaryId() = true. I have read the dune tutorial in detail and also searched through out the<br>
class documentation but could not find how the tags can be retrieved if intersect->boundaryId() = false. Do you know if this is supported or implemented at all in dune?<br>
<br>
</blockquote>
<br></div>
The behavior of boundaryId() is not specified anywhere. In fact,<br>
different grid implementations return different things when you<br>
call it.<br>
<br>
It seems to me what you really want to do is attach data to faces.<br>
(i.e., codim-1 entities). Jö's email which Jurgis just resurrected<br>
gives you some information on how to do that.<br>
<br>
Unfortunately, IIRC even though you can tag faces in the .msh format,<br>
our gmsh reader doesn't actually forward that information.<br>
We'd happily accept patches.<br>
<br>
Best,<br>
Oliver<br>
<br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
Thank you in advance for your help,<br>
<br>
Arya<br>
<br>
<br></div><div class="im">
On Thu, Jun 6, 2013 at 1:24 PM, Jurgis Pods <<a href="mailto:jurgis.pods@iwr.uni-heidelberg.de" target="_blank">jurgis.pods@iwr.uni-<u></u>heidelberg.de</a> <mailto:<a href="mailto:jurgis.pods@iwr.uni-heidelberg.de" target="_blank">jurgis.pods@iwr.uni-<u></u>heidelberg.de</a>>> wrote:<br>
<br>
Hi Steffen,<br>
<br>
thanks for the hint! I actually got it to work, it turned out that my problem actually was that I used dune-multidomaingrid the wrong way!<br>
<br>
[Begin Off-topic]<br>
When defining the multidomain grid like this:<br>
<br></div>
typedef Dune::MultiDomainGrid<__<u></u>HostGrid,Dune::mdgrid::__<u></u>FewSubDomainsTraits<HostGrid::<u></u>__dimension,2,Dune::mdgrid::__<u></u>CellAndVertexCodims> > Grid;<div class="im"><br>
<br>
<br>
and then calling for an IntersectionIterator 'iit' the following:<br>
<br></div>
gv.indexSet().subIndex(*iit->_<u></u>_inside(), iit->indexInInside(), 1)<div class="im"><br>
<br>
<br>
on the multidomain gridview, everything goes well. But when calling this on a *subdomain* gridview:<br>
<br></div>
subgv.indexSet().subIndex(*__<u></u>iit->inside(), iit->indexInInside(), 1)<div class="im"><br>
<br>
<br>
the program would exit and complain with<br>
<br></div>
Dune reported error: GridError [invoke:/home/jpods/workspace/<u></u>__dev/dune-multidomaingrid/<u></u>dune/__grid/multidomaingrid/__<u></u>indexsets.hh:92]: codim not supported<div class="im"><br>
<br>
<br>
Apparently, the lesson learned is to only use the subIndex() method on the multidomain gridview.<br>
[End Off-topic]<br>
<br>
Thanks again!<br>
Jurgis<br>
<br>
<br>
On 06.06.2013 10:13, Steffen Müthing wrote:<br>
<br>
Hi Jurgis,<br>
<br>
you don't need actual face entity objects to do this, you just need their indices (and those should be provided by<br>
all DUNE grids, if I understand the grid paper correctly - you are fine at least, because YaspGrid definitely provides<br>
indices for faces). If your grid does not support face entities, you can still get their indices with the help of the cell<br>
entity if you know the embedding of the face in the cell (usually from Intersection::indexInInside() ). You can even get<br>
the indices of the face's subentities. Take a look at IndexSet::subIndex() for the details.<br>
<br>
That said (and slightly off-topic for this list), I don't have the slightest idea if IntersectionIndexSet still works. That thing<br>
was only ever really used by Sven's mimetic FD code, and that hasn't been maintained for quite a while now. YMMV<br>
(it's definitely broken in PDELab master, though)...<br>
<br>
Steffen<br>
<br>
Am 05.06.2013 um 14:58 schrieb Jurgis Pods:<br>
<br>
Hi Steffen,<br>
<br>
this approach (using PDELab's IntersectionIndexSet) will not work on grids which do not support codim-1 entities, will it? Does this mean I have to use an IdSet in this case?<br>
<br>
Jurgis<br>
<br>
<br></div><div class="im">
On <a href="tel:07.11.2012%2022" value="+41711201222" target="_blank">07.11.2012 22</a> <tel:07.11.2012%2022>:21, Steffen Müthing wrote:<br>
<br>
Hi Marco,<br>
<br>
as long as your grid has a conforming macro grid (which is true for every Dune grid I know),<br>
you can always associate the data with the face belonging to the more-refined<br>
entity (the one with the higher level), or with the face belonging to the cell with<br>
the lower index (if the levels are the same). To get the index of that face, you can<br>
use the subIndex() method of the IndexSet with the cell and the value of indexInInside()<br>
or indexInOutside() from the intersection.<br>
<br>
In PDELab, there is an IntersectionIndexSet that does something like that. Perhaps you<br>
can simply use that, or you can use it as inspiration for your own implementation… ;-)<br>
<br>
Steffen<br>
<br>
<br>
Am 07.11.2012 um 18:03 schrieb Marco Cisternino:<br>
<br>
<br>
Hi Duners,<br>
I need to attach data to intersections. I would like to avoid redundance of data (using a mapper to elements and attaching a stl container to store values on its intersections) and<br>
time consumption to access data (using a stl map).<br>
I wonder if something like a mapper is available for intersections. Choosing the right layout for a MCMG mapper would not work, I guess, on non conforming grid, doesn't it?<br>
Thank you very much, again.<br>
<br>
Marco<br>
<br>
<br>
--<br>
Marco Cisternino<br>
Optimad Engineering s.r.l.<br>
<br></div>
<a href="http://www.optimad.it" target="_blank">www.optimad.it</a> <<a href="http://www.optimad.it" target="_blank">http://www.optimad.it</a>><br>
<a href="mailto:marco.cisternino@optimad.it" target="_blank">marco.cisternino@optimad.it</a> <mailto:<a href="mailto:marco.cisternino@optimad.it" target="_blank">marco.cisternino@<u></u>optimad.it</a>><br>
<br>
<a href="tel:%2B3901119719782" value="+3901119719782" target="_blank">+3901119719782</a> <tel:%2B3901119719782><br>
<br>
<br>
______________________________<u></u>___________________<br>
Dune mailing list<br>
<br>
<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a> <mailto:<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a>><br>
<a href="http://lists.dune-project.org/__mailman/listinfo/dune" target="_blank">http://lists.dune-project.org/<u></u>__mailman/listinfo/dune</a> <<a href="http://lists.dune-project.org/mailman/listinfo/dune" target="_blank">http://lists.dune-project.<u></u>org/mailman/listinfo/dune</a>><div class="im">
<br>
<br>
Steffen Müthing<br>
Universität Stuttgart<br>
Institut für Parallele und Verteilte Systeme<br>
Universitätsstr. 38<br>
70569 Stuttgart<br></div>
Tel: <a href="tel:%2B49%20711%20685%2088429" value="+4971168588429" target="_blank">+49 711 685 88429</a> <tel:%2B49%20711%20685%<u></u>2088429><br>
Fax: <a href="tel:%2B49%20711%20685%2088340" value="+4971168588340" target="_blank">+49 711 685 88340</a> <tel:%2B49%20711%20685%<u></u>2088340><br>
Email:<br>
<a href="mailto:steffen.muething@ipvs.uni-__stuttgart.de" target="_blank">steffen.muething@ipvs.uni-__<u></u>stuttgart.de</a> <mailto:<a href="mailto:steffen.muething@ipvs.uni-stuttgart.de" target="_blank">steffen.muething@ipvs.<u></u>uni-stuttgart.de</a>><br>
<br>
<br>
<br>
<br>
<br>
______________________________<u></u>___________________<br>
Dune mailing list<br>
<br>
<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a> <mailto:<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a>><br>
<a href="http://lists.dune-project.org/__mailman/listinfo/dune" target="_blank">http://lists.dune-project.org/<u></u>__mailman/listinfo/dune</a> <<a href="http://lists.dune-project.org/mailman/listinfo/dune" target="_blank">http://lists.dune-project.<u></u>org/mailman/listinfo/dune</a>><div class="im">
<br>
<br>
Steffen Müthing<br>
Universität Stuttgart<br>
Institut für Parallele und Verteilte Systeme<br>
Universitätsstr. 38<br>
70569 Stuttgart<br></div>
Tel: <a href="tel:%2B49%20711%20685%2088429" value="+4971168588429" target="_blank">+49 711 685 88429</a> <tel:%2B49%20711%20685%<u></u>2088429><br>
Fax: <a href="tel:%2B49%20711%20685%2088340" value="+4971168588340" target="_blank">+49 711 685 88340</a> <tel:%2B49%20711%20685%<u></u>2088340><br>
Email: <a href="mailto:steffen.muething@ipvs.uni-__stuttgart.de" target="_blank">steffen.muething@ipvs.uni-__<u></u>stuttgart.de</a> <mailto:<a href="mailto:steffen.muething@ipvs.uni-stuttgart.de" target="_blank">steffen.muething@ipvs.<u></u>uni-stuttgart.de</a>><br>
<br>
<br>
<br>
______________________________<u></u>___________________<br>
Dune mailing list<br>
<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a> <mailto:<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a>><br>
<a href="http://lists.dune-project.org/__mailman/listinfo/dune" target="_blank">http://lists.dune-project.org/<u></u>__mailman/listinfo/dune</a> <<a href="http://lists.dune-project.org/mailman/listinfo/dune" target="_blank">http://lists.dune-project.<u></u>org/mailman/listinfo/dune</a>><div class="im">
<br>
<br>
<br>
<br>
<br>
______________________________<u></u>_________________<br>
Dune mailing list<br>
<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a><br>
<a href="http://lists.dune-project.org/mailman/listinfo/dune" target="_blank">http://lists.dune-project.org/<u></u>mailman/listinfo/dune</a><br>
</div></blockquote><div class="HOEnZb"><div class="h5">
<br>
<br>
______________________________<u></u>_________________<br>
Dune mailing list<br>
<a href="mailto:Dune@dune-project.org" target="_blank">Dune@dune-project.org</a><br>
<a href="http://lists.dune-project.org/mailman/listinfo/dune" target="_blank">http://lists.dune-project.org/<u></u>mailman/listinfo/dune</a><br>
</div></div></blockquote></div><br></div>