I want to fill the space between four lines (quadrilateral) using gray color using tikz. How can I do it.
I also want to tag the origin point as 's'
\documentclass[12pt]{beamer}
\usepackage[T1]{fontenc}
\usetheme{metropolis}
\mode<handout>{
\usepackage{pgfpages}
\pgfpagesuselayout{2 on 1}[a4paper,border shrink=5mm]
}
\usepackage{tikz}
\usetikzlibrary{calc}
\makeatother
\begin{document}
\begin{frame}{Introduction}
\begin{block}{Pareto Optimal Solutions}
\begin{center}
\begin{tikzpicture}
\coordinate (Origin) at (0,0);
\draw[thick,->] (0,0) -- (6,0);
\draw[thick,->] (0,0) -- (0,4.5);
\coordinate (Bone) at (1.7,2.8);
\coordinate (Btwo) at (3.2,1.2);
\coordinate (Bthree) at (4,2.8);
\draw [thick,-] (Origin) -- (Bone) (Bone) -- (Bthree) (Bthree) -- (Btwo) (Btwo) -- (Origin) node {};
\end{tikzpicture}
\end{center}
\end{block}
\end{frame}
\end{document}
Best Answer
Edit: To add the label S in the middle, you can either guess the coordinates, using e.g. something like
or you can compute the position: