Claim:其实这更多的是一个数学问题...
个人探索的另一个更优雅和直观的方式是基于「一些神必的数学」

而更碰巧的是,tikz提供了「coordinate transformation matrix」这样的feature
所以可以得到如下个人觉得比较简单的实现:
\documentclass[tikz,border=5pt]{standalone}
\begin{document}
\def\radius{1}
\def\height{1.05}%to tune the eccentricity
\def\leftheight{2}
\def\rightheight{4}
\def\midheight{\fpeval{(\leftheight+\rightheight)/2}}
\def\hh{\fpeval{abs(\leftheight-\rightheight)/2}}
\begin{tikzpicture}[line join=round]
    \draw[dashed] (\radius,0) arc (0:180:{\radius} and {1/3});
    \draw (-\radius,0) arc (180:360:{\radius} and {1/3});
    \draw (-\radius,0) -- (-\radius,\leftheight) coordinate (A);
    \draw (\radius,0) -- (\radius,\rightheight) coordinate (B);
    \def\phii{\fpeval{acos(\hh/\height)}}
    \def\xa{0}
    \def\ya{\fpeval{-\height*sin(\phii)}}
    \def\xb{\radius}
    \def\yb{\fpeval{\height*cos(\phii)}}
    \draw[cm={\xa,\ya,\xb,\yb,(0,\midheight)}] circle [radius=1cm];
    \filldraw[red] (A) circle[radius=.5pt] node[left,text=black] {$A$}
                   (B) circle[radius=.5pt] node[right,text=black] {$B$};
    \node[align=left,rectangle] at (\radius+4,\rightheight/2) {%
        $\phi$ \texttt{=\phii}\\
        $(x_1,y_1)$ \texttt{=(\xa,\ya)}\\
        $(x_2,y_2)$ \texttt{=(\xb,\yb)}
    };
\end{tikzpicture}
\end{document}
欣赏一下局部细节

Edit
忽然想到:
要欣赏一下局部细节
tikz提供了spy这样的工具,尝尝鲜嘻嘻
\documentclass[tikz,border=5pt]{standalone}
\usetikzlibrary{spy}
\begin{document}
\def\radius{1}
\def\height{1.05}%to tune the eccentricity
\def\leftheight{2}
\def\rightheight{4}
\def\midheight{\fpeval{(\leftheight+\rightheight)/2}}
\def\hh{\fpeval{abs(\leftheight-\rightheight)/2}}
\begin{tikzpicture}[
    line join=round,
    line cap=round,
    spy using outlines={%
        circle,size=2cm,
        magnification=10,
        connect spies
    }%
]
    \draw[dashed] (\radius,0) arc (0:180:{\radius} and {1/3});
    \draw (-\radius,0) arc (180:360:{\radius} and {1/3});
    \draw (-\radius,0) -- (-\radius,\leftheight) coordinate (A);
    \draw (\radius,0) -- (\radius,\rightheight) coordinate (B);
    \def\phii{\fpeval{acos(\hh/\height)}}
    \def\xa{0}
    \def\ya{\fpeval{-\height*sin(\phii)}}
    \def\xb{\radius}
    \def\yb{\fpeval{\height*cos(\phii)}}
    \draw[cm={\xa,\ya,\xb,\yb,(0,\midheight)}] circle [radius=1cm];
    \node[align=left,rectangle] at (\radius+4,1) {%
        $\phi$ \texttt{=\phii}\\
        $(x_1,y_1)$ \texttt{=(\xa,\ya)}\\
        $(x_2,y_2)$ \texttt{=(\xb,\yb)}
    };
    \spy[red] on (A) in node [left] at (-1,4);
    \spy[blue] on (B) in node [right] at (2.5,3);
\end{tikzpicture}
\end{document}





















问 如何绘制斜截的圆柱,要求倾斜的椭圆截面与圆柱的母线精确相切?