I would like to draw in tikz two cones tangent along a common generatrix, like in the picture below. I managed to draw the vertical cone (even taking into account that the two generatrices drawn should be tangent to the ellipse, so that their endpoints are not the endpoints of the major semi axis), but I'm not sure how to draw the inclined cone. Any help would be much appreciated.

enter image description here

  • 1
    Could you please add a minimum working example (your code, but stripped by everything irrelevant, such that anyone might copy it and immediately compile it)? – Concerto Dec 23 '20 at 23:33
  • It should be easy to draw this with tikz-3dplot. – user231225 Dec 24 '20 at 0:03

Maybe this is a start. I just copied the critical angle from another post but this works only for the main coordinates. The top circles of the cones are correct, I think, and the cones are tangential.

\begin{tikzpicture}[tdplot_main_coords,line join=round, line cap=round,
 declare function={H=4;alpha=25;beta=15;
 \draw (0,0,0) coordinate (O) -- (5,0,0) node[below]{$1$}
  (O) -- (0,5,0) node[below]{$2$};
 \path (O) -- (0,0,5) coordinate (z);
 \begin{scope}[canvas is xy plane at z=ha]
  % https://tex.stackexchange.com/a/540838
  \draw  (\tdplotmainphi-\alphacrit:ra) coordinate (c1) -- (O)
   -- (180+\tdplotmainphi+\alphacrit:ra) coordinate (c2);
  \draw (0,0) circle[radius=ra];
 \draw[dashed] (O) -- (0,0,{ha-ra*cos(\tdplotmaintheta)}) coordinate (i1);
 \draw[thick,-stealth] (i1) -- (0,0,5) node[above right]{$\boldsymbol{L}$};
  \draw[name path=z'] (O) -- (0,0,5) coordinate[label=above:{$3$}](z');
  \begin{scope}[canvas is xy plane at z=hb]
   % https://tex.stackexchange.com/a/540838
   \draw  (\tdplotmainphi-\alphacrit:rb) coordinate (c3) -- (O)
     (90+\tdplotmainphi:rb) coordinate (i2);
   \draw[name path=circb] (0,0) circle[radius=rb];
   \draw[dashed,name intersections={of=circb and z',by=i2}] (O) -- (i2);
  \draw[-stealth] (i2) -- (0,0,4.5) node[left]{$\boldsymbol{L_3}$}; 

enter image description here

  • This is exactly what I needed! Thanks a lot. – user3476591 Dec 24 '20 at 11:33
  • 1
    Just one more thing. Would it be hard to also shade the cones in some way (for example, light gray)? – user3476591 Dec 25 '20 at 12:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.