Tip Deflection Determination of a Barrel for the Effect of an Accelerating Projectile Before Firing Using Finite Element and Artificial Neural Network Combined Algorithm

For realistic applications, design and control engineers have limited modelling options in dealing with some vibration problems that hold many nonlinearity such as non-uniform geometry, variable velocity loadings, indefinite damping cases, etc. For these reasons numerous time consuming experimental studies at high costs must be done for determining the actual behaviour such nonlinear systems. However, using advantages of multiple computational methods like Finite Element Method (FEM) together with an Artificial Intelligence (ANN), many complicated engineering problems can be handled and solved to some extent. This study, proposes a new collective method to deal with the nonlinear vibrations of the barrels in order to fulfil accurate shooting expectancy. Using known analytical methods, in practical, to determine dynamic behaviour of the barrel beam is not possible for all conditions of firing that include numerous varieties of ammunition for different purposes, and each projectile of different ammunition has different mass and exit velocity. In order to cover all cases this study proposes a new method that combines a precise FEM with ANN, and can be used for determining the exact dynamic behaviour of a barrel for some cases and then for precisely predicting the behaviour for all other possible cases of firing. In this study, the whole nonlinear behaviour of an antiaircraft barrel were obtained with 3.5% accuracy errors by ANN trained by FEM using calculated analysis results of ammunitions for a particular range. The proposed FEM-ANN combined method can be very useful for design and control engineers in design and control of barrels in order to compensate the effect of nonlinear vibrations of a barrel for achieving a higher shooting accuracy; and can reduce high-cost experimental works.


