summaryrefslogtreecommitdiff
path: root/js/MatrixOp
diff options
context:
space:
mode:
authorSunil Shetye2018-06-26 14:59:47 +0530
committerSunil Shetye2018-06-26 14:59:47 +0530
commiteb7c8e0cd42d4afe02be3adda2e94b6b0dfdaa00 (patch)
tree6378935263fe5cafd389b6893ac3b37a1dd4b1a7 /js/MatrixOp
parentafed64f1a0eab0b2d742088186d7bc340a2c895b (diff)
downloadsci2js-eb7c8e0cd42d4afe02be3adda2e94b6b0dfdaa00.tar.gz
sci2js-eb7c8e0cd42d4afe02be3adda2e94b6b0dfdaa00.tar.bz2
sci2js-eb7c8e0cd42d4afe02be3adda2e94b6b0dfdaa00.zip
add return value from scicos_getvalue to global vars
Diffstat (limited to 'js/MatrixOp')
-rw-r--r--js/MatrixOp/CUMSUM.js20
-rw-r--r--js/MatrixOp/CUMSUM.pickle10
-rw-r--r--js/MatrixOp/EXTRACT.js20
-rw-r--r--js/MatrixOp/EXTRACT.pickle12
-rw-r--r--js/MatrixOp/EXTTRI.js20
-rw-r--r--js/MatrixOp/EXTTRI.pickle10
-rw-r--r--js/MatrixOp/MATBKSL.js6
-rw-r--r--js/MatrixOp/MATBKSL.pickle6
-rw-r--r--js/MatrixOp/MATCATH.js8
-rw-r--r--js/MatrixOp/MATCATH.pickle8
-rw-r--r--js/MatrixOp/MATCATV.js8
-rw-r--r--js/MatrixOp/MATCATV.pickle8
-rw-r--r--js/MatrixOp/MATDET.js6
-rw-r--r--js/MatrixOp/MATDET.pickle6
-rw-r--r--js/MatrixOp/MATDIAG.js6
-rw-r--r--js/MatrixOp/MATDIAG.pickle6
-rw-r--r--js/MatrixOp/MATDIV.js6
-rw-r--r--js/MatrixOp/MATDIV.pickle6
-rw-r--r--js/MatrixOp/MATEIG.js16
-rw-r--r--js/MatrixOp/MATEIG.pickle10
-rw-r--r--js/MatrixOp/MATEXPM.js6
-rw-r--r--js/MatrixOp/MATEXPM.pickle6
-rw-r--r--js/MatrixOp/MATINV.js6
-rw-r--r--js/MatrixOp/MATINV.pickle6
-rw-r--r--js/MatrixOp/MATLU.js8
-rw-r--r--js/MatrixOp/MATLU.pickle8
-rw-r--r--js/MatrixOp/MATMAGPHI.js8
-rw-r--r--js/MatrixOp/MATMAGPHI.pickle8
-rw-r--r--js/MatrixOp/MATMUL.js78
-rw-r--r--js/MatrixOp/MATMUL.pickle12
-rw-r--r--js/MatrixOp/MATPINV.js6
-rw-r--r--js/MatrixOp/MATPINV.pickle6
-rw-r--r--js/MatrixOp/MATRESH.js20
-rw-r--r--js/MatrixOp/MATRESH.pickle12
-rw-r--r--js/MatrixOp/MATSING.js16
-rw-r--r--js/MatrixOp/MATSING.pickle10
-rw-r--r--js/MatrixOp/MATSUM.js20
-rw-r--r--js/MatrixOp/MATSUM.pickle10
-rw-r--r--js/MatrixOp/MATTRAN.js8
-rw-r--r--js/MatrixOp/MATTRAN.pickle8
-rw-r--r--js/MatrixOp/MATZREIM.js8
-rw-r--r--js/MatrixOp/MATZREIM.pickle8
-rw-r--r--js/MatrixOp/RICC.js4
-rw-r--r--js/MatrixOp/RICC.pickle8
-rw-r--r--js/MatrixOp/ROOTCOEF.js10
-rw-r--r--js/MatrixOp/ROOTCOEF.pickle8
-rw-r--r--js/MatrixOp/SQRT.js10
-rw-r--r--js/MatrixOp/SQRT.pickle6
-rw-r--r--js/MatrixOp/SUBMAT.js22
-rw-r--r--js/MatrixOp/SUBMAT.pickle18
50 files changed, 336 insertions, 226 deletions
diff --git a/js/MatrixOp/CUMSUM.js b/js/MatrixOp/CUMSUM.js
index b2bcb38e..3cc0ba37 100644
--- a/js/MatrixOp/CUMSUM.js
+++ b/js/MatrixOp/CUMSUM.js
@@ -39,19 +39,19 @@ function CUMSUM() {
label[9-1] = [];
}
while (true) {
- [ok,typ,decomptyp,lab] = scicos_getvalue("Set CUMSUM block parameters",[["Datatype(1=real double 2=Complex)"],["Sum along (0=the first non singleton dimension 1=Rows 2=Columns)"]],list("vec",1,"vec",1),label);
+ [ok,this.typ,this.decomptyp,this.lab] = scicos_getvalue("Set CUMSUM block parameters",[["Datatype(1=real double 2=Complex)"],["Sum along (0=the first non singleton dimension 1=Rows 2=Columns)"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
- label = lab;
- if ((typ==1)) {
- if ((decomptyp==0)) {
+ label = this.lab;
+ if ((this.typ==1)) {
+ if ((this.decomptyp==0)) {
function_name = "cumsum_m";
out = [-1,-2];
- } else if ((decomptyp==1)) {
+ } else if ((this.decomptyp==1)) {
function_name = "cumsum_r";
out = [-1,1];
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "cumsum_c";
out = [1,-2];
} else {
@@ -60,12 +60,12 @@ function CUMSUM() {
}
it = 1;
ot = 1;
- } else if ((typ==2)) {
- if ((decomptyp==0)) {
+ } else if ((this.typ==2)) {
+ if ((this.decomptyp==0)) {
function_name = "cumsumz_m";
- } else if ((decomptyp==1)) {
+ } else if ((this.decomptyp==1)) {
function_name = "cumsumz_r";
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "cumsumz_c";
} else {
message("decomposition type is not supported");
diff --git a/js/MatrixOp/CUMSUM.pickle b/js/MatrixOp/CUMSUM.pickle
index 0d1dde24..a200ffa9 100644
--- a/js/MatrixOp/CUMSUM.pickle
+++ b/js/MatrixOp/CUMSUM.pickle
@@ -4,6 +4,12 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+aS'lab'
+p4
+aS'decomptyp'
+p5
+atp6
+Rp7
. \ No newline at end of file
diff --git a/js/MatrixOp/EXTRACT.js b/js/MatrixOp/EXTRACT.js
index 73b1f888..92fa33f9 100644
--- a/js/MatrixOp/EXTRACT.js
+++ b/js/MatrixOp/EXTRACT.js
@@ -39,17 +39,17 @@ function EXTRACT() {
label[9-1] = [];
}
while (true) {
- [ok,typ,a,b,exprs] = scicos_getvalue("Set EXTRACT Block",[["Datatype (1=real double 2=Complex)"],["Lines to extract"],["Columns to extract"]],list("vec",1,"mat",[1,-1],"mat",[1,-1]),label);
- a = a.slice();
- b = b.slice();
+ [ok,this.typ,this.a,this.b,exprs] = scicos_getvalue("Set EXTRACT Block",[["Datatype (1=real double 2=Complex)"],["Lines to extract"],["Columns to extract"]],list("vec",1,"mat",[1,-1],"mat",[1,-1]),label);
+ this.a = this.a.slice();
+ this.b = this.b.slice();
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "extract";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "extractz";
ot = 2;
it = 2;
@@ -57,25 +57,25 @@ function EXTRACT() {
message("Datatype is not supported");
ok = false;
}
- ma = size(a,1);
- mb = size(b,1);
+ ma = size(this.a,1);
+ mb = size(this.b,1);
if ((ma==0||mb==0)) {
message("empty field");
ok = false;
}
for (i=1;i<=ma;i+=1) {
- if ((a[i-1]<=0)) {
+ if ((this.a[i-1]<=0)) {
message("invalid index");
ok = false;
}
}
for (j=1;j<=mb;j+=1) {
- if ((b[j-1]<=0)) {
+ if ((this.b[j-1]<=0)) {
message("invalid index");
ok = false;
}
}
- model.ipar = [[a],[b],[ma],[mb]];
+ model.ipar = [[this.a],[this.b],[ma],[mb]];
in1 = [model.in1,model.in2];
out = [ma,mb];
funtyp = 4;
diff --git a/js/MatrixOp/EXTRACT.pickle b/js/MatrixOp/EXTRACT.pickle
index 0d1dde24..2df3177f 100644
--- a/js/MatrixOp/EXTRACT.pickle
+++ b/js/MatrixOp/EXTRACT.pickle
@@ -2,8 +2,14 @@ c__builtin__
set
p0
((lp1
-S'x'
+S'a'
p2
-atp3
-Rp4
+aS'x'
+p3
+aS'b'
+p4
+aS'typ'
+p5
+atp6
+Rp7
. \ No newline at end of file
diff --git a/js/MatrixOp/EXTTRI.js b/js/MatrixOp/EXTTRI.js
index 00eafa27..caf3aa3a 100644
--- a/js/MatrixOp/EXTTRI.js
+++ b/js/MatrixOp/EXTTRI.js
@@ -39,17 +39,17 @@ function EXTTRI() {
label[9-1] = [];
}
while (true) {
- [ok,typ,decomptyp,lab] = scicos_getvalue("Set EXTTRI block parameters",[["Datatype(1=real double 2=Complex)"],["extraction type (1=lower 2=upper 3=diagonal)"]],list("vec",1,"vec",1),label);
+ [ok,this.typ,this.decomptyp,this.lab] = scicos_getvalue("Set EXTTRI block parameters",[["Datatype(1=real double 2=Complex)"],["extraction type (1=lower 2=upper 3=diagonal)"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
- label = lab;
- if ((typ==1)) {
- if ((decomptyp==1)) {
+ label = this.lab;
+ if ((this.typ==1)) {
+ if ((this.decomptyp==1)) {
function_name = "exttril";
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "exttriu";
- } else if ((decomptyp==3)) {
+ } else if ((this.decomptyp==3)) {
function_name = "extdiag";
} else {
message("decomposition type is not supported");
@@ -57,12 +57,12 @@ function EXTTRI() {
}
it = 1;
ot = 1;
- } else if ((typ==2)) {
- if ((decomptyp==1)) {
+ } else if ((this.typ==2)) {
+ if ((this.decomptyp==1)) {
function_name = "exttrilz";
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "exttriuz";
- } else if ((decomptyp==3)) {
+ } else if ((this.decomptyp==3)) {
function_name = "extdiagz";
} else {
message("decomposition type is not supported");
diff --git a/js/MatrixOp/EXTTRI.pickle b/js/MatrixOp/EXTTRI.pickle
index 0d1dde24..a200ffa9 100644
--- a/js/MatrixOp/EXTTRI.pickle
+++ b/js/MatrixOp/EXTTRI.pickle
@@ -4,6 +4,12 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+aS'lab'
+p4
+aS'decomptyp'
+p5
+atp6
+Rp7
. \ No newline at end of file
diff --git a/js/MatrixOp/MATBKSL.js b/js/MatrixOp/MATBKSL.js
index f956a990..a4bea4b5 100644
--- a/js/MatrixOp/MATBKSL.js
+++ b/js/MatrixOp/MATBKSL.js
@@ -39,15 +39,15 @@ function MATBKSL() {
label[9-1] = [];
}
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set MATBKSL Block",["Datatype (1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set MATBKSL Block",["Datatype (1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_bksl";
ot = 1;
it = [1,1];
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_bksl";
ot = 2;
it = [2,2];
diff --git a/js/MatrixOp/MATBKSL.pickle b/js/MatrixOp/MATBKSL.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/MATBKSL.pickle
+++ b/js/MatrixOp/MATBKSL.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/MATCATH.js b/js/MatrixOp/MATCATH.js
index b1d626d8..dbdbc97b 100644
--- a/js/MatrixOp/MATCATH.js
+++ b/js/MatrixOp/MATCATH.js
@@ -39,14 +39,14 @@ function MATCATH() {
label = "size(evstr("+label[2-1]+"),\'*\')";
}
while (true) {
- [ok,nin,lab] = scicos_getvalue("Set MATCATH block parameters",["Number of input"],list("vec",1),label);
+ [ok,this.nin,this.lab] = scicos_getvalue("Set MATCATH block parameters",["Number of input"],list("vec",1),label);
if (!ok) {
break;
}
- label = lab;
- in1 = [-1*(ones(nin,1)),-(transpose([2:nin+1]))];
+ label = this.lab;
+ in1 = [-1*(ones(this.nin,1)),-(transpose([2:this.nin+1]))];
out = [-1,0];
- it = -1*(ones(nin,1));
+ it = -1*(ones(this.nin,1));
ot = -1;
[model,graphics,ok] = set_io(model,graphics,list(in1,it),list(out,ot),[],[]);
if (ok) {
diff --git a/js/MatrixOp/MATCATH.pickle b/js/MatrixOp/MATCATH.pickle
index 0d1dde24..5c203d19 100644
--- a/js/MatrixOp/MATCATH.pickle
+++ b/js/MatrixOp/MATCATH.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'nin'
+p3
+aS'lab'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/MATCATV.js b/js/MatrixOp/MATCATV.js
index d635fb4f..4824e14d 100644
--- a/js/MatrixOp/MATCATV.js
+++ b/js/MatrixOp/MATCATV.js
@@ -40,13 +40,13 @@ function MATCATV() {
label = "size(evstr("+label[2-1]+"),\'*\')";
}
while (true) {
- [ok,nin,lab] = scicos_getvalue("Set MATCATV block parameters",["Number od inputs"],list("vec",1),label);
+ [ok,this.nin,this.lab] = scicos_getvalue("Set MATCATV block parameters",["Number od inputs"],list("vec",1),label);
if (!ok) {
break;
}
- label = lab;
- in1 = [-(transpose([2:nin+1])),-ones(nin,1)];
- it = -ones(nin,1);
+ label = this.lab;
+ in1 = [-(transpose([2:this.nin+1])),-ones(this.nin,1)];
+ it = -ones(this.nin,1);
ot = -1;
out = [0,-1];
[model,graphics,ok] = set_io(model,graphics,list(in1,it),list(out,ot),[],[]);
diff --git a/js/MatrixOp/MATCATV.pickle b/js/MatrixOp/MATCATV.pickle
index 0d1dde24..5c203d19 100644
--- a/js/MatrixOp/MATCATV.pickle
+++ b/js/MatrixOp/MATCATV.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'nin'
+p3
+aS'lab'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/MATDET.js b/js/MatrixOp/MATDET.js
index fc12d549..9aed36c1 100644
--- a/js/MatrixOp/MATDET.js
+++ b/js/MatrixOp/MATDET.js
@@ -39,15 +39,15 @@ function MATDET() {
label[9-1] = [];
}
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set MATDET Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set MATDET Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_det";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_det";
ot = 2;
it = 2;
diff --git a/js/MatrixOp/MATDET.pickle b/js/MatrixOp/MATDET.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/MATDET.pickle
+++ b/js/MatrixOp/MATDET.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/MATDIAG.js b/js/MatrixOp/MATDIAG.js
index fae53116..b1ac519f 100644
--- a/js/MatrixOp/MATDIAG.js
+++ b/js/MatrixOp/MATDIAG.js
@@ -39,15 +39,15 @@ function MATDIAG() {
label[9-1] = [];
}
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set MATDIAG Block",["Datatype (1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set MATDIAG Block",["Datatype (1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_diag";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_diag";
ot = 2;
it = 2;
diff --git a/js/MatrixOp/MATDIAG.pickle b/js/MatrixOp/MATDIAG.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/MATDIAG.pickle
+++ b/js/MatrixOp/MATDIAG.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/MATDIV.js b/js/MatrixOp/MATDIV.js
index 38f01397..18fdf4a9 100644
--- a/js/MatrixOp/MATDIV.js
+++ b/js/MatrixOp/MATDIV.js
@@ -39,15 +39,15 @@ function MATDIV() {
label[9-1] = [];
}
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set MATDIV Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set MATDIV Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_div";
ot = 1;
it = [1,1];
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_div";
ot = 2;
it = [2,2];
diff --git a/js/MatrixOp/MATDIV.pickle b/js/MatrixOp/MATDIV.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/MATDIV.pickle
+++ b/js/MatrixOp/MATDIV.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/MATEIG.js b/js/MatrixOp/MATEIG.js
index 4fa713d0..0016fd5c 100644
--- a/js/MatrixOp/MATEIG.js
+++ b/js/MatrixOp/MATEIG.js
@@ -39,17 +39,17 @@ function MATEIG() {
label[9-1] = [];
}
while (true) {
- [ok,typ,decomptyp,lab] = scicos_getvalue("Set MATEIG block parameters",[["Datatype(1=real double 2=Complex)"],["decomposition type (1=eig values 2=eig values+eig vectors"]],list("vec",1,"vec",1),label);
+ [ok,this.typ,this.decomptyp,this.lab] = scicos_getvalue("Set MATEIG block parameters",[["Datatype(1=real double 2=Complex)"],["decomposition type (1=eig values 2=eig values+eig vectors"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
- label = lab;
- if ((typ==1)) {
- if ((decomptyp==1)) {
+ label = this.lab;
+ if ((this.typ==1)) {
+ if ((this.decomptyp==1)) {
function_name = "mat_vps";
out = [-1,1];
ot = 2;
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "mat_vpv";
out = [[-1,-1],[-1,-1]];
ot = [2,2];
@@ -58,12 +58,12 @@ function MATEIG() {
ok = false;
}
it = 1;
- } else if ((typ==2)) {
- if ((decomptyp==1)) {
+ } else if ((this.typ==2)) {
+ if ((this.decomptyp==1)) {
function_name = "matz_vps";
out = [-1,1];
ot = 2;
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "matz_vpv";
out = [[-1,-1],[-1,-1]];
ot = [2,2];
diff --git a/js/MatrixOp/MATEIG.pickle b/js/MatrixOp/MATEIG.pickle
index 0d1dde24..a200ffa9 100644
--- a/js/MatrixOp/MATEIG.pickle
+++ b/js/MatrixOp/MATEIG.pickle
@@ -4,6 +4,12 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+aS'lab'
+p4
+aS'decomptyp'
+p5
+atp6
+Rp7
. \ No newline at end of file
diff --git a/js/MatrixOp/MATEXPM.js b/js/MatrixOp/MATEXPM.js
index 5053663d..672401ed 100644
--- a/js/MatrixOp/MATEXPM.js
+++ b/js/MatrixOp/MATEXPM.js
@@ -39,15 +39,15 @@ function MATEXPM() {
label[9-1] = [];
}
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set EXPM Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set EXPM Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_expm";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_expm";
ot = 2;
it = 2;
diff --git a/js/MatrixOp/MATEXPM.pickle b/js/MatrixOp/MATEXPM.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/MATEXPM.pickle
+++ b/js/MatrixOp/MATEXPM.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/MATINV.js b/js/MatrixOp/MATINV.js
index b495de7d..2a7995c3 100644
--- a/js/MatrixOp/MATINV.js
+++ b/js/MatrixOp/MATINV.js
@@ -39,15 +39,15 @@ function MATINV() {
label[9-1] = [];
}
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set MATINV Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set MATINV Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_inv";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_inv";
ot = 2;
it = 2;
diff --git a/js/MatrixOp/MATINV.pickle b/js/MatrixOp/MATINV.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/MATINV.pickle
+++ b/js/MatrixOp/MATINV.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/MATLU.js b/js/MatrixOp/MATLU.js
index 51c5af6a..10b6d6da 100644
--- a/js/MatrixOp/MATLU.js
+++ b/js/MatrixOp/MATLU.js
@@ -39,15 +39,15 @@ function MATLU() {
label[9-1] = [];
}
while (true) {
- [ok,typ,lab] = scicos_getvalue("Set MATLU block parameters",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,this.lab] = scicos_getvalue("Set MATLU block parameters",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_lu";
ot = [1,1];
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_lu";
ot = [2,2];
it = 2;
@@ -61,7 +61,7 @@ function MATLU() {
if (ok) {
funtyp = 4;
model.sim = list(function_name,funtyp);
- graphics.exprs = lab;
+ graphics.exprs = this.lab;
this.x.graphics = graphics;
this.x.model = model;
break;
diff --git a/js/MatrixOp/MATLU.pickle b/js/MatrixOp/MATLU.pickle
index 0d1dde24..c4c325d3 100644
--- a/js/MatrixOp/MATLU.pickle
+++ b/js/MatrixOp/MATLU.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+aS'lab'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/MATMAGPHI.js b/js/MatrixOp/MATMAGPHI.js
index 3047ca48..61f61bca 100644
--- a/js/MatrixOp/MATMAGPHI.js
+++ b/js/MatrixOp/MATMAGPHI.js
@@ -39,18 +39,18 @@ function MATMAGPHI() {
label[9-1] = [];
}
while (true) {
- [ok,decomptyp,lab] = scicos_getvalue("Set MATMAGPHI block parameters",["decomposition type (1=Complex2MAG&PHI 2=MAG&PHI2Complex)"],list("vec",1),label);
+ [ok,this.decomptyp,this.lab] = scicos_getvalue("Set MATMAGPHI block parameters",["decomposition type (1=Complex2MAG&PHI 2=MAG&PHI2Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- label = lab;
- if ((decomptyp==1)) {
+ label = this.lab;
+ if ((this.decomptyp==1)) {
function_name = "matz_abs";
in1 = [-1,-2];
it = 2;
out = [[-1,-2],[-1,-2]];
ot = [1,1];
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "matz_absc";
in1 = [[-1,-2],[-1,-2]];
it = [1,1];
diff --git a/js/MatrixOp/MATMAGPHI.pickle b/js/MatrixOp/MATMAGPHI.pickle
index 0d1dde24..92ce3a57 100644
--- a/js/MatrixOp/MATMAGPHI.pickle
+++ b/js/MatrixOp/MATMAGPHI.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'lab'
+p3
+aS'decomptyp'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/MATMUL.js b/js/MatrixOp/MATMUL.js
index e3f1dd0b..54d5d3b8 100644
--- a/js/MatrixOp/MATMUL.js
+++ b/js/MatrixOp/MATMUL.js
@@ -34,103 +34,103 @@ function MATMUL() {
label[3-1] = sci2exp(1);
}
while (true) {
- [ok,dtype,rule,np,exprs] = scicos_getvalue([["Set MATMUL parameter"],["For the Multipication rule:"],[" 1= Matrix by Matrix"],[" 2= Matrix by Matrix element wise "],[" 3= Matrix by Scalar"],["In the third case the second input will be the scalar"]],[["Datatype(1=real double 2=Complex 3=int32 ...)"],["Multiplication rule"],["Do on Overflow(0=Nothing 1=Saturate 2=Error)"]],list("vec",1,"vec",1,"vec",1),label);
+ [ok,this.dtype,this.rule,this.np,exprs] = scicos_getvalue([["Set MATMUL parameter"],["For the Multipication rule:"],[" 1= Matrix by Matrix"],[" 2= Matrix by Matrix element wise "],[" 3= Matrix by Scalar"],["In the third case the second input will be the scalar"]],[["Datatype(1=real double 2=Complex 3=int32 ...)"],["Multiplication rule"],["Do on Overflow(0=Nothing 1=Saturate 2=Error)"]],list("vec",1,"vec",1,"vec",1),label);
if (!ok) {
break;
}
- rule = int(rule);
- if ((dtype<1||dtype>8)) {
+ this.rule = int(this.rule);
+ if ((this.dtype<1||this.dtype>8)) {
message("type is not supported");
ok = false;
}
- if ((rule<1||rule>3)) {
+ if ((this.rule<1||this.rule>3)) {
message("Multiplication rule must be only 1,2 or 3");
ok = false;
}
- if ((dtype==1||dtype==2)) {
- np = 0;
+ if ((this.dtype==1||this.dtype==2)) {
+ this.np = 0;
}
TABMIN = [[0],[0],[-(2^31)],[-(2^15)],[-(2^7)],[0],[0],[0]];
TABMAX = [[0],[0],[(2^31)-1],[(2^15)-1],[(2^7)-1],[(2^32)-1],[(2^16)-1],[(2^8)-1]];
- if (rule==2) {
- if (np==0) {
+ if (this.rule==2) {
+ if (this.np==0) {
model.sim = list("matmul2_m",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matmul2_s",4);
} else {
model.sim = list("matmul2_e",4);
}
- } else if (rule==3) {
- if (np==0) {
+ } else if (this.rule==3) {
+ if (this.np==0) {
model.sim = list("matbyscal",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matbyscal_s",4);
} else {
model.sim = list("matbyscal_e",4);
}
} else {
- if ((dtype==1)) {
+ if ((this.dtype==1)) {
model.sim = list("matmul_m",4);
- } else if ((dtype==2)) {
+ } else if ((this.dtype==2)) {
model.sim = list("matzmul_m",4);
- } else if (dtype==3) {
- if (np==0) {
+ } else if (this.dtype==3) {
+ if (this.np==0) {
model.sim = list("matmul_i32n",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matmul_i32s",4);
} else {
model.sim = list("matmul_i32e",4);
}
- } else if (dtype==4) {
- if (np==0) {
+ } else if (this.dtype==4) {
+ if (this.np==0) {
model.sim = list("matmul_i16n",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matmul_i16s",4);
} else {
model.sim = list("matmul_i16e",4);
}
- } else if (dtype==5) {
- if (np==0) {
+ } else if (this.dtype==5) {
+ if (this.np==0) {
model.sim = list("matmul_i8n",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matmul_i8s",4);
} else {
model.sim = list("matmul_i8e",4);
}
- } else if (dtype==6) {
- if (np==0) {
+ } else if (this.dtype==6) {
+ if (this.np==0) {
model.sim = list("matmul_ui32n",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matmul_ui32s",4);
} else {
model.sim = list("matmul_ui32e",4);
}
- } else if (dtype==7) {
- if (np==0) {
+ } else if (this.dtype==7) {
+ if (this.np==0) {
model.sim = list("matmul_ui16n",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matmul_ui16s",4);
} else {
model.sim = list("matmul_ui16e",4);
}
- } else if (dtype==8) {
- if (np==0) {
+ } else if (this.dtype==8) {
+ if (this.np==0) {
model.sim = list("matmul_ui8n",4);
- } else if (np==1) {
+ } else if (this.np==1) {
model.sim = list("matmul_ui8s",4);
} else {
model.sim = list("matmul_ui8e",4);
}
}
}
- kmin = TABMIN[dtype-1];
- kmax = TABMAX[dtype-1];
- it = dtype*ones(1,2);
- ot = dtype;
- if (rule==1) {
+ kmin = TABMIN[this.dtype-1];
+ kmax = TABMAX[this.dtype-1];
+ it = this.dtype*ones(1,2);
+ ot = this.dtype;
+ if (this.rule==1) {
in1 = [[-1,-2],[-2,-3]];
out = [-1,-3];
- } else if (rule==2) {
+ } else if (this.rule==2) {
in1 = [[-1,-2],[-1,-2]];
out = [-1,-2];
} else {
@@ -140,7 +140,7 @@ function MATMUL() {
[model,graphics,ok] = set_io(model,graphics,list(in1,it),list(out,ot),[],[]);
if (ok) {
label = exprs;
- model.ipar = rule;
+ model.ipar = this.rule;
model.rpar = [[kmin],[kmax]];
graphics.exprs = label;
this.x.graphics = graphics;
diff --git a/js/MatrixOp/MATMUL.pickle b/js/MatrixOp/MATMUL.pickle
index 0d1dde24..06e59fe1 100644
--- a/js/MatrixOp/MATMUL.pickle
+++ b/js/MatrixOp/MATMUL.pickle
@@ -2,8 +2,14 @@ c__builtin__
set
p0
((lp1
-S'x'
+S'np'
p2
-atp3
-Rp4
+aS'x'
+p3
+aS'rule'
+p4
+aS'dtype'
+p5
+atp6
+Rp7
. \ No newline at end of file
diff --git a/js/MatrixOp/MATPINV.js b/js/MatrixOp/MATPINV.js
index e21a49dc..cc82ce10 100644
--- a/js/MatrixOp/MATPINV.js
+++ b/js/MatrixOp/MATPINV.js
@@ -39,15 +39,15 @@ function MATPINV() {
label[9-1] = [];
}
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set MATPINV Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set MATPINV Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_pinv";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_pinv";
ot = 2;
it = 2;
diff --git a/js/MatrixOp/MATPINV.pickle b/js/MatrixOp/MATPINV.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/MATPINV.pickle
+++ b/js/MatrixOp/MATPINV.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/MATRESH.js b/js/MatrixOp/MATRESH.js
index b2e357a2..ef21b5f9 100644
--- a/js/MatrixOp/MATRESH.js
+++ b/js/MatrixOp/MATRESH.js
@@ -39,12 +39,12 @@ function MATRESH() {
label[9-1] = [];
}
while (true) {
- [ok,typ,l1,out,lab] = scicos_getvalue("Set MATRESH block parameters",[["Datatype(1=real double 2=Complex)","input size"],["output size desired"]],list("vec",-1,"vec",-1,"vec",-1),label);
+ [ok,this.typ,this.l1,this.out,this.lab] = scicos_getvalue("Set MATRESH block parameters",[["Datatype(1=real double 2=Complex)","input size"],["output size desired"]],list("vec",-1,"vec",-1,"vec",-1),label);
if (!ok) {
break;
}
- nout = size(out);
- nin = size(l1);
+ nout = size(this.out);
+ nin = size(this.l1);
if (nout==0) {
message("output must have at least one element");
ok = false;
@@ -54,24 +54,24 @@ function MATRESH() {
ok = false;
}
if (ok) {
- if (((out[1-1]>(l1[1-1]*l1[2-1])))) {
+ if (((this.out[1-1]>(this.l1[1-1]*this.l1[2-1])))) {
message("the first dimension of the output is too big");
ok = false;
}
- if (((out[2-1]>(l1[1-1]*l1[2-1])))) {
+ if (((this.out[2-1]>(this.l1[1-1]*this.l1[2-1])))) {
message("the second dimension of the output is too big");
ok = false;
}
- if ((((out[2-1]*out[1-1])>(l1[1-1]*l1[2-1])))) {
+ if ((((this.out[2-1]*this.out[1-1])>(this.l1[1-1]*this.l1[2-1])))) {
message("the dimensions of the output are too big");
ok = false;
}
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_reshape";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_reshape";
ot = 2;
it = 2;
@@ -80,8 +80,8 @@ function MATRESH() {
ok = false;
}
if (ok) {
- label = lab;
- [model,graphics,ok] = set_io(model,graphics,list(l1,it),list(out,ot),[],[]);
+ label = this.lab;
+ [model,graphics,ok] = set_io(model,graphics,list(this.l1,it),list(this.out,ot),[],[]);
}
if (ok) {
funtyp = 4;
diff --git a/js/MatrixOp/MATRESH.pickle b/js/MatrixOp/MATRESH.pickle
index 0d1dde24..c19ab011 100644
--- a/js/MatrixOp/MATRESH.pickle
+++ b/js/MatrixOp/MATRESH.pickle
@@ -4,6 +4,14 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'out'
+p3
+aS'typ'
+p4
+aS'lab'
+p5
+aS'l1'
+p6
+atp7
+Rp8
. \ No newline at end of file
diff --git a/js/MatrixOp/MATSING.js b/js/MatrixOp/MATSING.js
index aefdb157..6c26c5b9 100644
--- a/js/MatrixOp/MATSING.js
+++ b/js/MatrixOp/MATSING.js
@@ -39,18 +39,18 @@ function MATSING() {
label[9-1] = [];
}
while (true) {
- [ok,typ,decomptyp,lab] = scicos_getvalue("Set MATSVD block parameters",[["Datatype(1=real double 2=Complex)"],["decomposition type (1=singular values 2=sing values+matrix U & V)"]],list("vec",1,"vec",1),label);
+ [ok,this.typ,this.decomptyp,this.lab] = scicos_getvalue("Set MATSVD block parameters",[["Datatype(1=real double 2=Complex)"],["decomposition type (1=singular values 2=sing values+matrix U & V)"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
- label = lab;
- if ((typ==1)) {
- if ((decomptyp==1)) {
+ label = this.lab;
+ if ((this.typ==1)) {
+ if ((this.decomptyp==1)) {
function_name = "mat_sing";
in1 = [-1,-2];
out = [-1,1];
ot = 1;
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "mat_svd";
in1 = [-1,-2];
out = [[-1,-1],[-1,-2],[-2,-2]];
@@ -60,13 +60,13 @@ function MATSING() {
ok = false;
}
it = 1;
- } else if ((typ==2)) {
- if ((decomptyp==1)) {
+ } else if ((this.typ==2)) {
+ if ((this.decomptyp==1)) {
function_name = "matz_sing";
in1 = [-1,-2];
out = [-1,1];
ot = 1;
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "matz_svd";
in1 = [-1,-2];
out = [[-1,-1],[-1,-2],[-2,-2]];
diff --git a/js/MatrixOp/MATSING.pickle b/js/MatrixOp/MATSING.pickle
index 0d1dde24..a200ffa9 100644
--- a/js/MatrixOp/MATSING.pickle
+++ b/js/MatrixOp/MATSING.pickle
@@ -4,6 +4,12 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+aS'lab'
+p4
+aS'decomptyp'
+p5
+atp6
+Rp7
. \ No newline at end of file
diff --git a/js/MatrixOp/MATSUM.js b/js/MatrixOp/MATSUM.js
index dee13795..ad5cb933 100644
--- a/js/MatrixOp/MATSUM.js
+++ b/js/MatrixOp/MATSUM.js
@@ -39,19 +39,19 @@ function MATSUM() {
label[9-1] = [];
}
while (true) {
- [ok,typ,decomptyp,lab] = scicos_getvalue("Set MATSUM block parameters",[["Datatype(1=real double 2=Complex)"],["Sum along (0=all 1=lines 2=Columns)"]],list("vec",1,"vec",1),label);
+ [ok,this.typ,this.decomptyp,this.lab] = scicos_getvalue("Set MATSUM block parameters",[["Datatype(1=real double 2=Complex)"],["Sum along (0=all 1=lines 2=Columns)"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
- label = lab;
- if ((typ==1)) {
- if ((decomptyp==0)) {
+ label = this.lab;
+ if ((this.typ==1)) {
+ if ((this.decomptyp==0)) {
function_name = "mat_sum";
out = [1,1];
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "mat_suml";
out = [-1,1];
- } else if ((decomptyp==1)) {
+ } else if ((this.decomptyp==1)) {
function_name = "mat_sumc";
out = [1,-2];
} else {
@@ -60,14 +60,14 @@ function MATSUM() {
}
it = 1;
ot = 1;
- } else if ((typ==2)) {
- if ((decomptyp==0)) {
+ } else if ((this.typ==2)) {
+ if ((this.decomptyp==0)) {
function_name = "matz_sum";
out = [1,1];
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "matz_suml";
out = [-1,1];
- } else if ((decomptyp==1)) {
+ } else if ((this.decomptyp==1)) {
function_name = "matz_sumc";
out = [1,-2];
} else {
diff --git a/js/MatrixOp/MATSUM.pickle b/js/MatrixOp/MATSUM.pickle
index 0d1dde24..a200ffa9 100644
--- a/js/MatrixOp/MATSUM.pickle
+++ b/js/MatrixOp/MATSUM.pickle
@@ -4,6 +4,12 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+aS'lab'
+p4
+aS'decomptyp'
+p5
+atp6
+Rp7
. \ No newline at end of file
diff --git a/js/MatrixOp/MATTRAN.js b/js/MatrixOp/MATTRAN.js
index 3baaa628..b93447cc 100644
--- a/js/MatrixOp/MATTRAN.js
+++ b/js/MatrixOp/MATTRAN.js
@@ -27,16 +27,16 @@ function MATTRAN() {
label[2-1] = sci2exp(1);
}
while (true) {
- [ok,typ,rule,exprs] = scicos_getvalue("Set MATTRAN Block",[["Datatype(1=real double 2=Complex)"],["rule (1=.\' 2=\')"]],list("vec",1,"vec",1),label);
+ [ok,this.typ,this.rule,exprs] = scicos_getvalue("Set MATTRAN Block",[["Datatype(1=real double 2=Complex)"],["rule (1=.\' 2=\')"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mattran_m";
ot = 1;
it = 1;
- } else if ((typ==2)) {
- if (rule==1) {
+ } else if ((this.typ==2)) {
+ if (this.rule==1) {
function_name = "matztran_m";
} else {
function_name = "mathermit_m";
diff --git a/js/MatrixOp/MATTRAN.pickle b/js/MatrixOp/MATTRAN.pickle
index 0d1dde24..9e238f36 100644
--- a/js/MatrixOp/MATTRAN.pickle
+++ b/js/MatrixOp/MATTRAN.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+aS'rule'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/MATZREIM.js b/js/MatrixOp/MATZREIM.js
index a2f7ea3b..58cb5d71 100644
--- a/js/MatrixOp/MATZREIM.js
+++ b/js/MatrixOp/MATZREIM.js
@@ -39,18 +39,18 @@ function MATZREIM() {
label[9-1] = [];
}
while (true) {
- [ok,decomptyp,lab] = scicos_getvalue("Set MATZREIM block parameters",["decomposition type (1=Complex2Real&Imag 2=Real&Imag2Complex)"],list("vec",1),label);
+ [ok,this.decomptyp,this.lab] = scicos_getvalue("Set MATZREIM block parameters",["decomposition type (1=Complex2Real&Imag 2=Real&Imag2Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- label = lab;
- if ((decomptyp==1)) {
+ label = this.lab;
+ if ((this.decomptyp==1)) {
function_name = "matz_reim";
in1 = [-1,-2];
it = 2;
out = [[-1,-2],[-1,-2]];
ot = [1,1];
- } else if ((decomptyp==2)) {
+ } else if ((this.decomptyp==2)) {
function_name = "matz_reimc";
in1 = [[-1,-2],[-1,-2]];
it = [1,1];
diff --git a/js/MatrixOp/MATZREIM.pickle b/js/MatrixOp/MATZREIM.pickle
index 0d1dde24..92ce3a57 100644
--- a/js/MatrixOp/MATZREIM.pickle
+++ b/js/MatrixOp/MATZREIM.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'lab'
+p3
+aS'decomptyp'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/RICC.js b/js/MatrixOp/RICC.js
index 44e698eb..f4553a71 100644
--- a/js/MatrixOp/RICC.js
+++ b/js/MatrixOp/RICC.js
@@ -39,7 +39,7 @@ function RICC() {
label[9-1] = [];
}
while (true) {
- [ok,tpe,mod,exprs] = scicos_getvalue("Set RICC Block",[["Type (1=Cont 2=Disc)"],["Model(1=Schr 2=sign(cont) inv(disc))"]],list("vec",1,"vec",1),label);
+ [ok,this.tpe,this.mod,exprs] = scicos_getvalue("Set RICC Block",[["Type (1=Cont 2=Disc)"],["Model(1=Schr 2=sign(cont) inv(disc))"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
@@ -50,7 +50,7 @@ function RICC() {
label = exprs;
[model,graphics,ok] = set_io(model,graphics,list(in1,it),list(out,ot),[],[]);
if (ok) {
- model.ipar = [[tpe],[mod]];
+ model.ipar = [[this.tpe],[this.mod]];
graphics.exprs = label;
arg1.graphics = graphics;
arg1.model = model;
diff --git a/js/MatrixOp/RICC.pickle b/js/MatrixOp/RICC.pickle
index 0d1dde24..d514a4ad 100644
--- a/js/MatrixOp/RICC.pickle
+++ b/js/MatrixOp/RICC.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'tpe'
+p3
+aS'mod'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/ROOTCOEF.js b/js/MatrixOp/ROOTCOEF.js
index 7f17176d..44a382f0 100644
--- a/js/MatrixOp/ROOTCOEF.js
+++ b/js/MatrixOp/ROOTCOEF.js
@@ -39,15 +39,15 @@ function ROOTCOEF() {
label[9-1] = [];
}
while (true) {
- [ok,typ,inp,exprs] = scicos_getvalue("Set ROOTCOEF Block",[["Datatype(1=real double 2=Complex)"],["input row size"]],list("vec",1,"vec",1),label);
+ [ok,this.typ,this.inp,exprs] = scicos_getvalue("Set ROOTCOEF Block",[["Datatype(1=real double 2=Complex)"],["input row size"]],list("vec",1,"vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "root_coef";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "rootz_coef";
ot = 2;
it = 2;
@@ -55,8 +55,8 @@ function ROOTCOEF() {
message("Datatype is not supported");
ok = false;
}
- in1 = [inp,model.in2];
- out = [inp+1,model.out2];
+ in1 = [this.inp,model.in2];
+ out = [this.inp+1,model.out2];
funtyp = 4;
if (ok) {
label = exprs;
diff --git a/js/MatrixOp/ROOTCOEF.pickle b/js/MatrixOp/ROOTCOEF.pickle
index 0d1dde24..dd42296d 100644
--- a/js/MatrixOp/ROOTCOEF.pickle
+++ b/js/MatrixOp/ROOTCOEF.pickle
@@ -4,6 +4,10 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'inp'
+p3
+aS'typ'
+p4
+atp5
+Rp6
. \ No newline at end of file
diff --git a/js/MatrixOp/SQRT.js b/js/MatrixOp/SQRT.js
index 4dba0fcd..f3ead18e 100644
--- a/js/MatrixOp/SQRT.js
+++ b/js/MatrixOp/SQRT.js
@@ -26,20 +26,20 @@ function SQRT() {
label = graphics.exprs;
model = arg1.model;
while (true) {
- [ok,typ,exprs] = scicos_getvalue("Set SQRT Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
+ [ok,this.typ,exprs] = scicos_getvalue("Set SQRT Block",["Datatype(1=real double 2=Complex)"],list("vec",1),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "mat_sqrt";
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "matz_sqrt";
} else {
message("type is not supported");
ok = false;
}
- it = typ;
- ot = typ;
+ it = this.typ;
+ ot = this.typ;
in1 = [model.in1,model.in2];
out = [model.out,model.out2];
funtyp = 4;
diff --git a/js/MatrixOp/SQRT.pickle b/js/MatrixOp/SQRT.pickle
index 0d1dde24..86921c4a 100644
--- a/js/MatrixOp/SQRT.pickle
+++ b/js/MatrixOp/SQRT.pickle
@@ -4,6 +4,8 @@ p0
((lp1
S'x'
p2
-atp3
-Rp4
+aS'typ'
+p3
+atp4
+Rp5
. \ No newline at end of file
diff --git a/js/MatrixOp/SUBMAT.js b/js/MatrixOp/SUBMAT.js
index 9f9dcc68..fa74de90 100644
--- a/js/MatrixOp/SUBMAT.js
+++ b/js/MatrixOp/SUBMAT.js
@@ -39,15 +39,15 @@ function SUBMAT() {
label[6-1] = sci2exp([1,1]);
}
while (true) {
- [ok,typ,a,b,c,d,inp,exprs] = scicos_getvalue("Set SUBMAT Block",[["Datatype (1=real double 2=Complex)"],["Starting Row Index"],["Ending Row Index"],["Starting Column Index"],["Ending Column Index"],["Input Dimensions"]],list("vec",1,"vec",1,"vec",1,"vec",1,"vec",1,"vec",2),label);
+ [ok,this.typ,this.a,this.b,this.c,this.d,this.inp,exprs] = scicos_getvalue("Set SUBMAT Block",[["Datatype (1=real double 2=Complex)"],["Starting Row Index"],["Ending Row Index"],["Starting Column Index"],["Ending Column Index"],["Input Dimensions"]],list("vec",1,"vec",1,"vec",1,"vec",1,"vec",1,"vec",2),label);
if (!ok) {
break;
}
- if ((typ==1)) {
+ if ((this.typ==1)) {
function_name = "submat";
ot = 1;
it = 1;
- } else if ((typ==2)) {
+ } else if ((this.typ==2)) {
function_name = "submatz";
ot = 2;
it = 2;
@@ -55,29 +55,29 @@ function SUBMAT() {
message("Datatype is not supported");
ok = false;
}
- if ((a<=0)||(b<=0)||(c<=0)||(d<=0)) {
+ if ((this.a<=0)||(this.b<=0)||(this.c<=0)||(this.d<=0)) {
message("invalid index");
ok = false;
}
- if (b<a) {
+ if (this.b<this.a) {
message("ending row must be greater than starting row");
ok = false;
}
- if (d<c) {
+ if (this.d<this.c) {
message("ending column must be greater than starting column");
ok = false;
}
- if (b>inp[1-1]) {
+ if (this.b>this.inp[1-1]) {
message("index of ending row is out of range");
ok = false;
}
- if (d>inp[2-1]) {
+ if (this.d>this.inp[2-1]) {
message("index of ending column is out of range");
ok = false;
}
- model.ipar = [[a],[b],[c],[d]];
- in1 = [inp[1-1],inp[2-1]];
- out = [(b-a)+1,(d-c)+1];
+ model.ipar = [[this.a],[this.b],[this.c],[this.d]];
+ in1 = [this.inp[1-1],this.inp[2-1]];
+ out = [(this.b-this.a)+1,(this.d-this.c)+1];
funtyp = 4;
label = exprs;
if (ok) {
diff --git a/js/MatrixOp/SUBMAT.pickle b/js/MatrixOp/SUBMAT.pickle
index 0d1dde24..c63ca321 100644
--- a/js/MatrixOp/SUBMAT.pickle
+++ b/js/MatrixOp/SUBMAT.pickle
@@ -2,8 +2,20 @@ c__builtin__
set
p0
((lp1
-S'x'
+S'a'
p2
-atp3
-Rp4
+aS'c'
+p3
+aS'b'
+p4
+aS'd'
+p5
+aS'inp'
+p6
+aS'x'
+p7
+aS'typ'
+p8
+atp9
+Rp10
. \ No newline at end of file