# How to Draw Polygon inside circle and calculate its area?

**URL:** https://discourse.julialang.org/t/how-to-draw-polygon-inside-circle-and-calculate-its-area/83900
**Category:** General Usage
**Tags:** plotting
**Created:** [July 7, 2022, 2:00pm UTC](https://discourse.julialang.org/t/how-to-draw-polygon-inside-circle-and-calculate-its-area/83900 "2022-07-07T14:00:23Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Freya\_the\_Goddess](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/freya_the_goddess/32/36835_2.png) [@Freya\_the\_Goddess](https://discourse.julialang.org/u/Freya_the_Goddess)
#### Post date: [July 7, 2022, 2:00pm UTC](https://discourse.julialang.org/t/how-to-draw-polygon-inside-circle-and-calculate-its-area/83900/1 "2022-07-07T14:00:23Z")

</div>

I want to know how to create polygons inside circle and calculate its area, just like the image below:  
 ![GeometryPost11Fig3](https://global.discourse-cdn.com/julialang/original/3X/9/d/9df3fba7f31f84bb11de902407228e8b38b70719.jpeg)

---

<div class="post-metadata">

### Author: ![joa-quim](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/joa-quim/32/227_2.png) [@joa-quim](https://discourse.julialang.org/u/joa-quim)
#### Post date: [July 7, 2022, 2:19pm UTC](https://discourse.julialang.org/t/how-to-draw-polygon-inside-circle-and-calculate-its-area/83900/2 "2022-07-07T14:19:01Z")

</div>

GMT symbol sizes are determined by the circumscribed circle. See [image](https://discourse.julialang.org/uploads/short-url/AghjctSncJOvOMP7KKBMifKGG6B.png) in GMT [plot manual](https://docs.generic-mapping-tools.org/dev/plot.html#s) (not to be confused with the GMT.jl [plot manual](https://www.generic-mapping-tools.org/GMTjl_doc/documentation/modules/plot/index.html#plot))

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

---

<div class="post-metadata">

### Author: ![Freya\_the\_Goddess](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/freya_the_goddess/32/36835_2.png) [@Freya\_the\_Goddess](https://discourse.julialang.org/u/Freya_the_Goddess)
#### Post date: [July 8, 2022, 11:25am UTC](https://discourse.julialang.org/t/how-to-draw-polygon-inside-circle-and-calculate-its-area/83900/3 "2022-07-08T11:25:21Z")

</div>

@joa-quim there is a problem here:

I can’t add or use GMT package. I use Julia-1.7.3

![Capture d’écran_2022-07-08_18-11-06](https://global.discourse-cdn.com/julialang/original/3X/d/2/d217e4c6ff7aefeb82eff7c4f97a873b94255f31.png)

---

<div class="post-metadata">

### Author: ![joa-quim](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/joa-quim/32/227_2.png) [@joa-quim](https://discourse.julialang.org/u/joa-quim)
#### Post date: [July 8, 2022, 12:57pm UTC](https://discourse.julialang.org/t/how-to-draw-polygon-inside-circle-and-calculate-its-area/83900/4 "2022-07-08T12:57:50Z")

</div>

I’m afraid you are suffering from the `libstd++` problem discussed [here](https://discourse.julialang.org/t/failing-to-register-new-version-because/82346/3) and while [#45582](https://github.com/JuliaLang/julia/pull/45582) is not solved, your option is to install GMT with a package manager or build it yourself (not difficult). See general instructions for Linux [here](https://github.com/GenericMappingTools/gmt/blob/master/INSTALL.md#linux)
