Skip to content
Snippets Groups Projects
Forked from agnumpde / dune-tectonic
178 commits ahead of the upstream repository.
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
3d-performance.tikz 1.75 KiB
\def\fname{rtol=1e-5_diam=1e-2}

\newread\threequakesminread
\openin\threequakesminread=generated/timeframe:min:threequakes:\fname.tex
\read\threequakesminread to \threequakesmin
\closein\threequakesminread

\newread\threequakesmaxread
\openin\threequakesmaxread=generated/timeframe:max:threequakes:\fname.tex
\read\threequakesmaxread to \threequakesmax
\closein\threequakesmaxread

\begin{tikzpicture}[trim axis group left, trim axis group right]
  \begin{groupplot}[
    xmin=\threequakesmin, xmax=\threequakesmax,
    max space between ticks=40pt,
    x tick label style={
      /pgf/number format/.cd,
      1000 sep={},
      /tikz/.cd
    },
    tick label style={font=\footnotesize},
    label style={font=\small},
    group style={
      x descriptions at = edge bottom,
      group size=1 by 3,
      vertical sep=0cm
    },
    height=3.5cm, width=12cm,
    enlargelimits=false]

    \nextgroupplot[
    semithick,
    ylabel style={align=center}, ylabel = time step\\size, y unit = s,
    ytick={1e-3,1e-2,1e-1},
    ymax = 1, ymin = 1e-4,
    ymode = log]
    \addplot[const plot, mark=none] table[col sep=comma, y=timeIncrement]
    {generated/3d-performance:\fname.csv};
    \nextgroupplot[
    semithick,
    ylabel style={align=center}, ylabel = fixed-point\\iterations,
    ytick={2,4,6,8},
    ymin=0, ymax=10]
    \addplot[const plot, mark=none] table[col sep=comma, y=fixedPointIterations]
    {generated/3d-performance:\fname.csv};
    \nextgroupplot[
    semithick,
    xlabel = time, x unit = s,
    ylabel style={align=center}, ylabel=multigrid\\iterations,
    ytick={5,10,15,20},
    ymin=0, ymax=25
    ]
    \addplot[const plot, mark=none] table[col sep=comma, y=multiGridIterations]
    {generated/3d-performance:\fname.csv};
  \end{groupplot}
\end{tikzpicture}