Flatten a Matrix
|
10-09-2014, 12:49 PM
Post: #3
|
|||
|
|||
RE: Flatten a Matrix
I wonder why "Flatten a Matrix" doesn't flatten a -list- of matrices flatter?
example: a:=([1,2],[3,4]) b:=([5,6],[0,1]) mat2list(a) => {1,2,3,4} and mat2list(b) => {5,6,0,1} Good! mat2list(a,b) also mat2list({a,b}) also mat2list([a,b]) => {{[1,2],[3,4]},{{[5,6],[0,1]}} The above takes on 'flattening' a list of matrices fed to the mat2list function each yield a list of matrices, instead of their collective elements. Would it not be more consistent to have the function return "the elements" for the collection of input matrices, as the user guide suggests? Like this do-si-do does: mat2list(concat(a,b)) => {1,2,5,6,3,4,0,1} -or- perhaps even better => {1,2,3,4,5,6,0,1} -Dale- |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
Flatten a Matrix - dalupus - 10-09-2014, 03:04 AM
RE: Flatten a Matrix - Joe Horn - 10-09-2014, 04:05 AM
RE: Flatten a Matrix - DrD - 10-09-2014 12:49 PM
RE: Flatten a Matrix - dalupus - 10-09-2014, 02:17 PM
|
User(s) browsing this thread: 1 Guest(s)