NotebookDirectory[]

I have deleted all the output from this notebook. To recreate the output Alt+v o  or click the manu item Evaluation -> Evaluate notebook

A plane

Given a point in (ℝ^3) (below it is vr0) and two non-collinear vectors (below uu and vv) the parametric equation of the plane which goes through the given point and is parallel to the given vectors is illustrated below.

vr0={1,-2,1};uu={2,3,2}; vv={-1,2,3}; 

ParametricPlot3D[vr0+s uu+t vv,{s,-13,13},{t,-13,13},PlotRange->{{-5,5},{-5,5},{-5,5}}]

Or, with more details,

?Mesh

vr0={1,-2,1};uu={2,3,2}; vv={-1,2,3}; 

Show[
ParametricPlot3D[vr0+s uu+t vv,{s,-5,5},{t,-5,5},PlotStyle->{Opacity[0.75]},
Mesh->{Range[-10,10,(1/2)],Range[-10,10,(1/2)]},MeshStyle->{{Thickness[0.003],Purple},{Thickness[0.003],Blue}},PlotRange->{{-5,5},{-5,5},{-5,5}},AxesLabel->{x,y,z}],
Graphics3D[{{Black,Thickness[0.015],Arrow[{{0,0,0},vr0}]},{PointSize[0.03],Point[vr0]},{Blue,Thickness[0.01],Arrow[{vr0,vr0+uu}]},
{Purple,Thickness[0.01],Arrow[{vr0,vr0+vv}]}}]
]

A random surface

In general, a surface in (ℝ^3) is given by a triple of equations:  x= f(s,t), y = g(s,t), z = h(s,t).  Below we came up with three random formulas and plotted the resulting surface.

ParametricPlot3D[{(s^2)-t,(s^(Exp[t])),Cos[t]Log[s]},{s,0,5},{t,-13,13},PlotRange-> {{-3,3},{0,2},{-1,1}},PlotPoints->{50,50},AxesLabel->{x,y,z}]

A sphere

However, it is more interesting to find parametric equations for familiar surfaces.  The most common parametric equations for a unit sphere centered at the origin are equations obtained from the spherical coordinates.

ParametricPlot3D[{Cos[θ] Sin[ϕ],Sin[θ] Sin[ϕ],Cos[ϕ]},{θ,0,2 Pi},{ϕ,0,Pi},PlotRange-> {{-1.2,1.2},{-1.2,1.2},{-1.2,1.2}}]

sph1=ParametricPlot3D[{Cos[θ] Sin[ϕ],Sin[θ] Sin[ϕ],Cos[ϕ]},{θ,0,2 Pi},{ϕ,0,Pi},PlotStyle->{Opacity[0.5]},PlotRange-> {{-1.2,1.2},{-1.2,1.2},{-1.2,1.2}}]

Below, I will illustrate how you can view the unit sphere as a union of horizontal circles with varying radii (blue) and also as a union of vertical semi-circles (purple).

Manipulate[
Show[ParametricPlot3D[{0,0,Cos[s]}+Sin[s]{Cos[θ],Sin[θ],0},{θ,0,2 Pi},PlotStyle->{Thickness[0.01],Blue},PlotRange-> {{-1.2,1.2},{-1.2,1.2},{-1.2,1.2}}],ParametricPlot3D[Cos[ϕ]{0,0,1}+Sin[ϕ]{Cos[t],Sin[t],0},{ϕ,0,Pi},PlotStyle->{Thickness[0.01],Purple},PlotRange-> {{-1.2,1.2},{-1.2,1.2},{-1.2,1.2}}],sph1],
{{s,(Pi/2)},0,Pi},{t,0,2 Pi}]

The horizontal circles with varying radii (blue) make up the sphere:

Manipulate[
Show[Table[ParametricPlot3D[{0,0,Cos[sr]}+Sin[sr]{Cos[θ],Sin[θ],0},{θ,0,2 Pi},PlotStyle->{Thickness[0.007],Blue},PlotRange-> {{-1.2,1.2},{-1.2,1.2},{-1.2,1.2}}],{sr,0,s,.1}]],
{s,0,Pi}]

The vertical semi-circles (purple) make up the sphere:

