![绘制简单的三维轴](https://linux22.com/image/475107/%E7%BB%98%E5%88%B6%E7%AE%80%E5%8D%95%E7%9A%84%E4%B8%89%E7%BB%B4%E8%BD%B4.png)
答案1
作为起点,可以使用以下代码:
\documentclass[border=2pt]{standalone}
% Drawing
\usepackage{tikz}
\usepackage{tikz-3dplot}
\begin{document}
\tdplotsetmaincoords{60}{120}
\begin{tikzpicture}
[scale=3,
tdplot_main_coords,
axis/.style={->,blue,thick},
vector/.style={-stealth,red,very thick},
dot/.style = {circle, fill, minimum size=#1,
inner sep=0pt, outer sep=0pt},
dot/.default = 6pt,>=latex]
%standard tikz coordinate definition using x, y, z coords
\coordinate (E) at (3,0,0);
\coordinate (D) at (3,0,1);
\coordinate (A) at (0,0,1);
\coordinate (B) at (0,3,1);
\coordinate (G) at (0,3,0);
\coordinate (F) at (3,3,0);
\coordinate (C) at (3,3,1);
%draw axes
\draw[axis] (0,0,0) -- (4,0,0) node[anchor=north east]{$x$};
\draw[axis] (0,0,0) -- (0,4,0) node[anchor=north west]{$y$};
\draw[axis] (0,0,0) -- (0,0,2) node[anchor=south]{$z$};
\draw [thick](E)--(D)--(A)--(B)--(G)--(F)--cycle;
\draw (D)--(C)--(B);
\draw (C)--(F);
%draw dots and labels
\foreach \L in {A,B,C,D,E,F,G}{
\node[dot,label=left:$\L$] at (\L) {};}
\node at (C)[right] {$(3,3,1)$};
\end{tikzpicture}
\end{document}