我怎样才能画出这个钟摆?

我怎样才能画出这个钟摆?

我最近对使用 TikZ 绘制这个钟摆很感兴趣,但遇到了一些困难,这是我想要得到的:

在此处输入图片描述

这是我的尝试及其结果:

       \begin{tikzpicture}

 \draw[dashed, ->,smooth] (0,-3)--(0,4.5) node[right] {$z$};
 \draw[thick] (0,3)--(2,-2.5);
 \node[right] at (1,0.25) {$d$};
 \filldraw[black] (2,-2.5)circle(0.025);
 \draw[->] (2,-2.5)--(2,-3.5)node[left] {$\vec{P}$};
 \node[right] at (2,-2.5) {$G$};
 \filldraw[black] (0,3)circle(0.025);
 \draw[smooth, ->] (0,3)--(-0.17,3.8) node[left] {$\vec{R}$};
 \coordinate(o) at (2,-2.5);
\coordinate(b) at (0, -3);
\coordinate(a) at (0, 3);
\pic [draw=black!15!black,text=black,angle radius=13mm,"$\theta$",angle eccentricity=1.3]{angle = b--a--o};
\draw[dashed] (2,-2.5)--(2,3)--(0,3);
\coordinate(c) at (2,3);
\pic [draw=black!15!black,text=black,angle radius=13mm,"$\theta$",angle eccentricity=1.3]{angle = c--o--a};
\node[above] at (2,3) {$M$};
\node[left] at (0,3) {$O$};
\node[left] at (0,2.6){$(\Delta)$};
\pic [dashed ,draw=black!15!black ,angle radius=58.5mm,angle eccentricity=1.3]{angle = b--a--o};
\node[left] at (0,-2.8) {$G_0=O$};
\filldraw[black] (0,-2.85)circle(0.025); 
\end{tikzpicture}

在此处输入图片描述

有人能帮助我画出这样的身体吗:

在此处输入图片描述

答案1

你可以用平滑的曲线来画身体(见这个问题)。

例如,将以下几行添加到您的tikzpicture

\draw[dashed, red] (-1,3.3) -- (1,3) -- (1.5,2.5) -- (2.5,2) -- (3,-1) -- (2.5,-3) -- (1.5,-2.5) -- (0.5,0) -- cycle;
\draw plot [smooth cycle, tension=.4] coordinates {(-1,3.3) (1,3) (1.5,2.5) (2.5,2) (3,-1) (2.5,-3) (1.5,-2.5) (0.5,0)};

给出这个:

在此处输入图片描述

(红线协助施工)

相关内容