Exemplo n.º 1
0
def OM2ring(ring_desc, ordering="dp"):
    assert isinstance(ring_desc, OMA)
    if (ring_desc.args[0] == Rationals):
        i = ring_desc.args[1]
        return create_ring(char=0, nvars=i, ordering=ordering)

    raise SingularException("ring not supported")
Exemplo n.º 2
0
def OM2ring(ring_desc, ordering="dp"):
  assert isinstance(ring_desc, OMA)
  if (ring_desc.args[0]==Rationals):
    i=ring_desc.args[1]
    return create_ring(char=0, nvars=i, ordering=ordering)
 
  raise SingularException("ring not supported")
Exemplo n.º 3
0
def ringFromOM(ring_desc, ordering="dp"):
    assert isinstance(ring_desc, OMApply)
    if (ring_desc.args[0] == Rationals):
        i = ring_desc.args[1].getValue()
        return create_ring(char=0, nvars=i, ordering=ordering)
    raise SingularException("ring not supported")
Exemplo n.º 4
0
def ringFromOM(ring_desc, ordering="dp"):
  assert isinstance(ring_desc, OMApply)
  if (ring_desc.args[0]==Rationals):
    i=ring_desc.args[1].getValue()
    return create_ring(char=0, nvars=i, ordering=ordering)
  raise SingularException("ring not supported")