Manipulate[
Show[Table[ParametricPlot3D[{0,0,Cos[ϕ]}+Sin[ϕ]{Cos[tr],Sin[tr],0},{ϕ,0,Pi},PlotStyle->{Thickness[0.007],Purple},PlotRange-> {{-1.2,1.2},{-1.2,1.2},{-1.2,1.2}}],{tr,0,t,(Pi/32)}]],
{t,0,2Pi}]

Next, I will show how to place a decoration on the sphere.  Assume that at t=0 we start from the North pole of the sphere, that is the point (0,0,1). Than in we proceed downwards and after circling the sphere three times we end up at the South pole, that is the point (0,0,-1). Our height could be represented by  the function Cos[t/6].  The other coordinates are as follows below.

dec=ParametricPlot3D[{Sin[(t/6)]Cos[t],Sin[(t/6)]Sin[t],Cos[(t/6)]},{t,0,6Pi},PlotStyle->{Thickness[0.01],Red}]

Show[sph1,dec]

A vase

In the previous section we have seen that the sphere can be viewed as a union of horizontal circles varying radii. Similarly, a vase can be viewed as a union of horizontal circles varying radii. To illustrate this, we have to come up with a formula for the radius at the level z.

Manipulate[
ParametricPlot3D[{(2+Sin[z])Cos[θ],(2+Sin[z])Sin[θ],z},{θ,0,2 Pi},PlotStyle-> {Thickness[0.01],Blue},PlotRange->{{-3,3},{-3,3},{-0.1,2 Pi}}],{{z,0},0,2 Pi}]

Manipulate[
Show[
ParametricPlot3D[{(2+Sin[z])Cos[θ],(2+Sin[z])Sin[θ],z},{θ,0,2 Pi},PlotStyle-> {Thickness[0.01],Blue},PlotRange->{{-3,3},{-3,3},{-0.1,2 Pi}}],
ParametricPlot3D[{(2+Sin[s])Cos[θ],(2+Sin[s])Sin[θ],s},{θ,0,2 Pi},{s,0,z},PlotRange->{{-3,3},{-3,3},{-0.1,2 Pi}}]
],{{z,0.1},0.1,2 Pi}]

We can also view the vase as a union of the graphs of the function 2+Sin[z] in the vertical planes that contain the z-axis.

Manipulate[
Show[
ParametricPlot3D[(2+Sin[z]){Cos[θ],Sin[θ],0}+z{0,0,1},{z,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-3,3},{-3,3},{-0.1,2 Pi}}],
Graphics3D[{{Thickness[0.01],Arrow[{{0,0,0},{Cos[θ],Sin[θ],0}}]},{Thickness[0.01],Arrow[{{0,0,0},{0,0,1}}]},{Line[{{0,0,0},10 {Cos[θ],Sin[θ],0}}]},{Line[{{0,0,0},10 {0,0,1}}]}}]
],{{θ,0},0,2 Pi}]

Manipulate[
Show[ParametricPlot3D[(2+Sin[z]){Cos[θ],Sin[θ],0}+z{0,0,1},{z,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-3,3},{-3,3},{-0.1,2 Pi}}],
ParametricPlot3D[(2+Sin[z]){Cos[t],Sin[t],0}+z{0,0,1},{z,0,2 Pi},{t,0,θ},PlotRange->{{-3,3},{-3,3},{-0.1,2 Pi}}]
],{{θ,0.01},0.01,2 Pi}]

Let us now  put a decoration on this vase.

vase=ParametricPlot3D[(2+Sin[z]){Cos[t],Sin[t],0}+z{0,0,1},{z,0,2 Pi},{t,0,2 Pi},PlotStyle->{Opacity[0.6]},PlotRange->{{-3,3},{-3,3},{-0.1,2 Pi}}]

decv=ParametricPlot3D[(2+Sin[(t/3)]){Cos[t],Sin[t],0}+(t/3){0,0,1},{t,0,6Pi},PlotStyle->{Thickness[0.01],Red}]

Show[vase,decv]

A torus

The same principle that we used for the sphere and the vase with different radii lead to a torus.  At the level  z = Sin[s] let the radius of the circle be 2-Cos[s]. We start from s=0 and the radius 1. As s increases the level Sin[s] increases and the radius increases. At s= π/2 we are at the level 1 and the radius is 2. As s increases further, the level goes down, but the radius continuous to increase. At s=π the level is again 0, but the radius is 3.  Think what is happening while watching the manipulation below.

