[Tex/LaTex] auto-pst-pdf produces a confusing error message

auto-pst-pdfpstricksstandalone

Actually I don't want to use auto-pst-pdf forever. But Harish Kumar (in his comment) requested to use it for the sake of simplicity. I tried it several decades ago and it did not work. The MWE below is the example I tried and failed.

\documentclass[pstricks]{standalone}
\usepackage{pst-plot}
\usepackage{auto-pst-pdf}
\psset
{
    unit=\psrunit,
    polarplot,
    algebraic=true,
    plotpoints=1000,
}

\begin{document}
\multido{\i=1+1}{25}{%
\begin{pspicture}(-3,-3)(3,3)
\pscircle[linestyle=dashed](0,0){2}
\psplot[linecolor=red]{0}{TwoPi}{2+.5*cos(\i*x)}
\end{pspicture}}
\end{document}

Best Answer

the documentclass standalone cannot work together with the auto-pst-pdf package and the [pstricks] option for standalone. Use

\documentclass{standalone}
\usepackage{pst-plot}
\usepackage{auto-pst-pdf}
\psset{%
    polarplot,
    algebraic,
    plotpoints=1000}

\begin{document}
\multido{\i=1+1}{25}{%
  \begin{pspicture}(-3,-3)(3,3)
  \pscircle[linestyle=dashed](0,0){2}
  \psplot[linecolor=red]{0}{TwoPi}{2+.5*cos(\i*x)}
\end{pspicture}}
\end{document}

However, it makes no sense to use standalone and auto-pst-pdf together.

Related Question