gusucode.com > wlan工具箱matlab源码程序 > wlan/wlanexamples/vhtCSIFeedback.m
function mat = vhtCSIFeedback(rxSig, cfgVHT, userNum, numSTSVec) % Computes the channel state information (CSI) feedback matrix per user, % for each subcarrier. % Copyright 2016 The MathWorks, Inc. chanBW = cfgVHT.ChannelBandwidth; ind = wlanFieldIndices(cfgVHT); % Estimate channel rxVHTLTF = rxSig(ind.VHTLTF(1):ind.VHTLTF(2),:); demodVHTLTF = wlanVHTLTFDemodulate(rxVHTLTF, chanBW, sum(numSTSVec)); chanEst = wlanVHTLTFChannelEstimate(demodVHTLTF, chanBW, sum(numSTSVec)); % Nst-by-Nsts-by-Nr % Remove cyclic shift effect from the channel estimate chanEstMinusCSD = vhtBeamformingRemoveCSD(chanEst, chanBW, sum(numSTSVec)); % Nst-by-Nsts-by-Nr chanEstPerm = permute(chanEstMinusCSD, [3 2 1]); % Nr-by-Nsts-by-Nst % Compute the feedback matrix using singular value decomposition % for the streams allocated to the user V = zeros(length(chanEst), sum(numSTSVec), numSTSVec(userNum)); % Nst-by-Nsts-by-Nr for i = 1:length(chanEst) [~, ~, V(i,:,:)] = svd(chanEstPerm(:,:,i), 'econ'); end mat = V; end % [EOF]