newRPL: Simplified matrices proposal

06082015, 06:16 PM
(This post was last modified: 06082015 07:12 PM by Claudio L..)
Post: #12




RE: newRPL: Simplified matrices proposal
(06082015 04:39 PM)3298 Wrote: the SIZE command behaves differently on matrices and vectors: on matrices it obviously returns both dimensions as a list with two elements, on a vector or any other array it returns a list with just a single element. You are right, SIZE would change. I can't say it would break, because it was probably already broken... [ 1 2 3 ] SIZE > { 3 } [[ 1 2 3 ]] SIZE > { 1 3 } { 1 2 3 } SIZE > 3 {{ 1 2 3 }} SIZE > 1 So it works for numeric vectors, but for symbolic vectors it returns a number, not a list. For symbolic matrices doesn't even give a hint. So now the question becomes: Is this a behavior worth keeping? EDIT: I should clarify the first 2 examples also apply to the MATRIX symbolic matrices, so it's consistent as long as you don't use lists (49g only, not backwards compatible). So it looks like vectors should be a separate type to avoid compat. issues. I can't see a way around this one. 

« Next Oldest  Next Newest »

Messages In This Thread 
newRPL: Simplified matrices proposal  Claudio L.  06012015, 07:20 PM
RE: newRPL: Simplified matrices proposal  Werner  06012015, 08:48 PM
RE: newRPL: Simplified matrices proposal  Claudio L.  06022015, 12:46 AM
RE: newRPL: Simplified matrices proposal  Paul Dale  06012015, 10:24 PM
RE: newRPL: Simplified matrices proposal  Claudio L.  06022015, 01:37 AM
RE: newRPL: Simplified matrices proposal  Claudio L.  06022015, 12:19 PM
RE: newRPL: Simplified matrices proposal  rprosperi  06032015, 01:27 AM
RE: newRPL: Simplified matrices proposal  Claudio L.  06032015, 01:21 PM
RE: newRPL: Simplified matrices proposal  rprosperi  06052015, 11:41 PM
RE: newRPL: Simplified matrices proposal  Claudio L.  06082015, 12:50 PM
RE: newRPL: Simplified matrices proposal  3298  06082015, 04:39 PM
RE: newRPL: Simplified matrices proposal  Claudio L.  06082015 06:16 PM

User(s) browsing this thread: 1 Guest(s)