INTRODUCTION
The non-linear dynamic behaviour of a structure due to the effect of an accelerating mass is still a research interest with the applications of it in the new fields such as defence and transportation engineering.The effects of moving loads on the dynamics of the structures have been widely studied in literature, for example, (Dehestani et al., 2009;Lee, 1996;Michaltsos, 2002;Niaz and Nikkhoo, 2015;Omolofe and Oni, 2015;Wang, 2009) have investigated the subject.For the application to the bridge engineering (Michaltsos et al., 1996) have studied the effect of accelerating vehicles on the bridge beams, considering highway bridges and high speed rail road construction.Some more accurate tools of engineering calculations of the dynamic interaction using FEM have been proposed by (Esen, 2011(Esen, , 2015(Esen, , 2013;;Kahya, 2012) .Using analytical methods for simple cases neglecting damping effects and assuming uniform beam cross sections (Esmailzadeh and Jalili, 2003;Liu et al., 2015;Wyss et al., 2011) have studied the subject in terms of vehicle structure interaction problems.Using a two-axle half car model, (Lou, 2005) has studied the wheel -rail interaction and dynamics of a railway bridge.For both simple and realistic models of moving vehicles can be found in (Azimi et al., 2013;Lou and Au, 2013;Yang et al., 2013).
The moving mass problem is also vital in defence field, but the studies in this field are rarely available in literature due to the confidentiality.Using a precise FEM model (Esen and Koç, 2015a) have presented the interaction of an accelerating projectile and a barrel of a cannon.Effect of stepped barrels on the stability and the dynamics of barrels have been investigated by (Balla, 2011;Tawfik, 2008).In order to understand interaction between projectile and barrel, (Alexander, 2007) has prepared an ABAQUS explicit dynamic finite element model, and then compared analysis results to the test data 155 mm cannon.M. Stiavnicky and P. Lisy, 2013 have investigated numerical simulation to determine influence of the barrel fixing on barrel vibration when bullet exits barrel.Another aspect of reducing the vibrations is the usage of dynamic vibration absorbers, and (Esen and Koç, 2015b;Kathe, 1997;Littlefield et al., 2002) have studied the vibration reduction of barrels.
ANN also known as 'parallel distributed processing' is a powerful artificial intelligence for solving complicated engineering problems.This method can be applied to predict the desired output parameters when the database of the problem represents all relationships.ANN have been used in different engineering applications such as mechanical vibrations (Koide et al., 2014;Lagaros and Papadrakakis, 2012;Liu et al., 2015;Martínez-Martínez et al., 2015;Perez-Ramirez et al., 2016) rail rolling processing (Altınkaya et al., 2014), creep modelling (Düğenci et al., 2015), steel projectile penetration depth (Hosseini and Dalvand, 2014) and internal combustion engines to estimate some important parameters of fuels on emissions (Cay, 2013;Czarnigowski, 2010).The uses of ANN in the field of defence systems have recently begun to increase.ANN models have played an important role in the development of military automatic target recognition (ATR) (Rogers et al., 1995).
Considering all the nonlinearity such as projectile/barrel interaction, different masses, and exit velocities of projectiles, non-uniform barrel cross-sections, inertia effects of the accelerating mass, precise damping model of whole system, the design engineers need more methods that are accurate in order to determine actual behaviour to satisfy the perfect shooting expectancy.In practical, to determine the dynamic behaviour of a barrel beam is not possible for all conditions of firing.For Latin American Journal of Solids and Structures 13 (2016) 1968-1995 example, for a tank system, there are various classes of ammunition for different purposes, and each projectile of different ammunition has different mass and exit velocity.In order to cover all cases, this study proposes a new method that combines a precise FEM with an artificial intelligence technique ANN, and can be used for determining the dynamic behaviour of the barrel for some cases and then for precisely predicting the behaviour for all other possible cases of firing.The proposed FEM-ANN combined method can be very useful for control engineers in design of fire control algorithm of weapon in order to compensate the effect of nonlinear vibration of a barrel for achieving a higher shooting accuracy.There should be many compensation sub systems in a weapon system in order to satisfy the shooting accuracy that is the most important property in such systems.However, in order to design a proper compensation system, engineers need very large data about the dynamic behaviour of the barrels.The needed data can be created by means of experimental studies, but experimental studies are generally time-consuming and expensive.As an alternative to the experimental studies, one of the economic ways of creating accurate data is the modelling using the prediction power of artificial intelligence techniques.In this study, the mass and exit velocity of a projectile are used as input, while the tip deflection as output, and the predictions of the deflections have been achieved with an acceptable accuracy.Where, the R 2 is 0.99 for training and testing; the MSE for training is 8.25x10 -4 , for testing is 0.03767; the MEP, for training is 0.5%, for test is 0.1%.
Without omitting all the nonlinearities including damping, this method can also easily be adapted to other problems of the structural dynamics such as vehicle bridge interaction, wheel/rail interaction, high-speed precise machining, and flexible run-ways of robotic systems, etc. Being capable of predicting the nonlinear behaviour for many cases, this technique can reduce research and development costs by reducing costly and time-consuming experimental studies.

MATHEMATICAL MODELLING
In the formulation, the following assumptions will be adopted (Fig. 1)  The mass inertia is considered. The mass is always in contact with the beam. The beam is thin and small displacements in the beam occurred according to thin beam theory. The beam is of variable thickness and the material properties are constant trough length of the beam. The trajectory of the mass is defined by time-dependent x p (t) Based on the above assumptions, the motion equation of the barrel beam due to the effect of the projectile located at the time-dependent point x p within the barrel beam, is provided by Eq. (1) (L.Fryba, 1999): Latin American Journal of Solids and Structures 13 (2016) 1968-1995 The left hand side of Eq. ( 1) represents the resisting internal stiffness, inertia and damping forces due to the external forces on the right side.Where, ρ is the density, A(x) is the none-uniform cross-sectional area, σ is the equivalent viscous damping coefficient, E is the Young's modulus of elasticity; I(x) is the area moment of inertia, while x represents the central coordinate of the barrel system; t represents time; w(x, t) is the vertical displacement of the barrel; m p is the mass of the projectile; In order to determine time dependent displacements of the barrel tip, which is very important for shooting accuracy of the weapon, a rough analytical solution of the motion Eq. ( 1) can be obtained through some simplifications by ignoring the effects of inertia and damping, and accepting that the cross-section area is uniform and the projectile moves with a constant velocity.For simplified cases, that omits geometric and dynamic nonlinearities, such moving load problems have been extensively studied in the literature by numerous researchers.From this perspective, the proposed FEM-ANN combined method can be very useful for design and control engineers if they pay attention to the requirements of modelling as described below.
The model of the barrel with an accelerating projectile is shown in Figure 1.The interaction of the barrel and the projectile are determined in both vertical and horizontal directions.Solids and Structures 13 (2016) 1968-1995 While the barrel is vibrating, the transverse and longitudinal interaction forces between the barrel and the projectile that is accelerating trough the deflected barrel geometry can be determined by using the following equation (Cifuentes, 1989;L. Fryba, 1999): (3) In above equation f z (x,t) and f x (x,t) respectively, are transverse and horizontal contact forces between the barrel and the projectile accelerating at point x p on the axis, while t represents time, while δ(x-x p ) and g are the Dirac-delta function and the gravitational acceleration, respectively.
The parameters x 0 and v 0 are the initial position and initial speed of the projectile at time t=0, respectively.On the other hand, a m is the average acceleration of the projectile within the barrel.
Under the effect of the accelerating projectile, the equivalent nodal forces of the barrel element (Figure 2 a and b) and the relationships between the shape functions and the transverse and longitudinal deflection functions and the nodal displacements of the s th element at position x m (t) at time t are as follows: (Clough R.W;Penzien J., 2003): i  (i=1-6) are the shape functions of the beam element (Clough R.W;Penzien J., 2003) .The length of the element is l. and x m (t) is the variable distance between the accelerating projectile and the left end of the s th element at time t as shown in Figure 2b.The property matrices of a beam element in Figure 2, having transverse and longitudinal nodal forces and displacements, can be derived from the procedure of the principle of virtual work and the relation of the kinetic and internal potential energies of the element.
In the case of interaction with a projectile, any stiffness coefficient associated with beam flexure and axial displacements for the element on which the projectile locates is as follows: ( ) ( ) In the same manner, for the relation between nodal accelerations and resisting inertial forces, the elemental balance equation can be obtained.Including the effect of the projectile, any mass coefficient associated with beam flexural and axial accelerations are as follows: y y y y y y y y y y y y y y y y The damping in the system can be any type; and for structural systems, hysteric and structural damping may be applied.However, considering practical usage in engineering any type of damping can be modelled as viscous damping using equivalent damping approximations.In this study, the damping is modelled as equivalent viscous damping using Rayleigh's proportional damping theory Latin American Journal of Solids and Structures 13 (2016) 1968-1995 in which the damping matrix is proportional to the combination of the mass and stiffness matrices; and including the effect of accelerating projectile, the coefficients of time dependent damping matrix can be formed as follows: where i z and j z are the damping ratios of the structural system for any corresponding natural fre- quencies ω i and ω j .The instantaneous equation of motion for the entire system is can be expressed as: where and then can assemble them properly using the conventional FEM approach.In case of an accelerating projectile the time dependent elemental matrices of the beam element s are determined using the coefficients given Eqs.(6, 7 and 8).For calculation of time dependent property matrices, the instantaneous values of x m (t) and s are: (integer part of ( ) / ) 1, (1 ) Embedding the other inertia, centripetal and Coriolis forces in the left side of the system equation, only the vertical gravitational and longitudinal acceleration force components of moving projectile should be applied as external forces; thus, the instantaneous overall force vector becomes as follows: ( 2,3,5,6), ( 1, 4) 3 ARTIFICIAL NEURAL NETWORK MODELLING TO PREDICT THE AMOUNT OF TIP DIS-

PLACEMENT
Recent developments have also increased the use of computer systems for military purposes.In the beginning, they are used to perform complex operations in a short time, but today computers are used to make predictions on the relationship between separate events using big data analogous to Latin American Journal of Solids and Structures 13 (2016) 1968-1995 the human brain.Thanks to the discovery of new information, learning refers to the process of improvement in behaviour in living beings.On the other hand, Machine learning refers to a situation where all of these operations are conducted by a computer.To be able to learn, computers require a dataset on the event in question, thus learning through artificial neural networks requires a training set.Examples in the training set are based on previous experience with the problem in question.Learning is achieved by introducing these examples to the neural network in an order.Artificial neural networks are computer systems that are able to learn and to react to stimuli in the environment by making use of previous examples implemented by humans.At a most basic level, the task of an artificial neural network is to produce a set of outputs that correspond to given inputs.For the artificial neural network to be able to do that, the network needs to be trained by existing examples of events representing the engineering problem in question, and eventually needs to acquire the ability to generalize.
The most important parameter that affects the shooting accuracy of a weapon system is the vertical movement of the muzzle, which happens during shooting, also known as a muzzle displacement.These movements cause the barrel axis to displace, and have an adverse effect on the shooting accuracy of the weapon system.Considering the long ranges of contemporary weapon systems, small muzzle displacements can result in large deviations from the target.Muzzle displacements are affected by two basic parameters.The first of these parameters is the velocity of the projectile as it departs from the muzzle, and the second is the force of gravity perpendicular to the muzzle axis, due to the mass of the projectile.Contemporary firearms, in particular, are designed to have larger projectile masses and higher muzzle velocities in order to be more effective against rapidly moving and manoeuvring targets.However, larger projectile masses and higher muzzle velocities have generated serious problems on the target accuracies of weapons.
To deal with this problem, a number of active and passive control systems have been designed.For example, some studies (Esen and Koç, 2015a;Littlefield et al., 2002) report that when a massspring system is added to the muzzle, it is able to decrease muzzle displacement by around 50%.However, this technique was not able to eliminate muzzle displacement, which could be due to a number of reasons.One reason is that the projectile forces the barrel to change its frequency continuously until it departs the muzzle, making it difficult to design an appropriate absorber.In addition, even if an absorber were to be designed that matches the forcing frequency of the projectile, the natural frequencies of the whole system change when the absorber is mounted on the barrel.All of these factors limit the use of passive vibration absorbers on gun barrels.Active control systems have also been designed to prevent muzzles from dipping.However, these systems are very expensive and time consuming, and have limitations of their own.Different types of ammunition can be used in a weapon system for different purposes.Each type of ammunition would have its own projectile mass and exit velocity.Thus, barrel dynamics would react differently to the different types used.For illustrative purposes, Table 1 reports the different types of ammunition used in a 120 mm tank cannon.As the table shows, projectile mass varies between 5.5 and 12.2 kg, and the exit velocity of the projectile varies between 1140 and 1170 m/s.Similarly, Table 2  Using an artificial neural network, this study aims to predict the amount of tip displacement of a barrel in a weapon system, due to an accelerating projectile.Using this artificial neural network, designed for many different projectile masses and exit velocities, the amount of muzzle displacement that occurs when different types of ammunition are used can be predicted prior to shooting.This way, deviations from the target can be calculated and the needed adjustments can be made for the barrel position to eliminate all deviation.

The Structure of the Artificial Neural Network
An artificial neural network consists of a large number of process elements connected to each other and called parallel process structures.Each process element in turn, consists of five components: inputs, weights, aggregation function, activation function, and outputs.Figure 3 provides the structure of a process element.Inputs are the information that is input to the process element from the outside world.A process element can receive inputs from other process elements as well as from the outside world.Weights represent the effect of the incoming information on that process element.Aggregation function calculates the net input received by the process element.There are many different types of aggregation functions (multiplication, maximum, majority, etc.).This study uses a weighted aggregation function.This function calculates the net input to a process element by taking the weights of inputs into consideration, as follows: In Eq. ( 12), I p represents inputs and w represents weights.N is the total number of inputs received by a process element.The NET value that results is then sent to the activation function.
The activation function processes the net input received by the process element, and calculates the output that will be produced by the process element for this input.As is the case with the aggregation function, many different formulas can be used in an activation function to calculate the output.Because this study aims to create a multi-layered neural network model, the sigmoid function was used, which is a differentiable function and is expressed as follows: The output of a process element is the value produced by the activation function.The output of a process element can be sent to the outside world, or can be used as an input to another process element.

Multi-Layered Neural Network Structure
Figure 4 describes the three-layered neural network model used in this study.The layers that structure the neural network are the input layer, the hidden layer, and the output layer.The input layer consists of two process elements, one of which represents the projectile mass m p (kg) and the other represents the exit velocity v (m/s) of the projectile.The input data is transmitted to the hidden layer without undergoing any processing in the input layer.
The hidden layer contains six process elements.The task of the hidden layer is to process the information received from the input layer, and transmit it to the next layer after processing.As Figure 4 shows, this study uses a single hidden layer with six process elements.The output layer processes the information-received form the hidden layer, and calculates the output to be produced by the network in response to the input received at the input layer.In the output layer, this study uses the process element described in Figure 3.This process element represents the amount of muzzle displacement at the moment the projectile leaves the muzzle w z (x=L,t).

Learning Rule of the Multi-Layered Neural Network
A supervised learning strategy was used in the neural network model for muzzle displacements.The generalized delta rule (GDR) used for network learning consists of two parts.The first part is forward propagation and the second part is backward propagation.

Forward Propagation
At this stage, the first example in the training set is introduced to the network.Because there is no data processing in the input layer, incoming data is directly transmitted to the hidden layer.The input of the k th process element in the hidden layer is calculated as follows: In Eq. ( 15), G kj represents the weight of the link between the k th process element in the input layer and the j th process element in the hidden layer, as shown in Eq. ( 16).The output of the j th process element in the hidden layer, on the other hand, is calculated by processing the net input to Latin American Journal of Solids and Structures 13 (2016) 1968-1995 this element through the sigmoid function.Accordingly, the output of the j th process element in the hidden layer is calculated as follows: All process elements in the hidden layer are similarly related to the process elements in the output layer.The output of a process element in the output layer is also calculated by first calculating the net data received by this element, and processing that data through the sigmoid function, as follows: In Eq. ( 18), H jm represents weight of the link between the hidden layer and the output layer, and is expressed as in Eq. ( 19).

Backward Propagation
After the first example in the training set is introduced to the network and the output of the network is calculated, this output is compared to the expected output, and the difference between the two is called the error.Training an artificial neural network means reducing this error further with each new example in the training set.The error for the m th process element in the output layer is calculated as follows: In Eq. ( 20), B m represents the expected output value for the m th process element, and O m represents the output value produced by the neural network for this process element.This value is the error value for a process element.To reduce the error, weights of the links between the hidden layer and the output layer, and between the hidden layer and the input layer are changed.The error of the neural network is expressed using the mean squared error (MSE), and the absolute fraction of variance R 2 and the mean error percentage MEP are respectively given by: Latin American Journal of Solids and Structures 13 (2016) 1968-1995 In Eq. ( 22), λ represents learning coefficient, and Φ represents momentum coefficient.In addition, Λ m represents the error of the m th output unit, and it is calculated as follows when the sigmoid function is used as the activation function: After ΔH a (t), the amount of change at iteration t N , is calculated, the new value of the weights at iteration t N is calculated as follows: Once the new weights of the links between the process elements in the hidden layer and in the output layer are calculated, the new weights of the links between the process elements in the hidden layer and in the input layer are calculated.The amount of change in the links between the hidden level and the input layer, ΔG i , is expressed as follows: In Eq. ( 25), the error term Λ a is calculated as follows, assuming the activation function is the sigmoid function: After the error value is calculated, the new values for the weights of the links between the process elements in the hidden layer and in the input layer are calculated as follows: Latin American Journal of Solids and Structures 13 (2016) 1968-1995

Training of the Multi-Layered Neural Network
Training an artificial neural network means reducing, for each example in the training set, the difference between the actual output value and the output value produced by the neural network, to below error tolerance.The training process is the process of adjusting weights in the neural network until the expected outputs are achieved for each example in the training set.Before using (testing) a neural network, the network needs to be trained well.In the training set, the projectile mass varies between 0.5 kg and 1.5 kg, whereas exit velocity of the projectile varies between 1000 and 1600 m/s.To deal with this imbalance between the parameters in the training set, all values were scaled between 0 and 1, within their own groups.For example, for the parameter of velocity, 1 represents 1600 m/s, which is the highest value, and 0 represents 1000 m/s, which is lowest value.The following formula was used to scale the input values: In Eq. ( 28), x r represents the input value to be scaled, x min represents the minimum value in the input set, x max represents the maximum value in the input set, and x r ˈ represents the scale x r input Latin American Journal of Solids and Structures 13 (2016) 1968-1995 value.For example, for a projectile's exit velocity x r =1300 m/s, the scaled x value is calculated as x r ˈ =0.5 using Eq. ( 28), because x min =1000 m/s and x max =1600 m/s.
Because inputs in the training set and expected outputs are presented to the neural network in scaled format, the output values produced by the neural network will also be scaled between 0 and 1.To translate these values back to their original format, Eq. ( 28) is expressed as follows:

Defining Stopping Criteria
In an artificial neural network, needs to be stopped once the values of the weights are able to represent the problem space.The reason for this is that if the training continues after the weights become able to represent the problem space, further changes in the weights of the network may result in lower performance.There are two algorithms used to decide when to stop training.
In the first, training is stopped when the error values calculated for all the examples in the training set are reduced to below a pre-defined level.In the second, training is stopped after a certain number of iterations, which requires a few trials to be made, to determine the number of iterations.This study uses the second algorithm.Although determining the appropriate number of iterations is a laborious process, the result was worth the effort.

NUMERICAL EXAMPLES
In this paper, the Newmark direct integration method (Wilson, 2002) is used along with the time step Δt = 0.0001, β=0.25 and γ=0.5 values to obtain the solution of Eq. ( 11), where β and γ are parameters that manage the sensitiveness and stability of the Newmark procedure.When β takes 0.25 value and γ 0.5, this numerical procedure is unconditionally stable.
Example 1: Let us take a simple supported isotropic beam-plate transversed by a F = 4.4 N moving load.The dimensional and material specifications of the plate are identical with those chosen in (Reddy, 1984), i.e. l x = 10.36 cm; l y = 0.635 cm, h = 0.635 cm; E = 206.8GPa, ρ = 10686.9kg/m 3 ; T f = 8.149 s, where T f is the fundamental period.In Table 4, dynamic amplification factors (DAF), which are defined as the ratio of the maximum dynamic deflection to the maximum static deflection, are compared with several previous numerical, analytical, and experimental results available in literature.It is noted that T is the required time for moving load to travel the plate.It is seen that the results obtained by the new finite element (column 3) are very close to the analytical solution (Meirovitch, 1967), and the results of first order shear deformation theory (FSDT) method (Kadivar, 1998).Example 2: For numerical verification, Table 3 reports   (2) Analytical solution from Ref. (Meirovitch, 1967).
As Figure 4 shows, the topological structure of the neural network created contains an input layer, hidden layer, and an output layer.There are two process elements in the input layer, representing, respectively, the inputs of projectile mass and departure velocity.The hidden layer, on the other hand, contains six process elements.The output layer contains a single process element.This process element represents the amount of muzzle dip w z (x=L,t) at time t and projectile location x=L.Sigmoid function was used both in the hidden layer and in the output layer as the activation function.Figure 5 shows flowchart of the ANN and FEM combined algorithm for predict barrel tip displacement.
The training of the network was completed in 90,000 training rounds.Each round consisted of 25 iterations.Figure 5 displays the errors that resulted when the MSE expression given in Eq. (21a) was used.As the graph shows, the MSE dropped from 0.138 to less than 0.02 at the end of 10,000 training rounds.At the end of 90,000 training rounds, the MSE value was 0.000825, at which point the training was stopped.The effects of the various processing elements in the intermediate layer by GDR algorithm are presented in Figure 6.In this study, 9x10 4 training cycles were used.However, the graph show 5x10 3 iterations of the first portion to be understood more clearly.In addition, Figure 6a shows the change in the value of MSE for different process element, and in Figure 6b, the change in the value of R 2 for various process elements usage is presented.Once the neural network was trained using 90,000 training rounds, the neural network was tested using examples that were not included in the training set.Eqs. ( 30) and ( 31) provide the weights of the links between the input layer and the hidden layer, and between the hidden layer and the output layer, respectively, after the training was completed.

Iter=1
Calculate Net1 and Net2 inputs to the j th process element in the hidden layer using Eq. ( 15) Calculate output of the j th process element in the hidden layer by processing the input this element through the sigmoid function using Eq. ( 17) Determine learning (l) and momentum (a) coefficients

Training sample =1
Net input and output of the output layer is determined by using Eq. ( 18) Calculate error of the network for this sample using Eq. ( 20) Calculate amount of chance in iteration iter in the weight of the link between the jth process element in the hidden layer using Eq. ( 22)

Backward propogation
Calculate new value of the weights between output and hidden layer using Eq. ( 24) Calculate amount of chance in iteration iter in the weight of the link between hidden and input layer using Eq. ( 25) Build Finite Element Equation of entire system using Algorithm 1 (Appendix A).

FEM algorithm
Calculate ANN value for this sample and than translate this value back their orginal format using Eq. ( 29) Calculate E ve e t values for this sample.The most experienced problem during the training of multi-layered network is the very long period of learning.Many parameters affect the training time such as learning coefficient (λ), momentum coefficient (Φ), the number of iterations, the initial value of the weight vector between the input layer and middle layer; and between middle layer and output layer.There is no precise information about the optimal number of cycles to complete the training.This varies according to the problem applied to the neural network.For some problems, the training of the network can take more than 10 7 cycles, while for some others the training can be done at 100 cycles.In this study, 90,000 training cycle on a computer medium capacity (i7 processor, 32 GB RAM) has taken about 10 minutes.Table 5 shows the change in the mean error, for the training cycle from 50000 to 140000 with a 5000 interval increase; and errors for the examples and training set (4, 5, 9, 11, 15, 17, 21, and 22).The mean error MSE is decreased 4.29% for a 4x10 4 increase in the education cycle from 5x10 4 to 9x10 4 that are 8.62x10 -4 and 8.25x10 -4 .However, when 14x10 4 training cycle have reached, the MSE value is 8.11x10 -4 , it decreased 1.6% compared to the situation in 9x10 4 only.For a training cycle, 5x10 5 and after this point, the value of MSE may decrease between 0.3-0.5 percent.However, a training cycle 5x10 5 is not preferred due to the necessity of long time and memory capacity of the computer.In Table 6, the effect of the different training cycle of network, on the performance is presented.Performance of the network is tested using test samples in the test set (1,6,8,10,22,31) for the three different training cycle (5x10 4 , 9x10 4 , 14x10 4 ).The performances of the network for all sam-ples in the test set are different in different training cycles.For example, when the training cycle is decreased from 9x10 4 to 5x10 4 for test samples of (1, 6, 10 and 22), the error rate has been decreased between 0.1-0.4%,while for the test sample 8 and 31 it has increased of between 0.05-0.2percent.Moreover, increasing of the training cycle from 9x10 4 to 14x10 4 has reduced the error rate between 0.1-0.3% for 6,8,and 31. However,for (1,10,22) it has increased by approximately 0.2-0.3%.The reason of this behaviour is the learning performance of each example in training set can be different for different training cycles.For some examples, learning can be completed at the beginning of the training process, but it will continue until the specified tolerance of MSE is satisfied.In this case, the learning performance at the beginning of the training process with a very low error rate may decrease by increasing the error rate gradually.What is important for the network is not only to learn an example well, but also is to learn generally for all samples at low error rates.The other analyses made for all the other pairs in the test sample set have showed that similar results are valid.the third column shows the exit velocity of the projectile, the fourth column shows the value of the amount of muzzle displacement calculated using FEM, the fifth column shows muzzle displacements predicted using ANN, the sixth column shows the difference between the actual value and the expected value, that is to say the error term, and the last column shows the relative error.

Increment
For each example in the test set, relative error is calculated as follows: The data reported in Table 7 show that relative error is usually below 5%.The only exception is observed in the test set example 8, where the expected value was 0.7648 for a projectile mass of m p =0.65 kg and projectile exit velocity of 1600 m/s, but the ANN predicted a value of 0.9241.The relative error in this case was 20%.However, the relative errors for the rest of the test set examples show that overall the learning was very successful.Figure 8 shows the expected amount of muzzle displacement according to the theory and the amount predicted by the ANN.In this study, during the firing of a gun barrel, the displacement at the end of a barrel was estimated by the artificial neural network.The obtained values were compared with the FEM model.The performance of the GDR algorithm used in design of ANN was compared with scaled conjugate gradient learning algorithm (SCH) used in literature.A comparison of the two algorithms GDR and SCH is given in Table 8, for the number of neurons in the hidden layer of the neural network from 3 to 8, and two different training cycle (9x10 4 , 14x10 4 ).After training is completed, as shown in table, the result of the testing of the samples contained in the test kit was obtained at the lowest average error, for 6 processing elements in middle layer and training cycle 9x10 4 .The average error (MEP) in the algorithm SCR is obtained as 0.09235, while for GDR algorithm, (0.09512) it is also very close to previous value.It is observed that the average error is higher, where the number of processing elements in the intermediate layer is less than 6 or more.The cause of this is related to the topological structure of the network.It is not possible to create a Latin American Journal of Solids and Structures 13 (2016) 1968-1995 single network topology that can represent all the engineering problems.The determination of network topology depends on the type of the problem, and the best network topology that will represent the problem should be determined by designers using some trial and error methods.Therefore, a large number of neuron does not mean that it will certainly represent the problem well.Likewise, possession of a small number of neuron does not mean that the representation of problem is weak.

CONCLUSION
The use of different types of ammunition is a military necessity, because each type of ammunition has its specific intended use for operational purposes, and each type of ammunition has its specific weight and chemical content.This means that projectiles in different types of ammunition have different masses and muzzle exit velocities.Thus, muzzle behaviour during shooting varies by the type of ammunition used.The most important parameters affecting a weapon system's dynamics are the projectile-mass, acceleration, and exit velocity.The purpose of this study is to develop an artificial neural network to predict the amount of muzzle displacement, which is due to the force created by a projectile accelerating inside the barrel, and which reduces the shooting accuracy of a weapon system.Using the proposed method, one can determine the amount of muzzle displacement prior to shooting.In this method, the projectile mass and exit velocity are used as the input parameters of the neural network, while the amount of muzzle displacement w z (x=L,t) is the output of the model., 27, and 30) were between 0.1-0.2%,corresponding to about 0.009 mm, which is negligible for engineering purposes.In some of the test set examples (15 and 24), on the other hand, the relative error was about 8-9%, corresponding to a miscalculation of 0.15-0.7 mm.Only in one test set example (Test pattern number 8), the error was about 20%.
The method developed in this study makes it possible to examine the effect of different types of ammunition on the barrel using computers and eliminates the need for time consuming and costly tests.In addition, by integrating an artificial neural network trained according to barrel characteristics to the software, which is controlling barrel position, the shooting accuracy and strike power of the weapon system can be increased by simply adjusting the initial position of the barrel.This would make it possible to design weapons that are lighter and more effective against targets.The velocity of a projectile inside the barrel varies by time and forces the barrel to change its natural frequencies continuously.This means that for different projectiles and muzzle velocities, different vibration modes are created in the barrel.For example, the muzzle displacement value is positive at some muzzle velocities, and negative at others.In addition, predicting the amount of muzzle displacement in a weapon barrel may not be sufficient sometimes, predicting the angle of inclination of the barrel may also be required.The neural network modelled in this study does not require many complex systems to make prediction, but an artificial neural network with at least two hidden layers is required only, and a preparation of a larger training set that represents the problem space are needed to predict both positive and negative muzzle displacements.Using the proposed method may help engineers in improving the target accuracy of a weapon system.
Latin American Journal of Solids and Structures 13 (2016) 1968-1995 3. Determine x m (t) which is the time dependent position of the moving projectile on the s th element with (10).4. Calculate the time dependent interpolation functions with (5) by substituting the value x m (t) which is defined in the previous step.5. Calculate mass, stiffness and damping matrices of the time-dependent finite element using of Eqs.(6-8).6. Calculate the instantaneous overall mass and stiffness matrices of the entire system by combining the mass and stiffness matrices of each beam element, and then impose boundary conditions.If necessary, the Eigen solution of these matrices gives instantaneous natural frequency of the entire system at time t.
7. For t+∆t go to step 2

APPENDIX B
Algorithm 2: Solution of Equation of motion Using Newmark's integration method (Wilson, 2002), the solution of Eq. ( 9) can be obtained according to the following steps: 1. Determine the integration parameters β and γ and magnitude of the time interval Δt.Calculate integration constants: applied to the unit length of the barrel by the projectile (as a moving mass); while g and d represent gravitational acceleration and the Dirac delta function, respectively; and d 2 w(x p , t)/dt 2 represents the acceleration of the barrel at the contact point of lumped projectile mass.For inclined positions of the barrel beam one can refer to the study byEsen and Koç, 2015b.The initial and boundary conditions of the barrel beam are: ¶

Figure 1 :
Figure 1: Model of a barrel with an accelerating projectile. z

Figure 2 :
Figure 2: Modelling of the barrel and projectile interaction using FEM a-) FEM discretion of the barrel system b-) Beam element s over which the projectile mp passes at time t.
[M], [C ] and [K ] are, respectively, the instantaneous overall mass, damping and stiffness matrices, while  { ( )} U t ,  { ( )} U t and { ( )} U t are, respectively, the acceleration, velocity, and displacement vectors.Besides, { } ( ) F t is the overall external force vector of the system at time t.For the obtaining the matrices of [M], [K], and [C], one can determine the elemental property matrices;

