http://www.mathworks.com/matlabcentral/newsreader/view_thread/244122
MATLAB Central Newsreader  How to get the minimum of a function
Feed for thread: How to get the minimum of a function
enus
©19942015 by MathWorks, Inc.
webmaster@mathworks.com
MATLAB Central Newsreader
http://blogs.law.harvard.edu/tech/rss
60
MathWorks
http://www.mathworks.com/images/membrane_icon.gif

Mon, 09 Feb 2009 17:17:56 +0000
How to get the minimum of a function
http://www.mathworks.com/matlabcentral/newsreader/view_thread/244122#627134
thitetaf
Hello all<br>
<br>
I have the VarianceCovariance matrix on N assets and want to calculate the W=[w1,w2...wn] such as the variance of my portfolio is minimized.<br>
<br>
I.E : I want to find W such as W'*CovarMatrix*W is minimized. I know that fmincon function exist but my problem is that my CovarMatrix is a parameter. How can I use fmincon such as Matlab is just trying to "play" with the W's ?<br>
<br>
Thanks

Mon, 09 Feb 2009 18:44:01 +0000
Re: How to get the minimum of a function
http://www.mathworks.com/matlabcentral/newsreader/view_thread/244122#627162
Roger Stafford
thitetaf <thibault.tetafort@edhec.com> wrote in message <20069717.1234199906713.JavaMail.jakarta@nitrogen.mathforum.org>...<br>
> Hello all<br>
> <br>
> I have the VarianceCovariance matrix on N assets and want to calculate the W=[w1,w2...wn] such as the variance of my portfolio is minimized.<br>
> <br>
> I.E : I want to find W such as W'*CovarMatrix*W is minimized. I know that fmincon function exist but my problem is that my CovarMatrix is a parameter. How can I use fmincon such as Matlab is just trying to "play" with the W's ?<br>
> <br>
> Thanks<br>
<br>
As you have given W, the quantity W'*CovarMatrix*W would not make sense. Don't you mean that W is to be a column vector rather than a row vector?<br>
<br>
What constraints are you placing on W? If you require it to be a unit vector, it is a simple problem in eigenvectors. If there are no constraints, the minimum occurs at W = zeros(n,1), and I am sure you don't mean that.<br>
<br>
Roger Stafford