[pstricks] Where the $#@$#@ is the Div operator defined?!

Christoph Bersch usenet at bersch.net
Tue Jan 25 10:21:48 CET 2011


On 24.01.2011 18:17, Jean-Côme Charpentier wrote:
> Le 24/01/2011 15:42, A. Erhardt a écrit :
>> div is divide - don't remember integer divide or real divide.
>>
>> Just try:
>>
>> 9 2 div is either 4 or 4.5
>
>     It depends what you do with this. Without any context, it's 4.5:

You can look that up in the Postscript Language Reference 
<http://www.adobe.com/products/postscript/pdfs/PLRM.pdf>, chapter 8.2:

div num1 num2 div quotient

divides num1 by num2, producing a result that is always a real number 
even if both operands are integers. Use idiv instead if the operands are 
integers and an integer result is desired.

Christoph


More information about the PSTricks mailing list