Figure 3 :
Figure 3: The representation of an artificial neuron.

Figure 4 :
Figure 4: The ANN model used in this study for prediction tip displacement of the barrel.
21), N p represents the total number of examples in the training set, y i represents the value produced by the neural network for the i th example in the training set, and y k represents the actual value.The amount of change in iteration t N in the weight of the link between the j th process element in the hidden layer and the m th process element in the output layer, ΔH a , is expressed as follows: the training set created for a 35 mm anti-aircraft barrel, based on the theory explained in Section 2. The training set includes expected values for muzzle displacement for different projectile masses and muzzle velocities.The training set contains 25 examples.The examples in the training set were presented to the neural network in order, starting from example one.The neural network was trained using a special m.file written in MATLAB, with a learning coefficient of λ=0.5 and momentum coefficient of Φ=0.8, and then test-Latin American Journal of Solids and Structures 13 (2016) 1968-1995 ed.Here, learning coefficient represents the amount of change in weights.Momentum coefficient, on the other hand, represents the proportion of the amount of change in the previous iteration that is added to the new amount of change.

Figure 7
displays the errors that resulted for some of the examples in the training set, by the number of training rounds.Figure 7a shows the error (E=B-O) for examples 4, 5, and 7 in the training set. Figure 7b shows the change in the errors for examples 9, 11, 13 and 14 by the number of training rounds; Figure 7c shows the change in the errors for examples 15, 17, 19 and 20; and Figure 7d shows the change in the errors for examples 21, 22, 23, and 25.As these graphs show, the error decreased as the number of training rounds increased.Latin American Journal of Solids and Structures 13 (2016) 1968-1995

