Copula Theory and Its Applications in Computer Networks by Fang Dong B.Sc., Wuhan University, 2011 M.Eng., Wuhan University, 2013 A Dissertation Submitted in Partial Fulfillment of the Requirements for the Degree of DOCTOR OF PHILOSOPHY in the Department of Computer Science c Fang Dong, 2017 University of Victoria All rights reserved. This dissertation may not be reproduced in whole or in part, by photocopying or other means, without the permission of the author. ii Copula Theory and Its Applications in Computer Networks by Fang Dong B.Sc., Wuhan University, 2011 M.Eng., Wuhan University, 2013 Supervisory Committee Dr. Kui Wu, Co-Supervisor (Department of Computer Science) Dr. Venkatesh Srinivasan, Co-Supervisor (Department of Computer Science) Dr. Lin Cai, Outside Member (Department of Electrical and Computer Engineering) iii Supervisory Committee Dr. Kui Wu, Co-Supervisor (Department of Computer Science) Dr. Venkatesh Srinivasan, Co-Supervisor (Department of Computer Science) Dr. Lin Cai, Outside Member (Department of Electrical and Computer Engineering) ABSTRACT Traffic modeling in computer networks has been researched for decades. A good model should reflect the features of real-world network traffic. With a good model, synthetic traffic data can be generated for experimental studies; network performance can be analysed mathematically; service provisioning and scheduling can be designed aligning with traffic changes. An important part of traffic modeling is to capture the dependence, either the dependence among different traffic flows or the temporal dependence within the same traffic flow. Nevertheless, the power of dependence models, especially those that capture the functional dependence, has not been fully explored in the domain of computer networks. This thesis studies copula theory, a theory to describe dependence between random variables, and applies it for better performance evaluation and network resource provisioning. We apply copula to model both contemporaneous dependence between traffic flows and temporal dependence within the same flow. The dependence models are powerful and capture the functional dependence beyond the linear scope. With numerical examples, real-world experiments and simulations, we show that copula modeling can benefit many applications in computer networks, including, for example, tightening performance bounds in statistical network calculus, capturing full iv dependence structure in Markov Modulated Poisson Process (MMPP), MMPP parameter estimation, and predictive resource provisioning for cloud-based composite services. v Contents Supervisory Committee ii Abstract iii Table of Contents v List of Tables ix List of Figures xi Nomenclature xiii Acknowledgements xviii Dedication xix 1 Introduction 1 1.1 Motivation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1.2 Research Goals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 1.3 Contributions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 1.4 Publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 2 Preliminaries on Copula Theory 8 2.1 Definitions and Basic Properties . . . . . . . . . . . . . . . . . . . . . 8 2.2 Copula-based Dependence Measures . . . . . . . . . . . . . . . . . . . 13 2.3 Parametric Copulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 2.4 Empirical Copula . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 2.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 3 Copula Analysis for Contemporaneous Dependence and Its Application in Statistical Network Calculus 19 vi 3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 3.2 Related Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 3.3 Background of Stochastic Network Calculus . . . . . . . . . . . . . . 21 3.4 Insights of Copula Analysis . . . . . . . . . . . . . . . . . . . . . . . 23 3.4.1 Basic Lemmas . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 3.4.2 An Example of Copula Analysis . . . . . . . . . . . . . . . . . 25 3.4.3 Performance Bounds of SNC with Copulas . . . . . . . . . . . 27 3.5 Copula Modelling at Work . . . . . . . . . . . . . . . . . . . . . . . . 29 3.5.1 Copula Analysis in Real-world Applications . . . . . . . . . . 29 3.5.2 Copula Analysis with Simulated Traffic . . . . . . . . . . . . . 33 3.6 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 4 Copula Analysis of Temporal Dependence of Markov Modulated Poisson Process 39 4.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 4.2 Related Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 4.3 Preliminaries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 4.3.1 Markov Modulated Poisson Process . . . . . . . . . . . . . . . 42 4.3.2 Why Do Existing Results Not Suffice? . . . . . . . . . . . . . 43 4.4 Theoretical Copula Analysis for MMPP, HoMMPP and HeMMPP . . . . . . . . . . . . . . . . . . . . . . . . . 46 4.4.1 Theoretical Copula Analysis for Single MMPP . . . . . . . . . 46 4.4.2 Theoretical Copula Analysis for HoMMPP . . . . . . . . . . . 48 4.4.3 Theoretical Copula Analysis for HeMMPP . . . . . . . . . . . 51 4.4.4 An Algorithm to Compute HeMMPP Copula . . . . . . . . . 52 4.5 Parametric Copula Modeling for MMPP trace . . . . . . . . . . . . . 56 4.6 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 5 Application of MMPP Copulas for Network Traffic Prediction 58 5.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 5.2 Copula-based Prediction . . . . . . . . . . . . . . . . . . . . . . . . . 59 5.2.1 Prediction Based on Theoretical Copulas . . . . . . . . . . . . 59 5.2.2 Prediction Based on Parametric Copulas . . . . . . . . . . . . 60 5.3 Experimental Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . 61 5.3.1 Evaluation Methods . . . . . . . . . . . . . . . . . . . . . . . 62 vii 5.3.2 Case Study on A Single MMPP Trace from Real-world . . . . 63 5.3.3 Case Study on HoMMPP Trace with Simulation . . . . . . . . 69 5.3.4 Case Study on HeMMPP trace . . . . . . . . . . . . . . . . . 73 5.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76 6 Application of MMPP Copulas in Composite Cloud Service Provisioning 77 6.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77 6.2 Related Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 6.3 System Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 6.4 A Copula Model for Latent Dependence Structure in Service Composition 81 6.5 Collaborative Auto-Scaling of Virtualized Functions . . . . . . . . . . 82 6.5.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82 6.5.2 Copula-based Scaling Matrix . . . . . . . . . . . . . . . . . . . 83 6.5.3 Utilization-based Individual Scaling Matrix . . . . . . . . . . . 83 6.5.4 Integrated Scaling Matrix . . . . . . . . . . . . . . . . . . . . 84 6.6 Performance Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . 84 6.6.1 MMPP modeling of Real-world Cloud Trace . . . . . . . . . . 84 6.6.2 Performance Evaluation with Synthetic Data . . . . . . . . . . 86 6.7 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90 7 Application of MMPP Copulas in Parameter Estimation 91 7.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91 7.2 Related Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92 7.3 Copula-based Parameter Estimation of MMPP . . . . . . . . . . . . . 93 7.3.1 Matching Marginal Distribution . . . . . . . . . . . . . . . . . 94 7.3.2 Matching Copula . . . . . . . . . . . . . . . . . . . . . . . . . 99 7.3.3 A Summary of MarCpa Algorithm . . . . . . . . . . . . . . . 101 7.4 Performance Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . 103 7.4.1 Performance Evaluation Based on Ground Truth . . . . . . . . 103 7.4.2 Performance Evaluation Based on Average Goodness-of-Fitting and Running Time . . . . . . . . . . . . . . . . . . . . . . . . 105 7.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109 8 Conclusions and Future Work 110 8.1 Contemporaneous Dependence Modeling . . . . . . . . . . . . . . . . 110 viii 8.2 Temporal Dependence Modeling . . . . . . . . . . . . . . . . . . . . . 111 8.3 Future Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111 Bibliography 113 ix List of Tables Table 3.1 Kolmogorov-Smirnov goodness of fit test for a 1 and a 2 in three datasets. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 Table 3.2 “Blanket” goodness of fit test for copula between a 1 and a 2 across three datasets. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 Table 3.3 Kolmogorov-Smirnov goodness of fit test for backlog based on simulated dataset . . . . . . . . . . . . . . . . . . . . . . . . . . 36 Table 3.4 “Blanket” goodness of fit test for copula between B1 and B2 based on simulated dataset . . . . . . . . . . . . . . . . . . . . . . . . 37 Table 4.1 Definition of Matrices . . . . . . . . . . . . . . . . . . . . . . . . 54 Table 5.1 Dependence Measures of BCpAug89 Trace from Theoretical Analysis and Empirical Analysis . . . . . . . . . . . . . . . . . . . . 64 Table 5.2 One-Step Prediction RMSE on BC-pAug89 trace with Different Training Percentages. . . . . . . . . . . . . . . . . . . . . . . . . 66 Table 5.3 Dependence Measures of the Associated Trace from Theoretical Analysis and Empirical Analysis . . . . . . . . . . . . . . . . . . 67 Table 5.4 One-Step Prediction RMSE on the Associated Trace with Different Training Percentages. . . . . . . . . . . . . . . . . . . . . . . 68 Table 5.5 Dependence Measures of the HoMMPP trace from Theoretical Analysis and Empirical Analysis . . . . . . . . . . . . . . . . . . 69 Table 5.6 One-Step Prediction RMSE on the HoMMPP Trace with Different Training Percentage. . . . . . . . . . . . . . . . . . . . . . . 71 Table 5.7 Two-step Dependence Measures of the HoMMPP Trace from Theoretical Analysis and Empirical Analysis . . . . . . . . . . . . . 71 Table 5.8 Two-Step Prediction RMSE on the HoMMPP Trace with Different Training Percentage. . . . . . . . . . . . . . . . . . . . . . . 73 Table 5.9 One-Step Prediction RMSE on the HeMMPP trace with Different Training Percentages. . . . . . . . . . . . . . . . . . . . . . . . . 75 x Table 5.10Two-Step Prediction RMSE on the HeMMPP trace with Different Training Percentages. . . . . . . . . . . . . . . . . . . . . . . . . 75 Table 6.1 Calculation of Collaborative Scaling Matrix Sg . . . . . . . . . . 84 Table 6.2 Comparison of The First Two Order of Moments of Arrival Counts in Every 300 Seconds . . . . . . . . . . . . . . . . . . . . . . . . 86 Table 6.3 Parameters of Simulated Composite System . . . . . . . . . . . 87 Table 6.4 Simulation results with initial capacity as ? j = 1 . . . . . . . . . 89 Table 6.5 Simulation results with initial capacity as ? j = 2 . . . . . . . . . 89 Table 7.1 Estimated parameters for the simulation trace. . . . . . . . . . . 104 Table 7.2 Kolmogorov-Smirnov test results on sample trace. . . . . . . . . 105 Table 7.3 Running time in seconds. . . . . . . . . . . . . . . . . . . . . . . 105 Table 7.4 Ratio of experiments that pass K-S tests. . . . . . . . . . . . . . 109 xi List of Figures Figure 1.1 Scatter plot of successive arrival counts of BCpAug89 . . . . . . 3 Figure 2.1 An explanatory example of the definition of copula. . . . . . . . 9 Figure 2.2 An explanatory example of Sklar’s theorem. . . . . . . . . . . . 10 Figure 2.3 An explanatory example of the invariant property . . . . . . . . 11 Figure 2.4 Fr´echet-Hoeffding lower bound copula Clb . . . . . . . . . . . . . 13 Figure 2.5 Product copula Cind . . . . . . . . . . . . . . . . . . . . . . . . . 13 Figure 2.6 Fr´echet-Hoeffding upper bound copula Cub . . . . . . . . . . . . 14 Figure 2.7 Scatter plot figures of three Archimedean copulas with parameter ? = 7. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 Figure 3.1 Different Bounds with r 1 = 0.5, r 2 = 1 . . . . . . . . . . . . . . 27 Figure 3.2 Different Bounds with r 1 = 2, r 2 = 2 . . . . . . . . . . . . . . . 27 Figure 3.3 Experiment scenario . . . . . . . . . . . . . . . . . . . . . . . . 30 Figure 3.4 Histogram of a 1 and a 2 based on samples in one dataset. . . . . 31 Figure 3.5 Histograms of B1 and B2 based on samples in simulated dataset. 35 Figure 3.6 Backlog bound curves of two input flows of the simulated system. 36 Figure 3.7 Backlog bound for aggregate traffic A. . . . . . . . . . . . . . . 38 Figure 4.1 Arrival counts of the two traces . . . . . . . . . . . . . . . . . . 44 Figure 4.2 Covariances of two MMPPs over different time lags . . . . . . . 45 Figure 4.3 Scatter plot with marginal histograms of Ai and Ai+1 in two traces 45 Figure 4.4 Bivariate frequency histogram (upper layer) with its heat map (lower layer) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 Figure 5.1 Copula contours for MMPP learned from BCpAug89 trace. . . 65 Figure 5.2 Prediction with theoretical copula on the testing set (last 20%) of BCpAug89 trace . . . . . . . . . . . . . . . . . . . . . . . . . 65 Figure 5.3 Prediction with theoretical copula on the testing set (last 20%) of the associated trace . . . . . . . . . . . . . . . . . . . . . . . 67 xii Figure 5.4 One-step copula contours for HoMMPP. . . . . . . . . . . . . . 70 Figure 5.5 Prediction with theoretical HoMMPP copula on the testing set (last 20%) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 Figure 5.6 Two-step copula contours for HoMMPP. . . . . . . . . . . . . . 72 Figure 5.7 Two-step prediction with theoretical copula on the testing set (last 20%) of the HoMMPP trace . . . . . . . . . . . . . . . . . 72 Figure 5.8 Copula contours for HeMMPP. . . . . . . . . . . . . . . . . . . 74 Figure 6.1 The conceptual diagram of service composition . . . . . . . . . 78 Figure 6.2 A queueing model for composite service . . . . . . . . . . . . . 80 Figure 6.3 Q-Q plot of arrival counts in every 300 seconds . . . . . . . . . 87 Figure 6.4 Copula-based inference on call arrival counts . . . . . . . . . . . 89 Figure 7.1 An example of the initialization of parameter ? . . . . . . . . . 96 Figure 7.2 Arrival counts of simulation trace. . . . . . . . . . . . . . . . . 103 Figure 7.3 Performance in DM for 3-state MMPP traces. . . . . . . . . . . 106 Figure 7.4 Performance in DC for 3-state MMPP traces. . . . . . . . . . . 106 Figure 7.5 Performance in running time for 3-state MMPP traces. . . . . . 107 Figure 7.6 Performance in DM for 5-state MMPP traces. . . . . . . . . . . 107 Figure 7.7 Performance in DC for 5-state MMPP traces. . . . . . . . . . . 108 Figure 7.8 Performance in running time for 5-state MMPP traces. . . . . . 108 xiii Nomenclature Notation of Chapter 2 C Copula C (u, v; ?) Parametric copula Clb Fr´echet-Hoeffding lower bound copula Cub Fr´echet-Hoeffding upper bound copula Cind Product copula ˆ C Empirical copula u, v The argument value of copula, or the sample value of marginal distribution function U, V, X, Y Random variables x, y Sample value of random variables F Cumulative distribution function ˆ F Empirical cumulative distribution function ? t Kendall’s tau ? s Spearman’s rho ? Pearson correlation coefficient ? + t Upper tail dependence ? - t Lower tail dependence xiv Notation of Chapter 3 A(t) Cumulative traffic arrives in time interval (0, t] A * (t) Cumulative traffic departs in time interval (0, t] S (t) Cumulative amount of service in time interval (0, t] A Traffic model S Service model ¯ F Complementary distribution function/ survival function a The curve function in the definition of arrival model ß The curve function in the definition of service model ? A sliding window size ? Rate in SBB model r 1 , r 2 Parameter of exponential distributions R1, R 2 Constant service rate to flows B(t) Backlog at time t D(t) Delay at time t B Random variable of backlog a Random variable of the amount of data sent per unit of time a i Sample value of a in the ith unit of time (?, µ1 , s 1 , µ 2 , s 2 ) Parameters of mixture of two Gaussian distributions Notation of Chapter 4 (Q, ?) Parameter of MMPP m number of states in MMPP ? The stationary distribution for the CTMC xv P (t) The transition matrix for the CTMC after time t I i i-th time slot Ai The random variable of the arrival count in i-th time slot of single MMPP trace Si The random variable of the state of MMPP in i-th time slot ? Length of time slots M The cumulative distribution function of Ai Ci 0 The copula between arrival counts Ai and Ai+i 0 , i 0 ? N Gj The marginal distribution of Ai on the condition that associated CTMC is in state j G(x) The vector G(x) = [G1 (x), G 2 (x), · · · , Gm(x)] A l i The random variable of the arrival count in i-th time slot of HoMMPP/HeMMPP traces M l The cumulative distribution function of A l i C l i 0 The copula between arrival counts A l i and A l i+i 0 , i 0 ? N ?Ci 0 The single MMPP copula gardient ?C l i 0 The HoMMPP/HeMMPP copula gardient ( l Q, l ?) The parameters of the l-th MMPP in HoMMPP/HeMMPP l Ai The random variable of the arrival count in i-th time slot of the l-th MMPP trace l M The cumulative distribution function of l Ai l p The probability mass function of l Ai l Ci 0 The copula between arrival counts l Ai and l Ai+i 0 , i 0 ? N ?l Ci 0 The single MMPP copula gradient of the l-th MMPP xvi ˆ a The upper threshold of interested range of arrival counts ˆ M l The empirical cumulative distribution function of A l i C (u i , u i+i 0 ; ?) The parametric copula between A l i and A l i+i 0 learnt from tarce Notation of Chapter 5 x i Sample value of Ai or A l i ˆ x i Predicted value of Ai or A l i c(u i , u i+i 0 ; ?) Parametric copula density function (?1, ? 2 ,  t ) Parameters of AR(1) model s Parameter of LPC(1) model A 0 i An associate trace of Ai Notation of Chapter 6 d Scaling delay ß Capacity unit ? j Current capacity for VF j µ j Capacity level for VF j Sc Copula-based scaling matrix Su Utilization-based scaling matrix Sg Integrated scaling matrix % Utilization of queueing system Notation of Chapter 7 u i (ˆ u i ) Marginal (empirical) distribution value of Ai ? i ( ˆ ? i ) (Empirical) copula value of Ai and Ai+1 W1, W 2 Objective function to minimize in two-step matching xvii T1 , T2 Parameter sets to estimate in the first, and the second step a Step-size of gradient descent T (r) 1 , a (r) Estimated parameter, step-size in the r-th iteration H Coefficient matrix for copula matching E Constraints coefficient matrix for copula matching b Constraints vector for copula matching DM K-S distance between testing marginal and empirical marginal distributions DC K-S distance between testing copula and empirical copula xviii ACKNOWLEDGEMENTS I would like to thank: my supervisors, Dr. Kui Wu and Dr. Venkatesh Srinivasan, for giving me the strong support and guidance during my PhD. Whenever I am stuck with a research problem or have questions about research, you are always open to help me. Your continuous advising and mentoring in the fast four years are of great value to me. I am deeply grateful and happy to pursue a PhD degree under your supervision. my husband, Dr. Cheng Chen, for your love. You have always been with me through all those tough moments. Your encouragement always gives me the passion and strength to pursue what we believe and what we value the most. Your companionship makes our life wonderful and full of happiness. my family, for your unconditional love and companionship. You are always there to share and witness every moment of my life even though we are not living in the same country. I feel sorry that we don’t have much time together physically these years. I would like to express my sincere appreciation for your support and encouragement during the years of my education. my labmates and friends, for sincere friendship, your valuable advice and help, and the unforgettable moments we have spent together. xix DEDICATION To my family. Chapter 1 Introduction In this chapter, we describe the motivation for applying copula theory in the computer network domain, and explain our research goals and contributions. 1.1 Motivation In the modern society, our daily life heavily depends on computer networks. Everyday, tremendous network traffic is transmitted in both local area networks and the Internet for various applications. Whenever we transmit files between hosts, access a remote computer, visit a website, or watch a video online, network packets are generated and transmitted on networks. As more and more applications are emerging over the Internet, there is a high demand to explore accurate and robust models for network traffic flows. In many cases, a good network traffic model is a prerequisite for research in computer networks. A good network traffic model means that the model can characterize and mimic specific real network traffic well. A good model can identify specific network traffic [57], simulate the traffic similar to the real traffic [48], and analyse the network performance [9]. Network traffic models can be divided into two groups: the models for statistical properties, such as mean, variance, skewness [21], and the models for dependence, such as covariance and correlation [46, 53]. The dependence modeling is of great significance to characterize network traffic and deepen our understanding of network traffic from a different angle. Considering the period of FIFA World Cup or Olympic Games, hundreds of thousands of people may visit the same website to watch the 2 game videos from home computers. When modeling the network traffic flows sent from home computers to the designed server, we cannot just add up the models of each individual flow, rather we need to take the dependence among the constituent flows into consideration. A dependence model between traffic flows will lead to a more accurate model for the aggregate flow and help to improve the analysis of network performance. In another example where there is a single traffic flow from a source to a destination, understanding the dependence between its arrivals over different times is important to predict future arrivals or detect abnormal events [4]. The two scenarios we consider above show the impact of two categories of dependence in network traffic, the contemporaneous dependence and the temporal dependence. The contemporaneous dependence is the dependence between arrivals from different traffic flows, while temporal dependence is the dependence between arrivals from the same traffic flow but over different times. Both contemporaneous and temporal dependencies in network traffic are non trivial to model. The contemporaneous dependence in network traffic is normally ignored for ease of analysis. Network performance analysis under stochastic network framework suffers from this ignorance and leads to a loose bound on network delay or backlog in practice [44]. The temporal dependence in one network traffic flow has existing solutions that are mostly based on the covariance or correlation [53]. However, the covariance or correlation can only measure the linear dependence, which discards abundant dependence information carried by traffic flows. We take the traffic trace BCpAug89 [32] as an example. Fig. 1.1 shows the scatter plot of the successive arrival counts (number of arrivals) every second. The shape of the scatter plot shows the dependence between successive arrival counts. From the figure, the linear dependence only considers the projection of all the points onto a straight line, while neglecting their (varying) vertical distances to the line. Therefore, linear dependence measures, such as covariance and autocorrelation, only measure the dependence partially, and are far from sufficient to reflect the complex dependence structure. With the significance of network dependence modeling and the lack of rich models that capture the full spectrum of dependence structures, we are motivated to apply an advanced tool, copula, to model the functional dependence of network traffic and apply the new model to improve network studies. Copulas, as the term indicates, are functions that join one-dimensional marginal distributions to multivariate distributions. As an effective mathematical tool to capture dependence, copulas have been very popular in the domain of financial analysis, especially for risk manage- 3 0 200 400 600 800 0 200 400 600 800 A i A i+1 Figure 1.1: Scatter plot of successive arrival counts of BCpAug89 ment. To estimate the market risk appropriately, more than one assets need to be considered. Copulas are shown flexible and useful to measure the dependence between assets[67, 40] and the dependence along the time series of a single asset[66, 65, 71]. Although copulas have been considerably researched in the finance domain, they are quite new and rarely exploited in other domains. In recent years, researchers attempt to extend the usage of copulas in other areas. Specifically, copulas are used in the telecommunication networks domain to model the shortest-path trees[60], and in the agriculture domain to model the dependence between energy and agricultural commodities[50, 49]. To the best of our knowledge, copulas are seldom applied in computer networks domain, though dependence modeling of network traffic attracts a lot of attention and is considered of great significance for the examination and improvement of the network performance[46]. 1.2 Research Goals This thesis applies copulas to improve both contemporaneous and temporal dependence modeling of network traffic, which could further benefit the applications relying on dependence. Specifically, the research goals are described as follows: 1. Contemporaneous dependence modeling: Model the contemporaneous dependence between network traffic flows with copula. Contemporaneous dependence modeling is integrated to a network analysis framework, stochastic network calculus (SNC). With the contemporaneous dependence captured, the derived performance bounds would be tighter and more accurate. 4 2. Temporal dependence modeling: Model the temporal dependence for network traffic flow with copula. The temporal dependence in terms of copula can be used to improve the following network applications: • Network traffic prediction: By understanding the temporal dependence of network traffic, we can find a solution to predict the future arrivals based on current observations. • Cloud service provisioning: This application is based on network traffic predictions. Cloud service can be better offered according to the requested amount. Designing an effective service provisioning strategy based on prediction of requested amount is a goal in this context. • Parameter estimation problem: We propose a parameter estimation method for a widely-used network traffic model, Markov Modulated Poisson Process. The parameters will be estimated by matching statistical moments and temporal dependence, separately. We study both theoretical and parametric copulas for MMPP and design a method for fast and accurate parameter estimation. 1.3 Contributions The thesis makes the following contributions: 1. Copula analysis for contemporaneous dependence in statistical network calculus In Chapter 3, we integrate copula into the framework of SNC and make the following contributions: • we augment the power of SNC with copula analysis to utilize the dependence structure between traffic flows. In particular, copula analysis can be integrated into the SNC framework to provide tighter performance bounds. Such analysis offers extra benefit in inferring the adaptive behavior of some proprietary systems. • Using copula analysis, we show the range of stochastic bounds that SNC can achieve. This discovery has a deep implication in the future design of flow scheduling or input buffering methods. 5 • A real-world case study as well as simulation evaluation demonstrate the practicality of copula analysis and its improvement over the performance of SNC that is oblivious to the dependence structures between flows. 2. Copula analysis for temporal dependence of Markov Modulated Poisson Process In Chapter 4, we fully study the temporal dependence of Markov Modulated Poisson Process and makes the following contributions: • We use copula to analyse the dependence structure of MMPP traffic. The copula-based dependence reveals richer information of temporal dependence and is more powerful than the commonly-used measures, covariance and correlation. • We give the exact form of temporal dependence of MMPP with arbitrary number of states. This is the first theoretical result on the functional temporal dependence of multi-state MMPP. • We propose a way to construct copula for superposition of MMPPs. Recursive algorithms are designed to calculate the numerical values of copulas. • We propose parametric copula modeling method for both single MMPP and superposition of MMPPs. 3. Application of MMPP copula for traffic prediction In Chapter 5, we apply MMPP copula for network traffic flow prediction and make the following contributions: • We introduce MMPP traffic prediction based on either theoretical copulas or parametric copulas. • We demonstrate applications of MMPP copula on both real-world traffic traces and simulated traffic traces. Both single MMPP flow and superposition of multiple MMPP flows are studied. • Case studies show that our copula-based traffic prediction method is more accurate and stable than existing methods. 4. Application of MMPP copula in collaborative auto-scaling of cloud service In Chapter 6, we apply MMPP copula in composite cloud service system to 6 design effective service provisioning strategy and make the following contributions: • We introduce a novel approximation approach that transforms the timeordered, spatially distributed calls to virtual functions (VFs) into a Markov Modulated Poisson Process (MMPP). This method solves the challenging problem in performance modeling of composite service, where the workflow of a task may pass through multiple VFs in an arbitrary order. By analysing the performance of MMPP input into a virtual queue, we can easily estimate the performance of composite services. • To address the difficulty that the amount of calls at different VFs might scale up differently, we introduce a copula model to capture the stable dependence structure, even if the amount of calls to different VFs may scale up differently. This unique feature greatly simplifies the dependence modeling, since there is no need to rebuild the dependence model when the total amount of service calls varies. • Cloud brokerage needs a mechanism to carefully balance the cost of purchasing VF resources and the QoS of composite service. As such, we propose a tiered, collaborative resource auto-scaling strategy, based on the predictive power of the copula model. 5. Application of MMPP copula in parameter estimation In Chapter 7, we apply MMPP copula to develop a fast and accurate estimation method to learn parameters of MMPP, and make the following contributions: • We model the joint behavior of successive arrival counts in terms of their marginal distribution and copula. The theoretical forms of marginal distribution and copula of arrival counts in MMPP lay solid foundation for parameter estimation. • Based on the MMPP copula, we propose a two-step estimation algorithm, MarCpa, to estimate MMPP parameters by matching marginal and matching copula separately. • Case studies with a large number of simulations demonstrate that our proposed method is more efficient and accurate than existing estimation methods that learn MMPP parameters from arrival counts. 7 1.4 Publications Fang Dong, Kui Wu, and Venkatesh Srinivasan. “Copula Analysis for Statistical Network Calculus,” in 2015 IEEE Conference on Computer Communications (INFOCOM), April 2015. Fang Dong, Kui Wu, Venkatesh Srinivasan, and Jianping Wang. “Copula Analysis of Latent Dependency Structure for Collaborative Auto-scaling of Cloud Services”, in 2016 25th International Conference on Computer Communication and Networks (ICCCN), August 2016. Fang Dong, Kui Wu, Venkatesh Srinivasan. “Copula-based Parameter Estimation for Markov-modulated Poisson Process”, in Proceedings of IEEE/ACM International Symposium on Quality of Service (IWQoS), June 2017. Fang Dong, Kui Wu, Venkatesh Srinivasan. “Copula Analysis of Temporal Dependence Structure in Markov Modulated Poisson Process and Its Applications,” ACM Transactions on Modeling and Performance Evaluation of Computing Systems (ToMPECS), accepted in May 2017. 8 Chapter 2 Preliminaries on Copula Theory 2.1 Definitions and Basic Properties We start with the definition of copulas and three core theorems. Definition 1. (Copulas) A 2-dimensional copula is a function C having the following properties [59]: 1. Its domain is [0, 1] × [0, 1]; 2. C is 2-increasing, i.e., for every u 1 , u 2 , v 1 , v 2 ? [0, 1] and u 1 = u 2 , v 1 = v 2 , we have C (u 2 , v 2 ) - C (u 2 , v 1 ) - C (u 1 , v 2) + C (u 1 , v 1 ) = 0. 3. C (u, 0) = C (0, v ) = 0, C (u, 1) = u, C (1, v ) = v, for every u, v ? [0, 1]. The function is called a subcopula if it has the second and the third properties of copula, but its domain is b 1 × b 2 , where b 1 and b 2 are subsets of [0, 1] containing 1 and 0. By definition, a copula is essentially the joint distribution function of two random variables, denoted by U and V , that follow uniform distributions on the interval [0, 1]. That is, C (u, v) = FUV (u, v) where U ~ Uni(0, 1), V ~ Uni(0, 1) and FUV is their joint distribution. An example is given in Example 1 to visualize the idea. In the example, the scatter plot shows the way U and V jointly distribute; In other words, the plot suggests the relationship between U and V . Different relationships will lead to different copulas. Therefore, the shape of a scatter plot of U and V indicates copula. Both scatter plot and contour are widely-used ways to visualize a copula. 9 Example 1. Consider two random variables U and V that follow uniform distribution on [0, 1] and their samples shown in scatter plot in Fig. 2.1a. The scatter plot shows how U and V jointly distribute on two dimensional plane. The contour of the related copula is shown in Fig. 2.1b. 0 0.5 1 U9Uni(0,1) 0 0.5 1 V9Uni(0,1) (a) Scatter plot of samples of (U, V ) 0.1 0.1 0.1 0.1 0.2 0.2 0.2 0.3 0.3 0.3 0.4 0.4 0.4 0.5 0.5 0.6 0.6 0.7 0.8 0.9 0 0.2 0.4 0.6 0.8 1 u 0 0.2 0.4 0.6 0.8 1 v (b) Contour of the related copula Figure 2.1: An explanatory example of the definition of copula. Theorem 1. (Sklar’s theorem) [59] Let FXY be a joint distribution function with marginals FX and FY , then there exists a copula C such that for for all x and y, FXY (x, y) = P r(X = x, Y = y) = C (FX (x), F Y (y)). If the marginals FX and FY are continuous, then copula C is unique; otherwise, C is uniquely determined on the range of the marginals. Example 2 is given for explanation of the theorem. Sklars theorem is the core of copula theory. It shows how copula connects marginals with joint distribution, which is the essential way that copula captures dependence between random variables. On one hand, Sklars theorem is especially useful since the joint distribution of random variables is hard to find directly in many applications [11, 59]. In this situation, integration of a copula model and marginals makes it easy to understand the joint behaviour. On the other hand, Sklar’s theorem implies that copula, as a dependence measure, is entirely separated from both marginals and joint distribution. The modeling of marginal distributions and the modeling of copula could be totally separate to fit different application scenarios. Example 2. Consider two random variables X ~ Exp(1) and Y ~ Gaussian(1, 2.5), with their samples (x, y) shown in Fig. 2.2a. Regarding the marginal distribution value 10 of X and Y as random variable U and V , every sample pair (x, y) is mapped to a sample pair (u, v) in the marginal domain in the way u = FX (x) = P r(X = x) = 1 - e -x , v = FY (y) = P r(Y = y) = 1 2.5 v 2p Z y -8 -(y 0 - 1) 2 2 * 2.5 2 dy 0 . The scatter plot of U and V in Fig. 2.2b indicates the copula that represents the joint distribution of U and V , and is called the copula between X and Y . The copula links the marginal distribution of X and Y into their joint distribution in the way P r(X = x, Y = y) = P r(U = u, V = v) = C (u, v) = C (F (x), F (y)). 0 2 6 2 4 6 8 4 X ~Exp(1) Y ~ Gaussian(1,2.5) x-y scatter (a) X-Y scatter plot. 0 1 0 0.2 0.4 0.6 0.8 1 0.5 U ~Uni(0,1) V ~Uni(0,1) u-v scatter (b) U -V scatter plot. Figure 2.2: An explanatory example of Sklar’s theorem. Theorem 2. (The invariant property of copulas) [59] Let X and Y be continuous random variables with copula CXY . If a1 and a2 are strictly increasing functions on the range of X and the range of Y , respectively, then Ca1(X)a2(Y ) = CXY . In other words, CXY is invariant under strictly increasing transformations of X and Y . As Sklar’s theorem shows, copula is independent from both marginals and joint distributions, so the dependence in terms of copula is stable when the marginals change functionally, which is formally defined in the above invariant property. The practical meaning of the invariant property in computer networks domain is that the contemporaneous dependence between traffic flows and the temporal dependence 11 within one traffic flow in terms of copula will remain the same, even when the flow arrivals all scale up functionally. On this condition, we don’t need to build the dependence repeatedly. Example 3 shows an example for the invariant property. The example also shows other dependence measures, such as correlation and covariance, don’t satisfy the invariant property, making copula much more stable for practical use. Example 3. X1 is a random variable Gaussian distributed with the mean as 0 and the standard deviation as 1. Y 1 is a random variable functionally dependent with X1 , i.e., Y 1 = X 2 1 . Fig. 2.3a and 2.3b shows the scatter plot of X1 and Y 1 , and the scatter plot in the marginal domain, respectively. -2 0 2 0 5 10 X 1 ~ Gaussian(0,1) Y 1 ~X 1 2 X 1 - Y 1 scatter (a) X1 -Y 1 scatter plot. 0 1 0 0.2 0.4 0.6 0.8 1 0.5 U1 ~Uni(0,1) V1 ~Uni(0,1) u 1 -v 1 scatter (b) U1 -V 1 scatter plot. 0 5 10 5 10 15 X 2 ~X 1 2 Y 2 ~Y 1 +3 X 2 - Y 2 scatter (c) X2 -Y 2 scatter plot. 0 1 0 0.2 0.4 0.6 0.8 1 0.5 U2 ~Uni(0,1) V2 ~Uni(0,1) u 2 -v 2 scatter (d) U2 -V 2 scatter plot. Figure 2.3: An explanatory example of the invariant property Let’s generate another two random variables by applying increasing functions on X1 and Y 1 respectively, e.g., X2 = X 2 1 , Y 2 = Y 1 + 3. After the transformation, the 12 X2 - Y 2 scatter plot, in Fig. 2.3c, appears completely different from X1 - Y 1 scatter plot. However, in the marginal domain, the scatter plot turns to be the same as comparing Fig. 2.3d and 2.3b. As the scatter plot figures of U1 - V 1 and U2 - V 2 indicate two copulas, we can tell the dependence structure between random variables, in terms of copulas, has been kept stable under the increasing function transformation. From Figs. 2.3a and 2.3c, we can also tell that X1 and Y 1 are not linearly dependent, whereas X2 and Y 2 are. Therefore, the linear dependence structure is not invariant under functional transformation. Theorem 3. (Fr´echet-Hoeffding bounds) [59] For every copula C and for all u, v in [0, 1], the following inequality holds Clb (u, v) = max(u + v - 1, 0) = C (u, v) = min(u, v) = Cub (u, v). (2.1) We refer to Cub as the Fr´echet-Hoeffding upper bound and Clb as the Fr´echet-Hoeffding lower bound. Fr´echet-Hoeffding bounds show the range of all possible copulas. Consider copula C to model the dependence between X and Y . When C = Clb , Y is a decreasing function of X ; when C = Cub , Y is an increasing function of X [35]. Therefore Fr´echetHoeffding bounds actually capture two extreme functional dependencies. Except for these two special copulas, a third important copula is product copula, Cind (u, v) = uv. X and Y is independent if their copula is Cind . Figs. 2.4, 2.5 and 2.6 visualize the copulas Clb , Cind and Cub , respectively, with their scatter plot figures and contour figures. Theorem 4. (Inversion method) [59] Let FXY be a joint distribution function with marginals FX and FY . Let F -1 X and F -1 Y be the inverse function of FX and FY . Then the copula between X and Y can be constructed as C (u, v) = FXY (F -1 X (u), F -1 Y (v)) ?u, v, such that FXY (x, y) = C (FX (x), F Y (y)) ?x, y. The inversion method is used to construct a theoretical copula for the problem at hand. It uses Sklar’s theorem to construct copulas. The inversion method leads 13 0 0.5 1 U9Uni(0,1) -1 -0.5 0 V9Uni(0,1) (a) Scatter plot in U - V plane. 0.1 0.1 0.1 0.1 0.2 0.2 0.2 0.3 0.3 0.3 0.4 0.4 0.4 0.5 0.5 0.6 0.6 0.7 0.8 0.9 0 0.2 0.4 0.6 0.8 1 u 0 0.2 0.4 0.6 0.8 1 v (b) Copula contour. Figure 2.4: Fr´echet-Hoeffding lower bound copula Clb . 0 0.5 1 U9Uni(0,1) 0 0.5 1 V9Uni(0,1) (a) Scatter plot in U - V plane. 0.1 0.1 0.1 0.2 0.2 0.2 0.3 0.3 0.4 0.4 0.5 0.5 0.6 0.7 0.8 0.9 0 0.2 0.4 0.6 0.8 1 u 0 0.2 0.4 0.6 0.8 1 v (b) Copula contour. Figure 2.5: Product copula Cind . to a unique copula when the marginals are continuous, and leads to a unique subcopula when the marginals are not continuous. The unique subcopula can be easily extended to a copula via various ways, for instance, bilinear interpolation [59]. Thus, a subcopula shares most properties of copulas. In the following context, we do not differentiate between subcopula and copula, because their difference does not impact the our analysis and application in following chapters. 2.2 Copula-based Dependence Measures The copula-based dependence measures satisfy the invariant property as shown in Theorem 2. There are two main ways to measure the copula-based dependence. One is based on concordance statistics, which measures the extent to which two random 14 0 0.5 1 U9Uni(0,1) 0 0.5 1 V9Uni(0,1) (a) Scatter plot in U - V plane. 0.1 0.1 0.1 0.1 0.2 0.2 0.2 0.3 0.3 0.3 0.4 0.4 0.4 0.5 0.5 0.6 0.6 0.7 0.8 0.9 0 0.2 0.4 0.6 0.8 1 u 0 0.2 0.4 0.6 0.8 1 v (b) Copula contour. Figure 2.6: Fr´echet-Hoeffding upper bound copula Cub . variables are both large or small at the same time. The other one is tail dependence, which measures the amount of dependence in the upper and lower quadrant tail of joint distributions. Kendall’s tau and Spearman’s rho are two popular copula-based dependence measures defined in terms of concordance. Their definitions are as follows: Definition 2. (Kendall’s tau) [59] Let (Xi , Y i ) and (Xj , Y j ) denote two observations from a vector (X, Y ) of continuous random variables with copula between X and Y as C (u, v), the Kendalls’ tau is defined as ? t = P r((Xi -Xj )(Y i -Y j ) > 0)-P r((Xi -Xj )(Y i -Y j ) < 0) = 4 Z 1 0 Z 1 0 C (u, v)dC (u, v)-1. (2.2) Definition 3. (Spearman’s rho) [59] Let (Xi , Y i ), (Xj , Y j ) and (Xk , Y k ) denote three observations from a vector (X, Y ) of continuous random variables with copula between them as C (u, v), the Spearman’s rho is defined as ? s = 3(P r((Xi -Xj )(Y i -Y k ) > 0)-P r((Xi -Xj )(Y i -Y k ) < 0)) = 12 Z 1 0 Z 1 0 C (u, v)dudv-3. (2.3) Essentially, both Kendall’s tau and Spearman’s rho are calculated by using concordance minus discordance between samples of two random variables. Although their values could be quite different, they have the same range from 0 to 1, and are monotonic increasing functions of each other. From the values of Kendall’s tau 15 and Spearman’s rho, the degree of dependence is explained as follows: a large value indicates stronger positive functional dependence between variables, and a smaller value indicates stronger negative functional dependence between variables. The functional dependence degree is reflected by absolute values |? t | or |? s|. Three special dependence values are listed below with the related copulas [29]: • ? t = 1 or ? s = 1 is equivalent to C = Cub , indicating the largest positive functional dependence; • ? t = -1 or ? s = -1 is equivalent to C = Clb , indicating the largest negative functional dependence; • ? t = 0 or ? s = 0 is equivalent to C = Cind , indicating the independence As copula-based measures, both Kendall’s tau and Spearman’s rho can capture dependence beyond linear scope. Taking X1 and Y 1 in Example 3 as an example, the copula between X1 and Y 1 is Cub , and the copula-based dependence degree between the two random variables are ? t = 1 and ? s = 1. With copula-based dependence measures, the strong functional dependence between X1 and Y 1 has been shown. However, with linear dependence measures, for example, Pearson correlation coefficient, ? = 0 between X1 and Y 1 shows a zero dependence degree, and does not reflect the actual dependence. Tail dependence calculates the probability that two random variables achieve extreme large (or small) value simultaneously. The upper tail dependence and lower tail dependence are defined as follows: Definition 4. (Tail dependence) [29] Given two random variables X and Y with marginals as FX and FY , and their copula C , the upper tail dependence is ? + t = lim u?1 P r(X > F -1 X (u)|Y > F -1 Y (u)) = lim u?1 1 - 2u + C (u, v) 1 - u ; (2.4) the lower tail dependence is ? - t = lim u?0 P r(X < F -1 (u)|Y < F -1 (u)) = lim u?0 C (u, u) u . (2.5) In practice, the tail dependence shows the possibility of the concurrence of two extreme events. The information on the concurrence of extreme events gives a new aspect of understanding of dependence, and is helpful to monitor and identify events on extreme conditions. 16 2.3 Parametric Copulas In many applications, the exact copulas between random variables are difficult to construct. So parametric families of copulas have been proposed and explored to cover various types of dependence structures. Elliptical copulas and Archimedean copulas are two copula families mostly studied. Elliptical copulas are derived from multivariate distribution implicitly. They strictly have symmetrical lower tail dependence and upper tail dependence, indicating that the probability of occurrence of extreme large values is equal to the probability of occurrence of extreme small values. The typical elliptical copulas are Gaussian copula and Student’s t copula. Archimedean copulas are explicit copulas, which have clear and closed forms. Compared with elliptical copulas, Archimedean copulas are more flexible on the property of tail dependence. They could model either equal or distinct upper and lower tail dependence. Besides, Archimedean copulas are easier to construct due to the few parameters to estimate. Even with few parameters, this family of copulas include a great variety of copulas, and can model the dependence structure very effectively. All these advantages make Archimedean copulas good candidates for most applications. Three popular one-parameter Archimedean copulas are Clayton copula, Gumbel copula and Frank copula: • Clayton copula C (u, v; ?) = [max{u -? + v -? - 1, 0}] -1/? , ? ? [-1, 8) \ {0}; • Frank copula C (u, v; ?) = - 1 ? log[1 + (exp(-?u) - 1)(exp(-?v) - 1) exp(-?) - 1 ], ? ? [-8, 8) \ {0}; • Gumbel copula C (u, v; ?) = exp[-((- log u) ? + (- log v) ? ) 1/? ], ? ? [1, 8). The scatter plot figures of these three copulas are shown in Fig. 2.7. The three copulas are widely used due to several reasons. First, they are all one-parameter copulas, making it easier to fit models into the real problem. Second, the parameter of copula relates to copula-based dependence, Kendall’s tau and Spearman’ rho directly. 17 0 0.5 1 u 0 0.2 0.4 0.6 0.8 1 v (a) Clayton copula. 0 0.5 1 u 0 0.2 0.4 0.6 0.8 1 v (b) Frank copula. 0 0.5 1 u 0 0.2 0.4 0.6 0.8 1 v (c) Gumbel copula. Figure 2.7: Scatter plot figures of three Archimedean copulas with parameter ? = 7. For instance, ? t = ?/(? + 2) for Clayton copula, and ? t = 1 - 1/? for Gumbel copula. Thus the copula parameter itself reflects the degree of dependence. Finally, the three copulas capture three extremely distinct tail dependencies. Specifically, Clayton copula captures low tail dependence, Gumbel copula captures upper tail dependence, and Frank copula capture symmetric tail dependence. Taking Clayton copula as an example, we can observe that samples cluster on the bottom left of scatter plot in Fig. 2.7a, indicating strong lower tail dependence. In this thesis, we will exploit these three Archimedean copulas for dependence modeling in network applications. 2.4 Empirical Copula Empirical copula is statistically counted from samples and defined as Definition 5. Given two random variables X and Y , and n number of observed 18 sample pairs (x i , y i ). The empirical copula between X and Y , ˆ C is defined as: ˆ C (u, v) = 1 n n X i=1 1(u i = u, v i = v) = 1 n n X i=1 1( ˆ FX (x i ) = u, ˆ FY (y i ) = v), (2.6) where ˆ FX and ˆ FY are empirical marginal distribution functions defined as ˆ FX (x i ) = 1 n n X i 0 =1 1(x i 0 = x i ) (2.7) ˆ FY (y i ) = 1 n n X i 0 =1 1(y i 0 = y i ) (2.8) From the definition, the empirical copula is purely determined by samples, so it is the raw model that represents the samples. Empirical copula can be used as benchmark to test whether a parametric copula is the underlying copula of samples [36]. Many research works use empirical copula for goodness-of-fitting test [26, 36]. If the parametric copula to test is close enough to empirical copula, it can be accepted as the underlying copula; otherwise, it is not the copula of samples. 2.5 Summary From the introduction to copula theory in this chapter, we show the advantages of copulas for dependence modeling. First, copulas can measure the functional dependence beyond linear scope with Spearman’s rho and Kendall’s tau. Second, copulas separate marginals from joint distributions, allowing copulas to remain stable and invariant even when the marginals change functionally. Third, copulas are very useful to reveal the joint information of random variables. Usually, marginals are more accessible than joint distributions, and joint distributions are hard to find directly. In this situation, integration of a copula model and marginals makes it easier to understand the joint behaviour. All these benefits of copulas help to better understand the dependence in network traffic. Therefore, in this thesis, we use copula theory for dependence modeling, and explore its applications in different computer network scenarios. 19 Chapter 3 Copula Analysis for Contemporaneous Dependence and Its Application in Statistical Network Calculus 3.1 Introduction Since its introduction in early 1990s [22], network calculus has been widely adopted to analyse complex queueing systems, such as multimedia networks, where the Markovian property of arrivals generally does not hold and thus traditional queueing theory becomes hard to apply. Network calculus was initially developed along the deterministic track [15, 51] and later evolved to stochastic version [15, 18, 30, 44]. Stochastic network calculus (SNC) has received much attention in recent years due to its power in deriving probabilistic performance bounds, which are more meaningful in practice. The practical use of SNC, however, has faced challenges due to the lingering problem in deriving tight stochastic performance bounds [20]. In particular, inappropriate traffic models and the extensive use of model transform may lead to loose performance bounds [20]. While substantial efforts have been devoted to improving the bounds [19, 42], the problem has only been tackled for special types of traffic and service models, using probability inequalities, e.g., Chernoff bounds and martingale inequalities. In many cases, the independence assumption is required to ease the analysis, e.g., the independence of the traffic arrivals and the independence between 20 the arrivals and the service. In practice, loose bounds may occur due to the inaccurate a-prior traffic arrival models and/or the obliviousness of potential correlations in traffic flows. To alleviate this problem, Beck et al. [9] proposed to integrate statistical inference, based on past traffic data, into SNC. This important move opens the door for new opportunities to use the powerful analytical toolsets of SNC for real-world applications. Along the same line of statistical modeling and inference, this chapter points out the potential benefits of using copula theory in SNC. With copula analysis and numerical experiments, we clearly show the region where copulas can be helpful and the best bound that SNC can possibly achieve. Statistical analysis on real-world trace data in an experiment with Skype conference calls shows that copula analysis can discover the (hidden) correlation between traffic flows, which in turn can help obtain tighter performance bounds. The discovery of copula modeling provides hints and also sheds light on the adaptive strategies in proprietary systems such as Skype. To the best of our knowledge, none of existing work has utilized copula analysis to enhance the capability of SNC in traffic modeling and performance bounds improvement. 3.2 Related Work The theory of network calculus was first proposed by Cruz in 1991 [22, 23] for network performance evaluation. There are two main tracks of network calculus theorydeterministic network calculus (DNC) and stochastic network calculus (SNC). The details and the results of deterministic network calculus theory can be found in the books [51, 15]. This track of research only analyse the performance bounds of the worst case, which are too loose for practical use. As an alternative, stochastic network calculus was developed. The basic properties and results of SNC are concluded in [43, 44]. It is generally non-trivial to derive tight performance bounds. Union bounds are generally used [44]. To achieve tighter performance bounds, independence case study is introduced in [44], which assumes the independence between arrivals and service. In addition, Martingales have been used to tighten the performance bounds [68, 20, 19, 42]. The basic idea is to construct a Martingale process and derive performance bounds with Doob’s inequality. Whether or not the above proposed assumptions accord well with the real traffic or service process is a problem. An error model may lead to failure when applying theoretical bounds on real case study. To avoid this situation, Beck et al [9] propose 21 statistical network calculus (StatNC). In his work, traffic models are established by measuring arrivals statistically. The performance bounds are also analysed in a statistical way. Due to advantage of StatNC, the performance bounds study reap great accuracy and robustness for different cases. Our work in Chapter 3 shares the same spirit as StatNC. Nonetheless, they are significantly different in that we make use of copula to capture the dependence between flows, while the work of [9] mainly focuses on the statistical estimation of a single flow. 3.3 Background of Stochastic Network Calculus We introduce the notation and key concepts of stochastic network calculus [44, 54]. We assume that all arrival curves and service curves are non-negative and wide-sense increasing functions. Conventionally, A(t) and A * (t) are used to denote the cumulative traffic that arrives and departs in time interval (0, t], respectively, and S (t) is used to denote the cumulative amount of service provided by the system in time interval (0, t]. For any 0 = s = t, let A(s, t) = A(t) - A(s), A * (s, t) = A * (t) - A * (s), and S (s, t) = S (t) - S (s). By default, A(0) = A * (0) = S (0) = 0. We denote by F the set of non-negative wide-sense increasing functions, i.e., F = {f (·) : ?0 = x = y, 0 = f (x) = f (y)}, and by ¯ F the set of non-negative wide-sense decreasing functions, i.e., ¯ F = {f (·) : ?0 = x = y, 0 = f (y) = f (x)}. For any random variable X , its distribution function, denoted by FX (x) = P r{X = x}, belongs to F , and its complementary distribution function (or survival function), denoted by ¯ FX (x) = P r{X > x}, belongs to ¯ F . The (min, +) convolution of functions f and g is useful for SNC, and is defined 22 under the (min, +) algebra [15, 22, 51]: (f ? g)(t) = inf 0=s=t {f (s) + g(t - s)}. (3.1) In addition, the (min, +) deconvolution [15, 22, 51] of functions f and g is defined as: (f g)(t) = sup s=0 {f (t + s) + g(s)}. (3.2) For simplicity, we denote [x] 1 = min{x, 1} and [x] + = max{x, 0} in the following. Stochastic traffic arrival curve and stochastic service curve are core concepts in stochastic network calculus, with the former used for traffic modeling and the latter for service modeling. In the literature, there are different definitions of stochastic arrival curve and stochastic service curve [44]. Definition 6. The t.a.c. model [44]: A flow A(t) is said to have a traffic-amountcentric (t.a.c.) stochastic arrival curve a ? F with bounding function f ? ¯ F , denoted by A ~tac hf, ai , if for all t = s = 0 and all x = 0, P r{A(s, t) - a(t - s) > x} = f (x). (3.3) In addition, we call A(t - d, t), 0 = d = ? the statistic of A within sliding window of size ?. Intuitively, the above model means the cumulative amount of traffic arrivals in any time period is upper bounded by a function with some violation probability. The model is actually quite general and covers several broadly-used models. For example, the stochastically bounded burstiness (SBB) model [82] is a special case of the t.a.c. model by setting a(t - s) = ? · (t - s). Following the same notation, when the traffic arrival A(t) follows the SBB model with upper rate of ? and bounding function of f , we denote it as A ~SBB hf, ? i. Definition 7. The v.b.c. model [44]: A flow A(t) is said to have a virtual-backlogcentric (v.b.c.) stochastic arrival curve a ? F with bounding function f ? ¯ F , denoted by A ~vbc hf, ai , 23 if for all t = s = 0 and all x = 0, P r{ sup 0=s=t {A(s, t) - a(t - s)} > x} = f (x). (3.4) In addition, we call sup 0=d=? {A(t - d, t)} the statistic of A within sliding window of size ?. Remark 1. Assume that a (virtual) server with service rate a is fed with arrival A. The term sup 0=s=t {A(s, t) - a(t - s)} represents the backlog of this virtual server at time t. Intuitively, the v.b.c model implies that the queue length of a virtual server of service rate a fed with the flow A is upper-bounded with some violation probability [44]. We adopt the following model for services: Definition 8. The s.s.c. model [44]: A server is said to to provide a strict stochastic service curve (s.s.c.) ß ? F with bounding function g ? ¯ F , denoted by S ~ssc hg, ß i , if during any period (s, t] the amount of service S (s, t) provided by the server satisfies P r{S (s, t) < ß(t - s) - x} = g(x). (3.5) Remark 2. In the literature, there are different definitions of stochastic arrival curve and stochastic service curve [44]. We adopt the above models with the consideration of their capability to model real-world traffic/services and the convenience to derive performance bounds. 3.4 Insights of Copula Analysis 3.4.1 Basic Lemmas In stochastic network calculus, we are often interested in the complementary distribution function of Z = X + Y , i.e., P r{Z > z}. The following two lemmas have been widely used in the derivation of stochastic bounds. Lemma 1. General case [44]: For the sum of two random variables X and Y , Z = X + Y , no matter whether X and Y are independent or not, ¯ FZ (z ) = ( ¯ FX ? ¯ FY )(z ). 24 Lemma 2. Independent case: Assume that non-negative random variables X and Y are independent and ¯ FX (x) = f (x) and ¯ FY (x) = g(x), where f, g ? ¯ F . Then, for all x = 0, P r{X +Y > x} = 1 -( ¯ f * ¯ g)(x), where ¯ f (x) = 1 -[f (x)] 1 , ¯ g(x) = 1 -[g(x)] 1 , and * is the Stieltjes convolution operation. The following lemmas from copula analysis are useful for SNC: Lemma 3. Let Z be the sum of two random variables X and Y . The survival function of Z , ¯ FZ (z ) can be calculated in terms of FX (x), FY (y) and their copula CXY : ¯ FZ (z ) = 1 - Z Z x+y x} = (f ? g)(x - a ß (0)) (3.19) where a = n X i=1 ? i , (3.20) f = 1 - Z · · · Z x1+...+xn h(a + x, ß )} = (f ? g)(x) (3.22) where h denotes the maximum horizontal distance between two curves and a = n X i=1 ? i , (3.23) f = 1 - Z · · · Z x1+...+xn