[pstricks] Using ps code in psplot's limits
Hubert Lam
publishing at hubertlam.fastmail.com.au
Sat Mar 8 00:17:02 CET 2008
Alan Ristow wrote:
> Hubert Lam wrote:
>> Given that the usage of \psplot (excluding options) is
>>
>> \psplot{x_min}{x_max}{PS code for function}
>>
>>
>> is there a mechanism that I'm not aware of that will allow the effects
>> of this:
>>
>> \usepackage{pstricks,pst-math}
>> \def\PiFour{PI 4 div}
>> \psplot{0}{\PiFour}{x SIN}
>
> Yes. I suppose there's more than one way to do it, but the way I would
> do this is (untested):
Thank you gentlemen -- Jurgen's way is correct. That will make life MUCH
easier now! :)
Perhaps for the next example of the pstricks user manual might have more
examples on using PostScript code? I'm happy to contribute especially
with things like
\def\Func{x COS}
\psdot(!4 PI mul 7 div /x 4 PI mul 7 div def \Func)
where the dot is created at (4pi/7, cos(4pi/7)). This I learnt from
looking at one of Herbert Voss' examples on tug.org/pstricks and would
be helpful to teachers/academics who are drawing curves.
More information about the PSTricks
mailing list