Inverted anhamonic oscillator model for distribution of financial returns

We construct a quantum-mechanical model to explain the distribution of financial returns in a stock market when it exhibits an upward trend. By combining a critical phenomenon effect in the form of a power law and the Schrodinger equation, we show that an appropriate potential of the financial returns is given by a time-dependent inverted anharmonic oscillator, whose coefficients depend on the critical time and exponent, which are empirically obtained from the Stock Exchange of Thailand (SET) from 1992 to 1994, during the critical phase of the Asian financial crisis. With the derived potential, we simulate the dynamics of returns as a function of time by employing the time-dependent variational method and the fourth-order Runge-Kutta method. Then we compute key characteristics of the return distribution such as mean, variance, skewness, and kurtosis and compare them with real financial data from SET. The results are found that the mean, skewness and kurtosis show good agreement with actual data computed from SET, but the variance is higher than that from the SET data.


Introduction
Econophysics is an interdisciplinary research field, employing theories and methods originally developed by physicists to model or solve problems in economics. Since 1990s, there have been many research articles in literature, mostly concerning agent-based dynamics of assets' prices, labor distribution and financial returns, which indicate the money gained or lost on an investment [1][2][3][4]. There are several ways to compute the financial return, such as the simple return defined as r := dp(t) dt /p(t), where p(t) is an asset price or stock price at time t; or the time-lag return defined as r(τ ) := dp(t−τ ) dt /p(t). We only consider the simple return in this article.
The employment of the Schrodinger equation to calculate the financial returns has been done before with various assumptions. Ataullah et al [5] used a finite square well to model the potential that influenced the returns of the stock data from UK Financial Times-Stock Exchange (FTSE) from 1994 to 2007. By comparing the standardized variance, skewness and kurtosis statistics, the results showed that the returns were incompatible with the normal distribution, but a finite square well model could reasonably predict the probability density of returns [5]. Zhang and Huang [6] chose an infinite square well to model the return distribution during a day, under the assumptions that the rate of return cannot be more than 10% compared with the previous day's closing price. As such, the wave function cannot be outside the infinite square well, but within it, traders exchanged information, so a fluctuating external field was added to construct the governing Hamiltonian. The results suggested the imbalance of the distribution of returns [6], as also observed in a financial market. More recently in 2017, Gao and Yao [7] combined the agent-based dynamics and a quantum mechanical approach in a market comprising three types of traders; namely, (i) market makers who work as intermediaries to absorb the existing orders by providing buy and sell quotations of the stocks hold by themselves and other market participants, (ii) contrarians who sell their holdings when the stock price increases (positive price return) and place buy orders when the stock price decreases (negative price return), and (iii) trend followers who act conversely. Based on the demand-supply dynamic equation between the contrarians' and trend followers' tendencies, a potential was derived to have the form of an anharmonic oscillator, which were employed to simulate financial returns yielding good agreement with the return data from a real market [7].
However, it has been pointed out by many authors that the financial returns often exhibit a power-law behavior [8][9][10]. Unlike all the scenarios mentioned above, a normal financial market is full of complexity and hazard, e.g bubbles, where the existence of critical behaviors has been demonstrated in terms of a power law and log-periodic function of time [9]. In this article, we aim to derive an appropriate potential for describing dynamics of the stock price return under the influence of bubble existence, where the price is assumed to obey a power law. The dynamics of the return distribution is investigated, and compared with real financial data from the Stock Exchange of Thailand (SET) before the Asia financial crisis in 1997.

Methodology: Time-dependent Variational Principle
In order to simulate the time-dependent Schrodinger equation , we employ the time-dependent variation method [11]. At time t + τ , we write a trial function as If Ψ is an exact solution, then φ = HΨ(x, t); otherwise, it is an approximated solution. We can choose the appropriate basis functions ϕ k 's and write Ψ( . Substituting these functions into the Schrodinger equation, we obtain where the matrix elements are given by O mn = ϕ m (x)|ϕ n (x) and H mn = ϕ m (x)|H|ϕ n (x) .
In the matrix form, the equation 1 becomes which is a system of differential equations that can be solved numerically by, for example, the fourth-order Runge-Kutta method [12]. After solving for the coefficients a k 's from the equation 2, we can construct the solution Ψ(x, t) of the time-dependent Schrodinger equation. In our simulation procedure, we first must obtain a power-law behavior of SET index from 1992 to 1994, where the goodness of fitting and critical parameters are shown in figure 1. The initial wave function is obtained from the Gaussian-fitting of the distribution of returns of 3months data prior to the starting point (t 0 ) of the power-law distribution. It is then expressed in terms of a linear combination of a chosen basis set ϕ k (x) = sin [kπ(x − s 1 )/(s 2 − s 1 )], where s 1 , s 2 are adjustable, but currently chosen as s 1 = −0.2, s 2 = 0.2, reasonable values for the financial returns. After deriving the appropriate potential for financial returns, see details in Section 3.1, we solve for the time-dependent coefficients according to the equations 1-2 using the fourth-order Runge-Kutta method. The resulting |Ψ(x, t)| 2 will represent the distribution of financial returns from which the statistical properties, e.g. mean, variance, skewness, kurtosis, can be computed and compared with those from the real financial data during the same time frame. We remark that a different basis set and a different initial wave function can affect the computational resources and prediction accuracy. Investigation of these issues is forthcoming.

