[texhax] pstricks and pdflatex

Herbert Voss Herbert.Voss at FU-Berlin.DE
Sat Oct 22 08:59:23 CEST 2011

Am 22.10.2011 02:37, schrieb Alex:

> I am writing because I have a problem with PSTricks that I do not seem to be
> a ble to solve, even after several hours of trying to follow the
> instructions on your web-site. I simply want to learn how to compile using
> PDFLaTeX a file containing PSTricks objects (such as psmatrix). I have tried
> http://tug.org/PSTricks/main.cgi?file=pdf/pdfoutput) that describe how to
> use the package auto-pst-pdf (including enabling write18 appropriately), but
> to no avail. The file compiles without errors, but the psmatrix does not
> appear in the final pdf file.

> %%This is a file that serves as a test of pdflatex with pstricks objects
> \documentclass{amsart}
> %\usepackage{graphicx}
> %\usepackage[pdftex]{graphicx}
> \usepackage{pstricks}
> \usepackage{pst-node}
> \usepackage{auto-pst-pdf}

try
\usepackage[crop=off]{auto-pst-pdf}

I suppose you have no Perl installed the resaon why pdfcrop cannot work.
If it doesn't help, then send the log file.

However, instead of using the package auto-pst-pdf and the postscript
environment you can simply run xelatex, it does all the conversion on
the fly.

Herbert

> %%Shortcut to the \mathbb command
> \newcommand{\mbb}[1]{\ensuremath{\mathbb{#1}}}
>
> \begin{document}
> Hello $\mbb{Z}$.
>
> \begin{postscript}
> $> \begin{psmatrix}[rowsep=0.5cm] > H^{q}\left(N_{X}^{M},_{X}^{M}-X;\mbb{Z}\right) > &H^{q}\left(M,M-X;\mbb{Z}\right)&H^{q}(M;\mbb{Z})\\ > H^{p}\left(N_{Y}^{M},N_{Y}^{M}-Y;\mbb{Z}\right) > &H^{p}\left(M,M-Y;\mbb{Z}\right)&H^{p}(M;\mbb{Z}))\\ > H^{p+q}\left(N_{z}^{M},N_{z}^{M}-\{z\};\mbb{Z}\right) > &H^{p+q}\left(M,M-\{z\};\mbb{Z}\right)&H^{p+q}(M;\mbb{Z}) > \end{psmatrix} > \everypsbox{\scriptstyle} > \psset{doubleline=false,linewidth=0.45pt,nodesep=3pt, arrows=->} > \ncline{1,1}{1,2} > \ncline{1,2}{1,3} > \ncline{2,1}{2,2} > \ncline{2,2}{2,3} > \ncline{3,1}{3,2} > \ncline{3,2}{3,3} >$
> \end{postscript}
> \end{document}