Portfolio Optimization: A Technical Perspective

Similar documents
GAMS Productivity - Performance - Reliability

for Algebraic Modeling Systems?

GAMS, Condor and the Grid: Solving Hard Optimization Models in Parallel. Michael C. Ferris University of Wisconsin

Optimization applications in finance, securities, banking and insurance

Branch-and-Price Approach to the Vehicle Routing Problem with Time Windows

Dynamic Asset Allocation Using Stochastic Programming and Stochastic Dynamic Programming Techniques

Quality Assurance For Mathematical Modeling Systems

Open-source Quality Assurance and Performance Analysis Tools

Chapter 1 INTRODUCTION. 1.1 Background

Practical Financial Optimization. A Library of GAMS Models. The Wiley Finance Series

A joint control framework for supply chain planning

CASH FLOW MATCHING PROBLEM WITH CVaR CONSTRAINTS: A CASE STUDY WITH PORTFOLIO SAFEGUARD. Danjue Shang and Stan Uryasev

SBB: A New Solver for Mixed Integer Nonlinear Programming

Fundamentals and Recent Developments of the GAMS System

Optimal Allocation of renewable Energy Parks: A Two Stage Optimization Model. Mohammad Atef, Carmen Gervet German University in Cairo, EGYPT

A MILP Scheduling Model for Multi-stage Batch Plants

Supply Chain Design and Inventory Management Optimization in the Motors Industry

Supply planning for two-level assembly systems with stochastic component delivery times: trade-off between holding cost and service level

Optimal Scheduling for Dependent Details Processing Using MS Excel Solver

Two-Stage Stochastic Linear Programs

Grid-Enabled Optimization with GAMS

Sanjeev Kumar. contribute

COST OPTIMIZATION IN DYNAMIC RESOURCE ALLOCATION USING VIRTUAL MACHINES FOR CLOUD COMPUTING ENVIRONMENT

Credit Risk Modeling with MATLAB

Network Optimization using AIMMS in the Analytics & Visualization Era

Master of Arts in Mathematics

Software that writes Software Stochastic, Evolutionary, MultiRun Strategy Auto-Generation. TRADING SYSTEM LAB Product Description Version 1.

A Weighted-Sum Mixed Integer Program for Bi-Objective Dynamic Portfolio Optimization

Eastern Washington University Department of Computer Science. Questionnaire for Prospective Masters in Computer Science Students

OPTIMIZATION AND FORECASTING WITH FINANCIAL TIME SERIES

Energy Management for Heat Intensive Production Plants using Mixed Integer Optimization

Solving convex MINLP problems with AIMMS

Distributionally Robust Optimization with ROME (part 2)

Summary of specified general model for CHP system

Multiple Choice: 2 points each

Distributed and Scalable QoS Optimization for Dynamic Web Service Composition

How Can Metaheuristics Help Software Engineers

Demand Response Management System ABB Smart Grid solution for demand response programs, distributed energy management and commercial operations

RevoScaleR Speed and Scalability

A Constraint Programming based Column Generation Approach to Nurse Rostering Problems

Optimization Modeling for Mining Engineers

Solving Very Large Financial Planning Problems on Blue Gene

Robust Optimization for Unit Commitment and Dispatch in Energy Markets

MARKAL Version 5.9a-f Enhancements and Updates August 26, Table of Contents

Stochastic programming approach to ALM in Finnish pension insurance companies p.1/36

Asset Liability Management / Liability Driven Investment Optimization (LDIOpt)

High-Mix Low-Volume Flow Shop Manufacturing System Scheduling

Including Risk Part 1 Non Adaptive. Bruce A. McCarl

Scheduling Jobs and Preventive Maintenance Activities on Parallel Machines

Understanding the Impact of Weights Constraints in Portfolio Theory

CRLS Mathematics Department Algebra I Curriculum Map/Pacing Guide

