next | previous | forward | backward | up | top | index | toc | Macaulay2 website
Divisor :: Number * BasicDivisor

Number * BasicDivisor -- multiply a divisor by a number

Synopsis

Description

Multiply a divisor by an integer or a real or rational number.

i1 : R = QQ[x,y];
i2 : D = divisor(x^2*y/(x+y));

o2 : WeilDivisor on R
i3 : E = divisor({1/2, -5/3}, {ideal(x), ideal(y)}, CoefficientType=>QQ)

o3 = 1/2*Div(x) + -5/3*Div(y)

o3 : QWeilDivisor on R
i4 : F = divisor({1.5, 0, -3.2}, {ideal(x), ideal(y), ideal(x^2-y^3)}, CoefficientType=>RR)

o4 = -3.2*Div(-y^3+x^2) + 1.5*Div(x) + 0*Div(y)

o4 : RWeilDivisor on R
i5 : 8*D

o5 = -8*Div(x+y) + 16*Div(x) + 8*Div(y)

o5 : WeilDivisor on R
i6 : (-2/3)*D

o6 = 2/3*Div(x+y) + -4/3*Div(x) + -2/3*Div(y)

o6 : QWeilDivisor on R
i7 : 0.0*D

o7 = 0, the zero divisor

o7 : RWeilDivisor on R
i8 : (3/2)*E

o8 = 3/4*Div(x) + -5/2*Div(y)

o8 : QWeilDivisor on R
i9 : (-1.414)*E

o9 = 2.35667*Div(y) + -.707*Div(x)

o9 : RWeilDivisor on R
i10 : 6*F

o10 = -19.2*Div(-y^3+x^2) + 9*Div(x)

o10 : RWeilDivisor on R
i11 : (-3/2)*F

o11 = 4.8*Div(-y^3+x^2) + -2.25*Div(x)

o11 : RWeilDivisor on R