Python sympy from_rgs()方法
在sympy.combinatorics.Partition.from_rgs()方法的帮助下,我们可以通过传递索引数组和成员列表来获得子数组。
语法 : sympy.combinatorics.Partition.from_rgs()
返回:返回子数组。
例子#1 :
在这个例子中,我们可以看到,通过使用sympy.combinatorics.Partition.from_rgs()方法,我们能够通过传递索引数组和成员列表作为参数来获得子数组的阵列。
输出 :
{{a, d}, {b, e}, {c, f}}
例子#2 :
输出 :
{{m}, {c, f}, {g, i}, {h, j}, {a, d, k}, {b, e, l}}