Unable to perform assignment because the size of the left side is 1-by-35 and the size of the right side is 1-by-39

1 次查看(过去 30 天)
for(SFRtype=SINUSOID);
dwmin(i)=ytN(tmin(i),param);
end
bilbus1=bilbus1+1;
for j=1:k
dataA1(bilbus1,:)=[bilbus1 fobj1 x dwmin tmin tau sum_dP wss] %error in this line
end
end

回答(1 个)

Image Analyst
Image Analyst 2020-2-7
It's just normal debugging. You need to figure out what all the sizes of those variables are and why you're creating a row vector with 39 elements and trying to stuff it into the "bilbus1" row of a matrix that has only 35 elements. If you still can't figure it out, tell us size of bilbus1, fobj1, x, dwmin, tmin, tau, sum_dP, and wss are, and we'll add up the lengths and show you how it equals 39. But why you're concatenating so many variables, or variables of the unintended size(s), we won't know. Only you'll know that.

类别

Help CenterFile Exchange 中查找有关 Bounding Regions 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by