diff options
Diffstat (limited to 'js/IntegerOp/CONVERT.js')
-rw-r--r-- | js/IntegerOp/CONVERT.js | 274 |
1 files changed, 137 insertions, 137 deletions
diff --git a/js/IntegerOp/CONVERT.js b/js/IntegerOp/CONVERT.js index b6a29de9..9b1f363f 100644 --- a/js/IntegerOp/CONVERT.js +++ b/js/IntegerOp/CONVERT.js @@ -3,16 +3,16 @@ function CONVERT() { CONVERT.prototype.define = function CONVERT() { sgn = 2; this.model = scicos_model(); - this.model.sim = list(new ScilabString("convert"),new ScilabDouble(4)); - this.model.in1 = new ScilabDouble(-1); - this.model.out = new ScilabDouble(-1); - this.model.in2 = new ScilabDouble(-2); - this.model.out2 = new ScilabDouble(-2); - this.model.intyp = new ScilabDouble(1); - this.model.outtyp = new ScilabDouble(3); + this.model.sim = list(new ScilabString(["convert"]), new ScilabDouble([4])); + this.model.in1 = new ScilabDouble([-1]); + this.model.out = new ScilabDouble([-1]); + this.model.in2 = new ScilabDouble([-2]); + this.model.out2 = new ScilabDouble([-2]); + this.model.intyp = new ScilabDouble([1]); + this.model.outtyp = new ScilabDouble([3]); this.model.rpar = []; - this.model.ipar = new ScilabDouble(sgn); - this.model.blocktype = new ScilabString("c"); + this.model.ipar = new ScilabDouble([sgn]); + this.model.blocktype = new ScilabString(["c"]); this.model.dep_ut = [true,false]; exprs = [[sci2exp(1)],[sci2exp(3)],[sci2exp(0)]]; gr_i = []; @@ -59,308 +59,308 @@ function CONVERT() { block_parameter_error(msprintf("Wrong value for \'%s\' parameter: %d.","Output Type",this.ot),msprintf("Must be in the interval %s.","[1, 8]")); ok = false; } - this.model.sim = list(new ScilabString("convert"),new ScilabDouble(4)); + this.model.sim = list(new ScilabString(["convert"]), new ScilabDouble([4])); if ((this.it==this.ot)) { - this.model.ipar = new ScilabDouble(1); + this.model.ipar = new ScilabDouble([1]); } else { if ((this.np==0)) { if ((this.it==1)) { if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(2); + this.model.ipar = new ScilabDouble([2]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(3); + this.model.ipar = new ScilabDouble([3]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(4); + this.model.ipar = new ScilabDouble([4]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(5); + this.model.ipar = new ScilabDouble([5]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(6); + this.model.ipar = new ScilabDouble([6]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(7); + this.model.ipar = new ScilabDouble([7]); } } else if ((this.it==3)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(8); + this.model.ipar = new ScilabDouble([8]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(9); + this.model.ipar = new ScilabDouble([9]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(10); + this.model.ipar = new ScilabDouble([10]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(1); + this.model.ipar = new ScilabDouble([1]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(11); + this.model.ipar = new ScilabDouble([11]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(12); + this.model.ipar = new ScilabDouble([12]); } } else if ((this.it==4)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(13); + this.model.ipar = new ScilabDouble([13]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(14); + this.model.ipar = new ScilabDouble([14]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(15); + this.model.ipar = new ScilabDouble([15]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(16); + this.model.ipar = new ScilabDouble([16]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(1); + this.model.ipar = new ScilabDouble([1]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(17); + this.model.ipar = new ScilabDouble([17]); } } else if ((this.it==5)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(18); + this.model.ipar = new ScilabDouble([18]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(19); + this.model.ipar = new ScilabDouble([19]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(20); + this.model.ipar = new ScilabDouble([20]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(21); + this.model.ipar = new ScilabDouble([21]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(22); + this.model.ipar = new ScilabDouble([22]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(1); + this.model.ipar = new ScilabDouble([1]); } } else if ((this.it==6)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(23); + this.model.ipar = new ScilabDouble([23]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(1); + this.model.ipar = new ScilabDouble([1]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(24); + this.model.ipar = new ScilabDouble([24]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(25); + this.model.ipar = new ScilabDouble([25]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(26); + this.model.ipar = new ScilabDouble([26]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(27); + this.model.ipar = new ScilabDouble([27]); } } else if ((this.it==7)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(28); + this.model.ipar = new ScilabDouble([28]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(29); + this.model.ipar = new ScilabDouble([29]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(1); + this.model.ipar = new ScilabDouble([1]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(30); + this.model.ipar = new ScilabDouble([30]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(31); + this.model.ipar = new ScilabDouble([31]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(32); + this.model.ipar = new ScilabDouble([32]); } } else if ((this.it==8)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(33); + this.model.ipar = new ScilabDouble([33]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(34); + this.model.ipar = new ScilabDouble([34]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(35); + this.model.ipar = new ScilabDouble([35]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(1); + this.model.ipar = new ScilabDouble([1]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(36); + this.model.ipar = new ScilabDouble([36]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(37); + this.model.ipar = new ScilabDouble([37]); } } } else if ((this.np==1)) { if ((this.it==1)) { if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(38); + this.model.ipar = new ScilabDouble([38]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(39); + this.model.ipar = new ScilabDouble([39]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(40); + this.model.ipar = new ScilabDouble([40]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(41); + this.model.ipar = new ScilabDouble([41]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(42); + this.model.ipar = new ScilabDouble([42]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(43); + this.model.ipar = new ScilabDouble([43]); } } else if ((this.it==3)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(8); + this.model.ipar = new ScilabDouble([8]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(44); + this.model.ipar = new ScilabDouble([44]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(45); + this.model.ipar = new ScilabDouble([45]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(46); + this.model.ipar = new ScilabDouble([46]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(47); + this.model.ipar = new ScilabDouble([47]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(48); + this.model.ipar = new ScilabDouble([48]); } } else if ((this.it==4)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(13); + this.model.ipar = new ScilabDouble([13]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(14); + this.model.ipar = new ScilabDouble([14]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(49); + this.model.ipar = new ScilabDouble([49]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(50); + this.model.ipar = new ScilabDouble([50]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(51); + this.model.ipar = new ScilabDouble([51]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(52); + this.model.ipar = new ScilabDouble([52]); } } else if ((this.it==5)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(18); + this.model.ipar = new ScilabDouble([18]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(19); + this.model.ipar = new ScilabDouble([19]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(20); + this.model.ipar = new ScilabDouble([20]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(53); + this.model.ipar = new ScilabDouble([53]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(54); + this.model.ipar = new ScilabDouble([54]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(55); + this.model.ipar = new ScilabDouble([55]); } } else if ((this.it==6)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(23); + this.model.ipar = new ScilabDouble([23]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(56); + this.model.ipar = new ScilabDouble([56]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(57); + this.model.ipar = new ScilabDouble([57]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(58); + this.model.ipar = new ScilabDouble([58]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(59); + this.model.ipar = new ScilabDouble([59]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(60); + this.model.ipar = new ScilabDouble([60]); } } else if ((this.it==7)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(28); + this.model.ipar = new ScilabDouble([28]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(29); + this.model.ipar = new ScilabDouble([29]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(61); + this.model.ipar = new ScilabDouble([61]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(62); + this.model.ipar = new ScilabDouble([62]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(31); + this.model.ipar = new ScilabDouble([31]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(63); + this.model.ipar = new ScilabDouble([63]); } } else if ((this.it==8)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(33); + this.model.ipar = new ScilabDouble([33]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(34); + this.model.ipar = new ScilabDouble([34]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(35); + this.model.ipar = new ScilabDouble([35]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(64); + this.model.ipar = new ScilabDouble([64]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(36); + this.model.ipar = new ScilabDouble([36]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(37); + this.model.ipar = new ScilabDouble([37]); } } } else if ((this.np==2)) { if ((this.it==1)) { if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(65); + this.model.ipar = new ScilabDouble([65]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(66); + this.model.ipar = new ScilabDouble([66]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(67); + this.model.ipar = new ScilabDouble([67]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(68); + this.model.ipar = new ScilabDouble([68]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(69); + this.model.ipar = new ScilabDouble([69]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(70); + this.model.ipar = new ScilabDouble([70]); } } else if ((this.it==3)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(8); + this.model.ipar = new ScilabDouble([8]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(71); + this.model.ipar = new ScilabDouble([71]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(72); + this.model.ipar = new ScilabDouble([72]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(73); + this.model.ipar = new ScilabDouble([73]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(74); + this.model.ipar = new ScilabDouble([74]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(75); + this.model.ipar = new ScilabDouble([75]); } } else if ((this.it==4)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(13); + this.model.ipar = new ScilabDouble([13]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(14); + this.model.ipar = new ScilabDouble([14]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(76); + this.model.ipar = new ScilabDouble([76]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(77); + this.model.ipar = new ScilabDouble([77]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(78); + this.model.ipar = new ScilabDouble([78]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(79); + this.model.ipar = new ScilabDouble([79]); } } else if ((this.it==5)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(18); + this.model.ipar = new ScilabDouble([18]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(19); + this.model.ipar = new ScilabDouble([19]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(20); + this.model.ipar = new ScilabDouble([20]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(80); + this.model.ipar = new ScilabDouble([80]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(81); + this.model.ipar = new ScilabDouble([81]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(82); + this.model.ipar = new ScilabDouble([82]); } } else if ((this.it==6)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(23); + this.model.ipar = new ScilabDouble([23]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(83); + this.model.ipar = new ScilabDouble([83]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(84); + this.model.ipar = new ScilabDouble([84]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(85); + this.model.ipar = new ScilabDouble([85]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(86); + this.model.ipar = new ScilabDouble([86]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(87); + this.model.ipar = new ScilabDouble([87]); } } else if ((this.it==7)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(28); + this.model.ipar = new ScilabDouble([28]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(29); + this.model.ipar = new ScilabDouble([29]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(88); + this.model.ipar = new ScilabDouble([88]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(89); + this.model.ipar = new ScilabDouble([89]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(31); + this.model.ipar = new ScilabDouble([31]); } else if ((this.ot==8)) { - this.model.ipar = new ScilabDouble(90); + this.model.ipar = new ScilabDouble([90]); } } else if ((this.it==8)) { if ((this.ot==1)) { - this.model.ipar = new ScilabDouble(33); + this.model.ipar = new ScilabDouble([33]); } else if ((this.ot==3)) { - this.model.ipar = new ScilabDouble(34); + this.model.ipar = new ScilabDouble([34]); } else if ((this.ot==4)) { - this.model.ipar = new ScilabDouble(35); + this.model.ipar = new ScilabDouble([35]); } else if ((this.ot==5)) { - this.model.ipar = new ScilabDouble(91); + this.model.ipar = new ScilabDouble([91]); } else if ((this.ot==6)) { - this.model.ipar = new ScilabDouble(36); + this.model.ipar = new ScilabDouble([36]); } else if ((this.ot==7)) { - this.model.ipar = new ScilabDouble(37); + this.model.ipar = new ScilabDouble([37]); } } } |