In this item, the one-third-twisted triangular toroid is constructed by a rotating equilateral triangle. The triangle is rotated by the full circle, that is the angle $2\pi$.
Place the cursor over the image to start the animation.
The code that is used for the above picture (not the animation) is below:
Show[ParametricPlot3D[
3 {Cos[s], Sin[s], 0} +
NgonCos[t, 3] (Cos[s/3] {Cos[s], Sin[s], 0} + Sin[s/3] {0, 0, 1}) +
NgonSin[t,3] (-Sin[s/3] {Cos[s], Sin[s], 0} + Cos[s/3] {0, 0, 1}), {t, 0,
3}, {s, 0, 2 Pi}, PlotPoints -> {51, 201},
PlotStyle -> {Opacity[0.9]}, Mesh -> False, Exclusions -> None,
PlotRange -> {{-4, 4}, {-4, 4}, {-1.1, 1.1}}],
ParametricPlot3D[
3 {Cos[s], Sin[s], 0} +
NgonCos[0, 3] (Cos[s/3] {Cos[s], Sin[s], 0} + Sin[s/3] {0, 0, 1}) +
NgonSin[0,
3] (-Sin[s/3] {Cos[s], Sin[s], 0} + Cos[s/3] {0, 0, 1}), {s, 0,
2 Pi}, PlotPoints -> {201},
PlotStyle -> {RGBColor[0, 0, 0.75], Thickness[0.006]},
Exclusions -> None],
ParametricPlot3D[
3 {Cos[s], Sin[s], 0} +
NgonCos[1, 3] (Cos[s/3] {Cos[s], Sin[s], 0} + Sin[s/3] {0, 0, 1}) +
NgonSin[1, 3] (-Sin[s/3] {Cos[s], Sin[s], 0} + Cos[s/3] {0, 0, 1}), {s, 0,
2 Pi}, PlotPoints -> {201},
PlotStyle -> {RGBColor[0.95, 0, 0], Thickness[0.006]},
Exclusions -> None],
ParametricPlot3D[
3 {Cos[s], Sin[s], 0} +
NgonCos[2, 3] (Cos[s/3] {Cos[s], Sin[s], 0} + Sin[s/3] {0, 0, 1}) +
NgonSin[2, 3] (-Sin[s/3] {Cos[s], Sin[s], 0} + Cos[s/3] {0, 0, 1}), {s, 0,
2 Pi}, PlotPoints -> {201},
PlotStyle -> {RGBColor[0, 0.85, 0], Thickness[0.006]},
Exclusions -> None], ImagePadding -> {{0, 0}, {0, 0}},
Boxed -> True, BoxStyle -> {Opacity[0]}, Axes -> False,
ImageSize -> 1000, PlotRange -> {{-4, 4}, {-4, 4}, {-1.1, 1.1}}]
The above code uses the functions that we defined earlier:
Clear[NgonCos, NgonSin];
NgonCos[t_, nn_] := (1 - (t - Floor[t])) Cos[(2/nn) \[Pi] Floor[t]] + (t -
Floor[t]) Cos[(2/nn) \[Pi] (1 + Floor[t])];
NgonSin[t_, nn_] := (1 - (t - Floor[t])) Sin[(2/nn) \[Pi] Floor[t]] + (t -
Floor[t]) Sin[(2/nn) \[Pi] (1 + Floor[t])];
In this item, the one-third-twisted triangular toroid is constructed by a rotating line segment. The line segment is rotated by the three full circles, that is by the angle $6\pi$.
Place the cursor over the image to start the animation.
The code that is used for the above picture (not the animation) is below:
Show[ParametricPlot3D[
3 {Cos[s], Sin[s], 0} +
NgonCos[t, 3] (Cos[s/3] {Cos[s], Sin[s], 0} + Sin[s/3] {0, 0, 1}) +
NgonSin[t, 3] (-Sin[s/3] {Cos[s], Sin[s], 0} + Cos[s/3] {0, 0, 1}), {t, 0,
1}, {s, 0, 6 Pi}, PlotPoints -> {51, 201},
PlotStyle -> {Opacity[0.9]}, Mesh -> False, Exclusions -> None,
PlotRange -> {{-4, 4}, {-4, 4}, {-1.1, 1.1}}],
ParametricPlot3D[
3 {Cos[s], Sin[s], 0} +
NgonCos[0, 3] (Cos[s/3] {Cos[s], Sin[s], 0} + Sin[s/3] {0, 0, 1}) +
NgonSin[0, 3] (-Sin[s/3] {Cos[s], Sin[s], 0} + Cos[s/3] {0, 0, 1}), {s, 0,
6 Pi}, PlotPoints -> {201},
PlotStyle -> {RGBColor[0, 0, 0.75], Thickness[0.006]},
Exclusions -> None], ImagePadding -> {{0, 0}, {0, 0}},
Boxed -> True, BoxStyle -> {Opacity[0]}, Axes -> False,
ImageSize -> 1000, PlotRange -> {{-4, 4}, {-4, 4}, {-1.1, 1.1}}]
The above code uses the functions that we defined earlier:
Clear[NgonCos, NgonSin];
NgonCos[t_, nn_] := (1 - (t - Floor[t])) Cos[(2/nn) \[Pi] Floor[t]] + (t -
Floor[t]) Cos[(2/nn) \[Pi] (1 + Floor[t])];
NgonSin[t_, nn_] := (1 - (t - Floor[t])) Sin[(2/nn) \[Pi] Floor[t]] + (t -
Floor[t]) Sin[(2/nn) \[Pi] (1 + Floor[t])];
One of the remarkable applications of trigonometric functions Cos[t] and Sin[x] is that they describe small oscillations of a stretched string. In the animation below you can see the function \[ \cos(t) \sin(x) \qquad \text{with} \qquad x \in [0,\pi] \quad \text{and} \quad t \in [0,2\pi] \] As \(t\) takes values from \(0\) to \(2\pi\), the function \(\sin(x)\) is scaled with a different number \(\cos(t)\) between \(1\) and \(-1\). In the animation below I take 241 values of \(t\) between, and including, \(0\) to \(2\pi\), create 241 images and use Mathematica to export those 241 images as an animated gif file.
Hover over the image to start the animation.
(* create a list of 240 images of an oscillating sine function, call \
this list SinxCost *)
SinxCost =
Table[Plot[Evaluate[Sin[x] Cos[t]], {x, 0, Pi},
PlotStyle -> {{Thickness[0.01], RGBColor[1, 0, 0]}},
Epilog -> {
{PointSize[0.012], White, Point[#] & /@ {{0, 0}, {Pi, 0}}},
{Text["t =", {Pi/2 - 0.1, 1.26},
BaseStyle -> {FontWeight -> "Normal",
FontColor -> RGBColor[1, 1, 1]}],
Text[NumberForm[N[t], {3, 2}], {Pi/2, 1.26},
BaseStyle -> {FontWeight -> "Normal",
FontColor -> RGBColor[1, 1, 1]}]}
},
PlotRange -> {{-0.1, Pi + 0.1}, {-1.4, 1.4}}, AspectRatio -> 1/5,
Frame -> True, FrameTicks -> {{{}, {}}, {Range[0, Pi, Pi/4], {}}},
Axes -> False, ImageSize -> 800, Background -> Black], {t, 0,
2 Pi, 2 Pi/240.}];
(* decide which duration you want for each frame, here 0.1 and create \
a table of these durations, call it dds *)
dds = 0.1 & /@ Range[Length[SinxCost]];
(* Set the directory where you want the movie to be exported. *)
SetDirectory["C:\\Dropbox\\Work\\myweb\\Courses\\Math_pages\\Math_307\
\\Pictures"]
(* Export the list of 240 images as an animated gif file *)
Export["SinxCostAni.gif", SinxCost,
"AnimationRepetitions" -> Infinity, "ImageSize" -> 800, "DisplayDurations" -> dds]
(* Export the first image as a gif file *)
Export["SinxCostS1.gif", SinxCost[[1]], "ImageSize" -> 800]
Since we worked so much with the cosine and sine function, I started playing with the graph of the sine function. I moved it around, placed it climbing along the \(y\)-axis. Then, I decided to animate each of the graphs and this turns into art.
Hover over the image to start the animation.
Hover over the image to start the animation.
Hover over the image to start the animation.
To appreciate the Beauty of Trigonometry, it is essential to understand the key feature of the trigonometric functions Cos[t] and Sin[t]:
The trigonometric functions Cos[t] and Sin[t] provide a parametrization of the unit circle. But that is just the beginning—most importantly, a deep understanding of the sphere and torus is impossible without Cos[t] and Sin[t].
The animation below is my attempt to illustrate how the parametrization of the unit circle works.
Hover over the image to start the animation.
Clear[NgonCos, NgonSin, t, nn];
NgonCos[t_, nn_]
:= (1 - (t - Floor[t])) Cos[(2/nn) \[Pi] Floor[t]]
+ (t - Floor[t]) Cos[(2/nn) \[Pi] (1 + Floor[t])];
NgonSin[t_, nn_]
:= (1 - (t - Floor[t])) Sin[(2/nn) \[Pi] Floor[t]]
+ (t - Floor[t]) Sin[(2/nn) \[Pi] (1 + Floor[t])];
I have enjoyed the interaction between my mind and computers since I first started using them in the early 1990s. Recently, I came across a powerful metaphor for this relationship, expressed by Steve Jobs. In an old interview, he illustrated the usefulness of computers with a compelling analogy: "For me, a computer has always been a bicycle for the mind." That perfectly describes Mathematica and other modern tools like ChatGPT. Isn't that wonderful?
See the Bicycle for the Mind video. Or, a longer
version.
I recently encountered a fascinating geometric fact online: Imagine two squares where a vertex of the larger square is positioned at the center of the smaller square. Regardless of how these two squares are positioned, the area of their intersection remains constant. My description might not fully capture the beauty of this fact — indeed, an animation is worth a thousand words. How am I to make an animation? I must use technology. Here is an animation created in Mathematica.
Hover over the image to start the animation.
Hover over the image to start the animation.