From c2987d9ea311a62a56427beae3a451b860620a62 Mon Sep 17 00:00:00 2001 From: Sandeep Gupta Date: Fri, 7 Jul 2017 01:39:22 +0530 Subject: SVD Function --- .../unit_tests/testLinearAlgebra/testsvd/testsvdrank.sci | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 2.3-1/tests/unit_tests/testLinearAlgebra/testsvd/testsvdrank.sci (limited to '2.3-1/tests/unit_tests/testLinearAlgebra/testsvd/testsvdrank.sci') diff --git a/2.3-1/tests/unit_tests/testLinearAlgebra/testsvd/testsvdrank.sci b/2.3-1/tests/unit_tests/testLinearAlgebra/testsvd/testsvdrank.sci new file mode 100644 index 00000000..108acde8 --- /dev/null +++ b/2.3-1/tests/unit_tests/testLinearAlgebra/testsvd/testsvdrank.sci @@ -0,0 +1,13 @@ +function testsvdrank() + disp(" ** SVD Function (Singular Value Decomposition)** ") + A = [1,2,3,11;4,5,6,12;7,8,9,13] // Matrix - A + [u,s,vt,rk] = svd(A) // Calling Function Sequence + disp("U Matrix") + disp(u) // A = U*sigma*Vt + disp("Sigma Matrix") + disp(s) + disp(" V transpose ") + disp(vt) + disp("Rank") + disp(rk) +endfunction -- cgit