Star polygon area calculator
Get the filled area of a regular star from its number of tips, its density and the radius to the tips: the classic five-pointed star {5/2} on a circle of radius 1 covers 1.122569941449. Useful for star badges, laser cutting and homework. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Number of outer vertices
- 5
- Density
- 2
- Radius
- 1
- Schlafli
- {5/2}
- Inner radius
- 0.3819660113
- Area
- 1.1225699414
- Convex area
- 2.3776412907
Regular star polygons such as the classic pentagram {5/2}, the heptagrams {7/2} and {7/3}, and denser forms like {9/4} appear in design systems, geometry homework, CAD motifs, game art, and manufacturing patterns. This capacity takes three numbers—how many outer tips the star has, the Schläfli density that says which vertices to connect, and the circumradius from center to tip—and returns the filled planar area of that regular star together with the inner valley radius, the Schläfli symbol, and the area of the convex regular n-gon on the same circle for comparison.
What a regular star polygon is and how density works
When d equals 1 the path is the ordinary convex regular n-gon. When d is at least 2 and gcd(n, d) equals 1, the path forms a single non-convex star whose edges cross, creating outer spikes and re-entrant valleys. The classic five-pointed star is {5/2}; seven points admit two non-equivalent stars, {7/2} and {7/3}, with different spike sharpness and different areas for the same circumradius.
If gcd(n, d) is greater than one—for example {6/2} or {10/4}—the construction decomposes into several superimposed polygons (a compound) rather than one connected star component. This calculator requires coprime n and d so the result always refers to a single regular star (or the convex {n/1} case). Density is also normalized into the range 1 through floor((n−1)/2), because {n/d} and {n/(n−d)} describe the same figure traversed in opposite step directions.
Understanding density up front prevents the common mistake of treating every “n-pointed star” as the same shape: two stars with the same tip count but different densities can have very different filled areas on the same circle.
What you can do with it
Homework and textbook star geometry
Students enter {5/2}, {7/2}, or {7/3} with a given circumradius and confirm the filled area against hand-derived isotoxal formulas.
Design and manufacturing of star badges
Product tools convert a specified outer radius and tip count into paint or material area before laser-cutting or printing a regular star motif.
FAQ
What does density mean for a star polygon?
Density d in Schläfli notation {n/d} means each edge skips to the vertex d steps away on the n-gon. For a simple star, d ≥ 2 and gcd(n, d) must be 1.
Why do non-coprime density and points fail?
If gcd(n, d) > 1 the construction is a compound of several polygons, not a single star component.
Does the result count overlapping regions once or with winding density?
Area is the filled silhouette of the regular isotoxal outline (union, each region once). It is not the density-weighted algebraic area of the self-intersecting vertex path.
What is the area of a five-pointed star with a radius of 1?
The star {5/2} covers 1.122569941449, its valleys sit 0.38196601125 from the centre, and the convex pentagon on the same circle covers 2.377641290738, so you see how much the points leave out.
Why do {7/2} and {7/3} give different areas?
Both stars have seven tips, but the density decides which tips are joined, so the spikes are sharper in one than in the other. On the same circle they fill different areas, which is why the density matters.
Related tools
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/geom/star-polygon-area \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"points":5,"density":2,"radius":1}'const res = await fetch("https://api.kit.forhosting.com/geom/star-polygon-area", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"points": 5,
"density": 2,
"radius": 1
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/geom/star-polygon-area",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"points": 5,
"density": 2,
"radius": 1
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/geom/star-polygon-area", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"points":5,"density":2,"radius":1}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"points":5,"density":2,"radius":1}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/geom/star-polygon-area", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"points": 5,
"density": 2,
"radius": 1
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "geom.star_polygon_area",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |
Technical notes
When density and point count share a common factor greater than one, the figure is a compound rather than a single star component; those inputs are rejected with invalid_input so you never mistake a compound for a simple star.
What a regular star polygon is and how density works
A regular star polygon is written in Schläfli notation as {n/d}, where n is the number of equally spaced vertices on a circle and d is the density: starting at any vertex, you draw a straight chord to the vertex d steps away, then continue until the path closes.
How to call the calculator and read the JSON result
Points must be an integer at least 5; density must be an integer in 1..floor((points−1)/2) after canonical reduction; radius must be a positive finite number. Send three fields: points (aliases n, point_count, vertices), density (aliases d, dens), and radius (aliases r, R). Digit strings that parse cleanly are accepted; missing fields, non-integers for points or density, non-positive radius, and non-coprime pairs fail with invalid_input that names the problem—including an explicit gcd message when density and points are not coprime. On success the JSON echoes the canonical points, density, and radius, reports schlafli as a string like {5/2}, returns inner_radius (distance from center to each re-entrant valley of the isotoxal outline), returns area (the filled star region you usually want for paint, material, or hit-tests), returns convex_area (the regular n-gon on the same circumradius), and sets is_star true when density is at least 2. Pricing for a successful API call is a flat $0.002 under the item unit; validation failures are never charged.
The area formula, precision, compounds, and limits
The filled boundary of a regular star {n/d} is a regular isotoxal 2n-gon that alternates outer tips at circumradius R with valleys at an inner radius r = R · cos(π d / n) / cos(π (d − 1) / n). Inputs that are not coprime are rejected rather than silently returning a compound area, because compounds (for example two triangles for {6/2}) are a different product intent. Related search intents such as irregular star areas, polygram compounds, or star perimeter alone are separate landings; this page is dedicated to regular star polygon area from points, density, and circumradius with an explicit coprime check. Summing the triangular sectors from the center gives the closed form A = n · R · r · sin(π / n), which reduces to the familiar (n/2) R² sin(2π/n) when d = 1. This is the geometric union area of the star silhouette (each region counted once), not the density-weighted algebraic area you would get from a naïve shoelace walk along the self-intersecting vertex path.
Integration use cases
Game art and collision fixtures
Pipelines freeze JSON golden areas for star-shaped sprites so physics hit-boxes and procedural generators stay consistent across builds.
Technical questions
How do I calculate the area of a regular star polygon?
POST points, density, and radius (circumradius to each tip) to the star-polygon-area endpoint, or use the free browser form. The response includes area, inner_radius, and the Schläfli symbol {n/d}.
Is the browser star polygon area calculator free?
Yes. The in-browser runner uses the same library as the API and costs nothing. The API charges $0.002 per successful request from your prepaid KIT balance.