Skip to content

Instantly share code, notes, and snippets.

@morris821028
Last active December 14, 2016 03:02
Show Gist options
  • Save morris821028/75db384dd3bb5f7265587d4609e92a37 to your computer and use it in GitHub Desktop.
Save morris821028/75db384dd3bb5f7265587d4609e92a37 to your computer and use it in GitHub Desktop.
Paper pgfplot example
\begin{tikzpicture}[scale=0.4,font=\sffamily]
\begin{axis}[
xlabel={Processor $p$},
ylabel={Time (second)},
xmin=1, xmax=16,
ymin=0, ymax=1.2,
scaled ticks = false,
tick label style={/pgf/number format/fixed},
xtick={1, 2, 4, 8, 16},
ytick={0, 0.2, 0.4, 0.6, 0.8, 1, 1.2},
legend pos=north east,
legend cell align=left,
ymajorgrids=true,
grid style=dashed,
,height=10cm,width=15cm,
]
\addplot [mark=square*, mark options={fill=white}] file{figure/parallel-p.dat};
\legend{parallel $n=5000$}
\end{axis}
\end{tikzpicture}
\usepackage{tikz}
\usetikzlibrary{calc}
\usetikzlibrary{positioning}
\usetikzlibrary{shapes,arrows}
\usetikzlibrary{plotmarks}
\usepackage{subfigure}
% Use pfgplots to generate plots and labeled axes
\usepackage{pgfplots}
1 0.928
2 0.508
4 0.303
8 0.240
16 0.218
\subsection{Parallel VGLCS}
\begin{frame}
\frametitle{Runtime}
\begin{figure}[!ht]
\centering
\subfigure[Runtime]{
\input{./figure/fig-parallel-n}
\label{fig:fig-parallel}
}
%\subfigure[Little core cluster]{
% \input{./data/light_little}
% \label{fig:light_little}
%}
\caption{Serial and Parallel Algorithm run on E5-2620}
\end{figure}
\end{frame}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment