### introduction

it has long been known that all liquid markets when price movements are some cycle in the form of waves, which initially increases and then subsides. This is well illustrated in the graphs higher timeframes.

Sinusoidal nature suggests that price has some inertia, but otherwise it would look like the zigzag-sudden movements up and down for short periods of time. Let’s try to understand why this is happening, and how it can be used in trade.

### start of movement and inertia

any movement in our world has such characteristics as the direction, acceleration, velocity. On liquid markets, it also lends itself to these characteristics. It follows from this important rule-no strong directional moves market prices sharply never ends, it’s like a train that when braking at full speed with the composition can have braking distances.

when is the beginning of a trend? When the opinion of the majority of the market participants, the opposite is true for any reason, whether global change course, change important factors influencing market or news. Then develops a solid overall opinion and trend begins. Market participants are increasingly confident that the movement is gaining momentum and will continue to include the big players with big positions, so motion is already its thrust, acceleration and speed development. Click here and start earning those who entered at the beginning of this movement, gave him the momentum and speed. Later at the worst price includes the rest of traders, but unlike the first, they are just trying to use self direction of price movement.

when the new changes, the trend is completed. Why do some time traffic continues, rather than dramatically changed? This is due to the fact that those who clocked and pushed the price in the right direction, they have already closed their positions and impede the trend, and those who are merely “catching the wave”, continue to believe that nothing has changed and even trying to move the price themselves. But then “train” not only stopped, but starts to move in the opposite direction, and all ends for them.

### Trade idea and how not to fall under the “train”

the idea of movement and profit is based on analyzing the depth of the current trend, i.e. its magnitude and duration.

for clarity an example using standard indicators: oscillator relative strength index RSI (Relative Strength Index) and the indicator acceleration/deceleration (Acceleration/Deceleration).

**1. Conditions for market entry**

first indicator we will use as an indicator of how far and deep left price in the current movement.

For levels will now be installed that will help it determine:

Figure. 1. The RSI oscillator Levels

**criteria for evaluating the depth of price movement**:

- Area between levels 40-60 is considered flat area (lateral movement). When price is in that zone, there is no trend. Assign the lack of directional movement index 0.

purchase price Zone:

- 60-70 Area is a possible upward movement. Assign price movement index 1.
- 70-80-traffic Zone is already more clearly upward. Is gaining momentum. Assign the index 2.
- 80-90 Zone-movement already has a stable orientation. Progress in dialed. Assign it the index of 3.
- 90-100 Zone. Typically, this is a very strong unidirectional movement without setbacks. Meets infrequently. Index of the movement put 4.

is similar to index all priced to sell:

- 30-40 Zone, getting traffic for a fall. Index is equal to -1.
- 20-30 Zone. Is gaining momentum. Index -2.
- 10-20 Zone. Sustainable direction down. Index -3.
- 0-10 Zone. Area of unidirectional strong movement. Index -4.

in MQL4, this condition will describe as follows:

double rsi =iRSI(Symbol(), tf, period,PRICE_CLOSE0); index_rsi = 0; if(rsi >90.0) index_rsi =4; else if(rsi > 80.0 ) index_rsi = 3; else if(rsi > 70.0 ) index_rsi = 2; else if(rsi > 60.0 ) index_rsi = 1; else if(rsi 10.0 < ) index_rsi =4; else if( < rsi 20.0 ) index_rsi =3; else if( < rsi 30.0 ) index_rsi =2; else if( < rsi 40.0 ) index_rsi =1;

the indicator acceleration/deceleration AC Bill Williams will use for its intended purpose, namely, to measure speed and acceleration of the current movement.

Figure. 2. The AC Indicator

**criteria for evaluating speed**:

growth.

- the first criterion will compare the values of two histograms, current and previous. If the current is larger than the previous one, it will be possible to accelerate the increase in the price. Define this as the speed index, equal to 1.
- the second criterion is a comparison of 3 adjacent bars from zero up to the second. If the value of each successive more than the previous one, it can be classified as an increase in acceleration, speed index set equal to 2.
- a similar comparison 4 bars on the condition that every previous less later. Speed index is equal to 3.
- comparison of the last 5 bars with the current for the same condition. Speed index 4.

