Subscript indices must either be real positive integers or logicals.
1 次查看(过去 30 天)
显示 更早的评论
k_est=k_p(bb,:);
XF_est=xf(bb).XF;
num_2=num_2+1;
kkk2(num_2,:)=k_est;
for iii=1:length(k_est)
X_re(k_est(iii))=XF_est(iii);
end
what is the problem in my four loop
0 个评论
回答(1 个)
Star Strider
2016-7-1
What is k_est and what is its size (what are its dimensions)?
2 个评论
Walter Roberson
2016-7-2
If k_est is a complex double, then how can you use it to index X_re in your statement
X_re(k_est(iii))=XF_est(iii);
??
Are you trying to define a "formula", sort of like a definition that for function f,
f(sqrt(2)) = 4.1293;
f(3.5) = 7.893;
?? If you are, then that is not possible in MATLAB, except in the case of a symbolic function being defined.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Array Geometries and Analysis 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!