Package com.quantfinlib.optimization


@NullMarked package com.quantfinlib.optimization
Portfolio optimisers and the solvers behind them. The main classes: PortfolioOptimizer (max Sharpe, min volatility, efficient frontier — derivative-free and deterministic), RiskParityOptimizer (equal risk contribution), BlackLitterman (equilibrium returns blended with confidence-weighted views) and ConstrainedPortfolioOptimizer (position caps/floors and turnover penalties against current holdings).
  • Classes
    Class
    Description
    Black-Litterman expected returns: start from the market-implied equilibrium (reverse optimization of the market portfolio) and blend in investor views with explicit confidences — the standard cure for mean-variance optimizers' hypersensitivity to raw return estimates (Black and Litterman 1992; He and Litterman 1999).
    Posterior mean, posterior covariance of the mean M, and Σ + M.
    Constrained long-only optimiser: per-asset weight bounds (position caps and floors) and an optional turnover penalty against current holdings, adjusted return = μ'w − τ·Σ|w − w_current|, so the optimiser trades expected gain against the cost of getting there.
    Derivative-free minimisation by the Nelder-Mead simplex method with the standard coefficients (reflection 1, expansion 2, contraction 1/2, shrink 1/2), following Lagarias, Reeds, Wright and Wright, "Convergence properties of the Nelder-Mead simplex method in low dimensions", SIAM J.
    Result: argmin, minimum, objective evaluations used.
    Long-only, fully invested mean-variance optimisation (Markowitz 1952), solved exactly as convex quadratic programs by QuadraticProgram: minimum variance: min w'Σw s.t.
    An optimized allocation with its risk/return profile (same periodicity as the inputs).
    Convex quadratic programming by the primal active-set method (Nocedal and Wright, Numerical Optimization, 2nd ed., Algorithm 16.3):
    Solution, its objective value, and the active-set iterations used.
    Risk parity: the portfolio where every asset contributes a set share of total risk (w_i (Σw)_i / w'Σw = b_i; equal shares by default).