COMPLETE MARKETS DO NOT ALLOW FREE CASH FLOW STREAMS

Advanced Lecture on Mathematical Science and Information Science I. Optimization in Finance

Strategic Alignment An ORTEC White Paper

Regulatory Impacts on Credit Portfolio Management

Abstract. 1. Introduction. Caparica, Portugal b CEG, IST-UTL, Av. Rovisco Pais, Lisboa, Portugal

The Psychology of Simulation Model and Metamodeling

STATISTICA Solutions for Financial Risk Management Management and Validated Compliance Solutions for the Banking Industry (Basel II)

The University of Chicago Booth School of Business Tools for Business Analysis: Excel and Matlab Winter, 2012.

A Reference Point Method to Triple-Objective Assignment of Supporting Services in a Healthcare Institution. Bartosz Sawik

A Student-centric Class and Exam Scheduling System at West Point

Chapter 11 Monte Carlo Simulation

TOMLAB - For fast and robust largescale optimization in MATLAB

Essays in Financial Mathematics

Resource Utilization of Middleware Components in Embedded Systems

JMulTi/JStatCom - A Data Analysis Toolkit for End-users and Developers

Testing Theories of Policy-Making: Educational Funding MICAH MCFADDEN

Delivering a first-class cloud experience.

Prescriptive Analytics. A business guide

Current Standard: Mathematical Concepts and Applications Shape, Space, and Measurement- Primary

Figure 1. The cloud scales: Amazon EC2 growth [2].

ANALYTICS STRATEGY: creating a roadmap for success

HYBRID GENETIC ALGORITHMS FOR SCHEDULING ADVERTISEMENTS ON A WEB PAGE

An Overview Of Software For Convex Optimization. Brian Borchers Department of Mathematics New Mexico Tech Socorro, NM

Simulation-based Optimization Approach to Clinical Trial Supply Chain Management

Financial Modeling and Optimization-Course Syllabus RM 392 Topic 1- unique # MW 2:00-3:15, CBA Spring 2013

An optimisation framework for determination of capacity in railway networks

Intercompany Reconciliation and Settlement. WIPRO CONSULTING SERVICES Business Methods Series.

Supply Chain Analytics - OR in Action

A MULTI-PERIOD INVESTMENT SELECTION MODEL FOR STRATEGIC RAILWAY CAPACITY PLANNING

Optimization under uncertainty: modeling and solution methods

HPC Deployment of OpenFOAM in an Industrial Setting

Big Data Optimization at SAS

Chapter 5 Discrete Probability Distribution. Learning objectives

Simplified Benders cuts for Facility Location

MIP-Based Approaches for Solving Scheduling Problems with Batch Processing Machines

Instituto Superior Técnico Masters in Civil Engineering. Lecture 2: Transport networks design and evaluation Xpress presentation - Laboratory work

MSCA Introduction to Statistical Concepts

Linear Threshold Units

Optimization Methods in Finance

Eastern Washington University Department of Computer Science. Questionnaire for Prospective Masters in Computer Science Students

Summary of Survey Cost White Paper. Alan F. Karr National Institute of Statistical Sciences

npsolver A SAT Based Solver for Optimization Problems

Professional Organization Checklist for the Computer Science Curriculum Updates. Association of Computing Machinery Computing Curricula 2008

Chapter 13: Binary and Mixed-Integer Programming

Computer Science. General Education Students must complete the requirements shown in the General Education Requirements section of this catalog.

WORKFLOW ENGINE FOR CLOUDS

This white paper was written by Csilla Zsigri, The 451 Group, based on the work done by the SmartLM Consortium in business modeling.

William E. Hart Carl Laird Jean-Paul Watson David L. Woodruff. Pyomo Optimization. Modeling in Python. ^ Springer

Transcription:

Portfolio Optimization: A Technical Perspective Franz Nelißen FNelissen@gams.com GAMS Software GmbH www.gams.de 1 1 OR 2006 Karlsruhe, Germany, September 6-8, 2006

