Macaulay2 » Documentation
Packages » Macaulay2Doc » rings » basic rings of numbers » QQ
next | previous | forward | backward | up | index | toc

QQ -- the class of all rational numbers

Description

i1 : 1/2 + 3/5

     11
o1 = --
     10

o1 : QQ

Functions and methods returning a rational number:

  • QQ * QQ -- see * -- a binary operator, usually used for multiplication
  • QQ * ZZ -- see * -- a binary operator, usually used for multiplication
  • ZZ * QQ -- see * -- a binary operator, usually used for multiplication
  • + QQ -- see + -- a unary or binary operator, usually used for addition
  • QQ + QQ -- see + -- a unary or binary operator, usually used for addition
  • QQ + ZZ -- see + -- a unary or binary operator, usually used for addition
  • ZZ + QQ -- see + -- a unary or binary operator, usually used for addition
  • - QQ -- see - -- a unary or binary operator, usually used for negation or subtraction
  • QQ - QQ -- see - -- a unary or binary operator, usually used for negation or subtraction
  • QQ - ZZ -- see - -- a unary or binary operator, usually used for negation or subtraction
  • ZZ - QQ -- see - -- a unary or binary operator, usually used for negation or subtraction
  • QQ / QQ -- see / -- a binary operator, usually used for division
  • QQ / ZZ -- see / -- a binary operator, usually used for division
  • ZZ / QQ -- see / -- a binary operator, usually used for division
  • gcd(QQ,QQ) -- see gcd -- greatest common divisor
  • gcd(QQ,ZZ) -- see gcd -- greatest common divisor
  • gcd(ZZ,QQ) -- see gcd -- greatest common divisor
  • random(QQ) -- get a random rational number

Methods that use a rational number:

  • QQ ! -- see ! -- factorial
  • CC % QQ -- see % -- a binary operator, usually used for remainder and reduction
  • QQ % QQ -- see % -- a binary operator, usually used for remainder and reduction
  • QQ % ZZ -- see % -- a binary operator, usually used for remainder and reduction
  • RR % QQ -- see % -- a binary operator, usually used for remainder and reduction
  • CC * QQ -- see * -- a binary operator, usually used for multiplication
  • QQ * CC -- see * -- a binary operator, usually used for multiplication
  • QQ * RR -- see * -- a binary operator, usually used for multiplication
  • QQ * RRi -- see * -- a binary operator, usually used for multiplication
  • RR * QQ -- see * -- a binary operator, usually used for multiplication
  • RRi * QQ -- see * -- a binary operator, usually used for multiplication
  • CC + QQ -- see + -- a unary or binary operator, usually used for addition
  • QQ + CC -- see + -- a unary or binary operator, usually used for addition
  • QQ + RR -- see + -- a unary or binary operator, usually used for addition
  • QQ + RRi -- see + -- a unary or binary operator, usually used for addition
  • RR + QQ -- see + -- a unary or binary operator, usually used for addition
  • RRi + QQ -- see + -- a unary or binary operator, usually used for addition
  • CC - QQ -- see - -- a unary or binary operator, usually used for negation or subtraction
  • QQ - CC -- see - -- a unary or binary operator, usually used for negation or subtraction
  • QQ - RR -- see - -- a unary or binary operator, usually used for negation or subtraction
  • QQ - RRi -- see - -- a unary or binary operator, usually used for negation or subtraction
  • RR - QQ -- see - -- a unary or binary operator, usually used for negation or subtraction
  • RRi - QQ -- see - -- a unary or binary operator, usually used for negation or subtraction
  • CC / QQ -- see / -- a binary operator, usually used for division
  • QQ / CC -- see / -- a binary operator, usually used for division
  • QQ / RR -- see / -- a binary operator, usually used for division
  • QQ / RRi -- see / -- a binary operator, usually used for division
  • RR / QQ -- see / -- a binary operator, usually used for division
  • RRi / QQ -- see / -- a binary operator, usually used for division
  • CC // QQ -- see // -- a binary operator, usually used for quotient
  • QQ // QQ -- see // -- a binary operator, usually used for quotient
  • QQ // ZZ -- see // -- a binary operator, usually used for quotient
  • RR // QQ -- see // -- a binary operator, usually used for quotient
  • abs(QQ) -- see abs -- absolute value function
  • QQ * BettiTally -- see BettiTally -- the class of all Betti tallies
  • factor(QQ) -- see factor(RingElement) -- factor a ring element
  • gcd(QQ) -- see gcd -- greatest common divisor
  • imaginaryPart(QQ) -- see imaginaryPart -- imaginary part
  • interval(QQ) -- see interval -- construct an interval
  • interval(QQ,QQ) -- see interval -- construct an interval
  • interval(QQ,RR) -- see interval -- construct an interval
  • interval(QQ,ZZ) -- see interval -- construct an interval
  • interval(RR,QQ) -- see interval -- construct an interval
  • interval(ZZ,QQ) -- see interval -- construct an interval
  • isMember(QQ,RRi) -- membership test in an interval
  • isReal(QQ) -- see isReal -- whether a number is real
  • lcm(QQ) -- see lcm -- least common multiple
  • lcm(QQ,QQ) -- see lcm -- least common multiple
  • lcm(QQ,ZZ) -- see lcm -- least common multiple
  • lcm(ZZ,QQ) -- see lcm -- least common multiple
  • lift(CC,type of QQ) -- see lift -- lift to another ring
  • lift(Ideal,type of QQ) -- see lift -- lift to another ring
  • lift(Matrix,type of CC_*,type of QQ) -- see lift -- lift to another ring
  • lift(Matrix,type of QQ,type of QQ) -- see lift -- lift to another ring
  • lift(Matrix,type of QQ,type of ZZ) -- see lift -- lift to another ring
  • lift(Matrix,type of RR_*,type of QQ) -- see lift -- lift to another ring
  • lift(Matrix,type of RRi_*,type of QQ) -- see lift -- lift to another ring
  • lift(QQ,type of QQ) -- see lift -- lift to another ring
  • lift(QQ,type of ZZ) -- see lift -- lift to another ring
  • lift(RR,type of QQ) -- see lift -- lift to another ring
  • lift(RRi,type of QQ) -- see lift -- lift to another ring
  • promote(RR,type of QQ) -- see promote -- promote to another ring
  • realPart(QQ) -- see realPart -- real part
  • round(QQ) -- see round -- round a number
  • toCC(QQ) -- see toCC -- convert to high-precision complex number
  • toCC(ZZ,QQ) -- see toCC -- convert to high-precision complex number
  • toCC(ZZ,QQ,QQ) -- see toCC -- convert to high-precision complex number
  • toCC(ZZ,QQ,RR) -- see toCC -- convert to high-precision complex number
  • toCC(ZZ,QQ,ZZ) -- see toCC -- convert to high-precision complex number
  • toCC(ZZ,RR,QQ) -- see toCC -- convert to high-precision complex number
  • toCC(ZZ,ZZ,QQ) -- see toCC -- convert to high-precision complex number

For the programmer

The object QQ is a ring, with ancestor classes Number < Thing.


The source of this document is in Macaulay2Doc/ov_rings.m2:190:0.