## 2 Complex Network Analysis Applied to Subway Networks
### Network Parameters  
Network parameters consist of a set of metrics which capture information on network connectivity and accessibility. These parameters can be defined as structural coefficients since they are invariant under graph isomorphisms; that is, if the network \(G\) is isomorphic to the network \(H\) (there exists a bijection \(\phi\) between their respective node sets such that \(\left(v_{i},v_{j}\right)\) is an edge of \(G\) if and only if \(\left(\phi\left(v_{i}\right),\phi\left(v_{j}\right)\right)\) is an edge of \(H\)) then the node structural coefficient \(C:V\rightarrow\mathbb{R}\) satisfies the following: \(C\left(v\right)=C\left(\phi\left(v\right)\right)\). Moreover, node centrality measures are structural coefficients that take values in \(\left[0,1\right]\) whose aim is to quantify the relative importance or influence of each node within \(G\). Note that all this parameters are local (they are associated to nodes and, in some cases, to edges) and the most important are degree centrality, closeness centrality, betweenness centrality, eccentricity, clustering coefficient and eigenvector centrality. Nevertheless, also global coefficients (in the sense that they are associated to the whole network) can be computed: average path length, diameter, etc. (see [26]). In this subsection the definition of these topological parameters is given. The _degree_ of a node \(v_{i}\) is one of the most important parameters in network analysis. It is defined as the total number of edges incident to \(v_{i}\): \(k_{i}=\sum_{j=1}^{N}a_{ij}\). Two local structural coefficients can be easily determined from it: (1) the _degree centrality_ that measures the average number of nearest neighbors that a node \(v_{i}\) is connected to, that is:  
\[C_{D}\left(v_{i}\right)=\frac{k_{i}}{N-1},\quad 0\leq C_{D}\left(v_{i}\right) \leq 1; \tag{2}\]  
and (2) the _importance_ of \(v_{i}\):  
\[I\left(v_{i}\right)=\frac{k_{i}}{\sum_{i=1}^{N}k_{i}},\quad 0\leq I\left(v_{i} \right)\leq 1, \tag{3}\]  
Figure 1: Madrid metro network computed using Mathematica. that is used to measure the level of \"disorder\" of the network. Moreover, also global structural coefficients can be defined. For example, the _average degree_ of the network is given by the following formula:  
\[\left\langle k\right\rangle=\frac{1}{N}\sum_{i=1}^{N}k_{i}=\frac{1}{N}\sum_{i,j= 1}^{N}a_{ij}=\frac{N-1}{N}\sum_{i=1}^{N}C_{D}\left(v_{i}\right). \tag{4}\]  
Note that \(I\left(v_{i}\right)=\frac{k_{i}}{N\left\langle k\right\rangle}\) for each \(i\). Moreover, the _standard entropy_ of the network can be defined as follows:  
\[E=-\sum_{i=1}^{N}I\left(v_{i}\right)\log\left(I\left(v_{i}\right)\right). \tag{5}\]  
As is shown, degree centrality \"computes\" in some way the \"importance\" of a node by simply considering the number of neighbors. Nevertheless, such characteristic (the'status', 'prestige', or 'importance') can be measured in a more sophisticated way taking into account not only a quantitative perspective (the total number of connections a node has) but also a qualitative perspective (the number of neighbor nodes with highest central coefficients). This is precisely measured by the _eigenvector centrality_. The idea is that a node is important not only because it connects with many nodes but also because the nodes it connects to are also important [27]. Mathematically it is defined as the principal eigenvector, \(C_{G}=\left(C_{G}\left(v_{1}\right),\ldots,C_{G}\left(v_{N}\right)\right)\), of the adjacency matrix. That is, the eigenvector associated to the largest eigenvalue of \(A\): \(\lambda\). The \(i\)-th component of \(C_{G}\) stands for the relative eigen centrality score of node \(v_{i}\) and the following holds:  
\[C_{G}\left(v_{i}\right)=\lambda^{-1}\sum_{j=1}^{N}a_{ij}C_{G}\left(v_{j}\right). \tag{6}\]  
As a metro network can be considered as connected graph, then its adjacency matrix is irreducible and its largest eigenvalue is positive (by applying the Perron-Frobenius Theorem). As a consequence \(0\leq C_{G}\left(v_{i}\right)\leq 1\).