Figure 5 :
Figure 5: The flowchart of the ANN and FEM combined algorithm for predict barrel tip displacement.

Figure 6 :
Figure 6: Performance of proposed ANN for different neuron number of hidden layer.

Figure 8 :
Figure 8: FEM and ANN calculation for 35 mm anti-aircraft barrel tip deflection.
A training set is created to characterize the problem consisting of 25 examples from the problem space.At the end of the training process, which consisted of 90,000 training rounds, both the MSE and the individual errors E for the examples in the training set were reduced to a very low level.The test set prepared to test the artificial neural network consisted of 32 examples covering the training space.Relative errors for some of the examples (Test pattern numbers 21

Latin American Journal of Solids and Structures 13 (2016) 1968-1995 are
represent axial displacement, vertical displacement and slope, respectively.

American Journal of Solids and Structures 13 (2016) 1968-1995
reports the characteristics of the different types of ammunition used in 35 mm anti-aircraft cannon.

Table 1 :
Experimental data of some ammunition for 120 mm tank.

Table 2 :
Experimental data of some ammunition for 35 mm anti-aircraft.

Table 3 :
Table 3 reports the calculated amounts of muzzle displacement for different projectile masses and muzzle velocities, which were used to train the neural network, calculated based on the theories explained in Section 2. The training set for 35 mm anti-aircraft cannon barrel.

Table 5 :
The effect of different training round upon MSE and training pattern error.

Table 6 :
The performance of the ANN for different training round.

Table 7
reports the test results that were obtained after the training of the neural network was completed, using examples that were not included in the training set.The first column in Table7shows the number of the training set, and the second column shows the projectile mass tested, and

Table 7 :
The testing set for 35 mm anti-aircraft cannon barrel and comparison of results.

Table 8 .
Statistical data for the barrel tip displacement using two different algorithms.