Graphics, Figures & TablesTikz curved rectangle

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
Prakhor
Posts: 1
Joined: Wed Jun 02, 2021 11:20 am

Tikz curved rectangle

Post by Prakhor »

I would like to curve a R^2 plane in Tikz so that it looks similar to the file attached. I've searched the internet but found nothing. Do anyone know how I could realize this?
Attachments
photo_2021-06-01_15-37-32.jpg
photo_2021-06-01_15-37-32.jpg (21.31 KiB) Viewed 3621 times

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

coachbennett1981
Posts: 274
Joined: Fri Feb 05, 2010 10:15 pm

Tikz curved rectangle

Post by coachbennett1981 »

Here is a link that can help you with the rectangular prism. Please try to create a MWE
https://tex.stackexchange.com/questions ... dimensions


Here is a link that may help with the curved plane

https://tex.stackexchange.com/questions ... -a-surface
User avatar
Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

Tikz curved rectangle

Post by Stefan Kottwitz »

Hi Prakhor,

welcome to the forum!

That looks like a job for pgfplots. For example, taken from the pgfplots manual and changed a bit:

Code: Select all

\documentclass[border=10pt]{standalone}
\usepackage{pgfplots}
\usepgfplotslibrary{colormaps}
\pgfplotsset{width=7cm,compat=newest,ticks=none}
\begin{document}
\begin{tikzpicture}
\begin{axis}[
%    title={$x \exp(-x^2-y^2)$}, 
%    xlabel=$x$, ylabel=$y$,
	small,
	3d box=complete,
]
\addplot3[
	surf,
	colormap/bone,
	domain=-2:2,
	domain y=-1.3:1.3,
] 
	{exp(-x^2-y^2)*x};
\end{axis}
\end{tikzpicture}
\end{document}
3d-plot.png
Stefan
LaTeX.org admin
Post Reply