What I am trying to achieve
Firstly, this is just for fun and has no real world purpose.
I am trying to create a plot of a helix that is perpendicular to a curve. The helix is defined by a parametric equation (see below). The helix looks almost like I wanted it to (see plots below). However, there is something wrong with my equation that causes some imperfections in certain areas of the helix (see 2D plot).
Plot: 2D view
Plot: 3D view
Equation for basic curve
This is the equation for the basic curve that the helix should go around. This equation produces the desired plot. In the plot it is represented by the orange line. $$ t=[0,2\pi[\\ r_1=5\\ \omega _1=1\\ r_2=2\\ \omega _2=7\\ r_3=0.5\\ \omega _3=500\\ \\ \begin{pmatrix} x\\ y\\ z\\ \end{pmatrix} = \begin{pmatrix} r_1\cdot cos(\omega_1\cdot t)+ r_2\cdot cos(\omega_2\cdot t)\\ r_1\cdot sin(\omega_1\cdot t)+ r_2\cdot sin(\omega_2\cdot t)\\ 0 \\ \end{pmatrix} $$
Equation with the helix
This is the equation for the helix (represented by the blue lines in the plots). It produces mostly the curve that I am trying to achieve. However the helix is not everywhere exactly perpendicular to its centre (basic curve, see above). I think this is due to the red part of the equation. $$ \begin{pmatrix} x\\ y\\ z\\ \end{pmatrix} = \begin{pmatrix} r_1\cdot cos(\omega_1\cdot t)+ r_2\cdot cos(\omega_2\cdot t)+ r_3\cdot cos(\omega_3\cdot t) \color{red}{\cdot cos(\omega_2\cdot t)}\\ r_1\cdot sin(\omega_1\cdot t)+ r_2\cdot sin(\omega_2\cdot t)+ r_3\cdot cos(\omega_3\cdot t) \color{red}{\cdot sin(\omega_2\cdot t)}\\ r_3 \cdot sin(\omega_3 \cdot t) \\ \end{pmatrix} $$ Question
How do I need to change the red part of the equation in order to get a helix that is always perpendicular to its centre?