Probably very simple, but I don't know where to start with this. How do I go about creating a symbolic matrix, such as the one below?
I want to be able to use this so that any list of lists that are entered to signify a matrix can be read as having indices {i,1,m},{j,1,n}, and then I can use another rule using the terms in the matrix, ai,j.
I found an answer that mentioned SymbolicMatrix, but this no longer seems to work on the most up-to-date versions of Mathematica.
EDIT: This seems to be trickier than I first thought. Essentially, whenever I enter a list of lists, such as mat[{{1,2,3},{4,5,6},{7,8,9}], I want to be able to automatically recognise that the first list corresponds to a1,1,a1,2,a1,3, the second list to a2,1,a2,2,a2,3, and the third list (in this example) to a3,1,a3,2,a3,3.
I then aim to write a rule that, when values of I and j are selected, gives back a list of {ai,j+1, ai,j-1, ai-1,j, ai+1,j}.
Table[Subscript[a, i, j], {i, 3}, {j, 4}] // MatrixForm
$\endgroup$Subscript
expressions and use indexed variables instead, as was shown withArray
. Much cleaner to handle thosea[1, 2]
objects later on! $\endgroup$