summaryrefslogtreecommitdiff
path: root/macros/schurrc.sci~
diff options
context:
space:
mode:
authorttt2018-05-04 14:17:52 +0530
committerttt2018-05-04 14:17:52 +0530
commite0ee212228386544ca248f0893d001107775ec4b (patch)
treec8648ca62b221da49af8eae94c2a6e2976c72f6e /macros/schurrc.sci~
parent9d4f22fb6e70ffdbeda496faf516a0c10f0b6133 (diff)
downloadFOSSEE-Signal-Processing-Toolbox-e0ee212228386544ca248f0893d001107775ec4b.tar.gz
FOSSEE-Signal-Processing-Toolbox-e0ee212228386544ca248f0893d001107775ec4b.tar.bz2
FOSSEE-Signal-Processing-Toolbox-e0ee212228386544ca248f0893d001107775ec4b.zip
deleted *~ files
Diffstat (limited to 'macros/schurrc.sci~')
-rw-r--r--macros/schurrc.sci~49
1 files changed, 0 insertions, 49 deletions
diff --git a/macros/schurrc.sci~ b/macros/schurrc.sci~
deleted file mode 100644
index 71beb39..0000000
--- a/macros/schurrc.sci~
+++ /dev/null
@@ -1,49 +0,0 @@
-//schurrc - Schur algorithm.
-//K = SCHURRC(R) computes the reflection coefficients from autocorrelation vector R. If R is a matrix, SCHURRC finds coefficients for each column of R, and returns them in the columns of K.
-//[K,E] = SCHURRC(R) returns the prediction error variance E. If R is a matrix, SCHURRC finds the error for each column of R, and returns them in the rows of E.
-//Modified to match matlab i/p and o/p and handle exceptions
-//Fixed bugs
-//by Debdeep Dey
-function [k,e] = schurrc(R)
- narginchk(1,1,argn(2));
-if(type(R)==10) then
- w=R;
- [nr,nc]=size(R);
- if(nr==1 & nc==1) then
- R=ascii(R);
- R=matrix(R,length(w));
- else
-
- R=ascii(R);
- R=matrix(R,size(w));
- end
-
-end
-if(type(R) > 1) then
- error('Input R is not a matrix')
-end
-if (min(size(R)) == 1) then
- R = R(:);
-end
-[m,n] = size(R);
-// Compute reflection coefficients for each column of the input matrix
-for j = 1:n
- X = R(:,j).';
- // Schur's iterative algorithm on a row vector of autocorrelation values
- U = [0 X(2:m); X(1:m)];
-
- for i = 2:m,
- U(2,:) = [0 U(2,1:m-1)];
- k(i-1,j) = -U(1,i)/U(2,i);
- U = [1 k(i-1,j); conj(k(i-1,j)) 1]*U;
- end
-
- e(j,1) = U(2,$);
-end
-endfunction
-function narginchk(l,h,t)
- if t<l then
- error("Too few input arguments");
- elseif t>l then
- error("Too many i/p arguments");
- end