# Specify Portfolio Constraints

Define constraints for portfolio assets such as linear equality and inequality, bound, budget, group, group ratio, and turnover constraints

Working with a `PortfolioMAD`

object,
use functions to define the constraints for portfolio assets such as
linear equality and inequality, bound, budget, group, group ratio,
and turnover constraints.

## Objects

`PortfolioMAD` | Create PortfolioMAD object for mean-absolute deviation portfolio optimization and analysis |

## Functions

## Topics

### Portfolio Optimizations

**Working with MAD Portfolio Constraints Using Defaults**

The most basic or “default” portfolio set requires portfolio weights to be nonnegative and to sum to`1`

.**Working with 'Simple' Bound Constraints Using PortfolioMAD Object**

`'Simple'`

bound constraints are optional linear constraints that maintain upper and lower bounds on portfolio weights.**Working with Budget Constraints Using PortfolioMAD Object**

The budget constraint is an optional linear constraint that maintains upper and lower bounds on the sum of portfolio weights.**Working with Conditional Budget Constraints Using PortfolioMAD Object**

The conditional budget constraint supports the Undertakings for Collective Investment in Transferable Securities (UCITS) directive for a PortfolioMAD object.**Working with Group Constraints Using PortfolioMAD Object**

Group constraints are optional linear constraints that group assets together and enforce bounds on the group weights.**Working with Group Ratio Constraints Using PortfolioMAD Object**

Group ratio constraints are optional linear constraints that maintain bounds on proportional relationships among groups of assets.**Working with Linear Equality Constraints Using PortfolioMAD Object**

Linear equality constraints are optional linear constraints that impose systems of equalities on portfolio weights.**Working with Linear Inequality Constraints Using PortfolioMAD Object**

Linear inequality constraints are optional linear constraints that impose systems of inequalities on portfolio weights.**Working with Average Turnover Constraints Using PortfolioMAD Object**

The turnover constraint is an optional linear absolute value constraint that enforces an upper bound on the average of purchases and sales.**Working with One-Way Turnover Constraints Using PortfolioMAD Object**

One-way turnover constraints are optional constraints that enforce upper bounds on net purchases or net sales.**Working with 'Conditional' BoundType, MinNumAssets, and MaxNumAssets Constraints Using PortfolioMAD Objects**

Using`'Conditional'`

`BoundType`

,`MinNumAssets`

, and`MaxNumAssets`

constraints with PortfolioMAD objects.**Adding Constraints to Satisfy UCITS Directive**

This example shows how to set up and solve a portfolio optimization problem that satisfies the Undertakings for Collective Investment in Transferable Securities (UCITS) Directive.

### Portfolio Theory

**Portfolio Optimization Theory**

Portfolios are points from a feasible set of assets that constitute an asset universe.**Supported Constraints for Portfolio Optimization Using PortfolioMAD Object**

The complete specification of a portfolio optimization problem is the set of feasible portfolios, which is called a portfolio set.**Default Portfolio Problem**

The default portfolio optimization problem has a risk and return proxy associated with a given problem, and a portfolio set that specifies portfolio weights to be nonnegative and to sum to`1`

.**PortfolioMAD Object Workflow**

PortfolioMAD object workflow for creating and modeling a mean-absolute deviation (MAD) portfolio.**When to Use Portfolio Objects Over Optimization Toolbox**

The three cases for using Portfolio, PortfolioCVaR, PortfolioMAD object are: always use, preferred use, and use Optimization Toolbox.