TikZ:非线性切线曲线

TikZ:非线性切线曲线

我想从点到点绘制一条切线曲线(a)(b)交点(c)(正方形的中心)。曲线应根据灰线拉伸(对数刻度)。我尝试过controls,但进展不大。有没有比使用更好的方法controls

我迄今为止的代码:

\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary{calc}
\begin{document}
\begin{tikzpicture}[every node/.style = {draw, circle, fill=white, inner sep=.01cm}]

\draw (0, 1) -- (10, 1) -- (10, -1) -- (0, -1) -- cycle;
\node (a) at (0, -1) {a};   % south-west corner
\node (b) at (10, 1) {b};   % north-east corner
\node (c) at (5, 0) {c};    % center
\foreach \n in {1,...,50} \draw[gray, very thin]
        ({10/pow(2, \n/12)}, 1)
    --  ({10/pow(2, \n/12)}, -1);

\draw[cyan] (a) -- (b);

\end{tikzpicture}
\end{document}

结果: 在此处输入图片描述

我想要实现以下目标(尽管曲线的左半部分应该下降得更快): 在此处输入图片描述

答案1

这也许更接近一点吧?

\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary{calc}
\begin{document}
\begin{tikzpicture}[every node/.style = {draw, circle, fill=white, inner sep=.01cm}]

\draw (0, 1) -- (10, 1) -- (10, -1) -- (0, -1) -- cycle;
\node (a) at (0, -1) {a};   % south-west corner
\node (b) at (10, 1) {b};   % north-east corner
\node (c) at (5, 0) {c};    % center
\foreach \n in {1,...,50} \draw[gray, very thin]
        ({10/pow(2, \n/12)}, 1)
    --  ({10/pow(2, \n/12)}, -1);

\draw[thick,cyan] (a) to[out=0,in=270,looseness=0.55] (c.center) to[out=65,in=180,looseness=0.5] (b);

\end{tikzpicture}
\end{document}

在此处输入图片描述

答案2

这是我从你的评论描述中得到的。我的想法接近你的想法了吗?如果不接近,也许你可以提供一个手绘模型。

这?

\usetikzlibrary{calc}
\begin{tikzpicture}[every node/.style = {draw, circle, fill=white, inner sep=.01cm}]

\draw (0, 1) -- (10, 1) -- (10, -1) -- (0, -1) -- cycle;
\node (a) at (0, -1) {a};   % south-west corner
\node (b) at (10, 1) {b};   % north-east corner
\node (c) at (5, 0) {c};    % center
\foreach \n in {1,...,50} \draw[gray, very thin]
        ({10/pow(2, \n/12)}, 1)
    --  ({10/pow(2, \n/12)}, -1);

\draw[cyan] (a) .. controls +(5, 0) and +(-.5, -.5) .. (c.center) .. controls +(.5,.5) and +(-1,0) .. (b);
\end{tikzpicture}

相关内容