# DIvide a Polygon Area in small pieces

**URL:** <https://discourse.julialang.org/t/divide-a-polygon-area-in-small-pieces/85014>\
**Category:** General Usage\
**Tags:** question\
**Created:** [July 30, 2022, 1:30am UTC](https://discourse.julialang.org/t/divide-a-polygon-area-in-small-pieces/85014 "2022-07-30T01:30:14Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jesus\_Chavez\_Solano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jesus_chavez_solano/32/25194_2.png) [@Jesus\_Chavez\_Solano](https://discourse.julialang.org/u/Jesus_Chavez_Solano)\
**Post date:** [July 30, 2022, 1:30am UTC](https://discourse.julialang.org/t/divide-a-polygon-area-in-small-pieces/85014/1 "2022-07-30T01:30:14Z")

</div>

Hi everyone ,I’m doing a momentum curvature usign Popovic’s Model and found a big problem beacuse to divide a polygon(convex or concave) into small fiber like this image but with more lines:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/f/e/fee24624ab76e9e49500ad33d14592cda364c682.png)

 ![image1](https://global.discourse-cdn.com/julialang/original/3X/b/4/b4a841d7783348774792da12c2d71f9764518a7b.png)

it’s not so easy to do an algorithm. I did a file when the polygon is rectangular and find the gravity center, perimeter and intersection points but for more general case my code doesn’t work, I’d like to know an algorithm or code, if it’s posible in julia or other language to learn how to do it.

Best regards.  
Jesus.

---

<div class="post-metadata">

**Author:** ![Sukera](https://avatars.discourse-cdn.com/v4/letter/s/ce7236/32.png) [@Sukera](https://discourse.julialang.org/u/Sukera)\
**Post date:** [July 30, 2022, 5:48pm UTC](https://discourse.julialang.org/t/divide-a-polygon-area-in-small-pieces/85014/2 "2022-07-30T17:48:53Z")

</div>

Not sure I understood your problem statement completely, but what I usually use for cutting a polygon up into more manageable pieces is a Delaunay Triangulation.

> **[Delaunay triangulation](https://en.m.wikipedia.org/wiki/Delaunay_triangulation)**
>
> In mathematics and computational geometry, a Delaunay triangulation (also known as a Delone triangulation) for a given set P of discrete points in a general position is a triangulation DT(P) such that no point in P is inside the circumcircle of any triangle in DT(P). Delaunay triangulations maximize the minimum of all the angles of the triangles in the triangulation; they tend to avoid sliver triangles. The triangulation is named after Boris Delaunay for his work on this topic from 1934.
> For a ...

---

<div class="post-metadata">

**Author:** ![Jesus\_Chavez\_Solano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jesus_chavez_solano/32/25194_2.png) [@Jesus\_Chavez\_Solano](https://discourse.julialang.org/u/Jesus_Chavez_Solano)\
**Post date:** [July 30, 2022, 11:41pm UTC](https://discourse.julialang.org/t/divide-a-polygon-area-in-small-pieces/85014/3 "2022-07-30T23:41:24Z")

</div>

Hi Sukera,I want to get like this image :

 ![image](https://global.discourse-cdn.com/julialang/original/3X/a/1/a1cd94151f3d762400950343ad58061f1e7a7cb5.png)

Not just for one line, I wanna divide for more lines and get the parts of the polygon( center of gravity, perimeter). I wanna learn an algorithm or code in julia, if it’s possible to do it in julia.

Best Regards

Jesus

---

<div class="post-metadata">

**Author:** ![stevengj](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stevengj/32/71_2.png) [@stevengj](https://discourse.julialang.org/u/stevengj)\
**Post date:** [July 31, 2022, 2:12am UTC](https://discourse.julialang.org/t/divide-a-polygon-area-in-small-pieces/85014/4 "2022-07-31T02:12:37Z")

</div>

See the [`Luxor.polysplit`](http://juliagraphics.github.io/Luxor.jl/v0.9.1/polygons.html) function, perhaps.

---

<div class="post-metadata">

**Author:** ![Jesus\_Chavez\_Solano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jesus_chavez_solano/32/25194_2.png) [@Jesus\_Chavez\_Solano](https://discourse.julialang.org/u/Jesus_Chavez_Solano)\
**Post date:** [July 31, 2022, 3:39pm UTC](https://discourse.julialang.org/t/divide-a-polygon-area-in-small-pieces/85014/5 "2022-07-31T15:39:39Z")

</div>

Thank you so much, stevengj. I’ll take a look this package ( [`Luxor.polysplit`](http://juliagraphics.github.io/Luxor.jl/v0.9.1/polygons.html)).

Best regards

Jesús.
