How can select a specific triangle in my Delaunay mesh?Create triangular mesh from random list of pointsHow can I find coordinates of centroid, orthocenter and center of out circle of the list of triangles?How to find the index of a facet of a boundary mesh region closest to a given point?How to change the style of mesh labels?Unexpected black lines on the edge of a RegionPlot3Dselect points outside the cells in a lattice?How to perform Loop subdivision on a triangle mesh with Mathematica?How to create a neighboring list for a given triangulation and find the triangle and construct the tile?Draw circles and compute <sum of circle areas>-<area of overlaps of the circles>How to get size of each polygon of a Voronoi diagram using Shoelace formula?

Why is there paternal, for fatherly, fraternal, for brotherly, but no similar word for sons?

n-level Ouroboros Quine

How frequently do Russian people still refer to others by their patronymic (отчество)?

Is it possible to spoof an IP address to an exact number?

How did the IEC decide to create kibibytes?

Are "confidant" and "confident" homophones?

How important is it for multiple POVs to run chronologically?

Did William Shakespeare hide things in his writings?

How did Einstein know the speed of light was constant?

What can a novel do that film and TV cannot?

Why do we need a bootloader separate from our application program in microcontrollers?

Is it acceptable that I plot a time-series figure with years increasing from right to left?

Is it bad to suddenly introduce another element to your fantasy world a good ways into the story?

Who is responsible for exterminating cockroaches in house - tenant or landlord?

Would the Life cleric's Disciple of Life feature supercharge the Regenerate spell?

What are some bad ways to subvert tropes?

How can select a specific triangle in my Delaunay mesh?

When is one 'Ready' to make Original Contributions to Mathematics?

Does 5e have an equivalent of the Psychic Paper from Doctor Who?

Why did Super-VGA offer the 5:4 1280*1024 resolution?

What happens if the limit of 4 billion files was exceeded in an ext4 partition?

How do I iterate equal values with the standard library?

Initializing variables variable in an "if" statement

Change the default text editor in Terminal



How can select a specific triangle in my Delaunay mesh?


Create triangular mesh from random list of pointsHow can I find coordinates of centroid, orthocenter and center of out circle of the list of triangles?How to find the index of a facet of a boundary mesh region closest to a given point?How to change the style of mesh labels?Unexpected black lines on the edge of a RegionPlot3Dselect points outside the cells in a lattice?How to perform Loop subdivision on a triangle mesh with Mathematica?How to create a neighboring list for a given triangulation and find the triangle and construct the tile?Draw circles and compute <sum of circle areas>-<area of overlaps of the circles>How to get size of each polygon of a Voronoi diagram using Shoelace formula?






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








5












$begingroup$


Here is the code I am working with. I create a list of random coordinates, then I create a triangular mesh with the code:



list = RandomInteger[1, 10, 10, 2]
mesh = DelaunayMesh[
list,
MeshCellLabel -> 0 -> "Index",
PlotTheme -> "Lines",
MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
Frame -> True
]


enter image description here



How can I select a specific triangle? For example, how can I select the triangle with vertices 10,7,2.










share|improve this question











