## 4 Methodology
where:

* \(\mathcal{U}\) is a set of users;
* \(\mathcal{T}\) is a set of timepoints (samples);
* \(\mathcal{C}\) is a generic corpus of texts, used only for training the word embedding model;
* \(\mathcal{W}\) is the semantic model obtained with the word embedding algorithm;
* \(\mathcal{M}\) associates each user with their mobility index;
* \(\mathcal{A}\) is a set of user's posts;
* \(\mathcal{CalculatePath}\) is the same function already defined in Algorithm 1;

In particular, to calculate the Radius of Gyration, Equation (1) has to be applied to the path, and it has a complexity which is linear with the path length, but constant with the number of users. The path length can be supposed to be constant (i.e., sampling each year, over a ten year timespan). For obtaining the path, all lemmas have to be transformed into some coordinates of the semantic space. Thus, the computation cost is linear with the number of the user's words \(m\) to transform, with complexity \(\mathcal{O}(m)\), but constant with respect to the number of users. As a trivial optimization, it is possible to store the current path of each user, and only update it with new data for adding a new point (essentially, caching results for gaining time performance). However, the complexity would remain unchanged, since it is determined by the worst case of newly discovered users. The transformation of each word is based on the pre-calculated word embedding, and it essentially requires accessing a dictionary, which depends on the number of lemmas \(l\) in the original corpus, with complexity \(\mathcal{O}(\log l)\), but is constant in all other respects. Actually, since the Radius of Gyration does not depend on the order of points in the path, also these finer grained computations are largely independent (thus, for example, they can be vectorized over of several Spark executors). Finally, we can state that Algorithm 2 has the following time complexity:

\[T(n,m,l)=\mathcal{O}(n\cdot m\cdot\log l) \tag{3}\]

where:

* \(n\) is the total number of users to analyze. * \(m\) is the number of words for each user, which all need to be converted into the semantic space coordinates. * \(l\) is the number of unique lemmas in the original corpus, used for offline computation of the word embedding space. ## 6 Conclusions

The main goal of this work is to build, study, and exploit semantic trajectories to extract new latent knowledge. We propose a methodology that aims to combine some analytical tools, traditionally used with geographic data, in a semantic realm obtained exploiting neural network embedding techniques. Indeed, we applied a word embedding algorithm (Word2 vec) to a large corpus of abstracts of scholarly articles to get scholars' trajectories over the time. After that, we applied the Radius of Gyration (RoG) to measure their mobility rate across scientific topics. Finally to extract knowledge we further analyzed trajectories and rog with statistical tools looking for correlation with researchers' success. Moreover, some interesting differences have emerged in the behavior of researchers working in different countries. Finally, some interesting similarities have emerged between mobility patterns in this semantic realm and those typically observed in the case of geographic mobility. Results show that rarely does a single researcher have a significant impact on several different research topics. Instead, the most successful researchers tend to focus on a quite narrow research area. These results are compatible with the framework proposed in [34], in which scholars were simulated by agents with different strategies and objectives, depending on the context in which they operate and the academic age. We believe that the main scientific contribution of this research work is methodological, demonstrating that the semantic spaces obtained through word embedding techniques are amenable to mobility measures, which are typically applied to the geographic realm.