summaryrefslogtreecommitdiff
path: root/2.3-1/tests/unit_tests/float/test_float_Spec.sci
diff options
context:
space:
mode:
authorSandeep Gupta2017-06-18 23:55:40 +0530
committerSandeep Gupta2017-06-18 23:55:40 +0530
commitb43eccd4cffed5bd1017c5821524fb6e49202f78 (patch)
tree4c53d798252cbeae9bcf7dc9604524b20bb10f27 /2.3-1/tests/unit_tests/float/test_float_Spec.sci
downloadScilab2C-b43eccd4cffed5bd1017c5821524fb6e49202f78.tar.gz
Scilab2C-b43eccd4cffed5bd1017c5821524fb6e49202f78.tar.bz2
Scilab2C-b43eccd4cffed5bd1017c5821524fb6e49202f78.zip
First commit
Diffstat (limited to '2.3-1/tests/unit_tests/float/test_float_Spec.sci')
-rw-r--r--2.3-1/tests/unit_tests/float/test_float_Spec.sci42
1 files changed, 42 insertions, 0 deletions
diff --git a/2.3-1/tests/unit_tests/float/test_float_Spec.sci b/2.3-1/tests/unit_tests/float/test_float_Spec.sci
new file mode 100644
index 00000000..42041925
--- /dev/null
+++ b/2.3-1/tests/unit_tests/float/test_float_Spec.sci
@@ -0,0 +1,42 @@
+//SCI2C: DEFAULT_PRECISION= FLOAT
+function test_float_Spec()
+
+
+ disp(spec(45)) ; // d0Spec
+ disp(spec(4+3*%i)); // z0Spec
+
+ a = [1 2 3; -4 5 98 ; 7 8 5] ;
+ b = [1 2 3; -4 5 98 ; 7 -100000 5] ;
+
+
+ disp(spec(a));
+ disp(spec(b));
+
+ disp(spec(a*%i));
+ // 2 outputs
+
+ [aa bb] = spec(45) ; // d0Spec
+ disp(aa);
+ disp(bb);
+
+ [cc dd] = spec(4+3*%i); // z0Spec
+
+ disp(cc);
+ disp(dd);
+
+ a = [1 2 3; -4 5 98 ; 7 8 5] ;
+ b = [1 2 3; -4 5 98 ; 7 -100000 5] ;
+
+
+ [ee ff] = spec(a);
+ disp(ee);
+ disp(ff);
+ [gg hh] = spec(b);
+ disp(gg);
+ disp(hh);
+
+ [ii jj] = spec(a*%i);
+ disp(ii);
+ disp(jj);
+
+endfunction