[top][index]
search for:

random Ring -- random element of a ring

Synopsis:

  • Usage: r = random R
  • Function: random -- get a random element
  • Input:
  • R, an instance of class Ring.
  • Output:
  • r, an instance of class RingElement: a random element of the ring R
  • Note: not implemented yet for RR, CC, and polynomial rings.

    Code:

         -- ../m2/enginering.m2:681-684
         random Ring := RingElement => (R) -> (
              if R.?random then R.random()
              else error "no method found for item of class Ring"
              )

    [top][index]
    search for: