Superformula derivation critical points I discovered lately the superformula for superellipse (no pun intended). It provides a parametrized definition for any closed curve given by its parameter tuples $(a, b, m, n_1, n_2, n_3)$ and variable $\theta$ within $[0, 2\pi]$.
I require to know the critical points of superformula derivative $\frac{d \, r}{d \, \theta}$. Since it has two moduli terms, I supposed the discontinuities would occur when the inner function is zero. However, since both functions $sin(\cdot)$ and $cos(\cdot)$ are in absolute value and never go to zero simultaneously, I am out of options.
The 2D-plots in Wikipedia article provide several parameter tuple possibilities with "beaks".
Could you help me with this question?
 A: The critical points can also come from one of the individual terms $\left|\cos \frac{m\phi}{4}\right|^{n_2}$ or $\left|\sin \frac{m\phi}{4}\right|^{n_3}$.
When we look at the examples where Wikipedia has "beaks" (the technical term is "cusps"), we see that they have $n_2=0.5$ and/or $n_3=0.5$:

That corresponds to a term that looks something like $\sqrt{|\cos \phi|}$.
Just like the function $f(x) = \sqrt{|x|}$ has a cusp at $x=0$, the function $r(\phi) = \sqrt{|\cos \phi|}$ will have a cusp when $\cos\phi = 0$. In virtually all cases, this cusp will still be a critical point for the entire superformula, due to the chain rule.
In general, $|x|^r$ has a critical point at $0$ whenever $r \le 1$. (Moreover, a function like $(c + |x|^r)^{1/n}$ inherits this critical point, due to the chain rule.) As a result, the superformula will have a critical point at:

*

*points where $\cos \frac{m\phi}{4} = 0$, whenever $n_2 \le 1$;

*points where $\sin \frac{m\phi}{4} = 0$, whenever $n_3 \le 1$.

In the diagrams, when $n_2=1$ or $n_3=1$, we see well-defined but noticeable corners.
