本文整理汇总了Python中sympy.polys.domains.ZZ.unify方法的典型用法代码示例。如果您正苦于以下问题:Python ZZ.unify方法的具体用法?Python ZZ.unify怎么用?Python ZZ.unify使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sympy.polys.domains.ZZ
的用法示例。
在下文中一共展示了ZZ.unify方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_Domain__unify
# 需要导入模块: from sympy.polys.domains import ZZ [as 别名]
# 或者: from sympy.polys.domains.ZZ import unify [as 别名]
def test_Domain__unify():
assert ZZ.unify(ZZ) == ZZ
assert QQ.unify(QQ) == QQ
assert ZZ.unify(QQ) == QQ
assert QQ.unify(ZZ) == QQ
assert EX.unify(EX) == EX
assert ZZ.unify(EX) == EX
assert QQ.unify(EX) == EX
assert EX.unify(ZZ) == EX
assert EX.unify(QQ) == EX
assert ZZ.poly_ring(x).unify(EX) == EX
assert ZZ.frac_field(x).unify(EX) == EX
assert EX.unify(ZZ.poly_ring(x)) == EX
assert EX.unify(ZZ.frac_field(x)) == EX
assert ZZ.poly_ring(x, y).unify(EX) == EX
assert ZZ.frac_field(x, y).unify(EX) == EX
assert EX.unify(ZZ.poly_ring(x, y)) == EX
assert EX.unify(ZZ.frac_field(x, y)) == EX
assert QQ.poly_ring(x).unify(EX) == EX
assert QQ.frac_field(x).unify(EX) == EX
assert EX.unify(QQ.poly_ring(x)) == EX
assert EX.unify(QQ.frac_field(x)) == EX
assert QQ.poly_ring(x, y).unify(EX) == EX
assert QQ.frac_field(x, y).unify(EX) == EX
assert EX.unify(QQ.poly_ring(x, y)) == EX
assert EX.unify(QQ.frac_field(x, y)) == EX
assert ZZ.poly_ring(x).unify(ZZ) == ZZ.poly_ring(x)
assert ZZ.poly_ring(x).unify(QQ) == QQ.poly_ring(x)
assert QQ.poly_ring(x).unify(ZZ) == QQ.poly_ring(x)
assert QQ.poly_ring(x).unify(QQ) == QQ.poly_ring(x)
assert ZZ.unify(ZZ.poly_ring(x)) == ZZ.poly_ring(x)
assert QQ.unify(ZZ.poly_ring(x)) == QQ.poly_ring(x)
assert ZZ.unify(QQ.poly_ring(x)) == QQ.poly_ring(x)
assert QQ.unify(QQ.poly_ring(x)) == QQ.poly_ring(x)
assert ZZ.poly_ring(x, y).unify(ZZ) == ZZ.poly_ring(x, y)
assert ZZ.poly_ring(x, y).unify(QQ) == QQ.poly_ring(x, y)
assert QQ.poly_ring(x, y).unify(ZZ) == QQ.poly_ring(x, y)
assert QQ.poly_ring(x, y).unify(QQ) == QQ.poly_ring(x, y)
assert ZZ.unify(ZZ.poly_ring(x, y)) == ZZ.poly_ring(x, y)
assert QQ.unify(ZZ.poly_ring(x, y)) == QQ.poly_ring(x, y)
assert ZZ.unify(QQ.poly_ring(x, y)) == QQ.poly_ring(x, y)
assert QQ.unify(QQ.poly_ring(x, y)) == QQ.poly_ring(x, y)
assert ZZ.frac_field(x).unify(ZZ) == ZZ.frac_field(x)
assert ZZ.frac_field(x).unify(QQ) == EX # QQ.frac_field(x)
assert QQ.frac_field(x).unify(ZZ) == EX # QQ.frac_field(x)
assert QQ.frac_field(x).unify(QQ) == QQ.frac_field(x)
assert ZZ.unify(ZZ.frac_field(x)) == ZZ.frac_field(x)
assert QQ.unify(ZZ.frac_field(x)) == EX # QQ.frac_field(x)
assert ZZ.unify(QQ.frac_field(x)) == EX # QQ.frac_field(x)
assert QQ.unify(QQ.frac_field(x)) == QQ.frac_field(x)
assert ZZ.frac_field(x, y).unify(ZZ) == ZZ.frac_field(x, y)
assert ZZ.frac_field(x, y).unify(QQ) == EX # QQ.frac_field(x,y)
assert QQ.frac_field(x, y).unify(ZZ) == EX # QQ.frac_field(x,y)
assert QQ.frac_field(x, y).unify(QQ) == QQ.frac_field(x, y)
assert ZZ.unify(ZZ.frac_field(x, y)) == ZZ.frac_field(x, y)
assert QQ.unify(ZZ.frac_field(x, y)) == EX # QQ.frac_field(x,y)
assert ZZ.unify(QQ.frac_field(x, y)) == EX # QQ.frac_field(x,y)
assert QQ.unify(QQ.frac_field(x, y)) == QQ.frac_field(x, y)
assert ZZ.poly_ring(x).unify(ZZ.poly_ring(x)) == ZZ.poly_ring(x)
assert ZZ.poly_ring(x).unify(QQ.poly_ring(x)) == QQ.poly_ring(x)
assert QQ.poly_ring(x).unify(ZZ.poly_ring(x)) == QQ.poly_ring(x)
assert QQ.poly_ring(x).unify(QQ.poly_ring(x)) == QQ.poly_ring(x)
assert ZZ.poly_ring(x, y).unify(ZZ.poly_ring(x)) == ZZ.poly_ring(x, y)
assert ZZ.poly_ring(x, y).unify(QQ.poly_ring(x)) == QQ.poly_ring(x, y)
assert QQ.poly_ring(x, y).unify(ZZ.poly_ring(x)) == QQ.poly_ring(x, y)
assert QQ.poly_ring(x, y).unify(QQ.poly_ring(x)) == QQ.poly_ring(x, y)
assert ZZ.poly_ring(x).unify(ZZ.poly_ring(x, y)) == ZZ.poly_ring(x, y)
assert ZZ.poly_ring(x).unify(QQ.poly_ring(x, y)) == QQ.poly_ring(x, y)
assert QQ.poly_ring(x).unify(ZZ.poly_ring(x, y)) == QQ.poly_ring(x, y)
assert QQ.poly_ring(x).unify(QQ.poly_ring(x, y)) == QQ.poly_ring(x, y)
assert ZZ.poly_ring(x, y).unify(ZZ.poly_ring(x, z)) == ZZ.poly_ring(x, y, z)
assert ZZ.poly_ring(x, y).unify(QQ.poly_ring(x, z)) == QQ.poly_ring(x, y, z)
assert QQ.poly_ring(x, y).unify(ZZ.poly_ring(x, z)) == QQ.poly_ring(x, y, z)
assert QQ.poly_ring(x, y).unify(QQ.poly_ring(x, z)) == QQ.poly_ring(x, y, z)
assert ZZ.frac_field(x).unify(ZZ.frac_field(x)) == ZZ.frac_field(x)
assert ZZ.frac_field(x).unify(QQ.frac_field(x)) == QQ.frac_field(x)
assert QQ.frac_field(x).unify(ZZ.frac_field(x)) == QQ.frac_field(x)
assert QQ.frac_field(x).unify(QQ.frac_field(x)) == QQ.frac_field(x)
assert ZZ.frac_field(x, y).unify(ZZ.frac_field(x)) == ZZ.frac_field(x, y)
#.........这里部分代码省略.........
示例2: test_Domain__unify
# 需要导入模块: from sympy.polys.domains import ZZ [as 别名]
# 或者: from sympy.polys.domains.ZZ import unify [as 别名]
def test_Domain__unify():
assert ZZ.unify(ZZ) == ZZ
assert QQ.unify(QQ) == QQ
assert ZZ.unify(QQ) == QQ
assert QQ.unify(ZZ) == QQ
assert EX.unify(EX) == EX
assert ZZ.unify(EX) == EX
assert QQ.unify(EX) == EX
assert EX.unify(ZZ) == EX
assert EX.unify(QQ) == EX
assert ZZ.poly_ring('x').unify(EX) == EX
assert ZZ.frac_field('x').unify(EX) == EX
assert EX.unify(ZZ.poly_ring('x')) == EX
assert EX.unify(ZZ.frac_field('x')) == EX
assert ZZ.poly_ring('x','y').unify(EX) == EX
assert ZZ.frac_field('x','y').unify(EX) == EX
assert EX.unify(ZZ.poly_ring('x','y')) == EX
assert EX.unify(ZZ.frac_field('x','y')) == EX
assert QQ.poly_ring('x').unify(EX) == EX
assert QQ.frac_field('x').unify(EX) == EX
assert EX.unify(QQ.poly_ring('x')) == EX
assert EX.unify(QQ.frac_field('x')) == EX
assert QQ.poly_ring('x','y').unify(EX) == EX
assert QQ.frac_field('x','y').unify(EX) == EX
assert EX.unify(QQ.poly_ring('x','y')) == EX
assert EX.unify(QQ.frac_field('x','y')) == EX
assert ZZ.poly_ring('x').unify(ZZ) == ZZ.poly_ring('x')
assert ZZ.poly_ring('x').unify(QQ) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(ZZ) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(QQ) == QQ.poly_ring('x')
assert ZZ.unify(ZZ.poly_ring('x')) == ZZ.poly_ring('x')
assert QQ.unify(ZZ.poly_ring('x')) == QQ.poly_ring('x')
assert ZZ.unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert QQ.unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert ZZ.poly_ring('x','y').unify(ZZ) == ZZ.poly_ring('x','y')
assert ZZ.poly_ring('x','y').unify(QQ) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(ZZ) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(QQ) == QQ.poly_ring('x','y')
assert ZZ.unify(ZZ.poly_ring('x','y')) == ZZ.poly_ring('x','y')
assert QQ.unify(ZZ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert ZZ.unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert QQ.unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert ZZ.frac_field('x').unify(ZZ) == ZZ.frac_field('x')
assert ZZ.frac_field('x').unify(QQ) == EX # QQ.frac_field('x')
assert QQ.frac_field('x').unify(ZZ) == EX # QQ.frac_field('x')
assert QQ.frac_field('x').unify(QQ) == QQ.frac_field('x')
assert ZZ.unify(ZZ.frac_field('x')) == ZZ.frac_field('x')
assert QQ.unify(ZZ.frac_field('x')) == EX # QQ.frac_field('x')
assert ZZ.unify(QQ.frac_field('x')) == EX # QQ.frac_field('x')
assert QQ.unify(QQ.frac_field('x')) == QQ.frac_field('x')
assert ZZ.frac_field('x','y').unify(ZZ) == ZZ.frac_field('x','y')
assert ZZ.frac_field('x','y').unify(QQ) == EX # QQ.frac_field('x','y')
assert QQ.frac_field('x','y').unify(ZZ) == EX # QQ.frac_field('x','y')
assert QQ.frac_field('x','y').unify(QQ) == QQ.frac_field('x','y')
assert ZZ.unify(ZZ.frac_field('x','y')) == ZZ.frac_field('x','y')
assert QQ.unify(ZZ.frac_field('x','y')) == EX # QQ.frac_field('x','y')
assert ZZ.unify(QQ.frac_field('x','y')) == EX # QQ.frac_field('x','y')
assert QQ.unify(QQ.frac_field('x','y')) == QQ.frac_field('x','y')
assert ZZ.poly_ring('x').unify(ZZ.poly_ring('x')) == ZZ.poly_ring('x')
assert ZZ.poly_ring('x').unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(ZZ.poly_ring('x')) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert ZZ.poly_ring('x','y').unify(ZZ.poly_ring('x')) == ZZ.poly_ring('x','y')
assert ZZ.poly_ring('x','y').unify(QQ.poly_ring('x')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(ZZ.poly_ring('x')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(QQ.poly_ring('x')) == QQ.poly_ring('x','y')
assert ZZ.poly_ring('x').unify(ZZ.poly_ring('x','y')) == ZZ.poly_ring('x','y')
assert ZZ.poly_ring('x').unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x').unify(ZZ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x').unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert ZZ.poly_ring('x','y').unify(ZZ.poly_ring('x','z')) == ZZ.poly_ring('x','y','z')
assert ZZ.poly_ring('x','y').unify(QQ.poly_ring('x','z')) == QQ.poly_ring('x','y','z')
assert QQ.poly_ring('x','y').unify(ZZ.poly_ring('x','z')) == QQ.poly_ring('x','y','z')
assert QQ.poly_ring('x','y').unify(QQ.poly_ring('x','z')) == QQ.poly_ring('x','y','z')
assert ZZ.frac_field('x').unify(ZZ.frac_field('x')) == ZZ.frac_field('x')
assert ZZ.frac_field('x').unify(QQ.frac_field('x')) == QQ.frac_field('x')
assert QQ.frac_field('x').unify(ZZ.frac_field('x')) == QQ.frac_field('x')
assert QQ.frac_field('x').unify(QQ.frac_field('x')) == QQ.frac_field('x')
assert ZZ.frac_field('x','y').unify(ZZ.frac_field('x')) == ZZ.frac_field('x','y')
#.........这里部分代码省略.........
示例3: test_Domain__unify
# 需要导入模块: from sympy.polys.domains import ZZ [as 别名]
# 或者: from sympy.polys.domains.ZZ import unify [as 别名]
def test_Domain__unify():
assert ZZ.unify(ZZ) == ZZ
assert QQ.unify(QQ) == QQ
assert ZZ.unify(QQ) == QQ
assert QQ.unify(ZZ) == QQ
assert EX.unify(EX) == EX
assert ZZ.unify(EX) == EX
assert QQ.unify(EX) == EX
assert EX.unify(ZZ) == EX
assert EX.unify(QQ) == EX
assert ZZ.poly_ring('x').unify(EX) == EX
assert ZZ.frac_field('x').unify(EX) == EX
assert EX.unify(ZZ.poly_ring('x')) == EX
assert EX.unify(ZZ.frac_field('x')) == EX
assert ZZ.poly_ring('x','y').unify(EX) == EX
assert ZZ.frac_field('x','y').unify(EX) == EX
assert EX.unify(ZZ.poly_ring('x','y')) == EX
assert EX.unify(ZZ.frac_field('x','y')) == EX
assert QQ.poly_ring('x').unify(EX) == EX
assert QQ.frac_field('x').unify(EX) == EX
assert EX.unify(QQ.poly_ring('x')) == EX
assert EX.unify(QQ.frac_field('x')) == EX
assert QQ.poly_ring('x','y').unify(EX) == EX
assert QQ.frac_field('x','y').unify(EX) == EX
assert EX.unify(QQ.poly_ring('x','y')) == EX
assert EX.unify(QQ.frac_field('x','y')) == EX
assert ZZ.poly_ring('x').unify(ZZ) == ZZ.poly_ring('x')
assert ZZ.poly_ring('x').unify(QQ) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(ZZ) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(QQ) == QQ.poly_ring('x')
assert ZZ.unify(ZZ.poly_ring('x')) == ZZ.poly_ring('x')
assert QQ.unify(ZZ.poly_ring('x')) == QQ.poly_ring('x')
assert ZZ.unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert QQ.unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert ZZ.poly_ring('x','y').unify(ZZ) == ZZ.poly_ring('x','y')
assert ZZ.poly_ring('x','y').unify(QQ) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(ZZ) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(QQ) == QQ.poly_ring('x','y')
assert ZZ.unify(ZZ.poly_ring('x','y')) == ZZ.poly_ring('x','y')
assert QQ.unify(ZZ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert ZZ.unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert QQ.unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert ZZ.frac_field('x').unify(ZZ) == ZZ.frac_field('x')
assert ZZ.frac_field('x').unify(QQ) == EX # QQ.frac_field('x')
assert QQ.frac_field('x').unify(ZZ) == EX # QQ.frac_field('x')
assert QQ.frac_field('x').unify(QQ) == QQ.frac_field('x')
assert ZZ.unify(ZZ.frac_field('x')) == ZZ.frac_field('x')
assert QQ.unify(ZZ.frac_field('x')) == EX # QQ.frac_field('x')
assert ZZ.unify(QQ.frac_field('x')) == EX # QQ.frac_field('x')
assert QQ.unify(QQ.frac_field('x')) == QQ.frac_field('x')
assert ZZ.frac_field('x','y').unify(ZZ) == ZZ.frac_field('x','y')
assert ZZ.frac_field('x','y').unify(QQ) == EX # QQ.frac_field('x','y')
assert QQ.frac_field('x','y').unify(ZZ) == EX # QQ.frac_field('x','y')
assert QQ.frac_field('x','y').unify(QQ) == QQ.frac_field('x','y')
assert ZZ.unify(ZZ.frac_field('x','y')) == ZZ.frac_field('x','y')
assert QQ.unify(ZZ.frac_field('x','y')) == EX # QQ.frac_field('x','y')
assert ZZ.unify(QQ.frac_field('x','y')) == EX # QQ.frac_field('x','y')
assert QQ.unify(QQ.frac_field('x','y')) == QQ.frac_field('x','y')
assert ZZ.poly_ring('x').unify(ZZ.poly_ring('x')) == ZZ.poly_ring('x')
assert ZZ.poly_ring('x').unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(ZZ.poly_ring('x')) == QQ.poly_ring('x')
assert QQ.poly_ring('x').unify(QQ.poly_ring('x')) == QQ.poly_ring('x')
assert ZZ.poly_ring('x','y').unify(ZZ.poly_ring('x')) == ZZ.poly_ring('x','y')
assert ZZ.poly_ring('x','y').unify(QQ.poly_ring('x')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(ZZ.poly_ring('x')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x','y').unify(QQ.poly_ring('x')) == QQ.poly_ring('x','y')
assert ZZ.poly_ring('x').unify(ZZ.poly_ring('x','y')) == ZZ.poly_ring('x','y')
assert ZZ.poly_ring('x').unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x').unify(ZZ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert QQ.poly_ring('x').unify(QQ.poly_ring('x','y')) == QQ.poly_ring('x','y')
assert ZZ.poly_ring('x','y').unify(ZZ.poly_ring('x','z')) == ZZ.poly_ring('x','y','z')
assert ZZ.poly_ring('x','y').unify(QQ.poly_ring('x','z')) == QQ.poly_ring('x','y','z')
assert QQ.poly_ring('x','y').unify(ZZ.poly_ring('x','z')) == QQ.poly_ring('x','y','z')
assert QQ.poly_ring('x','y').unify(QQ.poly_ring('x','z')) == QQ.poly_ring('x','y','z')
assert ZZ.frac_field('x').unify(ZZ.frac_field('x')) == ZZ.frac_field('x')
assert ZZ.frac_field('x').unify(QQ.frac_field('x')) == QQ.frac_field('x')
assert QQ.frac_field('x').unify(ZZ.frac_field('x')) == QQ.frac_field('x')
assert QQ.frac_field('x').unify(QQ.frac_field('x')) == QQ.frac_field('x')
assert ZZ.frac_field('x','y').unify(ZZ.frac_field('x')) == ZZ.frac_field('x','y')
#.........这里部分代码省略.........