Function Repository Resource:

CanalSurface

Source Notebook

Compute the parametrization of a canal surface

Contributed by: Wolfram Staff (original content by Alfred Gray)

ResourceFunction["CanalSurface"][dir,pm,r,{t,θ}]

computes the parametrization of a canal surface of variable radius r and parameter pm with directrix dir and variables t,θ.

Details and Options

A channel or canal surface is a surface generated as the envelope of a one-parameter family of spheres with respect to a directrix.

Examples

Basic Examples (2) 

Define a circle in 3D:

In[1]:=
circle[a_, t_] := {a Cos[t], a Sin[t], 0}

Compute a canal surface, using the circle as the directrix:

In[2]:=
canalcircle = ResourceFunction["CanalSurface"][circle[1, t], 1, Cos[t], {t, \[Theta]}]
Out[2]=

Plot the resulting canal surface:

In[3]:=
ParametricPlot3D[
 Evaluate[canalcircle], {t, 0, 2 \[Pi]}, {\[Theta], 0, 2 \[Pi]}]
Out[3]=

Plot the circle and a canal surface, along with the spheres:

In[4]:=
Show[ParametricPlot3D[
  Evaluate[{circle[1, t], ResourceFunction["CanalSurface"][circle[1, t], 1/2, Cos[t/2], {t, \[Theta]}]}], {t, 0, 2 \[Pi]}, {\[Theta], 0, 2 \[Pi]}, PlotStyle -> {Directive[Opacity[1], Thickness[.05]], Opacity[.5]}, Mesh -> None], Graphics3D[
  Table[Sphere[circle[1, ts], Abs[.49 Cos[ts/2]]], {ts, 0, 2 \[Pi], 2 \[Pi]/16}]]]
Out[4]=

Define a helix in 3D:

In[5]:=
helix[a_, t_] := {a Cos[t], a Sin[t], t}

Compute a canal surface, using the helix as the directrix:

In[6]:=
ParametricPlot3D[
 Evaluate[
  ResourceFunction["CanalSurface"][helix[1, t], .2 t, Cos[t], {t, \[Theta]}]], {t, 0, 4 \[Pi]}, {\[Theta], 0, 2 \[Pi]}, PlotPoints -> {40, 15}]
Out[6]=

Publisher

Enrique Zeleny

Version History

  • 1.0.0 – 26 February 2020

Source Metadata

License Information