三维表面积分

三维表面积分

我需要一个三维空间中任意函数的曲面积分的示例图。它是哪个函数并不重要。我需要帮助才能开始这项工作。图片不太好,但我想你明白了。我知道一些 tikz 基础知识,也画了一些 3D 矢量,但我不知道如何制作这样的矢量。这是我能做的一切:

\usepackage{tikz}
\usepackage{tikz-3dplot}
\usepackage{pgfplots}
\usetikzlibrary{calc,angles,3d,babel,intersections,pgfplots.fillbetween}

\centering
\begin{tikzpicture}
\coordinate (zero) at (0,0,0);
\coordinate (x) at (0,0,5);
\coordinate (y) at (5,0,0);
\coordinate (z) at (0,5,0);
\coordinate (x1) at (0,0,2);
\coordinate (x2) at (0,0,3);
\coordinate (y1) at (2,0,0);
\coordinate (y2) at (3,0,0);
\coordinate (xx1) at (2,0,2);
\coordinate (xx2) at (2,0,3);
\coordinate (yy2) at (3,0,2);
\coordinate (xy1) at (3,0,3);
\draw[->] (zero) -- (x) node[above]{$x$};
\draw[->] (zero) -- (y) node[above]{$y$};
\draw[->] (zero) -- (z) node[right]{$z$};
\draw[dashed] (x1) -- ++(y1);
\draw[dashed] (x2) -- ++(y2);
\draw[dashed] (y1) -- ++(x1);
\draw[dashed] (y2) -- ++(x2);
\draw (xx1) -- (xx2);
\draw (xx1) -- (yy2);
\draw (xy1) -- (xx2);
\draw (xy1) -- (yy2);
\draw (0,3,0) to [bend left=40] (5,1,0);
\draw (0,3,1) to [bend left=40] (5,1,1);
\draw (0,3,2) to [bend left=40] (5,1,2);
\draw (0,3,3) to [bend left=40] (5,1,3);
\draw (0,3,4) to [bend left=40] (5,1,4);
\draw (0,3,5) to [bend left=40] (5,1,5);
\draw [name path=A] (5,1,0) to [bend right=40] (5,1,5);
\path [name path=B] (5,1,0) -- (5,1,5);
\tikzfillbetween[of=A and B]{white, opacity=1};
\draw[->] (zero) -- (y) node[above]{$y$};
\end{tikzpicture}

答案1

画一些看起来像图画的图形相当简单。但是,我不确定我如何理解这与描述之间的关系。

\documentclass[tikz,border=3mm]{standalone}
\usepackage{tikz-3dplot}
\begin{document}
\tdplotsetmaincoords{70}{110}
\begin{tikzpicture}[tdplot_main_coords,line cap=round,>=stealth]
 \draw[->] (0,0,0) coordinate (O) -- (5,0,0) node[pos=1.05]{$x$};
 \draw[->] (O) -- (0,5,0) node[pos=1.05]{$y$};
 \draw[->] (O) -- (0,0,5) node[pos=1.05]{$z$};
 \begin{scope}[shift={(1,4,0)},declare function={fx(\x,\y)=0.5*\x*cos(\y);%
    fy(\x,\y)=0.5*\x*sin(\y);fz(\x,\y)=0.3*\x;}]
  \draw ({fx(5,270)},{fy(5,270)},0) -- ({fx(5,285)},{fy(5,285)},0)
    -- ({fx(6,285)},{fy(6,285)},0) -- ({fx(6,270)},{fy(6,270)},0) -- cycle;
  \foreach \X in {5,6} {\foreach \Y in {270,285} 
  {\draw[dashed] ({fx(\X,\Y)},{fy(\X,\Y)},0) -- ({fx(\X,\Y)},{fy(\X,\Y)},{fz(\X,\Y)});}}    
  \foreach \X in {5,6} {
   \draw[dashed] ({fx(\X,270)},{fy(\X,270)},0) -- ({-1},{fy(\X,270)},0);}
  \foreach \Y in {270,285}  {
   \draw[dashed] ({fx(6,\Y)},{fy(6,\Y)},0) -- ({fx(6,\Y)},{-4},0);}
  \foreach \X in {1,...,10}
   {\draw plot[variable=\x,domain=240:300,smooth] ({fx(\X,\x)},{fy(\X,\x)},{fz(\X,\x)});
    }
  \foreach \X in {0,...,4} 
  {\draw ({fx(1,240+\X*15)},{fy(1,240+\X*15)},{fz(1,240+\X*15)})
   -- ({fx(10,240+\X*15)},{fy(10,240+\X*15)},{fz(10,240+\X*15)});}
  \draw[blue,thick] plot[variable=\x,domain=270:285] ({fx(5,\x)},{fy(5,\x)},{fz(5,\x)})
        -- plot[variable=\x,domain=285:270] ({fx(6,\x)},{fy(6,\x)},{fz(6,\x)})
        -- cycle;
 \end{scope} 
\end{tikzpicture}
\end{document}

在此处输入图片描述

\documentclass[tikz,border=3mm]{standalone}
\usepackage{tikz-3dplot}
\begin{document}
\tdplotsetmaincoords{70}{110}
\begin{tikzpicture}[tdplot_main_coords,line cap=round,>=stealth,
    declare function={f(\x,\y)=3+0.5*sin(30*\x)*cos(30*\y);}]
 \draw[->] (0,0,0) coordinate (O) -- (5,0,0) node[pos=1.05]{$x$};
 \draw[->] (O) -- (0,5,0) node[pos=1.05]{$y$};
 \draw[->] (O) -- (0,0,5) node[pos=1.05]{$z$};
 \draw (1,2,0) -- (2,2,0)   -- (2,3,0) -- (1,3,0) -- cycle;
 \foreach \X in {1,2} {\foreach \Y in {2,3} 
   {\draw[dashed] (\X,\Y,0) -- (\X,\Y,{f(\X,\Y)});}}    
 \foreach \X in {1,2} {
   \draw[dashed] (\X,2,0) -- (\X,0,0);}
 \foreach \Y in {2,3} {
   \draw[dashed] (1,\Y,0) -- (0,\Y,0);}
 \foreach \X in {0,...,4}
  {\draw plot[variable=\x,domain=0:5,smooth] (\X,\x,{f(\X,\x)});
   }
 \foreach \Y in {0,...,5}
  {\draw plot[variable=\x,domain=0:4,smooth] (\x,\Y,{f(\x,\Y)});
   }
 \draw[blue,thick] plot[variable=\x,domain=1:2]  (\x,2,{f(\x,2)})
    -- plot[variable=\y,domain=2:3]  (2,\y,{f(2,\y)})
    -- plot[variable=\x,domain=2:1]  (\x,3,{f(\x,3)})
    -- plot[variable=\y,domain=3:2]  (1,\y,{f(1,\y)})
    -- cycle;
\end{tikzpicture}
\end{document}

在此处输入图片描述

相关内容