<blockquote>
  <p>what is the relation between radius of the in-circle and circum-circle of a polygon?</p>
</blockquote>

<p>That is $cos ( \frac{2\pi}{n}*\frac{1}{2} ) = cos ( \frac{\pi}{n})$</p>

<p>The triangle with edges from the center to the middle of a side, from the center to an adjacent corner and half the side connecting them is a right angle triangle. The angle of the point at the center $ =\frac\pi 2$. </p>

<p>Then it's simply the cosine to get the ratio between adjacent and hypotenuse.</p>

CC BY-SA 3.0
2017-11-06T15:56:48.057Z
2017-11-06T15:56:48.057Z
ratchet freak
<p>How can I find the vertices of a polygon (specifically hexagon) given the radius of the incircle? I want to calculate the vertices of a polygon given the face-to-face distance (inscribed circle diameter?)</p>

<p>I've below code to calculate the vertices from the Circum-circle of a polygon</p>

<p><code>(x,y)</code> - Center of the circumcircle</p>

<p><code>r</code> - Radius of the circumcircle</p>

<pre><code>for (var i = 1; i &lt;= sides; i++)
{
    var X = x + r * Math.Cos(2 * Math.PI * i / sides);
    var Y = y + r * Math.Sin(2 * Math.PI * i / sides);

    vertices.Add(new Tuple(X,Y));
}
</code></pre>

<p>Alternatively, what is the relation between radius of the in-circle and circum-circle of a polygon? Could you please share a relevant resource or a code snippet (any language is fine).</p>

<p>Thanks!</p>

<computational-geometry><polygon>
Vertices of a regular polygon given the incircle radius
user7413
# Vertices of a regular polygon given the incircle radius

(Asked by: username_0 on 2017-11-06)

How can I find the vertices of a polygon (specifically hexagon) given the radius of the incircle? I want to calculate the vertices of a polygon given the face-to-face distance (inscribed circle diameter?)

I've below code to calculate the vertices from the Circum-circle of a polygon

`(x,y)` - Center of the circumcircle

`r` - Radius of the circumcircle

```
for (var i = 1; i <= sides; i++)
{
    var X = x + r * Math.Cos(2 * Math.PI * i / sides);
    var Y = y + r * Math.Sin(2 * Math.PI * i / sides);

    vertices.Add(new Tuple(X,Y));
}

```

Alternatively, what is the relation between radius of the in-circle and circum-circle of a polygon? Could you please share a relevant resource or a code snippet (any language is fine).

Thanks!

**Tags:** computational-geometry, polygon


---

## 1 answers

### Answer by username_1 on 2017-11-06. Score: 3

> what is the relation between radius of the in-circle and circum-circle of a polygon?

That is $cos ( \frac{2\pi}{n}\*\frac{1}{2} ) = cos ( \frac{\pi}{n})$

The triangle with edges from the center to the middle of a side, from the center to an adjacent corner and half the side connecting them is a right angle triangle. The angle of the point at the center $ =\frac\pi 2$.

Then it's simply the cosine to get the ratio between adjacent and hypotenuse.


---