Manipulate[
Show[Table[ParametricPlot3D[{0,0,Sin[sr]}+(2-Cos[sr]){Cos[θ],Sin[θ],0},{θ,0,2 Pi},PlotRange-> {{-3.2,3.2},{-3.2,3.2},{-1.2,1.2}}],{sr,0,s,.1}]],
{s,0,2Pi}]

Manipulate[
ParametricPlot3D[2(Cos[θ]{1,0,0}+Sin[θ]{0,1,0})+Cos[t](Cos[θ]{1,0,0}+Sin[θ]{0,1,0})+Sin[t]{0,0,1},{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}],{{θ,0},0,2 Pi}]

Manipulate[
Show[
ParametricPlot3D[2(Cos[θ]{1,0,0}+Sin[θ]{0,1,0})+Cos[t](Cos[θ]{1,0,0}+Sin[θ]{0,1,0})+Sin[t]{0,0,1},{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}],
ParametricPlot3D[2(Cos[s]{1,0,0}+Sin[s]{0,1,0})+Cos[t](Cos[s]{1,0,0}+Sin[s]{0,1,0})+Sin[t]{0,0,1},{t,0,2 Pi},{s,0,θ},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}]
],{{θ,0.001},0.001,2 Pi}]

Manipulate[
ParametricPlot3D[(2+Cos[s])(Cos[θ]{1,0,0}+Sin[θ]{0,1,0})+Sin[s]{0,0,1},{θ,0,2 Pi},PlotStyle-> {Thickness[0.01],Blue},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}],{{s,0},0,2 Pi}]

Manipulate[
Show[
ParametricPlot3D[(2+Cos[s])(Cos[θ]{1,0,0}+Sin[θ]{0,1,0})+Sin[s]{0,0,1},{θ,0,2 Pi},PlotStyle-> {Thickness[0.01],Blue},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}],
ParametricPlot3D[(2+Cos[sr])(Cos[θ]{1,0,0}+Sin[θ]{0,1,0})+Sin[sr]{0,0,1},{θ,0,2 Pi},{sr,0,s},PlotStyle-> {Thickness[0.01]},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}]
],{{s,0.01},0.01,2 Pi}]

Or, changing the direction of movement of the circles

Manipulate[
Show[
ParametricPlot3D[(2+Cos[s])(Cos[θ]{1,0,0}+Sin[θ]{0,1,0})-Sin[s]{0,0,1},{θ,0,2 Pi},PlotStyle-> {Thickness[0.01],Blue},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}],
ParametricPlot3D[(2+Cos[sr])(Cos[θ]{1,0,0}+Sin[θ]{0,1,0})-Sin[sr]{0,0,1},{θ,0,2 Pi},{sr,0,s},PlotStyle-> {Thickness[0.01]},PlotRange->{{-3,3},{-3,3},{-1.1,1.1}}]
],{{s,((4 Pi)/3)},0.01,2 Pi}]

Recall the cardioid that we mentioned when we talked about parametrized curves.

Clear[t,rc]; 

rc[t_]:=(1+Cos[t]){Cos[t],Sin[t]};

