Re: [ojAlgo-user] Risk Parity on Markowitz model
Mathematics, linear algebra and optimisation
Brought to you by:
apete
From: Anders P. <an...@op...> - 2013-03-04 07:39:01
|
As far as I can see that means you have quadratic constraints, and ojAlgo can't handle that. You'l have to reformulate the problem or write a cover algorithm that does what you want. If that's not possible then you'll have find another library that can handle quadratic constraints. /Anders On 3 mar 2013, at 23:40, Matteo Baccan <mat...@gm...> wrote: > Hi > > I am performing some test on your ojalgo.finance.portfolio library based on Markowitz model, but I have a problem that I am not able to solve. > > > Assuming a case of a two-asset portfolio. The input values for Markowitz model are: expected return, expected volatility and covariance matrix. > > > Assets > > Expected Return > > Expected Volatility > > Asset 1 > > μ1 > > σ1 > > Asset 2 > > μ2 σ2 > > > > Covariance Matrix > > Asset 1 > > Asset 2 > > Asset 1 > > > σ1^2 > > σ2,1=σ1,2 > > Asset 2 > > σ1,2 > > σ2^2 > > > > The portfolio variance can be seen as the sum of the risk contribution of each asset class as following: > > > Assets > > Weights > > Risk Contribution > > Asset 1 > > X1 > > VP1=X1^2∙σ1^2+X1∙X2∙σ1,2 > > Asset 2 > > X2 > > > VP2=X2^2∙σ2^2+X1∙X2∙σ1,2 > > > Portfolio Variance = VP1+VP2 > > > > My goal is to calculate the asset allocation (sum weights =1) maximizing portfolio expected return and adding the following constraint: VP1=VP2 (risk parity approach). > > > > Considering n Assets, the logic is the same: maximizing portfolio return but adding the following constraint: > > VP1=VP2=⋯ =VPn > > > > Could you give me some suggestion in order to solve this problem using your library? > > > Best Regards, > > > > -- > Matteo Baccan > http://www.baccan.it > > ------------------------------------------------------------------------------ > Everyone hates slow websites. So do we. > Make your web apps faster with AppDynamics > Download AppDynamics Lite for free today: > http://p.sf.net/sfu/appdyn_d2d_feb_______________________________________________ > ojAlgo-user mailing list > ojA...@li... > https://lists.sourceforge.net/lists/listinfo/ojalgo-user |