[pstricks] Centering psPrintValues

Herbert Voss LaTeX at zedat.fu-berlin.de
Fri Jun 16 09:21:30 CEST 2006

Poul Riis wrote:
> How can I make the numbers accurately centered in the circles in the
> example below?

not possible with printValue, it works only on PostScript
side. Calculate the Fibinacci numbers on the TeX side.

-- load pstricks _always_ as last package
-- use package geometry for page margins
-- don't put a % at the end of PostScript lines! It causes
    an error, when the next line begins not with a slash or {



% \fib{k} returns the k-te Fibonaccinumber F_k
\newcommand*\step{\add \rotate}


   /phigylden 137.5078 def
   /storephi 5 sqrt 1 add 2 div def
   /antalfroe 25 def
   /radius 8 def
   /kk antalfroe radius div radius div def
   /xfroe {kk div dup kk mul phigylden mul cos exch sqrt mul} def
   /yfroe {kk div dup kk mul phigylden mul sin exch sqrt mul neg} def
   /fib {dup dup 1 eq exch 0 eq or not {dup 1 sub fib exch 2 sub fib 
add} if} def%
   /b 12 def}%
\definecolor[ps]{bl}{rgb}{tx at addDict begin Red Green Blue end}
   \pstVerb{/lambda #1 def lambda tx at addDict begin wavelengthToRGB end}}%


     linewidth=5pt,plotpoints=100]{0}{11}{t xfroe t yfroe}
   \rainbowcolor{\iA\space 10 mul 590 add}%
   \Cnode*[radius=20pt,linecolor=bl](!\iA\space xfroe \iA\space 


More information about the PSTricks mailing list