PSTricks is a set of macros that allow the inclusion of PostScript code (e.g. drawings) directly inside (La)TeX code. This tag is compatible with the tag {diagrams}.

learn more… | top users | synonyms

9
votes
1answer
78 views

Confusing behavior of uput with non-zero dimensional object

I really don't understand the behavior of \uput with non-zero dimensional object as illustrated below. \documentclass[pstricks,border=12pt]{standalone} \usepackage{multido} ...
5
votes
1answer
226 views

PSTricks: Partitioning and filling a circle in pst-pdgr

I am using the pst-pdgr package which uses PSTricks to generate medical pedigrees. I find this package to be very useful, however I ran into a problem with a certain situation I am having. I need a ...
3
votes
2answers
150 views

Definition of constant in PSTricks

Consider the following example, which produces the same figure as here, but the code is generalized. Code % pdflatex -shell-escape test.tex \documentclass{article} ...
4
votes
1answer
185 views

pst-map2d - unrecoverable error

I am using this piece of code \documentclass{article} \usepackage{pst-map2d} \begin{document} {\psset{xunit=0.5, yunit =0.5} \begin{pspicture}*(-9,-9)(10 ,9) \WorldMap[maillage = false] ...
2
votes
1answer
167 views

Improvement of PSTricks code for drawing of Pantheon

Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{ auto-pst-pdf, pst-eucl, pstricks-add } \usepackage[ locale=DE ]{siunitx} ...
2
votes
0answers
50 views

How to throw an error and abort the compilation for the following scenario? [duplicate]

Objectives: I want to throw exceptions (or error messages) when the following illegal code is invoked. \const[c,any]{temp}{\f[\i]} \const[others]{temp}{\f[\i]} Minimal Working Example: I cannot ...
7
votes
2answers
211 views

How to parse optional arguments without keyval?

The current implementation only supports rounding with the specified digits in the optional arguments. \documentclass{beamer} \usepackage{multido} \usepackage{pstricks} \usepackage[nomessages]{fp} % ...
1
vote
1answer
147 views

What causes this error? [closed]

After seeing Herbert's answer, apparently this problem should not occur if I realized the first row of the following code should be \documentclass{beamer}. Problems often come from not knowing what I ...
4
votes
1answer
125 views

How to implement a constant declarating macro to behave differently in preamble and pspicture?

The example below is extremely trivial just to illustrate the problem in the simplest way. \documentclass{beamer} \usepackage[nomessages]{fp} % constants declarator \def\LoadConstants{}% to load ...
3
votes
1answer
141 views

Definition of PSTricks constant and improvement of code for drawing of Pantheon

Consider the following. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{ auto-pst-pdf, pst-eucl, pstricks-add } \usepackage{siunitx} \begin{document} ...
3
votes
1answer
699 views

Equivalent of QTikZ for PSTricks

I have recently seen the very useful QTikZ program for interactive viewing of TikZ diagrams. I was wondering if a similar program exists for drawing PSTricks diagrams.
2
votes
2answers
266 views

Definition of PSTricks constant (again) and improvement of code

Consider the following example. (This is either the last one or the second to last.) Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{auto-pst-pdf,pstricks-add} ...
4
votes
2answers
228 views

Definition of PSTricks constant

Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{auto-pst-pdf,pstricks-add} \usepackage[locale=DE]{siunitx} ...
7
votes
3answers
381 views

Improve PSTricks code for drawing of the Olympic flag

Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{auto-pst-pdf,pstricks-add} \usepackage[locale=DE]{siunitx} \ExplSyntaxOn \cs_new_eq:NN ...
6
votes
1answer
378 views

Create a Frequency Allocation Diagram

I need to reproduce a frequency allocation diagram in TeX. I prefer TikZ but open to PSTricks. I can create a simple bar allocation char using \node but unsure how to create layered blocks like the ...
5
votes
2answers
129 views

Is it possible to construct more than one stroke with different colors inside a single \pscustom?

Is it possible to get the following output where the upper graph is red and the lower one is blue \documentclass[pstricks,border=17pt]{standalone} \usepackage{pst-plot} ...
9
votes
3answers
494 views

Improve PSTricks code for drawing of a general, regular polygon

Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{auto-pst-pdf,pst-eucl,pst-poly,pstricks-add} \usepackage[locale=DE]{siunitx} ...
42
votes
1answer
570 views

Given a PS interpreter, can pstricks be converted to pgf?

When producing pdf directly, PostScript code cannot be used, which means that pstricks macros do not work. Now, it is still possible to include pstricks code using external tools (running LaTeX on ...
6
votes
2answers
342 views

Improve PSTricks code for drawing of a football pitch

Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{auto-pst-pdf,pstricks-add} \usepackage{siunitx} \begin{document} % Paremeters ...
12
votes
4answers
416 views

Improve PSTricks code for drawing of a chest of drawers

Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{auto-pst-pdf,pstricks-add} \begin{document} \psset{unit=0.08cm} ...
6
votes
2answers
288 views

How to make the following recursive macro work?

For positive values less than 3 the following MWE works. \documentclass[pstricks,border=12pt]{standalone} \SpecialCoor \psset{showpoints=true} \def\Triangle#1{% \ifnum#1=1\relax ...
13
votes
3answers
217 views

Is it possible to get a coil with stable number of winding?

I want to create an animation with a spring. The winding must be kept constant to make more realistic animation. The following MWE illustrates the current situation of \pszigzag where it cannot ...
3
votes
2answers
1k views

Similar to Excel's line charts?

How could I create charts as the follow ones, which were produced by Microsoft Excel?
6
votes
2answers
196 views

Optimize (or improve, at least) PSTricks code for drawing a beehive

Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} \usepackage{ auto-pst-pdf, pst-eucl } \usepackage{siunitx} \begin{document} \begin{figure} ...
11
votes
4answers
404 views

How to improve my PSTricks code to construct a triangle diagram?

This question is similar to How to improve my PSTricks code to construct a triangle number diagram?. Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} ...
7
votes
2answers
228 views

