CVA on an iPad Mini Part 1: Intro Aarhus Kwant Factory PhD Course January 2014 Jesper Andreasen Danske Markets, Copenhagen [email protected] Outline Introduction: - Tactical CVA as a competitive advantage: The need and greed for speed. - Fast and furious: Pricing in a second – risk in a minute. The Beast model – specification, calibration, simulation: - Multi-Factor Cheyette interest rate models. Stochastic local volatility model for FX and equity. Stochastic volatility and correlation. The Beast correlation structure, quanto adjustments, and stochastic x-ccy basis. CVA calculations: 2 - The Jive scripting language. CVA regressions. CVA Jive overlay. The choice of regression variables. Compression and its Jive implementation. Cutting the IT edge: - Multi threading. - Adjoint differentiation! - The long hard sweaty route from “in principle” and “in theory” to actual implementation. - The iPad Maxi and live demo. Extensions: 3 - Collateralised counterparties. Stochastic credit. Value at Risk. Marginal incremental trade CVA. Other applications: - Model calibration by simulation. - General non-linear pricing: Transaction costs, feedback effects, etc. Practical CVA – by Nicki Rasmussen. Conclusion. 4 References Andreasen, J. (2005): “Back to the Future.” Risk September, 105-109. Andreasen, J. and B. Huge (2011a): “Volatility Interpolation.” Risk March, 8689. Andreasen, J. and B. Huge (2011b): “Random Grids.” Risk July, 66-71. Andreasen, J. (2012): “Kwant Summit.” Internal presentation, Danske Bank. Andreasen, J. (2012): “xVA.” Internal presentation, Danske Bank. Cheyette, O. (1992): “Markov Representation of the Heath-Jarrow-Morton Model.” SSRN. 5 Piterbarg, V. (2003): “A Stochastic Volatility Forward Libor Model with a Term Structure of Volatility Smiles.” SSRN. Piterbarg, V. (2007): “Markovian Projection Method for Volatility Calibration.” Risk April. 6 Introduction CVA stands for “Credit Valuation Adjustment”. The idea is to adjust the valuation of (derivatives) for the credit risk of the counterparty. Fundamentally, to compute CVA E[ T 0 V (t) creditloss ( dt) dt] default Next to the CVA there is a zoo of related quantities such as 7 DVA E[ FVA E[ OVA E[ T 0 T 0 V (t ) ( V (t) q(t) dt) dt] 0 creditloss owndefault dt] collateral funding cost (V (th 1) V (th ) ) 1 h change in collateral value [t ,t ] ] h h 1 default ... and many more. Often under the abbreviation xVA. Here and in the following, though, I will often use “CVA” when I really mean xVA. 8 Tactical CVA Contrary to most London banks, Danske Bank has not only been driven in to computing CVA quantities by (direct) regulation. Our motivation is that CVA have real material economic value and we want to incorporate that into the pricing of new trades that we do with our clients. This is to protect our trading books, to enter the good trades and stay away from the bad ones. I.e. to walk the fine balance of the negative gamma position: - Too aggressive: you pile up bad trades on the book. - Too conservative: you shy away from good trades. 9 With the added benefits of: - Quick and accurate response: good service to our clients. - Structure good trades that create value for us and clients. Rather than doing CVA calculations as over-night jobs we want to be able to price CVA as real time as we can. Further, we want to push the CVA calculations as close to the front line as possible. Most importantly: the quicker a model is, the more it will get used. ...and the more it gets used, the more money it makes (or protects). 10 Risk Reports Quick pricing of CVA is in itself a challenge but next to that there is the challenge of getting risk reports, i.e. first order derivates for all input parameters. Risk reports are used for - Hedging CVA. - Restructuring clients’ portfolios to reduce CVA. For the latter we would like to be able to compute incremental (marginal) CVA for adding different trades to the clients portfolio and using this for restructuring the clients’ portfolio. 11 If risk reports are done by bump-and-run then the sheer amount of input data and potential variations of the portfolio is overwhelming and will require massive amounts of hardware. Massive amounts of hardware require hordes of staff to look after it and have meetings with themselves. And that costs. But beyond that: if the risk report calculations can be done smarter and quicker than bump-and-run then it can be brought closer to the front and used on a more tactical basis. 12 Fast and Furious We have obtained fast CVA calculations through three steps. Models: - Ability to handle all the risk factors that affect the portfolio value: multi factor yield curves, multi FX, inflation, equities, commodities, etc. - Consistency with vanilla pricing – but not necessarily exotics. - Versatile, flexible and stable. - Quick calibration and simulation. Algorithms and implementation: - All trades done through scripting language. - Smart American Monte-Carlo regressions. 13 - Compression to save CPU time – and not least memory. 14 Turbo Charging On top of the model and algorithm machinery we have turbo charged our calculations with - Multi threading (MT) and (massive scale) parallelisation. - Adjoint differentiation (AD). Multi threading: - Perform similar calculations (such as different MC paths) on multiple computers (cores) simultaneously. About AD: 15 - On a computer, conventional calculations run from many parameters to one final value. - AD is a fantastic trick where computer calculations are run backwards in time starting at the final value, propagating partial derivatives backwards to all parameters in one sweep. In practice, the cost of the backward AD step is roughly a factor 6-10 of one pricing. But this can potentially create any number of derivatives. So from one price to one million partial derivatives in 10 times the computer time! Sounds like magic and it almost is, but it is not very easy to implement. Historically, we have primarily focussed on models and algorithms and it is only within the last year that we have started seriously on the sophisticated computer trickery. 16 Our targets were pricing in 1 second and all risks in 1 minute. We have not yet achieved this but we are quite close. On large netting sets around 10s for pricing and 1.5 minutes for all risk. Initially we thought we could code MT and AD in about 3 months time. ... but it turned out to be a lot harder than that. Antoine Savine and I have worked almost continuously on the project the past 12 months – and not all problems are fully solved yet. That said, we feel that the strides we have made so far, are very significant. 17 Particularly, the AD technology could be a real game changer in modelling technology – once we get our heads fully around it. 18 Program for Rest of the Day Models: MFC, SLV, Beast. Algorithms for CVA calculations: Jive, regression, compression. Cutting IT Edge: MT and AD. Practical CVA, by Nicki Rasmussen. Note: I have re-used quite a few slides from presentations that I gave to our traders. There might be terms that are Danske specific. So please ask if something needs clarification. Live Demo! 19
© Copyright 2024 ExpyDoc