如何使用 tikz 或 tkz-euclide 绘制如图所示的角度标记

如何使用 tikz 或 tkz-euclide 绘制如图所示的角度标记

有没有简单的方法可以画出如图所示的角度标记? 角度标记

    \documentclass[french,tikz,border=2.5mm]{standalone}
    \usepackage[ansinew]{inputenc}% caractères accentués
    \usepackage[T1]{fontenc} % fontes extended computer modern (EC)
    \usepackage{lmodern} % l'affichage correct des caractères diacritiqués français
    \usepackage{babel}% \usepackage[french]{babel} typographie française


    \usepackage{xcolor}
    \usepackage{tikz,tkz-euclide,siunitx}

    \usetikzlibrary{quotes ,babel,arrows.meta,angles,calc,shadings,positioning}

    \usetkzobj{all}



    \begin{document}
        \begin{tikzpicture}
            \tkzDefPoint(0,0){A}
            \tkzDefPoint(55:8.8){C}
            \tkzDefPoint(55:5.2){B}
            \tkzDefShiftPoint[B](20:3){B'}
            \tkzDefShiftPoint[C](20:-3){C'}
            \tkzDefShiftPoint[C](180:3){C''}
            \tkzDrawSegment[line cap =round, double distance=3mm](A,C)
            \tkzDrawPoints(A,B,C)
            \begin{scope}[very thick]
            \tkzDrawVector[-Stealth](B',B)
            \tkzDrawVector(C',C)
            \end{scope}

            \tkzLabelPoint(C){\(C\)}
            \tkzLabelPoint(A){\(A\)}
            \tkzLabelPoint(B){\(B\)}

            \draw (C)--(C'');

        \end{tikzpicture}
    \end{document}

答案1

你可能会做如下的事情:

  • 定义几个额外的点,c1指示c2角度的箭头从这些点开始;

  • 使用angles库在 ie和angle pic中绘制这些箭头;C'--C--c2c1--C--C'

  • 使用非绘制的angle将度数标签放置在 处C''--C--C'

其结果如下:

标记角度

完整代码:

\documentclass[tikz,border=2.5mm]{standalone}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern,siunitx}
\usepackage{tkz-euclide}
\usetikzlibrary{quotes,babel,arrows.meta,angles,positioning}
\usetkzobj{all}
\begin{document}
\begin{tikzpicture}
  [
    angle radius=20mm,
    angle eccentricity=1,
  ]
  \tkzDefPoint(0,0){A}
  \tkzDefPoint(55:8.8){C}
  \tkzDefPoint(55:5.2){B}
  \tkzDefShiftPoint[B](20:3){B'}
  \tkzDefShiftPoint[C](20:-3){C'}
  \tkzDefShiftPoint[C](35:-3){c1}
  \tkzDefShiftPoint[C](180:3){C''}
  \tkzDefShiftPoint[C](165:3){c2}
  \tkzDrawSegment[line cap =round, double distance=3mm](A,C)
  \tkzDrawPoints(A,B,C)
  \begin{scope}[very thick]
    \tkzDrawVector[-Stealth](B',B)
    \tkzDrawVector(C',C)
  \end{scope}
  \tkzLabelPoint(C){\(C\)}
  \tkzLabelPoint(A){\(A\)}
  \tkzLabelPoint(B){\(B\)}
  \draw (C)--(C'');
  \pic ["20\si{\degree}"] {angle = C''--C--C'};
  \pic [draw, {Stealth[]}-] {angle = C'--C--c1};
  \pic [draw, -{Stealth[]}] {angle = c2--C--C''};
\end{tikzpicture}
\end{document}

相关内容