fmincon "matrix dimensions must agree" error
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Brandon Campanile
am 7 Nov. 2018
Kommentiert: Ankita Chadha
am 7 Jun. 2021
I'm not going to post the entire code, but it can be seen in this Github repo on the "optimization" branch. Run the GUI and click the "Optimize" button to get the error, or you can just read the "optimization.m" file. The exact error is below; I was hoping someone could tell me what is going on. It was working yesterday and I haven't changed much. Thank you.
Matrix dimensions must agree.
Error in finitedifferences
Error in computeFinDiffGradAndJac
Error in barrier
Error in fmincon (line 813)
[X,FVAL,EXITFLAG,OUTPUT,LAMBDA,GRAD,HESSIAN] = barrier(funfcn,X,A,B,Aeq,Beq,l,u,confcn,options.HessFcn, ...
Error in optimization (line 39)
b_min = fmincon(func, x0, A, c, Aeq, beq, lb, ub, nlc);
0 Kommentare
Akzeptierte Antwort
Brandon Campanile
am 8 Nov. 2018
2 Kommentare
Ankita Chadha
am 7 Jun. 2021
So how do you get rid of this error? Since it is a built in function, I am unable to debug this one.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Get Started with Optimization Toolbox finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!