There is a whole family of curves (including knots) which are defined by the equations:[br][br][math]\text{x = r \cos(\phi) \cos(\vartheta)}[/math][br][math]\text{y = r \cos(\phi)\sin(\vartheta)}[/math][br][math]z=r\ \sin\left(\phi\right)[/math][br][br]that we usually use to convert from polar to Cartesian coordinates.[br]For the knot in the app below, [math]r[/math], [math]\phi[/math] and [math]\vartheta[/math] are functions of a parameter [math]\beta\in\left[0,2\pi\right][/math], as follows:[br][br][math]r\left(\beta\right)=0.8+1.6\sin\left(6\beta\right)[/math][br][math]\phi\left(\beta\right)=0.6\pi\sin\left(12\beta\right)[/math][br][math]\vartheta\left(\beta\right)=2\beta[/math][br][br]To rotate the view, right click and drag, or use the predefined gestures on mobile devices.
For the knot in the app below,[br][br][math]r\left(\beta\right)=1.2+0.6\sin\left(\frac{\pi}{2}+6\beta\right)[/math][br][math]\phi\left(\beta\right)=0.2\pi\sin\left(6\beta\right)[/math][br][math]\vartheta\left(\beta\right)=4\beta[/math]