=Paper= {{Paper |id=Vol-3682/Paper14 |storemode=property |title=Capturing An Optimal Trading Framework Involving Exponential and Second-Order Autoregressive Price Dynamics |pdfUrl=https://ceur-ws.org/Vol-3682/Paper14.pdf |volume=Vol-3682 |authors=Vipin Kumar Pandey,Arti Singh,Gopinath Sahoo |dblpUrl=https://dblp.org/rec/conf/sci2/PandeySS24 }} ==Capturing An Optimal Trading Framework Involving Exponential and Second-Order Autoregressive Price Dynamics== https://ceur-ws.org/Vol-3682/Paper14.pdf
                         Capturing An Optimal Trading Framework Involving
                         Exponential and Second-Order Autoregressive Price
                         Dynamics
                         Vipin Kumar Pandey1,* , Arti Singh2 and Gopinath Sahoo3
                         1
                           Bennett University, Greater Noida, 201310, India
                         2
                           University School of Automotion and Robotics, Guru Gobind Sigh Indraprastha University, East Delhi Campus.
                         3
                           Bennett University, Greater Noida, 201310, India


                                     Abstract
                                     In the constantly changing financial markets, investors and traders need to trade using optimal trading strategies.
                                     In this article, we optimize the expected cost and the execution risk to develop an optimal trading strategy for
                                     risk-averse investors. In this context, we study a second order convex function that incorporates both transient
                                     and permanent market impacts in the price path rule of motion. By the use of dynamic programming, we get a
                                     closed form solution of the unconstrained problem, in some particular cases for the risk-averse investor.

                                     Keywords
                                     Optimal trading, execution cost, autoregressive, quadratic programming problem




                         1. Introduction
                         The optimum trading issue is a significant difficulty faced by academics, algorithmic traders, and market
                         practitioners. Performing all required asset shares in a single transaction is inefficient because of it’s
                         potential for considerable price fluctuations, particularly when dealing with large trade volumes. Addi-
                         tionally, privileged knowledge about the asset and the constantly changing nature of the market affect
                         price variations, in addition to the trade order. Every order made in the market provides information
                         on the trading and financial goals of investors, so influencing the viewpoints of other investors over
                         a prolonged duration. As a result, the market expects changes in the stock’s fundamental worth or
                         predicts that future prices will deviate from earlier estimates.
                            The term “no-impact price" refers to the price of an asset when there are no trades or external
                         factors affecting it. Temporary price implications occur due to the urgent need for execution, leading to
                         short-term price fluctuations. On the other hand, the term “permanent price effect" refers to the steady
                         irregularity caused by imbalances in supply and demand, as well as other causes discussed before. The
                         interaction between the price impact factor and the price path without any influence determines the
                         execution price dynamics of an asset. Several models of price dynamics during execution had been
                         suggested in the literature, such as those given by [1];[2];[3];[4];[5];[6].
                            [1], had proposed three models to explain the dynamics of execution prices: the Linear Price Impact
                         Model, the Linear Price Impact with Information Price Model, and the Linear Percentage Temporary
                         Price Impact Model (LPT model). As compared to the first two models, which represented the no-
                         impact price using an arithmetic random walk, the LPT model models it using a geometric Brownian
                         motion. As a result of the linear price impact model, the price change is directly proportional to the
                         trade magnitude. However, in the linear price impact with information price model, the price impact is
                         directly proportional to both the trade size and the information component. The information component
                         captures the influence of characteristics such as asset information and changing market circumstances
                         on the execution price. The LPT model [1], quantified the price effect by a linear equation that took

                            Symposium
                         ComSIA’24:        on Computing
                                      Computing          and Intelligent
                                                 & Communication Systems forSystems,     May 10, 2024,
                                                                             Industrial Applications,      New 2024,
                                                                                                      May 10–11, Delhi,
                                                                                                                     NewIndia
                                                                                                                          Delhi, INDIA
                         *
                           Vipin Kumar Pandey
                         †
                           Arti Singh, Gopinath Sahoo
                         $ vipinady2016@gmail.com (V. K. Pandey); artisingh1212@gmail.com (A. Singh); sahoo.gopi@gmail.com (G. Sahoo)
                                  © 2022 Copyright for this paper by its authors. Use permitted under Creative Commons License Attribution 4.0 International (CC BY 4.0).


CEUR
                  ceur-ws.org
Workshop      ISSN 1613-0073
Proceedings
into account the transaction size and an information factor, which was calculated as a percentage of
the price without any impact. [2], proposed linear price impact functions and integrated an arithmetic
random walk to model the dynamics of execution prices, using the no-effect price as a benchmark.
[1], introduced the initial mathematical optimization model for inscribe the optimal trading problem.
Further, other researcher, including, [7],[2],[3],[4],[5], explored the inquires related the optimal trading
for single asset. [6], introduced the jump diffusion model to capture the unpredictable effects of large
transactions on prices during execution. In this model, the purpose is to provide a better understanding
of the fluctuations in asset values during significant transactions. However [8]; and [9], proposed
the use of stochastic dominance for all types of investors in portfolio optimization.Using the same
approach, [5], analyzed optimal trading strategies. In addition, [10], extended the linear price impact
with information price model of [1], referred to as the AR(1) price model, to a more general framework.
To describe the evolution of asset prices over time, the AR(2) model is commonly used in optimal trading
strategies. A second-order autoregressive model is called an AR(2) model.
   In this paper, we extend the AR(2) model of [10], to a more general framework. We use the con-
vex combination of temporary and permanent price impacts under the AR(2) model with an AR(2)
information factor.


2. Motivation and Contribution of the paper
In existing literature, no-impact price dynamics are often described as arithmetic random
walks.According to this assumption, the price of the asset in any given period will be determined
by the price of the asset in the previous period, reflecting a first-order autoregressive AR(1) behavior.
Using a more comprehensive model for the linear price impact with information, introduced by [1], this
paper makes a significant contribution to the literature.In the extension, the second-order autoregressive
with exponent behavior is incorporated into the AR(2) price model for both permanent and temporary
price impacts by [5]. The information factor indicates that the state in any given time period depends
on the state in two previous ones.


3. The optimization problem
Consider an investor with a goal to buy a significant amount of shares, let’s call it 𝑆¯ , within a specific
time period, say [0, 𝑇 ]. This time frame is split into smaller intervals, each with a length of Δ𝑡 = 𝑁  𝑇
                                                                                                            ,
and the 𝑡 time frame is equal to 𝑡Δ𝑡.
          𝑡ℎ

   Let’s use 𝑆𝑡 to represent the shares acquired during the interval 𝑡𝑡ℎ at a price of 𝑃𝑡 , and 𝑊𝑡 will be
the remaining shares to buy at time 𝑡𝑡ℎ .
   Now, the investor wants to minimize the expected cost of getting 𝑆     ¯ shares while keeping a handle
on a predetermined risk level. This perspective on risk is inspired by the work of Almgren and Chriss
(2000) and Huberman and Stanzl (2005). So, in a nutshell, the investor’s challenge is to navigate this
buying process in a way that minimizes costs and manages the associated risks effectively. The problem
(P1)
                                                          (︃ 𝑇         )︃
                                                            ∑︁
                                                min 𝐸           𝑃𝑡 𝑆 𝑡
                                                 {𝑆𝑡 }𝑇
                                                      𝑡=1        𝑡=1
                                    subject to                                                            (1)
                                                  𝑇
                                                 ∑︁
                                                       𝑆𝑡 = 𝑆
                                                 𝑡=1

where
                    𝑊1 = 𝑆, 𝑊𝑡 = 𝑊𝑡−1 − 𝑆𝑡−1                ∀ 𝑡 = 1, 2, ..., 𝑇,   𝑊𝑇 +1 = 0.
In outlining the dynamics of the stock price for this dynamic programming problem, let’s denote 𝑃˜𝑡
as the observed stock price at 𝑡 time. To simplify, we’ll assume that market prices follow geometric
                                𝑡ℎ

Brownian motion. This allows us to express the market price at 𝑡𝑡ℎ time as follows:

               𝑃˜𝑡 = 𝛼 exp(𝑍𝑡 )𝑃𝑡−1 + (1 − 𝛼)𝑢1 𝑃𝑡−1 + (1 − 𝛼)𝑢2 𝑃𝑡−2               ; 𝛼 ∈ [0, 1]          (2)

A trader’s decision-making involves not only the current stock price but also factors in the broader
market conditions. We represent this by introducing the market information variable, denoted as 𝑋𝑡 .
This variable captures the potential influence of evolving market conditions, encompassing aspects like
variations in buy-sell volume or private information about the security.
To model this variable, we adopt an autoregressive process of order 2 that is (AR(2)). In simpler terms,
the market information variable at 𝑡𝑡ℎ time, denoted as 𝑋𝑡 , is represented by its value at the previous
time step.
                                      𝑋𝑡 = 𝜌1 𝑋𝑡−1 + 𝜌2 𝑋𝑡−2 + 𝜂𝑡                                     (3)
   Here, 𝜂𝑡 is a white noise process with zero mean and variance 𝜎𝜂2 . At 𝑡𝑡ℎ time, the trader observes the
price 𝑃˜ 𝑡 and market information 𝑋𝑡 and decides to trade 𝑆𝑡 shares. We assume that the price impact of
trading is a linear function of 𝑆𝑡 and 𝑋𝑡 . Therefore, the average execution price 𝑃𝑡 of trading 𝑆𝑡 shares
at 𝑡𝑡ℎ time is given by:
                                       𝑃𝑡 = 𝑃 ˜ 𝑡 + 𝜃𝑆𝑡 + 𝛾𝑋𝑡 + 𝜖𝑡                                       (4)
  The average execution price 𝑃𝑡 of trading 𝑆𝑡 shares at 𝑡𝑡ℎ is determined by the observed market
price 𝑃
      ˜ 𝑡 , the quantity of shares traded 𝑆𝑡 , and the market information 𝑋𝑡 . Additionally, there is an
uncertainty component 𝜖𝑡 denoting the noise in the acquisition price, characterized by a white noise
process with zero mean and variance 𝜎𝜖2 .
  The motion of price expressed in equ. (2) − (4), is the generalization of [1] linear temporary price
impact. Once the order placed at time 𝑡𝑡ℎ is executed, the resulting stock price will be influenced not
only by the actions of other market participants but also by the lasting impact of executing 𝑆𝑡 shares.


4. Optimal trading under AR(2) price model with exponents: dynamic
   programming method
In solving the given problem using dynamic programming (DP) method, denoted as (P1), we leverage
the insight presented in (Bertsimas and Lo (1998)), According to this approach, the portion of the optimal
trading strategy (𝑆𝑡 , 𝑆𝑡+1 , ..., 𝑆𝑇 ) during any time period 𝑡, corresponding to time periods 𝑡 to 𝑇 , must
be optimal for these time intervals.
   In the context of an auto regressive model of order 2 (AR(2)), specifically considering the last two
trading periods 𝑃𝑡−1 and 𝑃𝑡−2 , the relevant information factors include 𝑋𝑡 and 𝑋𝑡−1 . Additionally, the
factor 𝑊𝑡 represents the number of shares that remain to be traded after the (𝑡 − 1)𝑡ℎ time period. The
control variable for the 𝑡𝑡ℎ time period is denoted by the number of shares 𝑆𝑡 to be traded during that
specific period.
Consider the problem (P1), to be solved by DP method.
   DP Problem
                                   𝑇
                                  ∑︁
                            min 𝐸(   𝑃𝑡 𝑆𝑡 )
                           {𝑆𝑡 }𝑇
                                𝑡=1   𝑡=1
              subject to
                                                                                                          (5)
                            𝑇
                           ∑︁
                                 𝑆𝑡 = 𝑆
                           𝑡=1
                           𝑊1 = 𝑆, 𝑊𝑡 = 𝑊𝑡−1 − 𝑆𝑡−1            ∀ 𝑡 = 1, 2, ..., 𝑇   𝑊𝑇 +1 = 0.
Let
                                                                     𝑇
                                                                    ∑︁
                  𝑉𝑡 (𝑃˜𝑡 , 𝑃𝑡−1 , 𝑃𝑡−2 , 𝑋𝑡 , 𝑋𝑡−1 , 𝑊𝑡 ) = 𝐸𝑡 (         𝑃𝑡 𝑆𝑡 ) ∀ 𝑡 = 1, 2, ..., 𝑇.         (6)
                                                                    𝑘=1

be the optimal cost of execution corresponding to trades into periods 𝑡 𝑡𝑜 𝑇.
During the final trading period 𝑇 , the optimal strategy is to execute all the remaining shares 𝑊𝑇 to
finish the trade. i.e. 𝑆𝑇 = 𝑊𝑇 . Thus 𝑉𝑇 is given as follows:

                       𝑉𝑇 (𝑃˜𝑇 , 𝑃𝑇 −1 , 𝑃𝑇 −2 , 𝑋𝑇 , 𝑋𝑇 −1 , 𝑊𝑇 ) = min 𝐸𝑇 [𝑃𝑇 𝑆𝑇 ]
                                                                          𝑆𝑡
                                                                                                              (7)
                                                                    = (𝑃˜𝑇 + 𝜃𝑊𝑇 + 𝛾𝑋𝑇 )𝑊𝑡

The Bellman Equation relating 𝑉𝑇 −𝑡 𝑡𝑜 𝑉𝑇 −𝑡+1 , is given as follows:

      𝑉𝑇 −𝑡 (𝑃𝑇˜−𝑡 , 𝑃𝑇 −𝑡−1 , 𝑃𝑇 −𝑡−2 , 𝑋𝑇 −𝑡 , 𝑋𝑇 −𝑡−1 , 𝑊𝑇 −𝑡 )
                                                        ˜ , 𝑃𝑇 −𝑡 , 𝑃𝑇 −𝑡−1 , 𝑋𝑇 −𝑡+1 , 𝑋𝑇 −𝑡 , 𝑊𝑇 −𝑡+1 )]    (8)
             = min 𝐸𝑇 −𝑡 [𝑃𝑇 −𝑡 𝑆𝑇 −𝑡 + 𝑉𝑇 −𝑡+1 (𝑃𝑇 −𝑡+1
               𝑆𝑇 −𝑡

Proposition 1. Under the AR(2), price model Under the Execution price dynamics 𝑃𝑡 , Eq. (2) and (3) with
information factor (4)

                           𝑃𝑡 = 𝑃˜𝑡 + 𝜃𝑆𝑡 + 𝛾𝑋𝑡 + 𝜖𝑡
                           𝑃˜𝑡 = 𝛼 exp(𝑍𝑡 )𝑃𝑡−1 + (1 − 𝛼)𝑢1 𝑃𝑡−1 + (1 − 𝛼)𝑢2 𝑃𝑡−2                             (9)
                           𝑋𝑡 = 𝜌1 𝑋𝑡−1 + 𝜌2 𝑋𝑡−2 + 𝜂𝑡

In each time period corresponding to the DP problem, the following equation gives the optimal trade and
the optimal cost:

                        ˜ 𝑇 −𝑟 + 𝐵𝑟−1 𝑋𝑇 −𝑟 + 𝐶𝑟−1 𝑋𝑇 −𝑟−1 + 𝐷𝑟−1 𝑃𝑇 −𝑟−1 + 𝐸𝑟−1 𝑊𝑡−𝑟
           𝑆𝑇 −𝑟 = 𝐴𝑟−1 𝑃                                                                                    (10)



        𝑉𝑇 −𝑟 (𝑃                                                           ˜ 2 + 𝑏𝑟 𝑃
               ˜ 𝑇 −𝑟 , 𝑃𝑇 −𝑟−1 , 𝑃𝑇 −𝑟−2 , 𝑋𝑇 −𝑟 , 𝑋𝑇 −𝑟−1 , 𝑊𝑇 −𝑟 ) = 𝑎𝑟 𝑃           ˜ 𝑇 −𝑟 𝑋𝑡−𝑟
                                                                             𝑇 −𝑟
               + 𝑐𝑟 𝑃˜ 𝑇 −𝑟 𝑋𝑇 −𝑟−1 + 𝑑𝑟 𝑃  ˜ 𝑇 −𝑟 𝑃𝑇 −𝑟−1 + 𝑒𝑟 𝑃
                                                                ˜ 𝑇 −𝑟 𝑊𝑇 −𝑟 + 𝑓𝑟 𝑋𝑇2 −𝑟 + 𝑔𝑟 𝑋𝑇2 −𝑟−1
                                                                                                             (11)
                + ℎ𝑟 𝑋𝑇 −𝑟 𝑊𝑇 −𝑟 + 𝑖𝑟 𝑋𝑇 −𝑟−1 𝑋𝑇 −𝑟 + 𝑗𝑟 𝑋𝑇 −𝑟−1 𝑊𝑇 −𝑟 + 𝑘𝑟 𝑊𝑇2 −𝑟
                + 𝑙𝑟 𝑃𝑇 −𝑟−1 𝑋𝑇 −𝑟 + 𝑚𝑟 𝑃𝑇2 −𝑟−1 + 𝑛𝑟 𝑃𝑇 −𝑟−1 𝑋𝑇 −𝑟−1 + 𝑜𝑟 𝑃𝑇 −𝑟−1 𝑊𝑇 −𝑟

where all the value should be put at initial.

      𝑚𝑟 = 2𝜃 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃2 + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃2 − 2𝑒𝑟−1 (1 − 𝛼)𝑢1 𝜃
          + 2𝑘𝑟−1 + 2𝑚𝑟−1 𝜃 − 2𝑜𝑟−1 𝜃
      𝛿1,𝑟 = 𝑜𝑟−1 − 2𝑚𝑟−1 𝜃 + (𝛼𝑞 + (1 − 𝛼)𝑢1 ) 𝑒𝑟−1 − 2(1 − 𝛼)𝑢1 𝜃 ((1 − 𝛼)𝑢1 − 𝛼𝑞) 𝑎𝑟−1
             − 𝜃 (𝛼𝑞 + 2(1 − 𝛼)𝑢1 ) 𝑑𝑟−1 − 1
      𝛿2,𝑟 = 𝑜𝑟−1 𝛾 − 𝑛𝑟−1 𝜃 − 2𝑚𝑟−1 𝜃𝛾 − 𝑙𝑟−1 𝜌1 𝜃 + 𝑗𝑟−1 + ℎ𝑟−1 𝜌1 − 𝑒𝑟−1 (1 − 𝛼)𝑢1 𝛾
                                                                                                             (12)
             − 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃𝛾 − 𝑐𝑟−1 (1 − 𝛼)𝑢1 𝜃 − 𝑏𝑟−1 𝜌1 (1 − 𝛼)𝑢1 𝜃
             − 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃𝛾 − 𝛾
      𝛿3,𝑟 = ℎ𝑟−1 𝜌2 − 𝑏𝑟−1 𝜌2 (1 − 𝛼)𝑢1 𝜃 − 𝑙𝑟−1 𝜌2 𝜃
      𝛿4,𝑟 = 𝑒𝑟−1 𝑢2 − 2𝑎𝑟−1 (1 − 𝛼)2 𝑢1 𝑢2 𝜃 − 𝑑3 (1 − 𝛼)𝑢2 𝜃
      𝛿5,𝑟 = 2𝑘𝑟−1 − 𝑜𝑟−1 𝜃 − 𝑒3 (1 − 𝛼)𝑢1 𝜃
From the above value we, calculate 𝑆𝑇 −𝑟 as follows:
                     𝛿1,𝑟              𝛿2,𝑟              𝛿3,𝑟              𝛿4,𝑟              𝛿5,𝑟
            𝐴𝑟−1 =        ,   𝐵𝑟−1 =        ,   𝐶𝑟−1 =        ,   𝐷𝑟−1 =        ,   𝐸𝑟−1 =
                     𝑚𝑟                𝑚𝑟                𝑚𝑟                𝑚𝑟                𝑚𝑟
where
          𝑎𝑟 = 𝜃 + 𝑎𝑟−1 (1 − 𝛼)2 𝑢12 𝜃 + 𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃2 − 𝑒𝑟−1 (1 − 𝛼)𝑢1 𝜃 + 𝑘𝑟−1
                                                                                 2

            + 𝑚𝑟 𝜃2 − 𝑜𝑟−1 )𝐴2𝑟 + (1 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃 + 𝑚𝑟−1 + (2𝑎𝑟−1 𝛼𝑞 − 𝑒𝑟−1 𝛼𝑞−
                                                                                                    (13)
            𝑒𝑟−1 (1 − 𝛼)𝑢1 )𝜃 + 𝑎𝑟−1 𝛼2 𝑞 2 +(𝑑𝑟−1 𝛼𝑞 + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 )𝜃 − 𝑜𝑟−1 ) 𝐴𝑟
            + 2𝛼𝑞(1 − 𝛼)𝑢1 𝑎𝑟−1 + 𝑑𝑟−1 𝛼𝑞(1 − 𝛼)𝑢1 𝑑𝑟−1


        𝑏𝑟 = 𝐵𝑟−1 (1 + 2𝜃𝐴𝑟−1 + 𝛾𝐴𝑟−1 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃2 𝐴𝑟−1 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃
           + 2𝑎𝑟−1 𝛼𝑞(1 − 𝛼)𝑢1 𝜃) + 𝐴𝑟−1 (2𝑘𝑟−1 𝐵𝑟−1 + 𝜌1 𝑙𝑟−1 + 𝜃𝑙𝑟−1 𝜌1 + 2𝑚𝑟−1 (𝜃2 𝐵𝑟−1
           + 𝜃 + 𝛾 + 𝜃𝛾) + 𝑛𝑟−1 (1 + 𝜃) − 𝑜𝑟−1 (𝐵𝑟−1 + 2𝜃𝐵𝑟−1 + 𝛾)) + 𝜌1 𝑙𝑟−1 𝜃𝐴𝑟−1
           − 𝑗𝑟−1 𝐴𝑟−1 − ℎ𝑟−1 𝜌1 + 𝑐𝑟−1 (𝛼𝑞 − (1 − 𝛼)𝑢1 + (1 − 𝛼)𝑢1 𝜃) + 𝑑𝑟−1 (𝛼𝑞𝜃
           + 𝛼𝑞𝛾 + (1 − 𝛼)𝑢1 𝜃2 + 2𝐵𝑟−1 + 2(1 − 𝛼)𝑢1 𝜃 + 2(1 − 𝛼)𝑢1 𝛾 + 2(1 − 𝛼)𝑢1 𝜃𝛾)
                                                                                                    (14)
           − 𝑒𝑟−1 (𝛼𝑞 + (1 − 𝛼)𝑢1 + 2(1 − 𝛼)𝑢1 𝜃 + (1 − 𝛼)𝑢1 𝛾) + 𝑏𝑟−1 𝜌1 (𝛼𝑞 + (1 − 𝛼)𝑢1
           + (1 − 𝛼)𝑢1 𝜃) + 2𝑎𝑟−1 ((1 − 𝛼)2 𝑢21 𝜃2 + (1 − 𝛼)2 𝑢21 𝜃 + 𝛼𝑞(1 − 𝛼)𝑢1 𝜃 + 𝛼𝑞
          (1 − 𝛼)𝑢1 𝛾 + 𝑐𝑟−1 (𝛼𝑞 − (1 − 𝛼)𝑢1 + (1 − 𝛼)𝑢1 𝜃) + 2𝑑𝑟−1 ((1 − 𝛼)𝑢1 𝜃2
           + (1 − 𝛼)𝑢1 𝜃 + 𝛼𝑞𝜃 + 𝛾) − 𝑒𝑟−1 (𝛼𝑞 + (1 − 𝛼)𝑢1 ) + 𝜌1 𝑙𝑟−1 𝜃
           + 𝑜𝑟−1 (2𝜃𝐴𝑟−1 + 𝛾𝐴𝑟−1 )


        𝑐𝑟 = 𝑐𝑟−1 + 2𝜃𝐴𝑟−1 𝐶𝑟−1 + 𝐶𝑟−1 𝜃[2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢1 + 2𝑎𝑟−1 𝛼𝑞
          (1 − 𝛼)𝑢1 ] + 𝜌2 [𝑏𝑟−1 (𝛼𝑞 + (1 − 𝛼)𝑢1 + (1 − 𝛼)𝑢1 𝜃𝐴𝑟−1 ) + 𝑙𝑟−1 (1 + 𝜃𝐴𝑟−1 )]           (15)
           + 𝜃𝐶𝑟−1 [2𝑑𝑟−1 (1 − 𝛼)𝑢1 − 𝑒𝑟−1 (2𝑎𝑟−1 (1 − 𝛼)𝑢1 − 2(1 − 𝛼)𝑢1 )] − 𝑜𝑟−1 𝐶𝑟−1


        𝑑𝑟 = 𝐷𝑟−1 + 2𝜃𝐴𝑟−1 𝐷𝑟−1 + 𝐷𝑟−1 𝜃[2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢1 + 2𝑎𝑟−1
          𝛼𝑞(1 − 𝛼)𝑢1 ] + 𝜃𝐷𝑟−1 [2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢1 + 2𝑎𝑟−1 𝛼𝑞(1 − 𝛼)𝑢1 ]
           + 𝛼𝑞𝐷𝑟−1 [𝑑𝑟−1 − 𝑒𝑟−1 ] + 𝜃𝐷𝑟−1 [2𝑑𝑟−1 (1 − 𝛼)𝑢1 − 𝑒𝑟−1 (2𝑎𝑟−1 (1 − 𝛼)𝑢1                 (16)
           − 2(1 − 𝛼)𝑢1 )] + 𝑑𝑟−1 (1 − 𝛼)𝑢2 + 𝜃𝐴𝑟−1 𝐷𝑟−1 [2𝑎𝑟−1 (1 − 𝛼)𝑢1 − 2(1 − 𝛼)𝑢1
           − 𝑒𝑟−1 (2𝑜𝑟−1 )] + 𝜃𝐷𝑟−1 [2𝑚𝑟−1 𝜃 + 2𝑚𝑟−1 ] − 𝑜𝑟−1 𝐷𝑟−1


        𝑒𝑟 = 𝐸𝑟−1 + 2𝜃𝐴𝑟−1 𝐸𝑟−1 + 𝐸𝑟−1 𝜃[2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢1 + 2𝑎𝑟−1 𝛼𝑞
          (1 − 𝛼)𝑢1 ] + 𝜃𝐸𝑟−1 [2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢1 + 2𝑎𝑟−1 𝛼𝑞(1 − 𝛼)𝑢1 ]
          + 𝜃𝐸𝑟−1 [2𝑑𝑟−1 (1 − 𝛼)𝑢1 − 𝑒𝑟−1 (2𝑎𝑟−1 (1 − 𝛼)𝑢1 − 2(1 − 𝛼)𝑢1 )] + 𝑒𝑟−1 (1 − 𝛼)𝑢1         (17)
                                         2
          + 2𝑘𝑟−1 𝐴𝑟−1 𝐸𝑟−1 + 𝑚𝑟−1 𝜃 + 2𝑚𝑟−1 𝜃𝐸𝑟−1 + 𝑜𝑟−1 + 𝑜𝑟−1 𝜃𝐴𝑟−1
          − 𝑜𝑟−1 𝐸𝑟−1 − 2𝑜𝑟−1 𝜃𝐴𝑟−1 𝐸𝑟−1

                  2
           𝑓𝑟 = 𝜃𝐵𝑟−1 [1 + 𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃 + 𝑘𝑟−1 + 𝑚𝑟−1 𝜃2 − 𝑜𝑟−1 𝜃]
             + 𝛾[𝐵𝑟−1 + 𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃𝐵𝑟−1 + 𝑏𝑟−1 𝜌1 (1 − 𝛼)𝑢1
                                                                                                    (18)
             + 𝑑𝑟−1 (1 − 𝛼)𝑢1 𝛾 + 𝑙𝑟−1 𝜌1 𝛾 + 𝑛𝑟−1 𝜃 + 𝑛𝑟−1 𝜃𝛾 − 𝑜𝑟−1 𝛾] + 𝑓𝑟−1 𝜌21
             + 𝑐𝑟−1 (1 − 𝛼)𝑢1 𝜃𝐵𝑟−1 + 𝑔𝑟−1 − ℎ𝑟−1 𝜌1 𝐵𝑟−1 + 𝑖𝑟−1 𝜌1 − 𝑗𝑟−1 𝐵𝑟−1 .
        2
 𝑔𝑟 = 𝜃𝐶𝑟−1 [1 + 𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃 + 𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃 + 𝑘𝑟−1 + 𝑚𝑟−1 𝜃2 − 𝑜𝑟−1 𝜃] + 𝜌22 𝑓𝑟−1
                                                                                                (19)
   + 𝜃𝐶𝑟−1 𝑏𝑟−1 𝜌2 (1 − 𝛼)𝑢1 − 𝜌2 𝐶𝑟−1 ℎ𝑟−1 + 𝜃𝐶𝑟−1 𝑙𝑟−1 𝜌2 − 𝜃𝐶𝑟−1 𝑒𝑟−1 (1 − 𝛼)𝑢1 .


ℎ𝑟 = 𝜃[2𝐵𝑟−1 𝐶𝑟−1 + 𝛾𝐸𝑟−1 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃𝐵𝑟−1 𝐸𝑟−1 + 𝑏𝑟−1 𝜌1 (1 − 𝛼)𝑢1 𝐸𝑟−1
   + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝛾𝐸𝑟−1 ] + 𝑐𝑟−1 (1 − 𝛼)𝑢1 𝐸𝑟−1 + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃𝐵𝑟−1 𝐸𝑟−1
   + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝛾𝐸𝑟−1 + 𝑒𝑟−1 (1 − 𝛼)𝑢1 𝐵𝑟−1 + 𝑒𝑟−1 (1 − 𝛼)𝑢1 𝛾 − 𝑒𝑟−1 (1 − 𝛼)𝑢1
                                                                                                (20)
  𝛾𝐸𝑟−1 − 2𝑒𝑟−1 (1 − 𝛼)𝑢1 𝜃𝐵𝑟−1 𝐸𝑟−1 + ℎ𝑟−1 𝜌1 − ℎ𝑟−1 𝜌1 𝐸𝑟−1 + 𝑗𝑟−1 − 𝑗𝑟−1 𝐸𝑟−1
   + 2𝑘𝑟−1 𝐵𝑟−1 𝐸𝑟−1 − 2𝑘𝑟−1 𝐵𝑟−1 + 𝑙𝑟−1 𝜌1 𝜃𝐸𝑟−1 + 2𝑚𝑟−1 𝜃2 𝐵𝑟−1 𝐸𝑟−1 + 2𝑚𝑟−1 𝜃𝛾𝐸𝑟−1
   + 𝑛𝑟−1 𝜃𝐸𝑟−1 + 𝑜𝑟−1 𝜃𝐵𝑟−1 + 𝑜𝑟−1 𝛾 − 2𝑜𝑟−1 𝜃𝐵𝑟−1 𝐸𝑟−1 − 𝑜𝑟−1 𝛾𝐸𝑟−1 ]


 𝑖𝑟 = 𝜃𝐶𝑟−1 [2𝜃𝐵𝑟−1 + 𝛾 + 𝑐𝑟−1 (1 − 𝛼)𝑢1 + 𝑛𝑟−1 𝜃 − 𝑗𝑟−1 ] + 𝜃𝐵𝑟−1 [2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃
   + 𝑏𝑟−1 𝜌2 (1 − 𝛼)𝑢1 + 𝑙𝑟−1 𝜌2 𝜃 + 2𝑚𝑟−1 𝜃2 ] + 𝛾[𝑏𝑟−1 𝜌2 (1 − 𝛼)𝑢1 + 𝑙𝑟−1 𝜌2 + 𝑜𝑟−1 ]
   + 2𝑓𝑟−1 𝜌1 𝜌2 − ℎ𝑟−1 𝜌1 𝐶𝑟−1 − ℎ𝑟−1 𝜌2 𝐵𝑟−1 + 𝑖𝑟−1 𝜌2 + 2𝑘𝑟−1 𝐵𝑟−1 𝐶𝑟−1 + 𝑙𝑟−1 𝜌1 𝜃𝐶𝑟−1      (21)
   + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃[𝜃𝐵𝑟−1 + 𝛾𝐶𝑟−1 ] − 𝑒𝑟−1 (1 − 𝛼)𝑢1 (𝜃𝐵𝑟−1 𝐶𝑟−1 + 𝛾𝐶𝑟−1 )
   − 2𝑜𝑟−1 𝜃[𝐵𝑟−1 𝐶𝑟−1 + 𝛾𝐶𝑟−1 ]


  𝑗𝑟 = 𝜃𝐶𝑟−1 [2 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃 + 𝑏𝑟−1 𝜌2 (1 − 𝛼)𝑢1 + 𝑒𝑟−1 (1 − 𝛼)𝑢1 + 𝑙𝑟−1 𝜌2 𝜃𝐸𝑟−1
    − 2𝑒𝑟−1 (1 − 𝛼)𝑢1 𝐸𝑟−1 + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃2 ] + ℎ𝑟−1 𝜌2 [1 − 𝐸𝑟−1 ] − 2𝑘𝑟−1 𝐶𝑟−1            (22)
    [1 − 𝐸𝑟−1 ] + 2𝑚𝑟−1 𝜃2 𝐶𝑟−1 𝐸𝑟−1 + 𝑜𝑟−1 𝜃𝐶𝑟−1 (1 − 2𝐸𝑟−1 ) .

           2
  𝑘𝑟 = 𝜃𝐸𝑟−1  [1 + 𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃 + 𝑚𝑟−1 𝜃 − 𝑜𝑟−1 𝜃] + 𝑒𝑟−1 (1 − 𝛼)𝑢1
                                                                                                (23)
    𝜃𝑒2𝑟−1 + 𝑘𝑟−1 1 + 𝐸𝑟−12
                  (︀                   )︀
                             − 2𝐸𝑟−1 .


  𝑙𝑟 = 𝜃𝐷𝑟−1 [2𝐵𝑟−1 + 𝛾 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢1 𝛾 + 2𝑎𝑟−1 (1 − 𝛼)2
    𝑢1 𝑢2 𝛾 + 𝑏𝑟−1 𝜌1 (1 − 𝛼)𝑢1 𝜃 + 𝑐𝑟−1 (1 − 𝛼)𝑢1 𝜃] + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃2 𝐵𝑟−1
    + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃𝛾 + 𝑑𝑟−1 (1 − 𝛼)𝑢2 𝛾 − 2𝑒𝑟−1 (1 − 𝛼)𝑢1 𝜃𝐵𝑟−1 − 𝑒𝑟−1 (1 − 𝛼)              (24)
    𝑢1 𝛾 − 𝑒𝑟−1 (1 − 𝛼)𝑢2 𝐵𝑟−1 − ℎ𝑟−1 𝜌1 − 𝑗𝑟−1 + 2𝑘𝑟−1 𝐵𝑟−1 + 𝑙𝑟−1 𝜌1 𝜃 + 2𝑚𝑟−1 𝜃2 𝐵𝑟−1
    + 2𝑚𝑟−1 𝜃𝛾 + 𝑛𝑟−1 𝜃 − 2𝑜𝑟−1 𝜃𝐵𝑟−1 − 𝑜𝑟−1 𝛾

         2
  𝑚𝑟 = 𝜃𝐷𝑟−1 [1 + 𝑎𝑟−1 (1 − 𝛼)2 𝑢21 + 𝑘𝑟−1 + 𝑚𝑟−1 𝜃2 − 𝑜𝑟−1 𝜃] + 𝑎𝑟−1 (1 − 𝛼)2 𝑢22 + 𝑑𝑟−1
                                                                                                (25)
     (1 − 𝛼)𝑢2 𝜃 − 𝑒𝑟−1 (1 − 𝛼)𝑢2 𝐷𝑟−1 .


𝑛𝑟 = 𝜃𝐷𝑟−1 [2𝐶𝑟−1 + 2𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃𝐶𝑟−1 + 𝑏𝑟−1 𝜌2 (1 − 𝛼)𝑢2 + 2𝑑𝑟−1 (1 − 𝛼)𝑢1 𝜃2 𝐶𝑟−1 ]
  + 𝑑𝑟−1 (1 − 𝛼)𝑢2 𝜃 − 2𝑐𝑟−1 (1 − 𝛼)𝑢1 𝜃𝐶𝑟−1 − 𝑒𝑟−1 (1 − 𝛼)𝑢2 − ℎ𝑟−1 𝜌2 + 2𝑘𝑟−1 𝐶𝑟−1            (26)
                        2
  + 𝑙𝑟−1 𝜌2 𝜃 + 2𝑚𝑟−1 𝜃 𝐶𝑟−1 − 2𝑜𝑟−1 𝜃𝐶𝑟−1


  𝑜𝑟 = 2𝜃𝐷𝑟−1 𝐸𝑟−1 [1 − 𝑒𝑟−1 (1 − 𝛼)𝑢1 𝜃 + 𝑎𝑟−1 (1 − 𝛼)2 𝑢21 𝜃2 − 2𝑜𝑟−1 ] + 𝑑𝑟−1 (1 − 𝛼)𝑢2
    𝜃𝐸𝑟−1 + 𝑒𝑟−1 (1 − 𝛼)𝑢2 − 2𝑒𝑟−1 (1 − 𝛼)𝑢1 𝜃𝐷𝑟−1 𝐸𝑟−1 − 𝑒𝑟−1 (1 − 𝛼)𝑢2 𝐸𝑟−1                   (27)
     + 2𝑘𝑟−1 𝐷𝑟−1 𝐸𝑟−1 − 2𝑘𝑟−1 𝐷𝑟−1 + 2𝑚𝑟−1 𝜃2 𝐷𝑟−1 𝐸𝑟−1 + 𝑜𝑟−1 𝜃𝐷𝑟−1
  Examining the influence of a change in 𝛼 on the strategy is another noteworthy aspect. In the
price path, 𝛼 determines the degree to which our trade has a lasting impact on the market price.
To illustrate this, we conducted a numerical example involving the purchase of 1000 shares, using
simulation parameters from [10].

         𝑇 = 20,            𝑆 = 1000,           𝑃0 = 50,           𝑋0 = 0,              𝜃 = 5 × 10−5 ,
                                                                                            √
        𝜌1 = 0.5,          𝜌2 = 0.5,            𝑢1 = 0.5,           𝑢2 = 0.5,          𝜎𝜂 = 0.001

Price process and market information have been considered as 𝜖𝑡 ∼ 𝑁 (0, 𝜎𝜂2 ). Figure 1 represent the
optimal trading strategy with 𝛼. We have also investigated how strategies change based on whether
the market is expected to be bullish or bearish. We consider the three market categories.




Figure 1: The optimal execution plans for investors with different levels of risk aversion. The market information
is shown by the black curve. For 𝛼 = 0 (only permanent market impact), the red curve exhibits the same trend
as the available market data.

  In addition, we analyzed how strategies differ when market expectations are bullish or bearish.we
examined three types of market situations by taking different value of 𝛼. There are different market
scenario mention as follows in figure 3 and figure 4 as follows:
Additionally, we have examined how trading strategies adapt to different market expectations, whether
bullish or bearish. We are considering three types of market scenario.
Figure 2: The optimal execution plans for investors with different levels of risk aversion. The market information
is shown by the black curve. For 𝛼 = 0 (only permanent market impact), the red curve exhibits the same trend
as the available market data.




Figure 3: The optimal execution plans for investors with different levels of risk aversion. The market information
is shown by the black curve. For 𝛼 < 0 (strong permanent market impact), the red curve exhibits the same trend
as the available market data.
Figure 4: The optimal execution plans for investors with different levels of risk aversion. The market information
is shown by the black curve. For 𝛼 > 0 (weak permanent market impact), the red curve exhibits the same trend
as the available market data.




Figure 5: The market type with different levels of risk aversion. The market information is shown by the black
curve. For 𝛼 > 0 (weak permanent market impact).


 In figure 5, the graph represents the market behaviour of different value of 𝑞 for various type of
market.


5. Conclusion
To develop complex methods for trading in financial markets optimally, this research proposes a
novel nonlinear programming approach. In a geometric Brownian motion under AR (2) model, our
model includes a second-order information element based on dynamic programming concepts. Trading
and portfolio managers are able to make more informed and flexible decisions by utilizing advanced
mathematical techniques, especially when navigating unpredictable and volatile market conditions.
We present a novel nonlinear programming approach to the optimal trading problem in the context of
developing sophisticated financial market trading methods. Utilizing dynamic programming concepts,
our model incorporates a second-order information element within the context of geometric Brownian
motion under AR (2). As part of our dynamic programming methodology, we explain its mathematical
foundation and its ability to manage second-order information elements under AR (2). Simulations
and empirical validations presented in the research demonstrate the effectiveness of our proposed
solution. We demonstrate the adaptability of our model across various market conditions, consistently
outperforming other methods.
The research presents simulations and empirical validations that show the effectiveness of our suggested
solution. In a variety of market conditions, the model consistently outperforms other trading strategy
optimization techniques.However, we also acknowledge that more empirical the market information’s
are necessary to validate and improve our model in a variety of asset classes and market situations
given the complex of financial markets.


References
 [1] D. Bertimas, A. W. Lo, Optimal control of execution costs, Journal of Financial Markets 1 (1998)
     1–50.
 [2] R. Almgren, N. Chriss, Optimal execution of portfolio transactions, Journal of Risk 3 (2000) 5–40.
 [3] G. Huberman, W. Stanzl, Optimal liquidity trading, Review of Finance 9 (2005) 165–200.
 [4] J. Gatheral, A. Schied, Optimal trade execution under geometric brownian motion in the almgren
     and chriss framework, International Journal of Theoretical and Applied Finance 14 (2011) 353–368.
 [5] R. Khemchandani, A. Bhardwaj, S. Chandra, Single asset optimal trading strategies with stochastic
     dominance constraints, Annals of Operations Research 243 (2016) 211–228.
 [6] S. Moazeni, T. F. Coleman, Y. Li, Optimal execution under jump models for uncertain price impact,
     Journal of Computational Finance 16 (2013) 1–44.
 [7] D. Bertimas, A. W. Lo, P. Hummel, Optimal control of execution costs for portfolios, Computing
     in Science & Engineering 1 (1999) 40–53.
 [8] D. Dentcheva, A. Ruszczyński, Portfolio optimization with stochastic dominance constraints,
     Journal of Banking & Finance 30 (2006) 433–451.
 [9] D. Roman, K. Daarby-Dowman, G. Mitra, Portfolio construction based on stochastic dominance
     and target return distributions, Mathematical Programming 108 (2006) 541–569.
[10] A. Singh, D. Selvamuthu, Mean-variance optimal trading problem subject to stochastic dominance
     constraints with second-order autoregressive price dynamics, Mathematical Methods of Operations
     Research 86 (2017) 29–69.