MATLAB: Do i get this error about cell arrays

cell arraysjacobinon-cell array

for i = 1:1000
P{i+1} = inv(eye(m).*A)*T*P{i}+ inv(eye(m).*A)*B;
P{i+1}=P{i};
end
When i execute this code i get Cell contents reference from a non-cell array object error. Help pls

Best Answer

a=10
a{1}=1 % will give an error
% to avoid error
clear a
a{1}=1