MATLAB: How can i combined array automatically

cell arraysMATLAB

a = [100, 125, 150, 175, 200, 225, 250, 275, 300, 325];
for k = 1: numel(a)
Fx{:,:,k} = a(k:numel(a))
end
Tx = [Fx{:,:,1},Fx{:,:,2},Fx{:,:,3},Fx{:,:,4},Fx{:,:,5},Fx{:,:,6},Fx{:,:,7},Fx{:,:,8},Fx{:,:,9},Fx{:,:,10}];
i want to generate Tx automatically without manual input

Best Answer

>> tmp = a(:)*ones(1,numel(a));
>> Tx = tmp(tril(true(numel(a))))
Tx =
100
125
150
175
200
225
250
275
300
325
125
150
175
200
225
250
275
300
325
150
175
200
225
250
275
300
325
175
200
225
250
275
300
325
200
225
250
275
300
325
225
250
275
300
325
250
275
300
325
275
300
325
300
325
325
>>
Related Question