压缩感知中贪婪算法之MP和OMP

压缩感知中贪婪算法之MP和OMP

1、 Matching Pusuit(匹配追踪):

在这里插入图片描述
MP是最简单的追踪算法之一,每次只从A中选取一列,每步迭代时就更新该列所对应的系数。但是,MP一般会反复选择矩阵A的同一列,以进一步减小逼近的误差。因此,算法复杂度较高。

Matlab代码实现如下:

function x = CS_MP(y, A, t )
  % Matching Pursuit
  %
  %   y = Phi * x
  %   x = Psi * theta
  %	  y = Phi*Psi * theta
  %   令 A = Phi*Psi, 则y=A*theta

    [y_rows,y_columns] = size(y);
    if y_rows<y_columns
        y = y';%y should be a column vector
    end
  R = y;
  for i = 1 : t
    AHR = A' * R;  % Hermitian Transpose times b is dot product with dictionary vectors
    if i==1, x = zeros( size( AHR ) ); end
    [~,maxIndx] = max( abs( AHR ) );
    alpha = AHR( maxIndx );
    x( maxIndx ) = alpha;
    R = R
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值