Archived

This topic is now archived and is closed to further replies.

Vertices of a Hexagon

This topic is 5001 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Does anyone know where these vertices are in relation to the center point (assuming of course that all sides are equal and are of a value of 1)? I''m not too great at geometry, so I have no clue how to find these out. If you do find them out rational numbers would be most appreciated. Thanks.
Pumpkin Pieman - [Blogger]

Go to war again, blood is freedom''s stain, But don''t you pray for my soul anymore.

Share this post


Link to post
Share on other sites
That''s not a hexagon. A hexagon has six corners.

The generation is rather simple for any n-sided polygon if you want all sides the same length. Let be a := 2 * pi / n. Then the corners simply have the coordinates (cos(i * a), sin(i * a)), 0 <= i < n.

Share this post


Link to post
Share on other sites
Thanks that worked great! I got one last question: when I generated the numbers for the third number out of 6 sides, it came really close to zero (which it''s supposed to) but not 0. Should it do this? It came to (-1, 1.22461^-16) and it should be directly across from (1, 0).

Thanks

Share this post


Link to post
Share on other sites