![sagemath 提供的 Latex 所需软件包](https://linux22.com/image/273648/sagemath%20%E6%8F%90%E4%BE%9B%E7%9A%84%20Latex%20%E6%89%80%E9%9C%80%E8%BD%AF%E4%BB%B6%E5%8C%85.png)
我正在尝试使用以下命令导出 sagemath 图表:
sage: M = Matrix ([ [0, 1, 1], [1, 0, 1], [1, 1, 0] ])
sage: # (the order is the number of edges)
sage: G = Graph(M); G.order()
sage: G.show();
sage: latex.engine();
sage: latex(G);
我的输出是:
\begin{tikzpicture}
%
\useasboundingbox (0,0) rectangle (5.0cm,5.0cm);
%
\definecolor{cv0}{rgb}{0.0,0.0,0.0}
\definecolor{cfv0}{rgb}{1.0,1.0,1.0}
\definecolor{clv0}{rgb}{0.0,0.0,0.0}
\definecolor{cv1}{rgb}{0.0,0.0,0.0}
\definecolor{cfv1}{rgb}{1.0,1.0,1.0}
\definecolor{clv1}{rgb}{0.0,0.0,0.0}
\definecolor{cv2}{rgb}{0.0,0.0,0.0}
\definecolor{cfv2}{rgb}{1.0,1.0,1.0}
\definecolor{clv2}{rgb}{0.0,0.0,0.0}
\definecolor{cv0v1}{rgb}{0.0,0.0,0.0}
\definecolor{cv0v2}{rgb}{0.0,0.0,0.0}
\definecolor{cv1v2}{rgb}{0.0,0.0,0.0}
%
\Vertex[style={minimum
size=1.0cm,draw=cv0,fill=cfv0,text=clv0,shape=circle},LabelOut=false,L=\\
hbox{$0$},x=3.6292cm,y=0.0cm]{v0}
\Vertex[style={minimum
size=1.0cm,draw=cv1,fill=cfv1,text=clv1,shape=circle},LabelOut=false,L=\\
hbox{$1$},x=5.0cm,y=5.0cm]{v1}
\Vertex[style={minimum
size=1.0cm,draw=cv2,fill=cfv2,text=clv2,shape=circle},LabelOut=false,L=\\
hbox{$2$},x=0.0cm,y=3.6915cm]{v2}
%
\Edge[lw=0.1cm,style={color=cv0v1,},](v0)(v1)
\Edge[lw=0.1cm,style={color=cv0v2,},](v0)(v2)
\Edge[lw=0.1cm,style={color=cv1v2,},](v1)(v2)
%
\end{tikzpicture}
但我肯定缺少一些可以导入 TeXstudio 的包,因为它无法识别\useasboundingbox
、\definecolor
或\Vertex
或\Edge
我必须使用什么包?