Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- dx = N[2/36];
- a = 0.5;
- c1 = ColorData["DarkRainbow"][0];
- c2 = ColorData["DarkRainbow"][1];
- Manipulate[
- With[{t = 0.25 + 0.67 (0.5 + 0.5 Sin[2 Pi \[Tau]])},
- Graphics[
- Translate[
- {
- {
- c1,
- Table[
- With[{y = Max[1 - t, a Sqrt[1 - x^2]]},
- Line[{{x, y - a Sqrt[1 - x^2]}, {x, y + a Sqrt[1 - x^2]}}]
- ], {x, -1 + dx/2, 1, dx}]
- },
- {
- c2,
- Table[
- With[{y = Min[-1 + t, -a Sqrt[1 - x^2]]},
- Line[{{x, y - a Sqrt[1 - x^2]}, {x, y + a Sqrt[1 - x^2]}}]
- ], {x, -1 + dx/2, 1, dx}]
- }
- },
- {0, -t}
- ], PlotRange -> {{-1, 1}, {-1.25 - 0.75, 1.25}},
- ImagePadding -> 10]
- ],
- {\[Tau], 0, 1}]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement