[top][index]
search for:

divideByVariable -- divide all columns by a (power of a) variable

divideByVariable(m,v) -- divide each column of the matrix 'm' by as high a power of the variable 'v' as possible.
divideByVariable(m,v,d) -- divide each column of the matrix 'm' by as high a power of the variable 'v' as possible, but divide by no more than v^d.

i1 : R = ZZ/101[a..d]

o1 = R

o1 : PolynomialRing
i2 : m = matrix{{a*b, a^2*c}, {a*b^2, a^4*d}}

o2 = | ab  a2c |
     | ab2 a4d |

             2       2
o2 : Matrix R  <--- R
i3 : divideByVariable(m,a)

o3 = | b  c   |
     | b2 a2d |

             2       2
o3 : Matrix R  <--- R
i4 : divideByVariable(m,a,1)

o4 = | b  ac  |
     | b2 a3d |

             2       2
o4 : Matrix R  <--- R

Caveat:

  • You can only divide by a variable, not a monomial, and you have little control on what power will be divided. This routine is mostly used by the saturation commands as a fast internal way of dividing.
  • We may eliminate this routine.

    Ways to use divideByVariable :

  • divideByVariable(Matrix,RingElement)
  • divideByVariable(Matrix,RingElement,ZZ)

  • [top][index]
    search for: