all. Recently, I discovered that any point $(x, y)$ could be expressed in terms of $(\cos(\theta), \sin(\theta))$ (because I don't study mathematics seriously -- I'm just an enthusiastic amateur). Furthermore, in exploring a YouTube channel on worldbuilding, I learnt about Kepler orbits and how to model them in 2D using programmes like Desmos.
Anyway, I was looking at a map of the Solar System according to the Geocentric Model and it has these really cool loops (see below) and I'd like to model it.
This model, obviously, is long since debunked, but the map is pretty cool and I know that to model a basic 2D solar system, one has to use the elliptical formula $\frac{(x-h)^2}{a^2}+\frac{(y-k)^2}{b^2}=1$ and then model a point orbit it in the form of $(a\cos(\theta)+h, b\sin(\theta)+k)$. I also know that a flower/rose-like pattern can be made using the formula $r=nt(k\theta)$ where $t(x)$ is either $\sin(x)$ or $\cos(x)$, $n$ is the radial distance from the origin to the extremes of the petals, and $k$ describes the number of petals such that $(k\mod2=0\Rightarrow N=2|k|) \land (k\mod2=1\Rightarrow N=|k|)$. The problem with the latter formula is that the petals extend outward from the origin instead of describing a similar shape where the petals are almost indentations of a circle with a given radius as depicted in the map.
So my question is two-fold:
- How would one model the looping patterns with one function (call it $O(x)$ for argument's sake)?
- How would one model a point in the form $(f(x), g(y))$ such that the point moves continuously around $O(x)$ either clockwise or counterclockwise (directionality doesn't matter for the purposes of my model)?
Thank you in advance!

The issue is that those paths you find interesting are not proper functions in polar coordinates (or in Cartesian coordinates for that matter). That is, you cannot describe them with a one-to-one pairing of points $(\theta, r(\theta))$ since there are single angle values $\theta$ that map to multiple radius values $r$.
So you can't actually draw those paths with a single function.
You could however, describe the paths parametrically with 2 separate functions of some auxiliary variable $t$ such that your path is the set of points ${ (\theta(t), r(t)) }$. But I'm not sure what exactly those functions would be for these particular paths.