Message Boards Message Boards

0
|
7667 Views
|
2 Replies
|
0 Total Likes
View groups...
Share
Share this post:

How can you convert a matrix back into a list of lists?

Posted 11 years ago
It is very simple in Mathematica to convert a list of lists into a matrix: all you need to do is apply the //MatrixForm function to it and voila.

Is it possible to do the reverse though? I have a matrix that I want to convert back into a list of lists, so as to manipulate its elements more easily. Is this possible? Is there a 'ListForm' function that deletes all MatrixForms from the element in question?

As an example, here is the FullForm for one of my elements:
MatrixForm[List[List[63],List[4,62]]]

Is there a function which would take this as input and return simply:
List[List[63],List[4,62]]

Thank you
POSTED BY: Aron Adler
2 Replies
In[1]:= m = MatrixForm[List[List[63], List[4, 62]]]

In[4]:= m[[1]]

Out[4]= {{63}, {4, 62}}
POSTED BY: Frank Kampas
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract