素胚勾勒不出你
您可以使用以下命令创建未评估的符号积MatMul: https: //docs.sympy.org/latest/modules/matrices/expressions.html#sympy.matrices.expressions.MatMulIn [16]: from sympy import * In [17]: A = Matrix([[1, 2], [3, 4]]) In [18]: B = Matrix([[5, 6], [7, 8]]) In [19]: product = MatMul(A, B) In [20]: product Out[20]: ⎡1 2⎤ ⎡5 6⎤⎢ ⎥⋅⎢ ⎥⎣3 4⎦ ⎣7 8⎦In [21]: product.doit() Out[21]: ⎡19 22⎤⎢ ⎥⎣43 50⎦In [22]: Eq(product, product.doit()) Out[22]: ⎡1 2⎤ ⎡5 6⎤ ⎡19 22⎤⎢ ⎥⋅⎢ ⎥ = ⎢ ⎥⎣3 4⎦ ⎣7 8⎦ ⎣43 50⎦