$endgroup$


















    5












    $begingroup$


    Here is the code I am working with. I create a list of random coordinates, then I create a triangular mesh with the code:



    list = RandomInteger[1, 10, 10, 2]
    mesh = DelaunayMesh[
    list,
    MeshCellLabel -> 0 -> "Index",
    PlotTheme -> "Lines",
    MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
    Frame -> True
    ]


    enter image description here



    How can I select a specific triangle? For example, how can I select the triangle with vertices 10,7,2.










    share|improve this question











    $endgroup$














      5












      5








      5





      $begingroup$


      Here is the code I am working with. I create a list of random coordinates, then I create a triangular mesh with the code:



      list = RandomInteger[1, 10, 10, 2]
      mesh = DelaunayMesh[
      list,
      MeshCellLabel -> 0 -> "Index",
      PlotTheme -> "Lines",
      MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
      Frame -> True
      ]


      enter image description here



      How can I select a specific triangle? For example, how can I select the triangle with vertices 10,7,2.










      share|improve this question











      $endgroup$




      Here is the code I am working with. I create a list of random coordinates, then I create a triangular mesh with the code:



      list = RandomInteger[1, 10, 10, 2]
      mesh = DelaunayMesh[
      list,
      MeshCellLabel -> 0 -> "Index",
      PlotTheme -> "Lines",
      MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
      Frame -> True
      ]


      enter image description here



      How can I select a specific triangle? For example, how can I select the triangle with vertices 10,7,2.







      computational-geometry






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 8 hours ago









      C. E.

      52.8k3 gold badges102 silver badges210 bronze badges




      52.8k3 gold badges102 silver badges210 bronze badges










      asked 8 hours ago









      Las des NestorLas des Nestor

      695 bronze badges




      695 bronze badges




















          1 Answer
          1






          active

          oldest

          votes


















          6












          $begingroup$

          SeedRandom[1]
          list = RandomInteger[1, 10, 10, 2];
          mesh = DelaunayMesh[list, MeshCellLabel -> 0 -> "Index",
          PlotTheme -> "Lines",
          MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
          Frame -> True]


          You can create an association mapping face vertices to face indices using the property "FaceVertexConnectivityRules":



          vertexToFace = Association[Reverse /@ mesh["FaceVertexConnectivityRules"]]



          <|3, 8, 5 -> 1, 8, 3, 7 -> 2, 2, 5, 10 -> 3, 1, 5, 8 ->
          4, 10, 5, 1 -> 5, 8, 9, 1 -> 6, 9, 7, 4 -> 7, 7, 9, 8 ->
          8, 10, 4, 6 -> 9, 4, 10, 9 -> 10, 10, 6, 2 ->
          11, 9, 10, 1 -> 12|>




          HighlightMesh[mesh, Style[2, vertexToFace[3, 8, 5], Red]]


          enter image description here






          share|improve this answer









          $endgroup$












          • $begingroup$
            How did you know about the faces vertex coordinates rules? I couldn't find it in the documentation.
            $endgroup$
            – Las des Nestor
            8 hours ago










          • $begingroup$
            @LasdesNestor Yes, these things are mostly undocumented. This is why Mathematica.StackExchange is so valuable: People try a lot of spelunking and also a few of the developers are around here.
            $endgroup$
            – Henrik Schumacher
            8 hours ago











          • $begingroup$
            @LasdesNestor, try mesh["Properties"] to see a long list of properties. Since they are not documented it is by trial and luck that you discover quiet a few useful properties.
            $endgroup$
            – kglr
            8 hours ago










          • $begingroup$
            Is there a way to extract that particular triangle, so I can compare them with the other ones? Let say that I select a triangle and I want to check if the triangle is part of the original plot.
            $endgroup$
            – Las des Nestor
            6 hours ago







          • 1




            $begingroup$
            @LasdesNestor, the triangle (polygon) can be obtained using MeshPrimitives[mesh, 2,1] or using MeshPrimitives[mesh, 2,vertexToFace[3,8,5]].
            $endgroup$
            – kglr
            6 hours ago













          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "387"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmathematica.stackexchange.com%2fquestions%2f201490%2fhow-can-select-a-specific-triangle-in-my-delaunay-mesh%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          6












          $begingroup$

          SeedRandom[1]
          list = RandomInteger[1, 10, 10, 2];
          mesh = DelaunayMesh[list, MeshCellLabel -> 0 -> "Index",
          PlotTheme -> "Lines",
          MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
          Frame -> True]


          You can create an association mapping face vertices to face indices using the property "FaceVertexConnectivityRules":



          vertexToFace = Association[Reverse /@ mesh["FaceVertexConnectivityRules"]]



          <|3, 8, 5 -> 1, 8, 3, 7 -> 2, 2, 5, 10 -> 3, 1, 5, 8 ->
          4, 10, 5, 1 -> 5, 8, 9, 1 -> 6, 9, 7, 4 -> 7, 7, 9, 8 ->
          8, 10, 4, 6 -> 9, 4, 10, 9 -> 10, 10, 6, 2 ->
          11, 9, 10, 1 -> 12|>




          HighlightMesh[mesh, Style[2, vertexToFace[3, 8, 5], Red]]


          enter image description here






          share|improve this answer









          $endgroup$












          • $begingroup$
            How did you know about the faces vertex coordinates rules? I couldn't find it in the documentation.
            $endgroup$
            – Las des Nestor
            8 hours ago










          • $begingroup$
            @LasdesNestor Yes, these things are mostly undocumented. This is why Mathematica.StackExchange is so valuable: People try a lot of spelunking and also a few of the developers are around here.
            $endgroup$
            – Henrik Schumacher
            8 hours ago











          • $begingroup$
            @LasdesNestor, try mesh["Properties"] to see a long list of properties. Since they are not documented it is by trial and luck that you discover quiet a few useful properties.
            $endgroup$
            – kglr
            8 hours ago










          • $begingroup$
            Is there a way to extract that particular triangle, so I can compare them with the other ones? Let say that I select a triangle and I want to check if the triangle is part of the original plot.
            $endgroup$
            – Las des Nestor
            6 hours ago







          • 1




            $begingroup$
            @LasdesNestor, the triangle (polygon) can be obtained using MeshPrimitives[mesh, 2,1] or using MeshPrimitives[mesh, 2,vertexToFace[3,8,5]].
            $endgroup$
            – kglr
            6 hours ago















          6












          $begingroup$

          SeedRandom[1]
          list = RandomInteger[1, 10, 10, 2];
          mesh = DelaunayMesh[list, MeshCellLabel -> 0 -> "Index",
          PlotTheme -> "Lines",
          MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
          Frame -> True]


          You can create an association mapping face vertices to face indices using the property "FaceVertexConnectivityRules":



          vertexToFace = Association[Reverse /@ mesh["FaceVertexConnectivityRules"]]



          <|3, 8, 5 -> 1, 8, 3, 7 -> 2, 2, 5, 10 -> 3, 1, 5, 8 ->
          4, 10, 5, 1 -> 5, 8, 9, 1 -> 6, 9, 7, 4 -> 7, 7, 9, 8 ->
          8, 10, 4, 6 -> 9, 4, 10, 9 -> 10, 10, 6, 2 ->
          11, 9, 10, 1 -> 12|>




          HighlightMesh[mesh, Style[2, vertexToFace[3, 8, 5], Red]]


          enter image description here






          share|improve this answer









          $endgroup$












          • $begingroup$
            How did you know about the faces vertex coordinates rules? I couldn't find it in the documentation.
            $endgroup$
            – Las des Nestor
            8 hours ago










          • $begingroup$
            @LasdesNestor Yes, these things are mostly undocumented. This is why Mathematica.StackExchange is so valuable: People try a lot of spelunking and also a few of the developers are around here.
            $endgroup$
            – Henrik Schumacher
            8 hours ago











          • $begingroup$
            @LasdesNestor, try mesh["Properties"] to see a long list of properties. Since they are not documented it is by trial and luck that you discover quiet a few useful properties.
            $endgroup$
            – kglr
            8 hours ago










          • $begingroup$
            Is there a way to extract that particular triangle, so I can compare them with the other ones? Let say that I select a triangle and I want to check if the triangle is part of the original plot.
            $endgroup$
            – Las des Nestor
            6 hours ago







          • 1




            $begingroup$
            @LasdesNestor, the triangle (polygon) can be obtained using MeshPrimitives[mesh, 2,1] or using MeshPrimitives[mesh, 2,vertexToFace[3,8,5]].
            $endgroup$
            – kglr
            6 hours ago













          6












          6








          6





          $begingroup$

          SeedRandom[1]
          list = RandomInteger[1, 10, 10, 2];
          mesh = DelaunayMesh[list, MeshCellLabel -> 0 -> "Index",
          PlotTheme -> "Lines",
          MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
          Frame -> True]


          You can create an association mapping face vertices to face indices using the property "FaceVertexConnectivityRules":



          vertexToFace = Association[Reverse /@ mesh["FaceVertexConnectivityRules"]]



          <|3, 8, 5 -> 1, 8, 3, 7 -> 2, 2, 5, 10 -> 3, 1, 5, 8 ->
          4, 10, 5, 1 -> 5, 8, 9, 1 -> 6, 9, 7, 4 -> 7, 7, 9, 8 ->
          8, 10, 4, 6 -> 9, 4, 10, 9 -> 10, 10, 6, 2 ->
          11, 9, 10, 1 -> 12|>




          HighlightMesh[mesh, Style[2, vertexToFace[3, 8, 5], Red]]


          enter image description here






          share|improve this answer









          $endgroup$



          SeedRandom[1]
          list = RandomInteger[1, 10, 10, 2];
          mesh = DelaunayMesh[list, MeshCellLabel -> 0 -> "Index",
          PlotTheme -> "Lines",
          MeshCellHighlight -> 1, All -> Green, 0, All -> Black,
          Frame -> True]


          You can create an association mapping face vertices to face indices using the property "FaceVertexConnectivityRules":



          vertexToFace = Association[Reverse /@ mesh["FaceVertexConnectivityRules"]]



          <|3, 8, 5 -> 1, 8, 3, 7 -> 2, 2, 5, 10 -> 3, 1, 5, 8 ->
          4, 10, 5, 1 -> 5, 8, 9, 1 -> 6, 9, 7, 4 -> 7, 7, 9, 8 ->
          8, 10, 4, 6 -> 9, 4, 10, 9 -> 10, 10, 6, 2 ->
          11, 9, 10, 1 -> 12|>




          HighlightMesh[mesh, Style[2, vertexToFace[3, 8, 5], Red]]


          enter image description here







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered 8 hours ago









          kglrkglr

          202k10 gold badges231 silver badges462 bronze badges




          202k10 gold badges231 silver badges462 bronze badges











          • $begingroup$
            How did you know about the faces vertex coordinates rules? I couldn't find it in the documentation.
            $endgroup$
            – Las des Nestor
            8 hours ago










          • $begingroup$
            @LasdesNestor Yes, these things are mostly undocumented. This is why Mathematica.StackExchange is so valuable: People try a lot of spelunking and also a few of the developers are around here.
            $endgroup$
            – Henrik Schumacher
            8 hours ago











          • $begingroup$
            @LasdesNestor, try mesh["Properties"] to see a long list of properties. Since they are not documented it is by trial and luck that you discover quiet a few useful properties.
            $endgroup$
            – kglr
            8 hours ago










          • $begingroup$
            Is there a way to extract that particular triangle, so I can compare them with the other ones? Let say that I select a triangle and I want to check if the triangle is part of the original plot.
            $endgroup$
            – Las des Nestor
            6 hours ago







          • 1




            $begingroup$
            @LasdesNestor, the triangle (polygon) can be obtained using MeshPrimitives[mesh, 2,1] or using MeshPrimitives[mesh, 2,vertexToFace[3,8,5]].
            $endgroup$
            – kglr
            6 hours ago
















          • $begingroup$
            How did you know about the faces vertex coordinates rules? I couldn't find it in the documentation.
            $endgroup$
            – Las des Nestor
            8 hours ago










          • $begingroup$
            @LasdesNestor Yes, these things are mostly undocumented. This is why Mathematica.StackExchange is so valuable: People try a lot of spelunking and also a few of the developers are around here.
            $endgroup$
            – Henrik Schumacher
            8 hours ago











          • $begingroup$
            @LasdesNestor, try mesh["Properties"] to see a long list of properties. Since they are not documented it is by trial and luck that you discover quiet a few useful properties.
            $endgroup$
            – kglr
            8 hours ago










          • $begingroup$
            Is there a way to extract that particular triangle, so I can compare them with the other ones? Let say that I select a triangle and I want to check if the triangle is part of the original plot.
            $endgroup$
            – Las des Nestor
            6 hours ago







          • 1




            $begingroup$
            @LasdesNestor, the triangle (polygon) can be obtained using MeshPrimitives[mesh, 2,1] or using MeshPrimitives[mesh, 2,vertexToFace[3,8,5]].
            $endgroup$
            – kglr
            6 hours ago















          $begingroup$
          How did you know about the faces vertex coordinates rules? I couldn't find it in the documentation.
          $endgroup$
          – Las des Nestor
          8 hours ago




          $begingroup$
          How did you know about the faces vertex coordinates rules? I couldn't find it in the documentation.
          $endgroup$
          – Las des Nestor
          8 hours ago












          $begingroup$
          @LasdesNestor Yes, these things are mostly undocumented. This is why Mathematica.StackExchange is so valuable: People try a lot of spelunking and also a few of the developers are around here.
          $endgroup$
          – Henrik Schumacher
          8 hours ago





          $begingroup$
          @LasdesNestor Yes, these things are mostly undocumented. This is why Mathematica.StackExchange is so valuable: People try a lot of spelunking and also a few of the developers are around here.
          $endgroup$
          – Henrik Schumacher
          8 hours ago













          $begingroup$
          @LasdesNestor, try mesh["Properties"] to see a long list of properties. Since they are not documented it is by trial and luck that you discover quiet a few useful properties.
          $endgroup$
          – kglr
          8 hours ago




          $begingroup$
          @LasdesNestor, try mesh["Properties"] to see a long list of properties. Since they are not documented it is by trial and luck that you discover quiet a few useful properties.
          $endgroup$
          – kglr
          8 hours ago












          $begingroup$
          Is there a way to extract that particular triangle, so I can compare them with the other ones? Let say that I select a triangle and I want to check if the triangle is part of the original plot.
          $endgroup$
          – Las des Nestor
          6 hours ago





          $begingroup$
          Is there a way to extract that particular triangle, so I can compare them with the other ones? Let say that I select a triangle and I want to check if the triangle is part of the original plot.
          $endgroup$
          – Las des Nestor
          6 hours ago





          1




          1




          $begingroup$
          @LasdesNestor, the triangle (polygon) can be obtained using MeshPrimitives[mesh, 2,1] or using MeshPrimitives[mesh, 2,vertexToFace[3,8,5]].
          $endgroup$
          – kglr
          6 hours ago




          $begingroup$
          @LasdesNestor, the triangle (polygon) can be obtained using MeshPrimitives[mesh, 2,1] or using MeshPrimitives[mesh, 2,vertexToFace[3,8,5]].
          $endgroup$
          – kglr
          6 hours ago

















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Mathematica Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          Use MathJax to format equations. MathJax reference.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmathematica.stackexchange.com%2fquestions%2f201490%2fhow-can-select-a-specific-triangle-in-my-delaunay-mesh%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Invision Community Contents History See also References External links Navigation menuProprietaryinvisioncommunity.comIPS Community ForumsIPS Community Forumsthis blog entry"License Changes, IP.Board 3.4, and the Future""Interview -- Matt Mecham of Ibforums""CEO Invision Power Board, Matt Mecham Is a Liar, Thief!"IPB License Explanation 1.3, 1.3.1, 2.0, and 2.1ArchivedSecurity Fixes, Updates And Enhancements For IPB 1.3.1Archived"New Demo Accounts - Invision Power Services"the original"New Default Skin"the original"Invision Power Board 3.0.0 and Applications Released"the original"Archived copy"the original"Perpetual licenses being done away with""Release Notes - Invision Power Services""Introducing: IPS Community Suite 4!"Invision Community Release Notes

          Canceling a color specificationRandomly assigning color to Graphics3D objects?Default color for Filling in Mathematica 9Coloring specific elements of sets with a prime modified order in an array plotHow to pick a color differing significantly from the colors already in a given color list?Detection of the text colorColor numbers based on their valueCan color schemes for use with ColorData include opacity specification?My dynamic color schemes

          Ласкавець круглолистий Зміст Опис | Поширення | Галерея | Примітки | Посилання | Навігаційне меню58171138361-22960890446Bupleurum rotundifoliumEuro+Med PlantbasePlants of the World Online — Kew ScienceGermplasm Resources Information Network (GRIN)Ласкавецькн. VI : Літери Ком — Левиправивши або дописавши її