Graphics[{
{Thick,Blue,Line[Table[rc[v],{v,0,2 Pi,(Pi/128) }]]}
},
Frame->True,PlotRange->{{-.5,2.5},{-1.5,1.5}},
AspectRatio->Automatic, GridLines->{{#,{GrayLevel[0.5],Dashing[{0.01,0.01}]}}&/@Range[-10,10],{#,{GrayLevel[0.5],Dashing[{0.01,0.01}]}}&/@Range[-10,10]}
]

This is more detailed way of writing its equation

ParametricPlot[
(1+Cos[t])Cos[t]{1,0}+(1+Cos[t])Sin[t]{0,1},{t,0,2 Pi},
Frame->True,PlotRange->{{-.5,2.5},{-1.5,1.5}},
AspectRatio->Automatic, GridLines->{{#,{GrayLevel[0.5],Dashing[{0.01,0.01}]}}&/@Range[-10,10],{#,{GrayLevel[0.5],Dashing[{0.01,0.01}]}}&/@Range[-10,10]}
]

I want to use this cardioid to make a torus from it.  I will first move it away from the origin and flip it around

ParametricPlot[
3{1,0}+(1+Cos[t])Cos[t]{-1,0}+(1+Cos[t])Sin[t]{0,1},{t,0,2 Pi},
Frame->True,PlotRange->{{-.5,4.5},{-1.5,1.5}},
AspectRatio->Automatic, GridLines->{{#,{GrayLevel[0.5],Dashing[{0.01,0.01}]}}&/@Range[-10,10],{#,{GrayLevel[0.5],Dashing[{0.01,0.01}]}}&/@Range[-10,10]}
]

Now, I will place this cardioid vertically and rotate it around the z-axis.

Manipulate[
ParametricPlot3D[(3-(1+Cos[t])Cos[t]){Cos[θ],Sin[θ],0} +(1+Cos[t])Sin[t]{0,0,1},{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-4,4},{-4,4},{-1.5,1.5}}],{{θ,0},0,2 Pi}]

Finally,

ParametricPlot3D[(3-(1+Cos[t])Cos[t]){Cos[θ],Sin[θ],0} +(1+Cos[t])Sin[t]{0,0,1},{t,0,2 Pi},{θ,0,2 Pi},PlotRange->{{-4,4},{-4,4},{-1.5,1.5}}]

Since the above picture is not too interesting I will try rotating the cardioid as θ changes

Manipulate[
ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[θ]{Cos[θ],Sin[θ],0}+Sin[θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[θ]{Cos[θ],Sin[θ],0}+Cos[θ]{0,0,1}),{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}],{{θ,0},0,2 Pi}]

Manipulate[
Show[
ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[θ]{Cos[θ],Sin[θ],0}+Sin[θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[θ]{Cos[θ],Sin[θ],0}+Cos[θ]{0,0,1}),{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-5.5,4.5},{-5.5,4.5},{-2,2}}],
ParametricPlot3D[3{Cos[s],Sin[s],0}+(-(1+Cos[t])Cos[t])(Cos[s]{Cos[s],Sin[s],0}+Sin[s]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[s]{Cos[s],Sin[s],0}+Cos[s]{0,0,1}),{t,0,2 Pi},{s,0.001,θ},Mesh->False,PlotRange->{{-5.5,4.5},{-5.5,4.5},{-2,2}}]
],{{θ,0},0,2 Pi}]

ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[θ]{Cos[θ],Sin[θ],0}+Sin[θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[θ]{Cos[θ],Sin[θ],0}+Cos[θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},Mesh->False,PlotRange->{{-5.5,4.5},{-5.5,4.5},{-2,2}}]

Let us rotate the cardioid several times

nn=3; Manipulate[
ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}],{{θ,0},0,2 Pi}]

nn=3; Manipulate[
Show[
ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Red},PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}],
ParametricPlot3D[3{Cos[s],Sin[s],0}+(-(1+Cos[t])Cos[t])(Cos[nn s]{Cos[s],Sin[s],0}+Sin[nn s]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn s]{Cos[s],Sin[s],0}+Cos[nn s]{0,0,1}),{t,0,2 Pi},{s,0.001,θ},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}],ParametricPlot3D[3{Cos[0],Sin[0],0}+(-(1+Cos[t])Cos[t])(Cos[nn 0]{Cos[0],Sin[0],0}+Sin[nn 0]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn 0]{Cos[0],Sin[0],0}+Cos[nn 0]{0,0,1}),{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Red},PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}],Boxed->False,Axes-> False
],{{θ,0},0,2 Pi}]

nn=3;ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->600]

