I'm facing a problem with fmincon in making it minimize a function.
Please have a look at the problem I have.
where function 'ipca_loglikelihood' is as follows:
global cA resid
obj_fun=N*log(det(temp)) + rsum;
the 'obj_fun' is getting minimized over 'd_sigmae' of size 5*1. 'cA' is 3*5 matrix,'t_sigma_e' is 5*5 matrix, and an Inverse is computed for the 'temp' which is a composite matrix of the above two. size of 'resid' is 3*1000 and "N*log(det(temp))" is also there in the objective function.
The non-linear constraints are given by the function 'mycon' as follows:
function [c, ceq] = mycon(d_sigma_e)
If the problem is properly minimized, 'd_sigma_e' should turn out to be [0.1;0.08;0.15;0.2;0.18]
for getting this result even though i put bounds as LB=zeros(5,1) or any set of numbers less than the corresponding converged values, UB=1*ones(n,1) or any set of numbers which are just more than the corresponding converged values, the elements of 'd_sigma_e' are not turning out to be close to the solution and most of the elements are just close to either upper or lower bounds.
I am not knowing, what is wrong with the problem. I doubt the ability of fmincon for dealing with this kind of minimization problem, where there is an involvement of many matrices and inverses and logarithmic functions.
Can you suggest any other way of doing this.
I'm much grateful to the people that look into the problem.
awaiting for reply..
Thanks to all in advance.