paraboloid

Edit and compile if you like:

\documentclass{article}
%
% File name: classic-paraboloid.tex
% Description: 
% The graph of the surface
% z = x^{2} + y^{2}
% is generated. Also, the region x^2 + y^2 \leq 1
% is shown.
% 
% Date of creation: April, 23rd, 2022.
% Date of last modification: April, 23rd, 2022.
% Author: Efraín Soto Apolinar.
% https://www.aprendematematicas.org.mx/author/efrain-soto-apolinar/instructing-courses/
% Terms of use:
% According to TikZ.net
% https://creativecommons.org/licenses/by-nc-sa/4.0/
% 
\usepackage{tikz}
\usetikzlibrary{patterns}
\usepackage{tikz-3dplot}
\usepackage[active,tightpage]{preview}
\PreviewEnvironment{tikzpicture}
\setlength\PreviewBorder{1pt}
%
\begin{document}
	%
	\tdplotsetmaincoords{60}{110}
	\begin{tikzpicture}[tdplot_main_coords,scale=2.0]
		\pgfmathsetmacro{\tini}{0.5*pi}
		\pgfmathsetmacro{\tfin}{1.85*pi}
		\pgfmathsetmacro{\tend}{2.5*pi}
		% Node indicating the equation of the circumference
		\draw[white] (1.35,0,0) -- (0,1.35,0) node [red,below,midway,sloped] {$x^2 + y^2 = 1$};
		%%% Coordinate axis
		\draw[thick,->] (0,0,0) -- (1.5,0,0) node [below left] {\footnotesize$x$};
		\draw[dashed] (0,0,0) -- (-1.25,0,0);
		\draw[thick,->] (0,0,0) -- (0,1.5,0) node [right] {\footnotesize$y$};
		\draw[dashed] (0,0,0) -- (0,-1.25,0);
		% The region of integration
		\fill[yellow,opacity=0.35] plot[domain=0:6.2832,smooth,variable=\t] ({cos(\t r)},{sin(\t r)},{0.0});
		\draw[red,thick] plot[domain=0:6.2832,smooth,variable=\t] ({cos(\t r)},{sin(\t r)},{0.0});
		% The curves slicing the surface
		\draw[blue,thick,opacity=0.5] plot[domain=-1:1,smooth,variable=\t] ({\t},0,{\t*\t}); 
		\draw[blue,thick,opacity=0.5] plot[domain=-1:1,smooth,variable=\t] (0,{\t},{\t*\t}); 
		% El paraboloid (for z = constant)
		\foreach \altura in {0.0125,0.025,...,1.0}{
			\pgfmathparse{sqrt(\altura)}
			\pgfmathsetmacro{\radio}{\pgfmathresult}
			\draw[cyan,thick,opacity=0.5] plot[domain=\tini:\tfin,smooth,variable=\t] ({\radio*cos(\t r)},{\radio*sin(\t r)},{\altura}); 
		}
		% Circunference bounding the surface (above, first part)
		\draw[blue,thick,opacity=0.75] plot[domain=pi:1.75*pi,smooth,variable=\t] ({cos(\t r)},{sin(\t r)},{1.0}); 
		% last part of the z axis
		\draw[thick,->] (0,0,0) -- (0,0,1.75) node [above] {\footnotesize$z$};	
		\foreach \altura in {0.0125,0.025,...,1.0}{
			\pgfmathparse{sqrt(\altura)}
			\pgfmathsetmacro{\radio}{\pgfmathresult}
			\draw[cyan,thick,opacity=0.5] plot[domain=\tfin:\tend,smooth,variable=\t] ({\radio*cos(\t r)},{\radio*sin(\t r)},{\altura}); 
		}
		% Circunference bounding the surface (above, last part)
		\draw[blue,thick,opacity=0.75] plot[domain=-0.25*pi:pi,smooth,variable=\t] ({cos(\t r)},{sin(\t r)},{1.0}); 
		\node[blue,above right] at (-1,0.5,0.75) {$z = x^2 + y^2$};
	\end{tikzpicture}
\end{document}


Click to download: paraboloid.texparaboloid.pdf
Open in Overleaf:
paraboloid.tex
See more on the author page of Efraín Soto Apolinar.

Leave a Reply

Your email address will not be published.