{'fraction_non_alphanumeric': 0.0309728826628968, 'fraction_numerical': 0.017349955018635135, 'mean_word_length': 4.582496413199426, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Temperature estimators in computer simulation

Temperature is a key physical quantity that is used to describe equilibrium between two bodies in thermal contact. In computer simulations, the temperature is usually estimated by means of the equipartition theorem, as an average over the kinetic energy. However, recent studies have shown that the temperature can be estimated using only the particles positions, which has been called configurational temperature. Through classical molecular dynamics simulations of 108-argon-atoms system, we compare the performance of four different temperature estimators: the usual kinetic temperature and three configurational temperatures, Our results show that the different estimators converge to the same value, but their fluctuations are different.


Introduction
The notion of temperature, as a statistical concept, relies on the ability to take averages over long periods of time and over a large number of particles. One of the questions that naturally arises is whether it is possible to extend the definition of temperature to small, finite systems. It would be convenient, then, to know how di↵erent temperatures estimators (or "thermometers") behave, in order to decide which one is more suitable for each system.
In computer simulations, such as molecular dynamics, the temperature is calculated as the time average of the kinetic energy of the system in equilibrium. This temperature is usually called kinetic temperature. However, this is not the only way to estimate temperature. Recently, it has been shown [1, 2, 3] that a family of estimators for the temperature exist, which can be expressed in terms of the velocity only, or positions only, or both.
In this work, we study the behavior of four di↵erent temperature estimators in a system of 108 argon atoms interacting via the Lennard-Jones potential in the microcanonical ensemble. The paper is structurated as follows. In section 2 we present the theoretical framework and the explicit forms of temperature estimators. Section 3 describes the computational details of the simulations, and section 4 show the results obtained from this simulations.

The Conjugate Variables Theorem (CVT) and configurational temperature
In the framework of statistical mechanics of hamiltonian systems, it has been recently proven, using continuous maximum entropy inference, a general theorem (named Conjugated Variables Theorem, CVT) connecting the Lagrange multipliers and the expectation values of a certain particularly constructed functions of the states of the system [3]. This theorem states that for a system of N particles governed by a hamiltionian the following equality holds: whereũ is an arbitrary vector field, k B the Boltzmann constant, and T the temperature of the system. This equation provides di↵erent estimators for the temperature, depending on the choice of the vector fieldũ. For instance, takingũ = rH/krHk 2 , we obtain This particular choice ofũ corresponds to the expression for the dynamical temperature obtained by Rugh [1], and shows that more general arbitrary definitions of temperature can be given. Note that equation (3) provides a way to obtain the temperature as an average of what we call the instantaneous temperature This can be expressed in a more convenient way by taking the divergence of the quotient: A remarkable fact is that the operator r can be taken with respect top, or respect tor, or both. In this way we have a family of estimators for the temperature, T .
We are interested in comparing the performance of the following three di↵erent temperature estimators: 1. Kinetic Temperature: This is the most common way in which the temperature is defined, and in this formalism is obtained by taking the gradient over the momenta (r ⌘ rp) on equation (5). This leads to the expression j is the kinetic energy of the system. 2. Configurational Temperature: If the gradient goes over positionsr, we obtain On this expression we can clearly see that the temperature depends only on the positions of the particles (or configurations of the system), not on their velocities. This is what Rugh called dynamical temperature. 3. Truncated Configurational Temperature: It is not di cult to prove that the second term in equation (7) goes as 1/N , therefore the main contribution is on the first term. This means that is a good approximation for the configurational temperature when N is large.
In addition, we want to compare the average of these estimators, which corresponds to the inverse temperature 1/k B T , with the inverse temperature coming from the ratio between two averaged quantities: This equation comes from the choiceũ = rH in equation (2). Taking the gradient over the positionsr leads to 1

Model and computational details
In order to study the performance of 4 di↵erent temperature estimators in finite system we use classical molecular dynamics simulations employing LPMD software [4]. The model consists of 108 Argon atoms interacting through the Lennard-Jones potential, where r is the distance between atoms, whereas = 3.41Å and ✏ = 0.0103 eV are parameters fitted for the argon interaction [5]. The simulation is performed in the microcanonical ensemble, in three dimensions, without periodic boundary conditions. Initially, we applied an energy corresponding approximately to 10 K, and then we run the system for 10000 steps (one time step is equal to 1 fs). The instantaneous temperature is estimated by three di↵erent expressions:T 1 ,T 2 andT 3 . The temperature is estimated as an average over the last 5000 steps, and we called them T 1 , T 2 , T 3 and T 4 . Figure 1 displays the performance with respect to the time of three di↵erent temperature estimators, namelyT 1 ,T 2 andT 3 . We can see that the value of the estimators are not very di↵erent and whenT 2 andT 3 temperatures increases,T 1 decreases, and vice versa. Also the fluctuations are similar.

Results
For comparing the contribution of individual terms on theT 2 estimator, we show in Figure  2 three important terms: r 2 V /krV k 2 , rV · [r(rV · rV )]/krV k 4 and r 2 V /krV k 2 rV · [r(rV · rV )]/krV k 4 . We can see that the second term ofT 2 estimator is one hundred times smaller than the first term of that estimator. This is because the second term is of order 1/N , where N is the number of atoms in the simulation. Also, this explains that the first term ofT 2 estimator and the complete term are similar.  In order to study in more detail the behavior of the first term, r 2 V /krV k 2 , which is the main contributor to the estimatorT 2 , we show in Figure 3 and in Figure 4 the numerator and denominator of that term. We can see that the average of r 2 V is two thousand times bigger than the average of krV k 2 . On the other hand the fluctuations of r 2 V are smaller than fluctuations of krV k 2 .  Finally, we compute the averages of di↵erent temperature estimators and display them in Table 1. Note that the value of T 1 and T 2 , the kinetic and the configurational temperature, respectively, are almost the same, with a relative porcentual di↵erence of 0.07%. Also, T 4 is close to T 1 and T 2 . On the other hand, T 3 , which is T 2 truncated, give the more di↵erent value, although, also very close to T 1 and T 2 , with a relative porcentual di↵erence of 0.98%

Concluding remarks
In conclusion, we have calculated the temperature of a small system in four di↵erent ways. The explicit functional forms of the temperature were derived from CVT theorem [3], and three of them are based on the positions only. We conclude that for long enough simulation time, the 6.681±0.042 6.686± 0.035 6.620±0.0345 6.679±0.034 di↵erent temperature estimators converge to the same value, while the fluctuations are not the same for each estimator.