Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
""" Represents a Matrix using a function (Lambda)
This class is an alternative to SparseMatrix
>>> from sympy import FunctionMatrix, symbols, Lambda, MatMul, Matrix >>> i, j = symbols('i,j') >>> X = FunctionMatrix(3, 3, Lambda((i, j), i + j)) >>> Matrix(X) Matrix([ [0, 1, 2], [1, 2, 3], [2, 3, 4]])
>>> Y = FunctionMatrix(1000, 1000, Lambda((i, j), i + j))
>>> isinstance(Y*Y, MatMul) # this is an expression object True
>>> (Y**2)[10,10] # So this is evaluated lazily 342923500 """
def shape(self):
def lamda(self):
|