Results and Discussion
From 1992 to 1994, we observe the SET market underwent a power-law behavior prior to the Asia financial crisis, indicated by the box in figure 1(a). The actual returns and the distribution of returns are depicted in figures 1(b)-(c), respectively. More importantly, we obtain the critical exponent β = 0.24 and critical time t c = 1830, as the closing price p(t) = 1753.7 − 214.6(1830 − t) 0.24 yields the best fit with R 2 = 0.8 and RMSE = 86.0. Here t 0 = 1100 is the starting point of the fitting.
We note that one could alternatively use the opening price or the moving average of the price in the calculation of returns. However, for Thailand's SET Index, the opening price, the closing price, and the 7-day moving average are highly correlated, and their critical exponents β are estimated to be 0.22, 0.24 and 0.21, respectively, during the indicated time frame. Similarly, for the 15-day and 30-day moving averages, the correlations remain high (above 0.993), but the critical exponents yield β ≈ 0.19 and β ≈ 0.17, respectively. It is therefore reasonable to select any of these price-data sets to represent the SET Index to test the model in our current investigation, and we have chosen the closing price as indicated. Choosing a different price-data set would result in a slightly different value of β, and the prediction results may yield different accuracy. In any case, the feasibility of our model would still be validated.

Inverted Time-dependent Anharmonic Potential
We now derive that the corresponding potential for the distribution of returns under a generic power-law behavior of price, i.e. p(t) = p c + (k/β)(t c − t) β for t 0 ≤ t < t c , is given by a time-dependent inverted anharmonic oscillator. To that end, we that note that which implies Equation 4 can be thought of as an equation of motion for a particle with mass m = 1. In a financial return, mass is conceptually an inertia which opposes the change of the price, so without loss of generality, we can set m = 1. If we assume the Newton's second law, and that force is given by the negative gradient of the potential V , then it follows that We remark that the repulsive quartic term is present independent of time, as also found in Ref. [7]. The validity of the conservative force, hence the existence of the potential function in the equation 5 can be scrutinized. One can argue that the potential may be decomposed as V ξ (r) = V (r) + ξ(r, t), where V (r) gives a guiding center, and ξ(r, t) is a random variable or fluctuation, reasonably with mean zero at all time. In this sense, the potential V (r) only represents the mean approximation of the real potential, if exists. These issues aside, we consider the consequences of this potential on the distribution of the financial returns.

Dynamics of Wave Functions
The initial wave function comes from the Gaussian-fitting of the initial distribution of returns obtained from SET data, as shown in figure 2. The simulated distributions from this initial wave function are shown in figure 3. It is obvious that the probability amplitude decreases very quickly as time evolves. Still, we can compute the statistical properties of these distributions.

Mean, Variance, Skewness, Kurtosis and Financial Return Behaviors
To evaluate our model, we compare the mean, variance, skewness and kurtosis of the simulated distribution of returns with those from the real financial data, similar to Ref. [5]. The results are shown in figure 4, where the real-data mean, variance, skewness, and kurtosis are computed from 3-month data prior to the epoch, and from the moving window which takes all data from t = t 0 until the epoch of calculation. It is evident that the mean, skewness and kurtosis show good agreement, but the variance is higher than that from the real-market data. We hypothesize that the high variance in the simulated distribution manifests from the choice of basis (i.e. ϕ k (x) = sin [kπ(x − s 1 )/(s 2 − s 1 )]). A different basis set (e.g. Hermite polynomials suitable for a harmonic oscillator) is being investigated whether it can improve the variance profile. The nonzero skewness indicates financial returns are not symmetric during that time, where positive skewness means the traders are more likely to lose their money, and vice versa. The simulated distribution has kurtosis less than 3, indicating that it produces fewer and less extreme returns than the Gaussian distribution, which is consistent with that from the 3-month data, but inconsistent with that from all historical data. Figure 4. Comparison of mean, variance, skewness, and kurtosis of our simulated results with those from real financial data.

Conclusion
We have constructed a quantum-mechanical model to study the dynamics of the distribution of financial returns in a stock market undergoing an upward trend. By combining a power-law critical phenomenon and the Schrodinger equation, we derived the potential for the distribution of the financial returns as a time-dependent inverted anharmonic oscillator. We simulated the distribution of financial returns as a function of time with the initial data taken from SET, and calculated the return statistics such as the mean, variance, skewness, and kurtosis. Except for the variance, the simulated results are in good agreement with those from real financial data.