如何加上这样的线条?

发布于 2022-11-04 10:34:26

IMG_20221104_102209.jpg

 \documentclass{ctexart}
 \usepackage{amsmath}
 \begin{document}
    $\begin{vmatrix}
         a_{11} & a_{12} & a_{13} \\
         a_{21} & a_{22} & a_{23} \\
         a_{31} & a_{32} & a_{33}
     \end{vmatrix}$
\end{document}

查看更多

关注者
0
被浏览
877
2 个回答
寄存器
寄存器 2022-11-04
这家伙很懒,什么也没写!

用nicematrix宏包:texdoc nicematrix,读说明书。

Swit
Swit 2022-11-06
LaTeX nubility!
\documentclass{article}
\usepackage{amsmath}
\usepackage{tikz}
\usetikzlibrary{tikzmark}

\begin{document}

\[\begin{vmatrix}
  \tikzmarknode{11}{a_{11}} & \tikzmarknode{12}{a_{12}} & \tikzmarknode{13}{a_{13}} \\
  \tikzmarknode{21}{a_{21}} & \tikzmarknode{22}{a_{22}} & \tikzmarknode{23}{a_{23}} \\
  \tikzmarknode{31}{a_{31}} & \tikzmarknode{32}{a_{32}} & \tikzmarknode{33}{a_{33}}
\end{vmatrix}\]

\begin{tikzpicture}[remember picture, overlay]
    \draw (11)--(22)--(33);
    \draw (12)--(23);
    \draw (21)--(32);
    \draw[densely dashed] (31)--(22)--(13);
    \draw[densely dashed] (21)--(12);
    \draw[densely dashed] (32)--(23);

    \draw[rounded corners] (31)--++(1.25,-0.65)--++(1.25,0.65)--(23);
    \draw[rounded corners] (32)--++(1.25,-0.65)--++(1.25,0.65)--(13);
    \draw[rounded corners, densely dashed] (11)--++(1.25,0.65)--++(1.25,-0.65)--(23);
    \draw[rounded corners, densely dashed] (12)--++(1.25,0.65)--++(1.25,-0.65)--(33);
\end{tikzpicture}

\end{document}

c85f348760f8d40396d6f3dbf4a6a674.png

撰写答案

请登录后再发布答案,点击登录

发布
问题

分享
好友

手机
浏览

扫码手机浏览