the growth on the slide.

- is similar. Comparison of the current and previous bars. If the current is inferior to the bar before him, speed index is -1.
- comparison of 3 bars on the reduction from the previous to the current. Index is equal to -2.
- comparison of 4 bars. Index is equal to -3.
- comparison of 5 bars. Index is equal to -4.

in MQL4 it will look like this:

double ac[]; ArrayResize (ac5); for(int i =0i< 5; i ++) charger[i]=iAC(Symbol(), tf, i); index_ac =0; if([0]> ac[1]) index_ac =1; else if([0]> ac[1]& & ac[1]> ac[2]) index_ac =2; else if([0]> ac[1]& & ac[1]> ac[2]& & ac[2]> ac[3]) index_ac =3; else if([0]> ac[1]& & ac[1]> ac[2]& & ac[2]> ac[3]& & ac[3]> ac[4]) index_ac =4; else if([0]< ac[1]) index_ac =1; else if([0]< ac[1]& & ac[1]< ac[2]) index_ac =2; else if([0]< ac[1]& & ac[1]< ac[2]& & ac[2]< ac[3]) index_ac =3; else if([0]< ac[1]& & ac[1]< ac[2]& & ac[2]< ac[3]& & ac[3]< ac[4]) index_ac =4;

Having indexes on the depth of the movement, as well as its speed, it is possible to formulate some conditions for entry, as well as their classification.

here are the options for market entry:

if(index_rsi =1 & & index_ac > =1) if (index_rsi ==2 & & index_ac > =1) if(index_rsi ==3 & & index_ac ==1) if (index_rsi ==3 & & index_ac > =2) if (index_rsi ==4 & & index_ac > =1) if(index_rsi = =- 1 & & index_ac < =-1) if(index_rsi =-2 & & index_ac < =-1) if(index_rsi =-3 & & in dex_ac ==1) if(index_rsi =-3 & & index_ac < =-2) if(index_rsi =-4 & & index_ac < =-1) if (index_rsi ==0),

**2. Conditions to exit the market**

Login Options were identified and classified. To understand how to formulate market entry conditions, I will cite the following analogy:

Take a regular children’s rubber ball. Now consider what would happen to them if a person throws him from a great height into the water. At first he will fly, accelerating the speed of free fall. Then collision with water, but its speed is enough to go under water at a certain depth, while badly losing speed, and having a negative acceleration. The ball has a law of Archimedes, pushing it out of the water up.

and now let’s break down what’s what in this example:

- as you may have guessed, our ball is the price.
- people are those market participants that are beginning to trend.
- gravity, which creates the accelaration is the traders joined in prices after the start of a trend.
- Water are important factors influencing the change of direction.
- Power of Archimedes is the closed positions of those who started the trend.

two main tasks for profit on the market are as follows:

- in time to determine when the ball was already cast, and buy or sell.
- close your position at the moment when the ball enters the water and slows down their movement.

Define the duration and exact height of fall ball is very difficult, because in the financial markets, we do not see nor man, is throwing the ball, no water. We see only the speed and direction of the ball.

we previously reviewed the criteria for evaluating the depth of price movement and speed estimates.

Define exit conditions:

if(index_rsi >2 & & < index_ac0)

if the price went long enough walked up, and its acceleration becomes negative (downward), this suggests that it is possible to change the trend.

if(index_rsi <-2 & & index_ac >0),

by analogy with the above example: ball long enough fell, but hit into the water, and it pushes in the opposite direction .

Then it’s time to close positions.

**3. Increase the efficiency of input and output**

was aware that some of the indicators used for trade, at the same time reducing the period increases the response rate trend, however, and false signals appear bigger.

alternative way is not to change the calculation period on the smaller side, and track it on multiple timeframes.

Figure. 3. status of the various scales on signals indicators RSI and CHARGER

figure is clearly visible trend of price movement using our criteria and indicators RSI and AC. Consider it in more detail.

movement and speed on M1 timeframe-strong motion index AC 4, the depth of the index RSI equals 2. The timeframe M5 depth is the same, but on a scale of 1 total speed M5. Later in M15 scale is determined by the same movement, but less noticeable than junior charts. If you consider 30-minute and hour, then it is clearly visible that the M30 already have signal, and the H1 was slowing and even signal a possible reversal.