Agenda Introduction Mathematical Optimization in Finance An illustrative Example: The Mean Variance Model Advanced Portfolio Optimization Models Grid Computing 2 2

Agenda Introduction Mathematical Optimization in Finance An illustrative Example: The Mean Variance Model Advanced Portfolio Optimization Models Grid Computing 3 3

GAMS Development / GAMS Software Roots: Research project World Bank 1976 Pioneer in Algebraic Modeling Systems used for economic modeling Went commercial in 1987 Offices in Washington, D.C and Cologne Professional software tool provider, not a consulting company Operating in a segmented niche market Broad academic & commercial user base and network 4 4 General Algebraic Modeling System

Agenda Introduction Mathematical Optimization in Finance An illustrative Example: The Mean Variance Model Advanced Portfolio Optimization Models Grid Computing 5 5

Mathematical Optimization in Finance Very active research field with significant contributions and important practical applications Some of the reasons: - Continual stream of challenging problems with obvious impact of uncertainty - High availability of data - Validation potential benchmarking - Very competitive and liquid markets Many instruments, tools and strategies 6 6

Portfolio Optimization Models - Mean-Variance Model - Portfolio models for fixed income - Scenario optimization - Stochastic programming 7 7

Change in Focus Computation Past Model Now Application Future 8 8 Algorithm limits application Problem representation low priority Large expensive projects Long development times Centralized expert groups High computational costs Users left out Modeling skill limits applications Algebraic model representation Smaller projects and rapid development Decentralized modeling teams Machine independence Users involved Domain expertise limits application Off-the-shelf GUI Models embedded in business applications Links to other types of models Internet/Web Users hardly aware of model

Modeling Approaches - Programming languages: C++, Delphi, Java, VBA, - Spreadsheets - Specialized tools - Algebraic Modeling Languages - Balanced mix of declarative and procedural elements - Open architecture and interfaces to other systems - Different layers with separation of: - model and data - model and solution methods - model and operating system - model and interface 9 9

Agenda Introduction Introduction Mathematical Optimization in Finance An illustrative Example: The Mean Variance Model Advanced Portfolio Optimization Models Grid Computing 10 10

MV Model Algebra Variance of Portfolio Min I J i= 1 j= 1 x i Q i, j x j Target return I s. t. µ x i= 1 i i r Budget constraint I i= 1 x i = 1 No short sales x i 0 11 11

Declarative Model and some Data 12 12

Modeling Issues Basic MV-Model: Quadratic model Solver - NLP Codes (CONOPT, MINOS,...) or - QCP Codes (Cplex, Mosek, Xpress) - take advantage of special structure Large problem instances can be solved routinely 13 13

Business Rules - Institutional or legal requirements - Additional constraints, which have to be satisfied - Trading restrictions - Not defined by modeling experts - Independent of risk model Simple business rules: Do not change the model type: - Short selling - Risk free borrowing - Upper or lower bounds on certain instruments 14 14

More Complex Business Rules Require introduction of integer (binary) variables: Cardinality Constraint: Restrict number of investments y i in portfolio Threshold Constraint: Investments x i can only be purchased at certain minimum l l,i or maximum l u,i more trading restrictions 15 15

Trading Restrictions "Zero or Range"- Constraint: Revision of existing (not optimized) portfolio "Zero or Range - Constraint: Either no trade or the trade must stay between pre-defined ranges both for purchase and selling Portfolio turnover: The total purchase of investments x i may not exceed some threshold τ e.g. cn: either no trade (20%) or new share between 23-31% (u) or between 0-18% (l) 16 16

GAMS Formulation Variables xi(i) fractionofportfolioincrease, xd(i) fractionofportfoliodecrease, y(i) binaryswitchforincreasingcurrentholdingsofi, z(i) binaryswitchfordecreasingcurrentholdingsofi; Binary Variables y,z;positive Variables xi,xd; Equations xdef(i) finalportfoliodefinition, maxinc(i) boundofmaximumlotincreaseoffractionofi, mininc(i) boundofminimumlotincreaseoffractionofi, maxdec(i) boundofmaximumlotdecreaseoffractionofi, mindec(i) boundofminimumlotdecreaseoffractionofi, binsum(i) restrictsuseofbinaryvariables, turnover restrictsmaximumturnoverofportfolio; 17 17 xdef(i).. x(i) =e= bdata(i,'old')-xd(i)+xi(i); maxinc(i)..xi(i) =l= bdata(i,'umax')*y(i); mininc(i)..xi(i) =g= bdata(i,'umin')*y(i); maxdec(i)..xd(i) =l= bdata(i,'lmax')*z(i); mindec(i)..xd(i) =g= bdata(i,'lmin')*z(i); binsum(i)..y(i)+z(i) =l=1; turnover..sum(i,xi(i)) =l=tau; Model Type: MIQCP

Procedural Elements $gdxin data # get data & setup model $load i mu q q(i,j)=2*q(j,i); q(i,i)=q(i,i)/2; Modelvar/all/; setp pointsforefficientfrontier/minv,p1*p8,maxr/, pp(p)pointsusedforloop / p1*p8 /; parameterminr,maxr,rep(p,*), repx(p,i); # get bounds for efficient frontier solve var minimizing v using miqcp; #find portfolio with minimal variance minr=r.l;rep('minv','ret')=r.l; rep('minv','var')=v.l;repx('minv',i)=x.l(i); solve var maximizing r using miqcp; #find portfolio with maximal return maxr=r.l;rep('maxr','ret')=r.l; rep('maxr','var')=v.l;repx('maxr',i)=x.l(i); loop(pp, ); #calculate efficient frontier r.fx=minr+(maxr-minr)/(card(pp)+1)*ord(pp); solve var minimizing v using miqcp; rep(pp,'ret')=r.l;rep(pp,'var')=v.l;repx(pp,i)=x.l(i); 18 18 Execute_Unload 'results.gdx',rep, repx; # export results to GDX & Excel Execute 'GDXXRW.EXE results.gdx par=repx rng=portfolio!a1 Rdim=1'; Execute 'GDXXRW.EXE results.gdx par=rep rng=frontier!a1 Rdim=1';

Efficient Frontier and Portfolios (τ = 0.3) Canada Sweden France UK Return of portfolio (%) 0.16 Share of portfolio (%) Greece Japan US 0.14 0.12 0.1 0.08 0.06 0.04 0.02 19 19 0 0 5 10 15 20 25 30 Variance of portfolio oldr min var p1 p2 p3 p4 p5 p6 p7 p8 p9 p10 max ret Solution points

Scenario Optimization Models Scenarios capture complex interactions between multiple risk factors Different methods for risk measurement: Mean Absolute Deviation Models Index Tracking Models Expected Utility Models VAR Models (linear Version: CVAR) Models are solved over all scenarios Modeling Issues: Linear Models, but business rules may introduce binary variables Lots of independent scenarios, which can be handled in parallel 20 20

Stochastic Programming (SP) 21 Stochastic Programming models allow sequence of decisions. Scenarios: Complete set of possible discrete realizations of the uncertain parameters with probabilities Stages: Decisions points. First stage decisions now, second stage decision (depending of the outcome of the first stage decision) after a certain period and so on Recourse: Decision variables can adept to the different out comes of the random parameters at each stage 4 0 1 2 5 6 7 8 3 9 Stage 1 Stage 1 Stage 3 21

More Complex Scenario Trees 22 22

Challenges Deterministic equivalent: Includes all scenarios and stages Size of model explodes Generation difficult Solution may not be possible Interpretation and validation of results Less applications than one may expect But: Number of uncertain parameters is small: Efficient representation of the uncertain data within the Algebraic Modeling System? Scenarios may only differ slightly Problems are structured 23 23

Current Developments New language elements : - Special expressions and conventions for stages and scenario trees - Random distributions for some problem data - Support of scenario reduction techniques dramatically reduces the size of deterministic equivalent - Automatic translation of problem description into format for various SP-solvers (DECIS, SPLINE ) - Support for parallel optimization But: - Different approaches - Not yet clear which standards will be adopted 24 24

More Theory and Templates Theory Practical Financial Optimization (forthcoming) by S. Zenios A Library of Financial Optimization Models (forthcoming) by A. Consiglio, S. Nielsen, H. Vladimirou and S. Zenios Financial Optimization by S. Zenios (ed.) Templates available online GAMS Model Library: http://www.gams.com/modlib/libhtml/subindx.htm Course Notes Financial Optimization : http://www.gams.com/docs/contributed/financial/ 25 25

Agenda Introduction Introduction Mathematical Optimization in Finance An illustrative Example: The Mean Variance Model Advanced Portfolio Optimization Models Grid Computing 26 26

Grid Computing loop(pp, #calculate efficient frontier r.fx = minr + (maxr-minr)/(card(pp)+1)*ord(pp); solve var minimizing v using miqcp; rep(pp,'ret') =r.l;rep(pp,'var') = v.l;repx(pp,i)= x.l(i); ); Imagine.. you have to solve 1.000 s of independent scenarios.... and you can do this very rapidly for little additional money.. without having to do lots of cumbersome programming work.. 27 27 Grid Computing

What is Grid Computing? A pool of connected computers managed and available as a common computing resource Effective sharing of CPU power Massive parallel task execution Scheduler handles management tasks E.g. Condor, Sun Grid Engine, Globus Can be rented or owned in common Licensing & security issues 28 28

Advantages of Grid Computing Solve a certain number of scenarios faster, e.g: sequential: 50 hours parallel (200 CPUs): ~15 minutes Cost is $100 (2$ CPU/h) Get better results by running more scenarios*: 29 29 * http://www.tc.cornell.edu/nr/shared/presentations/24feb04.garp.pdf

GAMS & Grid Computing Scalable: support of massive grids, but also multi-cpu / multiple cores desktop machines 1 CPU - Grid Platform independent Only minor changes to model required Separation of model and solution method Model stays maintainable 30 30

Simple Serial Solve Loop Loop(p(pp), ret.fx=rmin+(rmax-rmin) /(card(pp)+1)*ord(pp); Solve minvar min var using miqcp; xres(i,p) =x.l(i); report(p,i,'inc')=xi.l(i); report(p,i,'dec')=xd.l(i) ); Loop Generation Solution Update 31 31 How do we get to parallel and distributed computing?

GRID Specific Enhancements 1. Submission of jobs 2. Grid Middleware Distribution of jobs Job execution 3. Collection of solutions 4. Processing of results 32 32

Results for 4096 MIPS on Condor Grid Submission started Jan 11,16:00 All jobs submitted by Jan 11, 23:00 All jobs returned by Jan 12, 12:40 20 hours wall time, 5000 CPU hours Peak number of CPU s: 500 Talk: Thursday, 08:30 Chemie-Hörsaal 1 33 33

Conclusions and Summary Finance is a success story for OR applications Rich set of different risk models available Incorporating business rules may increase complexity of problems but is essential Large classes of problems can be solved without major problems Stochastic programming still challenging Grid Computing now offers lots of promising developments 34 34

The End Thank you! Questions? 35 35

Contacting GAMS Europe: GAMS Software GmbH Eupener Str. 135-137 50933 Cologne Germany Phone: +49 221 949 9170 Fax: +49 221 949 9171 http://www.gams.de USA: GAMS Development Corp. 1217 Potomac Street, NW Washington, DC 20007 USA Phone: +1 202 342 0180 Fax: +1 202 342 0181 http://www.gams.com 36 36