---
title: "Diversified Mean-Variance Efficient Portfolio"
method: POST
path: "/portfolios/optimization/mean-variance-efficient/diversified"
tags: ["Portfolio Optimization / Mean-Variance"]
---

# Diversified Mean-Variance Efficient Portfolio

`POST /portfolios/optimization/mean-variance-efficient/diversified`

Compute the asset weights of a diversified mean-variance efficient portfolio, optionally subject to:  
* Minimum and maximum weights constraints
* Minimum and maximum group weights constraints
* Minimum and maximum portfolio exposure constraints

The diversification measure used in the optimization procedure is the [Herfindahl-Hirschman Index](https://en.wikipedia.org/wiki/Herfindahl%E2%80%93Hirschman_index) of the assets weights.

> A diversified mean-variance efficient portfolio does NOT belong to [the mean-variance efficient frontier](#post-/portfolio/analysis/mean-variance/efficient-frontier), but is close to this frontier.

References
 * [Alejandro Corvalan, 2005. Well Diversified Efficient Portfolios, Working Papers Central Bank of Chile 336, Central Bank of Chile](https://ideas.repec.org/p/chb/bcchwp/336.html)
 * [Bouchaud, Jean-Philippe and Potters, Marc and Aguilar, Jean-Pierre, Missing Information and Asset Allocation, arXiv, 1997](https://arxiv.org/abs/cond-mat/9707042)
 * Harry M. Markowitz, Portfolio Selection, Efficient Diversification of Investments, Second edition, Blackwell Publishers Inc.

## Request body

- object
  - `assets` integer, required — The number of assets
  - `assetsMeanReturns` number[], required — assetsMeanReturns[i] is the arithmetic (expected) return of asset i
  - `assetsCovarianceMatrix` array[], required — assetsCovarianceMatrix[i][j] is the covariance between the asset i and the asset j arithmetic returns
    - number[]
  - `portfolioMeanReturnTolerance` number — The relative tolerance over the mean-variance efficient portfolio return, if applicable
  - `portfolioVolatilityTolerance` number — The relative tolerance over the mean-variance efficient portfolio volatility
  - `constraints` object, required
    - `portfolioMeanReturn` number — The portfolio mean return; exclusive with portfolioVolatility and riskTolerance
    - `portfolioVolatility` number — The portfolio volatility; exclusive with portfolioReturn and riskTolerance
    - `riskTolerance` number — The portfolio risk tolerance; exclusive with portfolioReturn and portfolioVolatility
    - `minimumAssetsWeights` number[] — minimumAssetsWeights[i] is the minimum weight of the asset i in the portfolio, in percentage
    - `maximumAssetsWeights` number[] — maximumAssetsWeights[i] is the maximum weight of the asset i in the portfolio, in percentage
    - `assetsGroups` array[]
      - integer[] — assetsGroups[k] is the indexes of the assets belonging to the assets group k in the portfolio; exclusive with assetsGroupsMatrix
    - `assetsGroupsMatrix` array[] — assetsGroupsMatrix[k][i] is the weight of the asset i in the group of assets k; exclusive with assetsGroups
      - number[]
    - `maximumAssetsGroupsWeights` number[] — maximumAssetsGroupsWeights[k] is the maximum weight of the assets group k in the portfolio, in percentage between 0 and 1 if assetsGroups is provided
    - `minimumPortfolioExposure` number — The minimum portfolio exposure; must be lower than or equal to maximumPortfolioExposure
    - `maximumPortfolioExposure` number — The maximum portfolio exposure; must be higher than or equal to minimumPortfolioExposure

## Response `200`

OK

- object
  - `assetsWeights` number[], required — assetsWeights[i] is the weight of the asset i in the portfolio, in percentage

---

[API](https://skmtc.net/portfoliooptimizer/apis/portfolio-optimizer.md) · [All operations](https://skmtc.net/portfoliooptimizer/apis/portfolio-optimizer/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/portfoliooptimizer/portfolio-optimizer/versions/479fd4ac44aa/schema)
