Message Boards Message Boards

[GIF] Follow Through (Morphing 11-pointed star)

Morphing 11-pointed star

Follow Through

Put down points at multiples of $4\pi/11$, with each repeated, and form the resulting star. Then linearly interpolate the $i$th point with the $(i+9)$th point.

Here's the code:

smootheststep[t_] := -20 t^7 + 70 t^6 - 84 t^5 + 35 t^4;

DynamicModule[{n = 11, t, cols = RGBColor /@ {"#111F4D", "#F4F4F4"}},
 Manipulate[
  t = smootheststep[s];
  Graphics[{cols[[1]],
    Polygon[
     (1 - t) # + t RotateLeft[#, n - 2]
       &[Riffle[#, #] &[Table[{Cos[?], Sin[?]}, {?, ?/2, 4 ? + ?/2 - 4 ?/n, 4 ?/n}]]]]}, 
   PlotRange -> Sqrt[2], ImageSize -> 540, Background -> cols[[-1]]],
  {s, 0, 1}]
 ]

enter image description here - Congratulations! This post is now a Staff Pick as distinguished by a badge on your profile! Thank you, keep it coming!

POSTED BY: EDITORIAL BOARD
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract