parse error at '[', '=',')'.

조회 수: 12 (최근 30일)
ac_09
ac_09 2017년 12월 11일
댓글: ac_09 2017년 12월 11일
I am getting error at "b[j]=norm(X,1);" as: parse error at '[', '=',')'. How should i rectify it?
function [b]=rf(l,k,H,d)
b=zeros(1,Nu);
for j=0:Nu-1
X= H'*d(:,j);
b[j]=norm(X,1);
end
end

채택된 답변

Birdman
Birdman 2017년 12월 11일
b[j]=norm(X,1);
This line should be
b(j)=norm(X,1);
  댓글 수: 1
ac_09
ac_09 2017년 12월 11일
thanks again

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Call Python from MATLAB에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by