Formal Verification of Financial Algorithms
Many deep issues plaguing today’s financial markets are symptoms of a fundamental problem: The complexity of algorithms underlying modern finance has significantly outpaced the power of traditional tools used to design and regulate them. At Aesthetic Integration, we have pioneered the use of formal verification for analysing the safety and fairness of financial algorithms. With a focus on financial infrastructure (e.g., the matching logics of exchanges and dark pools and FIX connectivity between trading systems), we describe the landscape, and illustrate our Imandra formal verification system on a number of real-world examples. We sketch many open problems and future directions along the way.
We thank our incredible team at Aesthetic Integration. Without them, much of this work would not have been accomplished. In particular, Konstantin Kanishev, Ewen Maclean, Sergey Grigorchuk and Matt Bray have been crucially involved in the design and implementation of the Imandra FIX DSL and its surrounding verification infrastructure. Elijah Kagan’s unique design perspective has helped us communicate our ideas much more effectively and enjoyably than we would have been able to otherwise.
Finally, we thank Jeremy Avigad, Bob Boyer, Gerry Dunning, Paul Jackson, J Moore, Leo de Moura, Larry Paulson, John Detrixhe of Bloomberg, Philip Stafford of the Financial Times, Jim Northey of the FIX Trading Community and Austin Gerig of the US Securities and Exchange Commission for their encouragement, useful discussions and advice.
- 1.Bahr, P., Berthold, J., Elsman, M.: Certified symbolic management of financial multi-party contracts. In: 20th ACM SIGPLAN International Conference on Functional Programming, ICFP 2015, pp. 315–327 (2015)Google Scholar
- 2.Bevier, W.R., Hunt, W.A., Moore, J.S., Young, W.D.: Special issue on system verification. J. Autom. Reasoning 5(4), 409–530 (1989)Google Scholar
- 3.Buterin, V.: Ethereum: a next-generation smart contract and decentralized application platform (2014). https://github.com/ethereum/wiki/wiki/White-Paper
- 5.Harris, L.: Trading and Exchanges: Market Microstructure for Practitioners. Oxford University Press, Oxford (2002)Google Scholar
- 6.Hunt Jr., W.A., Krug, R.B., Moore, J.: Integrating nonlinear arithmetic into ACL2. In: Fifth International Workshop on the ACL2 Theorem Prover and Its Applications (2004)Google Scholar
- 7.Ignatovich, D.A., Passmore, G.O.: Case Study: 2015 SEC Fine Against UBS ATS. Aesthetic Integration, Ltd., Technical Whitepaper (2015)Google Scholar
- 8.Ignatovich, D.A., Passmore, G.O.: Creating Safe and Fair Markets. Aesthetic Integration, Ltd., Technical Whitepaper (2015)Google Scholar
- 9.Ignatovich, D.A., Passmore, G.O.: Transparent Order Priority and Pricing. Aesthetic Integration, Ltd., Technical Whitepaper (2015)Google Scholar
- 10.Ignatovich, D.A., Passmore, G.O.: Comment on SEC Reg ATS-N: The Precise Specification Standard, February 2016. https://www.sec.gov/comments/s7-23-15/s72315-24.pdf
- 11.Kaufmann, M., Moore, J.S., Manolios, P.: Computer-Aided Reasoning: An Approach. Kluwer Academic Publishers, Norwell (2000)Google Scholar
- 12.Leroy, X., Doligez, D., Frisch, A., Garrigue, J., Rémy, D., Vouillon, J.: The OCaml system (release 4.04): Documentation and user’s manual. INRIA (2017)Google Scholar
- 13.Li, W., Passmore, G.O., Paulson, L.C.: Deciding Univariate Polynomial Problems Using Untrusted Certificates in Isabelle/HOL. J. Autom. Reasoning (2017)Google Scholar
- 15.Myreen, M.O.: Formal verification of machine-code programs. Ph.D. thesis, University of Cambridge (2009)Google Scholar
- 16.Passmore, G.O.: Combined decision procedures for nonlinear arithmetics, real and complex. Ph.D. thesis, University of Edinburgh (2011)Google Scholar
- 18.US Securities and Exchange Commission: Regulation National Market System (Reg NMS) (2005). https://www.sec.gov/rules/final/34-51808.pdf
- 19.US Securities and Exchange Commission: Regulation Alternative Trading Systems (Reg ATS) (2015). https://www.sec.gov/rules/proposed/2015/34-76474.pdf
- 20.Wood, G.: Ethereum: a secure decentralised generalised transaction ledger (2014). http://gavwood.com/paper.pdf