A Limit Order Book (LOB) is a financial exchange that automatically matches the orders of buyers and sellers according to a predefined priority rule. As the popularity of Limit Order markets has increased, more attention has been paid to the optimal strategies for an agent who wishes to buy or sell an equity on the order book.
In this thesis, we first introduce challenges of market microstructure and concepts of stochastic optimal control such as the Dynamic Programming Principle, the Hamilton-Jacobi-Bellman Equation, and tools such as the Feynman-Kac Formula. Then, we present Fodra and Pham's model for the optimal risk-neutral market making strategy in a limit order book that follows a Semi-Markov stochastic process, and use numerical techniques in MATLAB to apply the theory to real-word Limit Order data. Statistical techniques such as Maximum Likelihood Estimation, the Kolmogorov-Smirnov Test and Akaike Information Criterion are employed to distributions such as the Generalized Inverse Gaussian. Finally, we find the optimal risk-neutral strategy in an extension of the model when the price process contains a stochastic bid-ask spread following a Markov Chain.