Weight constraint - dynamic position sizing

I would like to know what happen with the excess when a max position weight is reached.
Is it evenly distributed with the other positions ?

An involved procedure is in place to implement weight constraints.

The first step normalizes weights to the range of the weight constraints:
[font=courier new]For each position p in Positions, let p.Ideal[1] = MinConstraint + (p.Ideal[0] - MIN(q.Ideal[0])) * (MaxConstraint - MinConstraint) / (MAX(q.Ideal[0]) - MIN(q.Ideal[0]))[/font]

The next step normalizes [font=courier new]p.Ideal[1][/font] into the target position exposure (this usually means [font=courier new]SUM(q.Ideal[2])[/font] will be 100%):
[font=courier new]Let Pct = SUM(q.Ideal[1])
Let ScaleToward = IF(Pct > TargetPosExposure, MinConstraint, MaxConstraint)
Let FromPortWeight = ScaleToward * Count()
For each position p in Positions, let p.Ideal[2] = ScaleToward + (p.Ideal[1] - ScaleToward) * (TargetPosExposure - FromPortWeight) / (Pct - FromPortWeight)[/font]

[font=courier new]p.Ideal[2][/font] is used as weight upon which transactions will be based.

As you can see, there’s a lot going on above, but suffice it to say, it effectively maintains the raw distribution from the formula while both respecting weight constraints and target position exposure.

Thanks, Aaron.