summaryrefslogtreecommitdiff
path: root/js/Sources/RAND_m.js
diff options
context:
space:
mode:
authorSunil Shetye2018-07-16 18:13:55 +0530
committerSunil Shetye2018-07-18 11:36:15 +0530
commit8ce53461fe09f5102deeaedbb87bfc0d4f996ed2 (patch)
tree6b766b7c32effff12fa48cff99f11b9420136610 /js/Sources/RAND_m.js
parent5929c9088b6d5dcd23e8bbf9abdc5c9b4a49df1f (diff)
downloadsci2js-8ce53461fe09f5102deeaedbb87bfc0d4f996ed2.tar.gz
sci2js-8ce53461fe09f5102deeaedbb87bfc0d4f996ed2.tar.bz2
sci2js-8ce53461fe09f5102deeaedbb87bfc0d4f996ed2.zip
move the options in the loop
Diffstat (limited to 'js/Sources/RAND_m.js')
-rw-r--r--js/Sources/RAND_m.js14
1 files changed, 7 insertions, 7 deletions
diff --git a/js/Sources/RAND_m.js b/js/Sources/RAND_m.js
index f5753151..0e1fdf00 100644
--- a/js/Sources/RAND_m.js
+++ b/js/Sources/RAND_m.js
@@ -43,18 +43,18 @@ function RAND_m() {
return options;
}
RAND_m.prototype.set = function RAND_m() {
- this.typ = inverse(arguments[0]["typ"])
- this.flag = parseFloat(arguments[0]["flag"])
- this.a = parseFloat(arguments[0]["a"])
- this.b = parseFloat(arguments[0]["b"])
- this.seed_c = arguments[0]["seed_c"]
- this.exprs = arguments[0]["exprs"]
this.exprs = this.graphics.exprs;
if (size(this.exprs,"*")==14) {
this.exprs[9-1] = [];
}
while (true) {
- [ok,this.typ,this.flag,this.a,this.b,this.seed_c,this.exprs] = scicos_getvalue([["Set Random generator block parameters"],["flag = 0 : Uniform distribution A is min and A+B max"],["flag = 1 : Normal distribution A is mean and B deviation"],[" "],["A and B must be matrix with equal sizes"]],["Datatype(1=real double 2=complex)","flag","A","B","SEED"],list("vec",1,"vec",1,"mat",[-1,-2],"mat","[-1 -2]","mat",[1,2]),this.exprs);
+ var ok = true;
+ this.typ = inverse(arguments[0]["typ"]);
+ this.flag = parseFloat(arguments[0]["flag"]);
+ this.a = parseFloat(arguments[0]["a"]);
+ this.b = parseFloat(arguments[0]["b"]);
+ this.seed_c = arguments[0]["seed_c"];
+ this.exprs = arguments[0]["exprs"];
if (!ok) {
break;
}