Basic Loop Problem - Nodes in a system

2 次查看(过去 30 天)
Jack
Jack 2015-2-26
Hi,
Here is my code:
freedof=[Bl,BR,TL,TR];
for i=Bl+1:BR-1;
freedof=[3*i-2 3i-1 3i];
end
for i = BR+1:1:TL-1
end
for i=TL+1:1:TR-1
end
where Bl,BR,TL,TR are previously defined as simple positive numbers. I am trying to create a matrix, for example if Bl = 1 BR = 2 TL = 3 TR = 4 the I need to return a matrix of [1 2 3 4 5 6 7 8 9 10 11 12] i.e 3i-2 3i-1 3i for each defined input (BL etc).
Any help would be much appreciated :) Thanks.

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Multidimensional Arrays 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by