The financial markets have always witnessed the competition of their participants for more profit. In such environments, gaining high and stable profits requires adopting profitable TPs ahead, as the trading strategy. To take the first step towards predicting financial TPs, the TPs existing in the history of financial time series should be detected. Given the direct relationship between the profitability of the predicted TPs and the profitability of the detected TPs, never research into ways of improving the TPs detection methods has been stopped. Nonetheless, to the best of our knowledge, the ever-existing detection methods can't detect the optimal TPs. To address this research gap, we propose a mathematical modeling framework characterized by detecting the optimal TPs from the history of the financial time series. The assumptions considered for modeling and solving the corresponding detection problems are as follows. First; short-selling the financial asset is possible. Second; time value for the investment money isn't considered. Third; it is impossible to detect consecutive buying TPs and consecutive selling TPs. To present the proposed mathematical modeling framework, let's first define the following.
Definition 1. As represented in Fig. 2, the breakpoints (BPs) existing in the history of financial time series are featured by disturbing the existing trends in one of the four following ways: up-trend to down-trend, up-trend to steady-trend, down-trend to up-trend, and down-trend to steady-trend. Excluding the BPs, the remained data points will be named ordinary points (OPs). Accordingly, it can be concluded that in contrast to the BPs, the OPs lack trading value. Hence to achieve the optimal TPs, the BPs set will be used as the input of the proposed detection model.
Definition 2. The trading strategy, i.e., the trading system will be constructed from the sequence of the BPs. The distinct sequences of the existing BPs result in different trading strategies.
Definition 3. Let's define F= {pf1, pf2, ..., pfm} as the BPs set, i.e., the feasible TPs set; where pfi ; i = 1,2, .....,m indicates the financial asset's price in the ith BP and m represents the number of BPs existing in the history of the corresponding financial time series.
Definition 4. Let's define as the maximum profit obtained from trading in the (fi, fj) pair of BPs, using exactly intermediate BP(s) (i = 1,2, ...,m - 1,j = i+1,...,m, q = 0,1, ....,m - 2). To better understanding, Fig. 3, illustrates the (fi, fj) pairs of BPs using zero, one, and two intermediate BPs.
Definition 5. Let's defineas the maximum profit obtained from adopting the entire trading strategies existing in the history of the corresponding financial time series.
Considering the above assumptions and definitions, the proposed framework will find the optimal TPs set through the following three stages. First, the proposed model compares the profitabilities of all trading strategies. Second, the strategy with the maximum profit will be reported as the optimal trading system. Third, the entire TPs existing in the optimal trading strategy will be traced and thereafter reported as the optimal TPs existing in the history of the corresponding financial time series.
To solve the optimal TPs detection problem, Eq. (1) compares the entire trading strategies existing in the history of financial time series.
(1)
This comparison will be realized considering equations (2), (3), and (4). Through this context, the profits of the entire existing trading strategies will be compared and thereafter the optimal trading strategy will be identified. Then, the optimal trading strategy should be tracked to find its constructive BPs; which are in other terms, the optimal TPs. Figure 4, by illustrating the entire trading strategies existing in the history of time series, helps to better understand the process of the proposed mathematical modeling framework. Notably, Eq. (2) maximizes the profits of buying and short-selling the financial asset, considering the entire pairs of BPs. Since the time value of the investment money is not considered here, the collateral of the short-selling position won't be included in the calculations of Eq. (2). The parameters of TCb and TCs, used in Eq. (2), are respectively the financial asset's buying and selling transaction costs (TCs).
(2)
(3)
(4)