How to improve my PSTricks code to construct a triangle number diagram?

This question is similar to How to improve my PSTricks code to construct a triangle diagram?. Consider the following example. Code % pdflatex -shell-escape test.tex \documentclass{article} ...
8
votes
1answer
100 views

How to use each of the following operators defined in pst-tools?

I cannot find any documentation explaining how to use each of the following operators defined in pst-tools. Could you give practical examples (such as simplifying vector addition \pnode(2,2){A} ...
23
votes
2answers
4k views

How can I make a standard timeline?

I am looking to make a standard timeline, nothing fancy, like the one below (although, it does not have to be like that) using any library. How can I go about the achieving this in the best way?
1
vote
1answer
244 views

Footer scaling with scalebox

I use a pspicture to draw a electric diagram in one of my slides with beamer, and I've got a pause-command within the pspicture (to make thing appear). I use \scalebox to make my picture enter the ...
7
votes
1answer
177 views

How to increase the accuracy of \psTangentLine?

I want to draw the tangent line as well as the normal line for an arbitrary curve as follows. \documentclass[pstricks,border=12pt]{standalone} \usepackage{pstricks-add} \begin{document} ...
7
votes
2answers
2k views

PSTricks and LaTeX vs. pdfLaTeX

I'm trying to convert my thesis to pdfLaTeX, as latex + dvips behaves ugly when it comes to break (really long) URLs... I'm using up-to-date TeXLive 2012 on Linux. The only problem is (so far), that ...
5
votes
4answers
105 views

How to use getnodelist?

Taken from pst-node's documentation on page 39: This very short description about \getnodelist does not help me (maybe others as well) understand how to use it. Could you give me an example how to ...
4
votes
2answers
125 views

How to embed verbatim in pspicture?

I'm trying to insert a QR code at the beginning of my thesis with the contents being the BibTeX entry for it. Any way of embedding the raw text in \psbarcode? \documentclass[a4paper,12pt]{minimal} ...
3
votes
3answers
234 views

circuit macros latex, error noCurrentPoint [closed]

Following the manual of Circuit macros for LaTeX, just at the beginning I try to make the first circuit picture in LaTeX "quick.m4" processing that first with m4, then dpic, and adding the code ...
8
votes
4answers
675 views

How to draw a closed smooth curve from a list of nodes?

Karl is a list of randomly generated nodes by \curvepnodes using parametric points in RPN (I don't know how to use rand in algebraic expression). The number of elements of the list is \Karlnodecount ...
9
votes
1answer
252 views

What makes my line get shifted to the left when I invoke \LoadConstants?

In the beginning I use the following code. So far so good. \documentclass[pstricks,border=12pt]{standalone} \usepackage{multido} \usepackage[nomessages]{fp} \def\LoadConstants{} ...
7
votes
3answers
479 views

What is the TikZ equivalent for the following PSTricks code? Drawing a free fall diagram

I want to learn TikZ using "learn by example" approach because this way helps me to save time by skipping unnecessary concepts. I have made an example, it is a free fall diagram in PSTricks as ...
3
votes
1answer
47 views

How to create a new converting operator?

The following trivial example illustrates my objective to create a converting operator ptcm (pt to cm). Unfortunately, it produces errors in TeX world as opposed to PS world. \documentclass{beamer} ...
9
votes
2answers
237 views

What makes clipping with starred graphics object and its dual produce different result?

Based on the following taken from pstricks.tex, \def\solid@star{% \if@star \pslinewidth=\z@ \psdoublelinefalse \def\pslinestyle{none}% \def\psk@fillstyle{\psfs@solid}% ...
2
votes
0answers
87 views

Negative bar values using psbarchart [closed]

I'm plotting a barchart using pst-bar and \psaxes[axesstyle=frame,Ox=0,Oy=-1,Dx=1,labels=y,ticks=y](0,-1)(17,5) \psbarchart[barstyle={red,blue,green},chartstyle=stack]{\data} I have some negative ...
3
votes
2answers
133 views

What makes showgrid=true or showgrid=top displace my clip to the right?

The following code is trivial but important to show the problem. When I activate the showgrid with true or top option, my graphics object gets shifted to right as shown in the following animation. ...
6
votes
2answers
283 views

Clipping with PSTricks

Consider the following example. Code \documentclass{article} \usepackage{pstricks-add} \begin{document} \begin{figure} \psset{unit=0.05} \begin{pspicture}(120,216) ...
7
votes
1answer
324 views

Plot graph with axis discontinuities in PSTricks

Consider the following. Code \documentclass{article} \usepackage{pst-coil,pstricks-add} \begin{document} \psset{xunit=0.8,yunit=0.6} \begin{pspicture}(13,14) \pszigzag[coilheight=0.3](0,0)(2,0) ...
6
votes
2answers
247 views

Code improvement for PSTricks figure

Consider the following example. Code \documentclass{article} \usepackage{pstricks-add} \begin{document} \def\laengde{60 } \psset{unit=0.04} \begin{pspicture}(260,260) \pnode(0,0){P1} \pnode(!0 ...
5
votes
1answer
961 views

Use TeX Gyre fonts with latex+dvips+ps2pdf

I want to use the TeX Gyre fonts (especially the Pagella and Pagella Math) with LaTeX+dvips+ps2pdf. In the future I want to use this for PSTricks but first I've to solve my font problems. I use this ...
4
votes
1answer
271 views

Make lines disappear, pst-solides3D [duplicate]

I'm drawing the following cylinder which represents a water flowing and cooling down \documentclass[a4paper,10pt]{article} \usepackage{pstricks} \usepackage{auto-pst-pdf} \usepackage{pst-solides3d} ...
6
votes
2answers
537 views

Rindler coordinate chart (family of parametric curves) in TikZ

Is it possible to make a plot like this with TikZ or other drawing packages? This plot visualizes a two parameter family of curves, given by T = x Sinh(t) X = x Cosh(t) The pink curves are ...
2
votes
1answer
74 views

How to prevent preview from discarding my PostScript constants defined in the preamble?

Considerations: I have to use beamer document class to create a step-by-step tutorial. I have to use preview package to trim everything outside pspicture. Using standalone document class is not ...
10
votes
1answer
194 views

Shape driven formatting

I'm not exactly sure how to call it, so I've had a hard time search for it online. What I have is a solid block of text. What I want is to change the formatting of part of this block of text (make it ...
6
votes
1answer
434 views

3D figure with pst-3Dplot

I'm trying to plot a simple math function in 3D using the package pst-3dplot. The function is z = 1/(1+a*exp(-b*y)) * (c * (1 - exp(d*x)) * (1 - exp(e*(x-f)))). I tried the following: ...