# // -- a binary operator, usually used for quotient

• Usage:
x // y

## Description

For ring elements in the integers, polynomial rings, and other rings, there are two types of division: exact division, whose result is often in a larger field, such as the rationals or a function field, and division with remainder, whose result is in the same ring. In Macaulay2, '/' denotes the first kind of division, while '//' denotes the latter kind. The following example shows the difference between // and /.
 i1 : 4/2 o1 = 2 o1 : QQ i2 : 4//2 o2 = 2
 i3 : R = QQ[x]; i4 : (x^2-3)//(x-1) o4 = x + 1 o4 : R i5 : (x^2-3)%(x-1) o5 = -2 o5 : R i6 : (x^2-3)/(x-1) 2 x - 3 o6 = ------ x - 1 o6 : frac R

• / -- a binary operator, usually used for division
• % -- a binary operator, usually used for remainder and reduction

## Ways to use symbol // :

• "CC // CC"
• "CC // QQ"
• "CC // RR"
• "CC // ZZ"
• "InfiniteNumber // QQ"
• "InfiniteNumber // RR"
• "InfiniteNumber // ZZ"
• "Matrix // Number"
• "Number // InfiniteNumber"
• "Number // Matrix"
• "Number // RingElement"
• "QQ // QQ"
• "QQ // ZZ"
• "RingElement // Number"
• "RR // QQ"
• "RR // RR"
• "RR // ZZ"
• "ZZ // MonomialIdeal"
• "ZZ // ZZ"
• Constant // InfiniteNumber (missing documentation)
• InexactNumber // RingElement (missing documentation)
• InfiniteNumber // CC (missing documentation)
• InfiniteNumber // Constant (missing documentation)
• InfiniteNumber // InfiniteNumber (missing documentation)
• List // Number (missing documentation)
• List // RingElement (missing documentation)
• "Matrix // GroebnerBasis" -- see Matrix // Matrix -- factor a map through another
• Matrix // Matrix -- factor a map through another
• "Matrix // MonomialIdeal" -- see Matrix // Matrix -- factor a map through another
• "Matrix // RingElement" -- see Matrix // Matrix -- factor a map through another
• "RingElement // GroebnerBasis" -- see Matrix // Matrix -- factor a map through another
• "RingElement // Matrix" -- see Matrix // Matrix -- factor a map through another
• "RingElement // MonomialIdeal" -- see Matrix // Matrix -- factor a map through another
• "RingElement // RingElement" -- see Matrix // Matrix -- factor a map through another
• RingElement // InexactNumber (missing documentation)
• "Thing // Command" -- see Thing // Function -- apply a function
• Thing // Function -- apply a function
• "Thing // SelfInitializingType" -- see Thing // Function -- apply a function

## For the programmer

The object // is .

This operator may be used as a binary operator in an expression like x//y. The user may install binary methods for handling such expressions with code such as

         X // Y := (x,y) -> ...

where X is the class of x and Y is the class of y.