# Minimize overall portfolio turnover under constraints

Assume I have M portfolios, each of them can be represented as a T by N matrix, where N represents number of stocks traded and T represents number of days. For each portfolio matrix, each row is under the following constraints:

1. Absolute values for each row entries sum up to one which represents the weight of money allocation.
2. Sum of all entries on each row is zero which means a dollar neutral portfolio.

My question is that is there a mathematical solution of finding weights

w_1, w_2, ... w_M


such that

w_i>=0 for i in 1,2, ... M


and

w_1 + w_2 + ... + w_M = 1


such that the combined portfolio has minimum overall turnover.

## 1 Answer

I'm not entirely sure what you mean in your set-up. Typically, what one wants to do is maximize utility given some turnover constraint. I believe what you're talking about is optimizing several portfolios and minimizing the turnover across all of them. Hence, if you understand the simple case, then it should be easy to adapt it to your problem.

First, consider a booksize constraint

$$\sum\left|w_{i}\right|=K$$

that ensures that the absolute value of each position sums to some value $K$. Convex optimizers can't handle this because of the discontinuity. The trick is to re-write it with slack variables $x_{i}\geq0$ and $y_{i}\geq0$ with the constraints $$w_{i}=x_{i}-y_{i}$$ $$\sum\left(x_{i}+y_{i}\right)=K$$ So for instance, if $w_{1}=-0.1$, then $x_{1}=0$ and $y_{1}=0.1$

This analysis extends easily to handle turnover constraints of the form

$$\sum\left|w_{i} - w_{0}\right|=K$$

so all that is required is changing the constraint restricting $x$ and $y$ to

$$w_{i} - w_{0}=x_{i}-y_{i}$$

Sometimes when dealing with transaction costs, it can also be helpful to add in the constraint

$$x_{i}y_{i}=0$$

to ensure that $x$ or $y$ and identified and one is fixed to zero. It may not be necessary because the optimizer should force one to be zero as a result of finding the optimal portfolio, but if you see something like if $w_{1}=-0.1$ and $x_{1}=0.1$ and $y_{1}=0.2$, then you would want to add it. This would require an optimizer that handles non-linear constraints, whereas above only requires inequality constraints.

In addition, an alternate approach would be to place a constraint on the L2-norm $$\left\Vert w_{i}-w_{0}\right\Vert \leq K$$ which can be re-written $$\left(w_{i}-w_{0}\right)'\left(w_{i}-w_{0}\right)\leq K$$ and included in any optimizer that handles non-linear constraints. The downside of this is that it's a little less intuitive than a proper turnover constraint and you may have to test out different values of $K$.