How could I achieve that? (TikZ preferably)
I tried with \draw[blue] plot[smooth] coordinates {(0,0) (3.5,4) (5.5,7)};
but It's not super efficient and doesn't exactly produce the result.
Any help?
Thanks
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It only takes a minute to sign up.
Sign up to join this communityHow could I achieve that? (TikZ preferably)
I tried with \draw[blue] plot[smooth] coordinates {(0,0) (3.5,4) (5.5,7)};
but It's not super efficient and doesn't exactly produce the result.
Any help?
Thanks
Use Bézier curves.
\documentclass[tikz,border=3.14mm]{standalone}
\begin{document}
\begin{tikzpicture}[
font=\sffamily\scriptsize,
lbl/.style={
rectangle,
draw,
text width=1.8cm,
align=center,
inner sep=2pt
}
]
\draw[<->] (0,6) |- (6,0) node[pos=0.1,left] {S\textsubscript{p}} node[pos=0.75,below] {\# of processors};
\draw (0,0) -- (5,5) coordinate[pos=0.9] (A);
\draw[red,thick] (0,0) .. controls ++(3,3) and ++(-1,-0.1) .. (5.5,3) coordinate[pos=0.6] (B);
\draw[olive,thick] (0,0) .. controls ++(3,3) and ++(-.2,-1) .. (3.5,5.5) coordinate[pos=0.7] (C);
\draw[<-] (A) --++ (0.75,-0.5) node[lbl,below] {linear speedup};
\draw[<-] (B) --++ (0.5,-1) node[lbl,below] {sub-linear speedup (common)};
\draw[<-] (C) --++ (-1.5,0.5) node[lbl,above] {super-linear speedup (wonderful)};
\end{tikzpicture}
\end{document}