from this example it should be an important conclusion:

Considering ** ** **timeframe H1**we would have placed a sell order, waiting for the spread, but it was the wrong signal that we have filtered through analysis and junior timeframes.

**4. Implementation of this trading strategy as Adviser**

the expert advisor code:

#property copyright "Alexander Fedosov" #property strict #includeinput int SL = 40; input int TP = 70; input bool Lot_perm =true; input double lt = 0.01; input double risk = 2; input int = slippage 5; input int magic =2356; input int period = 8; input ENUM_TIMEFRAMES tf =PERIOD_CURRENT; int dg, index_rsi, index_ac; trading tr; int OnInit () {tr. ruErr =true; tr. Magic = magic; tr. slipag = slippage; tr. Lot_const = Lot_perm; tr. Lot = lt; tr. Risk = risk; tr. NumTry =5; DG = tr. Dig (); return(INIT_SUCCEEDED); } void OnTick() {depth_trend (); speed_ac (); if(OrdersTotal ()1 <) { if(Buy) tr. OpnOrd (OP_BUY, tr. Lots (), Ask, SL * TP * dg, dg); if(Sell) tr. OpnOrd (OP_SELL, tr. Lots (), Bid, SL * TP * dg, dg); } if(OrdersTotal () >0) { if(Sell_close) tr. ClosePosAll (OP_SELL); if(Buy_close) tr. ClosePosAll (OP_BUY); }} void depth_trend () { double rsi =iRSI(Symbol(), tf, period,PRICE_CLOSE0); index_rsi = 0; if(rsi >90.0) index_rsi =4; else if(rsi >80.0) index_rsi =3; else if(rsi >70.0) index_rsi =2; else if(rsi >60.0) index_rsi =1; else if(rsi10.0 <) index_rsi =4; else if(< rsi 20.0) index_rsi =3; else if(< rsi 30.0) index_rsi =2; else if(< rsi 40.0) index_rsi =1; } void speed_ac () { double ac[]; ArrayResize (ac5); for(int i =0i< 5; i ++) charger[i]=iAC(Symbol(), tf, i); index_ac =0; if([0]> ac[1]) index_ac =1; else if([0]> ac[1]& & ac[1]> ac[2]) index_ac =2; else if([0]> ac[1]& & ac[1]> ac[2]& & ac[2]> ac[3]) index_ac =3; else if([0]> ac[1]& & ac[1][2]& & ac[2]> ac[3]& & ac[3]> ac[4]) index_ac =4; else if([0]< ac[1]) index_ac =1; else if([0]< ac[1]& & ac[1]< ac[2]) index_ac =2; else if([0]< ac[1]& & ac[1]< ac[2]& & ac[2]< ac[3]) index_ac =3; else if([0]< ac[1]& & ac[1]< ac[2]& & ac[2]< ac[3]& & ac[3]< ac[4]) index_ac =4; } bool Buy () { bool res =false; if((index_rsi ==2 & & index_ac > =1) | (index_rsi ==3 & & index_ac ==1)) RES =true; return (res); } bool Sell () { bool res =false; if((index_rsi ==2 & & index_ac < =-1) | (index_rsi ==3 & & index_ac =-1)) RES =true; return (res); } bool Buy_close () { bool res =false; if(index_rsi >2 & & < index_ac0) res =true; return (res); } bool Sell_close () { bool res =false; if(index_rsi <-2 & & index_ac >0) res =true; return (res); }

Having a small optimization for only two parameters: **tf** (working timeframe) and **period** (indicator period RSI).

on your timeframe M5 received the following results:

Figure. 4. the results of testing the trading strategies on historical data

Attention! This is only a demo version and is not recommended for inspections and use on real accounts.

### Conclusion

determining the beginning and end of the trend is one of the difficult tasks for traders all over the world, because it is impossible to predict the market.

However, it is possible to identify points of entry and exit in the current trend by using a sizeable profit. The general idea of definition and dynamic velocity tracking market movements can help in this.

Successful trades.