MATLAB: How to fix matrices while using ssest

parametersssest

Hey everyone,
I try to estimate the A-matrix out of a data set constisting of the states and the human input. The other matrices B C D are given, so I want to fix them while using the command ssest.
Code:
A = NaN*ones(n); B = [1; zeros(n-1,1)]; C = eye(n); D = zeros(n,1); K = zeros(n);
dt= 0.01;
n=3;
q0= zeros(n,2);
sys_initial = idss(A,B,C,D,K,q0(:,1),dt);
sys_initial.Structure.B.Free = false;
sys_initial.Structure.C.Free = false;
sys_initial.Structure.D.Free = false;
sys_initial.Structure.K.Free = false;
sys_ssest = ssest(data,sys_initial);
The problem is, that the matrices B and C in sys_ssest change their values but this should not happen. Even bounding with
sys_initial.Structure.B.Minimum = B;
sys_initial.Structure.C.Minimum = C;
sys_initial.Structure.B.Maximum = B;
sys_initial.Structure.C.Maximum = C;
did not help at all. How can I solve this problem?
Thank you in advance!

Best Answer

Problem solved by removing the factor NaN in matrix A