⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ldlt.m

📁 统计自适应信号处理的matlab程序
💻 M
字号:
function [L,D]=ldlt(R)
% function [L,D]=ldlt(R)
% Computes the LDU decomposition of a 
% symmetric positive definite matrix.
%
% Programmed by: Dimitris Manolakis, 1996
%
%-----------------------------------------------------------
% Copyright 2000, by Dimitris G. Manolakis, Vinay K. Ingle,
% and Stephen M. Kogon.  For use with the book
% "Statistical and Adaptive Signal Processing"
% McGraw-Hill Higher Education.
%-----------------------------------------------------------



M=length(R);
L=zeros(M,M);
for m=1:M L(m,m)=1; end
D=zeros(M,1);

D(1)=R(1,1);
L(2,1)=R(2,1)/D(1);
D(2)=R(2,2)-D(1)*L(2,1)*L(2,1);

for j=3:M
  for i=1:j-1
    L(j,i)=R(j,i);
    for k=1:i-1 L(j,i)=L(j,i)-D(k)*L(j,k)*L(i,k); end
    L(j,i)=L(j,i)/D(i);
  end
  D(j)=R(j,j);
  for k=1:j-1 D(j)=D(j)-D(k)*L(j,k)*L(j,k); end
end

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -