Back to main page


Instructions for optimization with PSG Run-File, PSG MATLAB Toolbox, PSG MATLAB Subroutines and PSG R.

PROBLEM 1: problem_cdohedge_1
(formulation with cardinality function and continues variables)
Minimize Meanabs_err (minimize hedging risk)
subject to
Polynom_abs ≤ Const (budget constraint)
Cardn ≤ Const1 (constraint on cardinality)
Box constraints (upper bounds on positions)
——————————————————————–
Meanabs_err = Mean Absolute Error
Polynom_abs = Polynomial Absolute
Cardn = Cardinality
Box constraints = constraints on individual decision variables
——————————————————————–Problem statement with LINEARIZE=1 option for cardinality function and Car solver

# of Variables # of Scenarios Objective Value Solving Time, PC 3.14GHz (sec)
Dataset 1 1004 50 1.753722317517E-06 0.86
Environments
Run-File Problem Statement Data Solution
Matlab Toolbox Data
Matlab Subroutines Matlab Code Data
R R Code Data

Problem statement with MIP=1 option for cardinality function and Cargrb (Gurobi) solver

# of Variables # of Scenarios Objective Value Solving Time, PC 3.14GHz (sec)
Dataset 2 1004 50 1.579406671226E-08 31.67
Run-File Problem Statement Data Solution
PROBLEM 2: problem_cdohedge_2
(MIP formulation with Boolean variables)
Miminize Meanabs_err (minimize hedging risk)
subject to
Polynom_abs ≤ Const (budget constraint)
Linear ≤ Const1 (constraint on cardinality)
Linearmulti ≤ 0 (bounds of continue variables depend on Boolean variables)
Types of variables (defines Real and Boolean variables)
——————————————————————–
Meanabs_err = Mean Absolute Error
Polynom_abs = Polynomial Absolute
Linear = Linear
Linearmulti = System of linear constraints
——————————————————————–

# of Variables # of Scenarios Objective Value Solving Time, PC 3.14GHz (sec)
Dataset 4120 50 3.376044332981E-09 5.15
Environments
Run-File Problem Statement Data Solution
Matlab Toolbox Data
Matlab Subroutines Matlab Code Data
R R Code Data

Data (MPS file) and solution in Gurobi

Problem Datasets # of Variables # of Scenarios Objective Value Solving Time, PC 3.50GHz (sec)
Dataset1 MPS Data Solution 4120 50 0.000000053798 35.0

 

CASE STUDY SUMMARY
This case study demonstrates an optimization setup for a hedging problem. The first link in the beginning of the page problem statements with original notations coming from a bank contains mathematical formulations of hedging problems with notations coming from a bank. The second link lecture describing methodology contains a general description of linear regression problem with constraints. This lecture shows how to reduce regression problem with Cardinality constraint to a Mixed Integer Program (MIP).- Optimization Problem 1 minimizes Mean Absolute Error of losses subject to budget constraint and cardinality constraint (defined with PSG cardinality function). Problem 1 has two problem statements – one with option “linearize=1” and other with ‘mip=1” for constraint on cardinality. These options provide different approaches for working with cardinality function.
– Optimization Problem 2 minimizes Mean Absolute Error of losses subject to budget and cardinality constraints. Compared to Problem 1, the cardinality constraint is defined with a linear function on boolean variables. We provide also MPS file, which can be solved by a standard MIP solver, such as GUROBI.The objective is to build a portfolio of Credit Default Swaps (CDS) and Credit Indices that hedge against changes in a CDO (Collateralized Debt Obligation) book. CDSs are the most popular credit derivatives; they provide insurance against the risk of default (credit event) of a particular company. A buyer of the insurance has the right to sell bonds issued by the company for their face value when a credit event occurs to the seller of the insurance. The buyer of the CDS makes periodic payments to the seller until the end of the life of the CDS or until a credit event occurs. The total amount paid per year, as a percent of the notional principal, to buy protection is known as the CDS spread. Credit Indices are indices that track CDS spreads. CDO is a credit derivative based on defaults of a pool of assets. CDO makes available credit risk exposure to a broad set of investors. A common structure of CDO involves tranching or slicing the credit risk of the reference pool into different risk levels. The risk of loss on the reference portfolio is divided into tranches of increasing seniority. The losses first affect the equity (first loss) tranche, then the mezzanine tranche, and finally the senior and super senior tranches.