diff options
author | Sunil Shetye | 2018-07-18 15:33:44 +0530 |
---|---|---|
committer | Sunil Shetye | 2018-07-18 17:07:40 +0530 |
commit | 4d1e8bb193a7315a8fcfe1e09c33befdee660b7d (patch) | |
tree | 360c93b86402e468a69d22fe3187d0809b095587 /js/NonLinear/INTRP2BLK_f.js | |
parent | bfa780421678e897b17680f3e7c5db72d8ea8375 (diff) | |
download | sci2js-4d1e8bb193a7315a8fcfe1e09c33befdee660b7d.tar.gz sci2js-4d1e8bb193a7315a8fcfe1e09c33befdee660b7d.tar.bz2 sci2js-4d1e8bb193a7315a8fcfe1e09c33befdee660b7d.zip |
add throw after message()
Diffstat (limited to 'js/NonLinear/INTRP2BLK_f.js')
-rw-r--r-- | js/NonLinear/INTRP2BLK_f.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/js/NonLinear/INTRP2BLK_f.js b/js/NonLinear/INTRP2BLK_f.js index 54bcb917..c192893c 100644 --- a/js/NonLinear/INTRP2BLK_f.js +++ b/js/NonLinear/INTRP2BLK_f.js @@ -40,8 +40,10 @@ function INTRP2BLK_f() { } if (size(this.a,"*")!=size(this.c,"c")||size(this.b,"*")!=size(this.c,"r")) { message("incompatible dimension"); + throw "user error"; } else if (min(this.a.slice(2-1,$)-this.a.slice(1-1,$-1))<=0||min(this.b.slice(2-1,$)-this.b.slice(1-1,$-1))<=0) { message("X and Y must be strictly increasing"); + throw "user error"; } else { if (ok) { this.graphics.exprs = new ScilabDouble([this.exprs]); |