Opposite of CONCAT()?
|
01-06-2019, 02:04 PM
Post: #1
|
|||
|
|||
Opposite of CONCAT()?
CONCAT(matrix,identity(n)) is used to form an intermediate result. A later operation needs to remove identity(n) from the result:
Example: a:=[[1,3],[2,7]]; a:=CONCAT(a,identity(2)); a1:=RREF(a); // The concatenation of identity(2), and a^-1 I was hoping for something similar to these ideas, (to remove identity(n) from a concatenation): // SUPPRESS(a1,identity(2)); // remove(identity(2),a1); // SUB(a1,a1-identity(2)); Treating identity(n) as an object, fails. |
|||
01-06-2019, 02:25 PM
(This post was last modified: 01-06-2019 02:25 PM by parisse.)
Post: #2
|
|||
|
|||
RE: Opposite of CONCAT()?
from CAS: a1[:,3..4]
|
|||
01-06-2019, 04:08 PM
Post: #3
|
|||
|
|||
RE: Opposite of CONCAT()?
Thanks, Parisse! Peace, and Happy New Year to you!
-Dale- |
|||
01-06-2019, 05:25 PM
(This post was last modified: 01-06-2019 05:37 PM by compsystems.)
Post: #4
|
|||
|
|||
RE: Opposite of CONCAT()?
But you have to specify where the index flag starts. I found a visualization BUG (history view)
a1 := [ [1,0,7,-3], [0,1,-2,1] ] 'index':=1 [↵] "[] index start 1" // row#1: [ 1, 0, 7, -3 ], row#2: [0, 1, -2, 1] // col#3: [ 7, -2 ], col#4: [ -3, 1 ] a1[:, 3..4 ] [↵] [[7,-3],[-2,1]] // ok, extract all rows from 1 to 2 and columns from 3 to 4 a1[:, 3..4 ] => a1[1 .. 0-1 ,3 .. 4] (history view) 0-1 I do not know what this means. Here is an Bug of visualization, it should show a1[:, 3..4 ] => a1[2 .. 1 ,3 .. 4] or a1[1 .. 2 ,3 .. 4] but not a1[1 .. 0-1 ,3 .. 4] ======================== 'index':=0 [↵] "[] index start 0" // row#0: [ 1, 0, 7, -3 ], row#1: [0, 1, -2, 1] // col#3: [ 7, -2 ], col#4: [ -3, 1 ] a1[:,2..3] [↵] [[7,-3],[-2,1]] // ok, extract all rows from 0 to 1 and columns from 2 to 3 a1[:,2..3] => a1[0 .. -1 ,3 .. 4] ??? [↨up] [up] [copy]=> a1[0 .. -1, 2 .. 3] Here is an Bug of visualization, it should say a1[:, 2..3 ] => a1[0 .. 1 ,2 .. 3] or a1[1 .. 0 ,2 .. 3] but not a1[0 .. -1 ,3 .. 4] a1[:,3..4] [↵] [[-3],[1]] // ok, extract all rows 0 to 1 and columns from 3 |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)