VP={-0.2887510596076969`,-0.010287015546823111`,3.371426553090928`}

nn=2;card2torus=ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

nn=3;card3torus=ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

nn=4;card4torus=ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

SetDirectory[NotebookDirectory[]]

(* Export["card2torus.stl",card2torus] *)

nn=3; Manipulate[
Show[
ParametricPlot3D[3{Cos[θ],Sin[θ],0}+(-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}],
ParametricPlot3D[3{Cos[s],Sin[s],0}+(-(1+Cos[t])Cos[t])(Cos[nn s]{Cos[s],Sin[s],0}+Sin[nn s]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn s]{Cos[s],Sin[s],0}+Cos[nn s]{0,0,1}),{t,0,2 Pi},{s,0.01,θ},PlotStyle->{Opacity[.9]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}]

],{{θ,0},0,2 Pi}]

In the above I rotated the cardioid around the point where it is not differentiable; at its cusp.  Let me illustrate

Manipulate[
ParametricPlot[
(-(1+Cos[t])Cos[t]){Cos[θ],Sin[θ]} +(1+Cos[t])Sin[t]({-Sin[θ],Cos[θ]}),{t,0,2Pi},PlotRange->{{-3,3},{-3,3}}
],

{θ,0,2 Pi}]

The area of the cardioid is

(1/2)Integrate[(((1+Cos[t]))^2),{t,0,2 Pi}]

Integrate[Integrate[r,{r,0,1+Cos[t]}],{t,0,2 Pi}]

The center of mass of the cardioid is

(1/((3 π)/2))Integrate[Integrate[r Cos[t] r,{r,0,1+Cos[t]}],{t,0,2 Pi}]

(1/((3 π)/2))Integrate[Integrate[r Sin[t],{r,0,1+Cos[t]}],{t,0,2 Pi}]

Show[
ParametricPlot[
(-(1+Cos[t])Cos[t]){1,0} +(1+Cos[t])Sin[t]({0,1}),{t,0,2Pi},PlotRange->{{-3,3},{-3,3}}
],
Graphics[{{PointSize[0.02],Point[{-5/6,0}]}}]
]

Now move the cardioid so that the center of mass is at the origin

Show[
ParametricPlot[
{5/6,0}+(-(1+Cos[t])Cos[t]){1,0} +(1+Cos[t])Sin[t]({0,1}),{t,0,2Pi},PlotRange->{{-3,3},{-3,3}}
],
Graphics[{{PointSize[0.02],Point[{0,0}]}}]
]

Now rotate

Manipulate[
ParametricPlot[
((5/6)-(1+Cos[t])Cos[t]){Cos[θ],Sin[θ]} +(1+Cos[t])Sin[t]({-Sin[θ],Cos[θ]}),{t,0,2Pi},PlotRange->{{-3,3},{-3,3}}
],

{θ,0,2 Pi}]

Now implement with the cardioid torus

nn=3; Manipulate[
Show[
ParametricPlot3D[(3-(5/6)){Cos[θ],Sin[θ],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},PlotStyle-> {Thickness[0.01],Purple},PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}],
ParametricPlot3D[(3-(5/6)){Cos[s],Sin[s],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn s]{Cos[s],Sin[s],0}+Sin[nn s]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn s]{Cos[s],Sin[s],0}+Cos[nn s]{0,0,1}),{t,0,2 Pi},{s,0.01,θ},PlotStyle->{Opacity[.9]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}}]

],{{θ,0},0,2 Pi}]

((3-(5/6)){Cos[θ],Sin[θ],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}))/.{t->Pi,θ->0}

nn=2;card2torusM=ParametricPlot3D[(3-(5/6)){Cos[θ],Sin[θ],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

nn=3;card3torusM=ParametricPlot3D[(3-(5/6)){Cos[θ],Sin[θ],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

nn=4;card4torusM=ParametricPlot3D[(3-(5/6)){Cos[θ],Sin[θ],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

nn=5;card5torusM=ParametricPlot3D[(3-(5/6)){Cos[θ],Sin[θ],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

nn=6;card6torusM=ParametricPlot3D[(3-(5/6)){Cos[θ],Sin[θ],0}+((5/6)-(1+Cos[t])Cos[t])(Cos[nn θ]{Cos[θ],Sin[θ],0}+Sin[nn θ]{0,0,1}) +(1+Cos[t])Sin[t](-Sin[nn θ]{Cos[θ],Sin[θ],0}+Cos[nn θ]{0,0,1}),{t,0,2 Pi},{θ,0,2 Pi},PlotStyle->{Opacity[.8]},PlotPoints->{50,50},Mesh->False,PlotRange->{{-5.5,5.5},{-5.5,5.5},{-2,2}},Boxed->False,Axes-> False,ImageSize->800]

SetDirectory[NotebookDirectory[]]

(* Export["card5torusM.stl",card5torusM] *)

Making a surfaces starting from a curve

Starting from a circle

Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}]
},
PlotRange->{{-2,2},{-2,2},{-2,2}}]

At each point of this circle we can place a vertical line.

t0=1;Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{Cos[t0],Sin[t0],0}+{0,0,s},{s,-3,3},PlotStyle->{Cyan,Thickness[0.01]}]

},
PlotRange->{{-2,2},{-2,2},{-2,2}}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{Cos[t0],Sin[t0],0}+{0,0,s},{s,-3,3},PlotStyle->{Cyan,Thickness[0.01]}]

},
PlotRange->{{-2,2},{-2,2},{-2,2}}],
{t0,0,2 Pi}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{Cos[t],Sin[t],0}+{0,0,s},{s,-3,3},{t,0,t0}]
},
PlotRange->{{-2,2},{-2,2},{-2,2}}],
{t0,0.01,2 Pi}]

However, instead of using a vertical line we could go in any direction, Say

vv={1,2,3}; Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{Cos[t],Sin[t],0}+s vv,{s,-3,3},{t,0,t0}]
},
PlotRange->{{-2,2},{-2,2},{-2,2}}],
{t0,0.01,2 Pi}]

A different way of getting interesting surfaces is to move the original circle.

Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{0,0,1}+{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}]
},
PlotRange->{{-2,2},{-2,2},{-2,2}}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{0,0,s}+{Cos[t],Sin[t],0},{t,0,2 Pi},{s,0,h}]
},
PlotRange->{{-2,2},{-2,2},{0,4}}],{h,.1,4}]

However, it is not hard to get much more imaginative by moving the center as we go up

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{Cos[s],Sin[s],(s/Pi)}+{Cos[t],Sin[t],0},{t,0,2 Pi},{s,0,h}]
},
PlotRange->{{-2,2},{-2,2},{0,4}}],{h,.1,4 Pi}]

Another twist that we can introduce is to vary the radius as we go up

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{Cos[s],Sin[s],(s/Pi)}+(1+Sin[s]){Cos[t],Sin[t],0},{t,0,2 Pi},{s,0,h}]
},
PlotRange->{{-3,3},{-3,3},{0,4}}],{h,.1,4 Pi}]

This idea of varying the radius leads to a familiar surface

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{0,0,s}+(s){Cos[t],Sin[t],0},{t,0,2 Pi},{s,0,h}]
},
PlotRange->{{-3,3},{-3,3},{0,4}}],{h,.1,4 }]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{0,0,s}+(Sin[s]){Cos[t],Sin[t],0},{t,0,2 Pi},{s,0,h}]
},
PlotRange->{{-3,3},{-3,3},{0,4}}],{h,.1,Pi}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{0,0,Cos[s]}+(Sin[s]){Cos[t],Sin[t],0},{t,0,2 Pi},{s,0,h}]
},
PlotRange->{{-1.1,1.1},{-1.1,1.1},{-1.1,1.1}}],{h,.1,Pi}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{0,0,Sin[s]}+(2-Cos[s]){Cos[t],Sin[t],0},{t,0,2 Pi},{s,0,h}]
},
PlotRange->{{-3.1,3.1},{-3.1,3.1},{-1.1,1.1}}],{h,.1,2Pi}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[{2,0,0}+{Cos[s],0,Sin[s]},{s,0,2Pi},PlotStyle->{Cyan,Thickness[0.01]}]
},
PlotRange->{{-3.1,3.1},{-3.1,3.1},{-1.1,1.1}}],{h,.1,2Pi}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[2{1,0,0}+Cos[s]{1,0,0}+Sin[s]{0,0,1},{s,0,2Pi},PlotStyle->{Cyan,Thickness[0.01]}]
},
PlotRange->{{-3.1,3.1},{-3.1,3.1},{-1.1,1.1}}],{h,.1,2Pi}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[2{Cos[tt],Sin[tt],0}+Cos[s]{Cos[tt],Sin[tt],0}+Sin[s]{0,0,1},{s,0,2Pi},PlotStyle->{Cyan,Thickness[0.01]}]
},
PlotRange->{{-3.1,3.1},{-3.1,3.1},{-1.1,1.1}}],{tt,0,2Pi}]

Manipulate[Show[
{
ParametricPlot3D[{Cos[t],Sin[t],0},{t,0,2 Pi},PlotStyle->{Blue,Thickness[0.01]}],
ParametricPlot3D[2{Cos[tt],Sin[tt],0}+Cos[s]{Cos[tt],Sin[tt],0}+Sin[s]{0,0,1},{s,0,2Pi},PlotStyle->{Cyan,Thickness[0.01]}],
ParametricPlot3D[2{Cos[t],Sin[t],0}+Cos[s]{Cos[t],Sin[t],0}+Sin[s]{0,0,1},{s,0,2Pi},{t,0,tt}]
},
PlotRange->{{-3.1,3.1},{-3.1,3.1},{-1.1,1.1}}],{tt,0.1,2Pi}]