What could be a homeomorphism from the circle to a triangle?

I'm looking for a bijection from a circle to a triangle that is continuous with a continuous inverse. What could be one?


Here is an animation I made exhibiting such a homeomorphism:

enter image description here

Mathematica code:

CirclePoint[t_] := {Cos[2 Pi t], Sin[2 Pi t]}

TrianglePoint[t_] := 
 If[0 <= t < 1/3,
   {((1-(3t))+(-1/2) (3t)), -(1/Sqrt[3])(((1-(3t))+(-1/2)(3t))+1/2)+Sqrt[3]/2}, 
 If[1/3 <= t < 2/3,
   {-1/2, (1-(3t-1))Sqrt[3]/2+(3t-1)(-Sqrt[3]/2)},
   {((-1/2)(1-(3t-2))+(3t-2)),
          (1/Sqrt[3])(((-1/2)(1-(3t-2))+(3t-2))+1/2)-Sqrt[3]/2}]]

CircleTriangle[s_] := 
 ParametricPlot[(1-s) CirclePoint[t] + s TrianglePoint[t], {t, 0, 1},
   PlotRange -> {{-1.1, 1.1}, {-1.1, 1.1}}, Ticks -> None, Axes -> False]

Export["animation2.gif", 
 Join[Table[CircleTriangle[Max[s, 0]], {s, -0.1, 1, 0.02}], 
  Table[CircleTriangle[Min[s, 1]], {s, 1.1, 0, -0.02}]], 
 "DisplayDurations" -> 0.1]

I will assume that by circle you mean the curve, not the disk, and also that by triangle you mean the "curve" consisting of three line segments. In a remark at the end, we mention how to modify things if we are dealing with a disk and a triangle-with-interior.

We are given a circle $C$ and a triangle $T$. Draw the incircle $C^\ast$ of $T$. There is a natural bijection $\varphi$ from $C$ to $C^\ast$ (scale and translate).

We will produce a bijection from $C^\ast$ to $T$. Let $O$ be the centre of $C^\ast$, and let $P$ be any point on $C^\ast$. Draw the half-infinite ray $OP$. This ray meets the triangle at a uniquely defined point. Let $\psi(P)$ be that point. Then $\psi$ is a continuous bijection with continuous inverse from $C^\ast$ to $T$, so $\psi\circ\varphi$ is a continuous bijection from $C$ to $T$, with continuous inverse.

Remark: Using a similar idea, we can find a continuous bijection with continuous inverse from any disk $C$ to the figure made up of a triangle and its interior. All we need to do is to modify the definition of $\psi$. Let $O$ be the centre of the disk $C^\ast$, and let $P$ be a point on the boundary of that disk. Suppose that the ray $OP$ meets the boundary of the triangle at $Q$, and let $X$ be a point in the disk and on the line segment $OP$. Map $X$ to the point $Y$ on the line segment $OP$ such that $\frac{OY}{OX}=\frac{OQ}{OP}$.


I think it may be something like this.

enter image description here


I'm just answering to add a different homeomorphism: match arc length along the circle to cumulative perimeter along the triangle.