An Intelligent Adaptive Neural Network Controller for a Direct Torque Controlled eCAR Propulsion System

: This article deals with an intelligent adaptive neural network (ANN) controller for a direct torque controlled (DTC) electric vehicle (EV) propulsion system. With the realization of artiﬁcial intelligence (AI) conferred adaptive controllers, the torque control of an electric car (eCAR) propulsion motor can be achieved by estimating the stator reference ﬂux voltage used to synthesize the space vector pulse width modulation (SVPWM) for a DTC scheme. The proposed ANN tool optimizes the parameters of a proportional integral (PI) controller with real-time data and offers splendid dynamic stability. The response of an ANN controller is examined over standard drive cycles to validate the performance of an eCAR in terms of drive range and energy efﬁciency using MATLAB simulation software.


Introduction
The automotive market has been dealt a lethal blow in recent years but will soon reach its former prominence. The demand for electric vehicles (EVs) is increasing with concern for environmental safety. For EVs, the selection and pre-sizing of a propulsion motor drive, an optimal control strategy and optimal energy management are the most essential aspects particularly for battery driven vehicles. The advantages of EVs include greater energy efficiency, zero emissions and flexible charging at consumer outlets. The disadvantages are the long charging times, low energy density and drive range where range is the distance travelled on a full charge. Therefore, intensifying the energy efficiency and thus increasing the range of an EV is an imperative research track that earns attention [1,2].
An electric vehicle propulsion system consists of a battery, a power electronic converter, a motor and a drivetrain. Induction motors are chosen as propulsion motors due to their higher efficiency and low maintenance. The performance of torque control practices is deliberated and analyzed for a front wheel drive (FWD) EV, which is also termed as an eCAR. The architecture of a FWD eCAR propulsion system that includes a powertrain and a drivetrain with vehicle dynamics is shown in Figure 1.
In [3], a review on several direct torque controlled (DTC) schemes associated with fuzzy logic (FL), neural networks (NNs), sliding mode controls (SMCs) and genetic algorithms (GAs) was presented to improve the performance of an induction motor (IM) drive. A comparison was made amid these control schemes in terms of algorithm intricacy, parameter sensitivity, ripple reduction, switching loss and speed tracking. The authors concluded that it was very difficult to choose a proper control scheme as it relied on the application, accuracy, hardware readiness, reliability and cost of the system. In [4], a sensorless DTC scheme with an online adaptive neural network (ANN) speed estimator based on a constant V/F control technique for a three phase IM drive was proposed. This scheme offered a stable operation, fast dynamic response and accurate steady state response but during transient states the speed estimator was not effective due to the parameter variations. In [5], a DTC scheme with a torque controller for an IM drive was instigated and the pros and cons of the ANN approach over a traditional controller was considered. It was shown that the ANN approach had a reduction of the settling time at starting and in speed reversal. In [6], an ANN based torque controller was employed for a conventional DTC (C-DTC) and a space vector modulated DTC (SVM-DTC) IM drive to effectively track speed and torque under the altering load. The ANN based SVM-DTC approach proved to have superior performance. In [7], an ANN based DTC scheme was introduced for a fuel cell based battery sourced EV. This scheme utilized the stator flux as the control variable and the flux level was adjusted in accordance with the torque demand of the EV to achieve a high drive performance. Here the authors deliberated the performance of an IM drive as an EV propulsion without considering the actual vehicle dynamics (road load), drive range and fuel economy. In this paper, an intelligent ANN algorithm integrated with a space vector pulse width modulation (SVPWM) based DTC scheme was implemented for a 90 kW three phase induction motor as an eCAR propulsion system with road load. The ANN algorithm was used to tune the torque error so as to reduce the ripple amplitude. The developed propulsion system was tested over United States Environmental Protection Agency (EPA) standard drive cycles and performance parameters such as drive range and energy efficiency of the eCAR were computed. Furthermore, in Section 2, a mathematical modelling of an eCAR powertrain component with a physical description is discussed. Section 3 elaborates the direct torque control scheme based on SVPWM for an eCAR propulsion system. In Section 4, The integration of an ANN torque controller is explained for improving the DTC scheme. Section 5 presents a simulation analysis for the developed DTC scheme under different drive cycles and Section 6 summarizes the conclusions of the work done.
Electr. Veh. J. 2021, 12, x FOR PEER REVIEW 2 of 17 sensorless DTC scheme with an online adaptive neural network (ANN) speed estimator based on a constant V/F control technique for a three phase IM drive was proposed. This scheme offered a stable operation, fast dynamic response and accurate steady state response but during transient states the speed estimator was not effective due to the parameter variations. In [5], a DTC scheme with a torque controller for an IM drive was instigated and the pros and cons of the ANN approach over a traditional controller was considered. It was shown that the ANN approach had a reduction of the settling time at starting and in speed reversal. In [6], an ANN based torque controller was employed for a conventional DTC (C-DTC) and a space vector modulated DTC (SVM-DTC) IM drive to effectively track speed and torque under the altering load. The ANN based SVM-DTC approach proved to have superior performance. In [7], an ANN based DTC scheme was introduced for a fuel cell based battery sourced EV. This scheme utilized the stator flux as the control variable and the flux level was adjusted in accordance with the torque demand of the EV to achieve a high drive performance. Here the authors deliberated the performance of an IM drive as an EV propulsion without considering the actual vehicle dynamics (road load), drive range and fuel economy. In this paper, an intelligent ANN algorithm integrated with a space vector pulse width modulation (SVPWM) based DTC scheme was implemented for a 90 kW three phase induction motor as an eCAR propulsion system with road load. The ANN algorithm was used to tune the torque error so as to reduce the ripple amplitude. The developed propulsion system was tested over United States Environmental Protection Agency (EPA) standard drive cycles and performance parameters such as drive range and energy efficiency of the eCAR were computed. Furthermore, in Section 2, a mathematical modelling of an eCAR powertrain component with a physical description is discussed. Section 3 elaborates the direct torque control scheme based on SVPWM for an eCAR propulsion system. In Section 4, The integration of an ANN torque controller is explained for improving the DTC scheme. Section 5 presents a simulation analysis for the developed DTC scheme under different drive cycles and Section 6 summarizes the conclusions of the work done.

Components of an eCAR Powertrain
An eCAR propulsion system or powertrain includes various components such as a stack of lithium-ion batteries, a three phase induction motor, a SVPWM pulse generation circuit, a three phase two-level voltage source inverter and a simple gear and drivetrain.

Components of an eCAR Powertrain
An eCAR propulsion system or powertrain includes various components such as a stack of lithium-ion batteries, a three phase induction motor, a SVPWM pulse generation circuit, a three phase two-level voltage source inverter and a simple gear and drivetrain.

Battery Model
The battery model of an eCAR propulsion system includes an internal resistance to compute energy consumption and the state of charge (SOC) of a battery. Figure 2 represents the structure of a simple battery cell where R int represents the internal resistance, V oc is the

Battery Model
The battery model of an eCAR propulsion system includes an internal resistance to compute energy consumption and the state of charge (SOC) of a battery. Figure 2 represents the structure of a simple battery cell where Rint represents the internal resistance, Voc is the open circuit voltage of the battery, I is the current, E is the energy source and Vterm is the terminal voltage of the battery. During acceleration, the discharge current is implied as positive whereas in regenerative braking the charging current is implied as negative. The value of Voc is 690 Volts and Rint is 0.1 Ohms. Equation (1a,b) denote the power and power loss of the battery, respectively.
Equation (2a,b) represent the actual power at the outlet of the lithium-ion battery module.
Using Equation (1b), the expression for the battery current is resolved and is given in Equation (3).
Equation (4) represents the expression for the lithium-ion battery terminal voltage: Equation (5) represents the expression for the lithium-ion battery SOC.

Motor Model
The direct and quadrature axis (d-q) model of a three phase squirrel cage induction motor in a synchronously rotating reference frame is epitomized by Figure 3a  During acceleration, the discharge current is implied as positive whereas in regenerative braking the charging current is implied as negative. The value of V oc is 690 Volts and R int is 0.1 Ohms. Equations (1a) and (1b) denote the power and power loss of the battery, respectively. P ideal = IV oc . (1a) Equations (2a) and 2(b) represent the actual power at the outlet of the lithium-ion battery module. P actual = P ideal − P loss . (2a) Using Equation (1b), the expression for the battery current is resolved and is given in Equation (3).
Equation (4) represents the expression for the lithium-ion battery terminal voltage: Equation (5) represents the expression for the lithium-ion battery SOC.

Motor Model
The direct and quadrature axis (d-q) model of a three phase squirrel cage induction motor in a synchronously rotating reference frame is epitomized by Figure 3a The corresponding direct and quadrature axis voltage and flux vectors are given in Equations (6)-(9), respectively. The expression for torque developed by the induction motor in terms of current and flux vectors is given in Equation (10).
ψ dr = L lr I dr + L m (i ds + i dr ). (8) ψ qr = L lr I qr + L m i qs + i qr .
The efficiency of the three phase induction motor is computed as the ratio of the product of the torque and angular speed to the sum of the power and power loss. It is derived by Equation (11a,b), respectively. The parameters of the motor model are depicted in Table 1.  The efficiency of the three phase induction motor is computed as the ratio of the product of the torque and angular speed to the sum of the power and power loss. It is derived by Equations (11a) and (11b), respectively. The parameters of the motor model are depicted in Table 1.

Glider Model
The glider model of an eCAR is developed in terms of vehicle speed and tractive force. It includes inertia due to the weight of the vehicle, the aerodynamic force, the rolling resistance friction and the hill gradient force. In Figure 4 the effect of the allied forces on an eCAR is represented.

Glider Model
The glider model of an eCAR is developed in terms of vehicle speed and tractive force. It includes inertia due to the weight of the vehicle, the aerodynamic force, the rolling resistance friction and the hill gradient force. In Figure 4 the effect of the allied forces on an eCAR is represented. The maximum amount of effort required mostly due to the inertia weight or mass of an eCAR is given in Equation (12): where mi is the inertial mass that also accounts for the rotating inertia. Accordingly, mi, is faintly more than the actual (~4%). The force due to aerodynamic drag is computed by Equation (13): where ρ is air density, Cd is the air drag coefficient, Af is the frontal area and V represents velocity. The rolling friction resistance met at the wheels is given below in Equation (14).
where Crr is the rolling coefficient, m defines the mass and g represents the gravitational force. The gradient force due to uphill or downhill travel is computed in terms of a slope angle alpha using Equation (15): The maximum amount of effort required mostly due to the inertia weight or mass of an eCAR is given in Equation (12): where m i is the inertial mass that also accounts for the rotating inertia. Accordingly, m i , is faintly more than the actual (~4%). The force due to aerodynamic drag is computed by Equation (13): where ρ is air density, C d is the air drag coefficient, A f is the frontal area and V represents velocity. The rolling friction resistance met at the wheels is given below in Equation (14).
F rr = C rr mg (14) where C rr is the rolling coefficient, m defines the mass and g represents the gravitational force. The gradient force due to uphill or downhill travel is computed in terms of a slope angle alpha using Equation (15): where ∝ is angle of the slope. The rolling resistance and the aerodynamic drag are combinedly characterized as road load and are given in Equation (16) below: Another way to determine the road load by means of a quadratic equation relating to eCAR speed is shown in Equation (17) below.
World Electr. Veh. J. 2021, 12, 44 6 of 17 The distinctive values A 1 , B 1 , C 1 are specific for each eCAR configuration and analogous to the standards originating in the Environmental Protection Agency (EPA). All of these forces sum up to the total tractive effort represented by Equation (18): (18) where F TR is the tractive force. The expression for acceleration is obtained from Equations (12) and (18) as in Equation (19). The vehicle parameters are depicted in Table 2.

Driver Model
In an eCAR the driver model is a proportional integral (PI) controller. For the given drive cycle the difference in the reference speed and the actual speed is given as the input and the output of the controller decides the accelerator pedal position (APP) as a percentage of the reference torque. Figure 5 depicts the basic driver model. gous to the standards originating in the Environmental Protection Agency these forces sum up to the total tractive effort represented by Equation (18 where FTR is the tractive force. The expression for acceleration is obtained f (12) and (18) as in Equation (19). The vehicle parameters are depicted in Ta

Driver Model
In an eCAR the driver model is a proportional integral (PI) controller drive cycle the difference in the reference speed and the actual speed is giv and the output of the controller decides the accelerator pedal position (APP age of the reference torque. Figure 5 depicts the basic driver model.  In the driver model, the choice of the PI control parameter tuning method plays a vital role and the values of the proportional constant, k p , is 300 and the integral constant, k i , is 500.

Direct Torque Controlled eCAR
A direct torque control method is the most precise control strategy for the torque control of a three phase induction motor. However, at low speeds and low switching frequency high ripples in the flux and torque originate that leads to acoustic noise and degrades the control performance. Several DTC schemes have been presented to overcome this difficulty by focusing specifically on the torque and flux variables. The scientists Isao Takahashi and Manfred Depenbrock introduced DTC in 1984 to compete with traditional controls. It had a good dynamic performance and was the most robust with respect to the World Electr. Veh. J. 2021, 12, 44 7 of 17 motor parameter variations. The principle involved is based on a direct determination of the control pulses applied to the switches of the voltage source inverter. At present, a lot of research is being carried out on modern DTC schemes [8][9][10].
The artificial intelligence (AI) based DTC scheme has gained prominence in recent years and is making a remarkable impact on modern research areas. Fuzzy logic, adaptive neural networks, adaptive neuro fuzzy inference systems, particle swarm optimizations and genetic algorithms are the major families that constitute AI. In [11], the authors introduced AI methods to enhance the dynamic behavior of the DTC scheme under different operating conditions with a reduction in ripples of the torque and flux and an increase in efficiency and energy savings. The use of the voltage source inverter (VSI) develops a three phase voltage with controllable amplitude and frequency. A classic two-level VSI supplying an input voltage to a three phase induction motor is shown in Figure 6. An optimal advanced discontinuous PWM (ADPWM) algorithm has been proposed to train the actual value of gamma (γ) according to a set policy for a DTC controlled IM drive. The SVPWM technique provides a solution to a few hardships with traditional PWM schemes. The proposed ADPWM algorithm lowered the ripple in the steady state line current, acoustic noise and switching losses compared with traditional schemes [12].

Direct Torque Controlled eCAR
A direct torque control method is the most precise control strategy for the torque control of a three phase induction motor. However, at low speeds and low switching frequency high ripples in the flux and torque originate that leads to acoustic noise and degrades the control performance. Several DTC schemes have been presented to overcome this difficulty by focusing specifically on the torque and flux variables. The scientists Isao Takahashi and Manfred Depenbrock introduced DTC in 1984 to compete with traditional controls. It had a good dynamic performance and was the most robust with respect to the motor parameter variations. The principle involved is based on a direct determination of the control pulses applied to the switches of the voltage source inverter. At present, a lot of research is being carried out on modern DTC schemes [8][9][10].
The artificial intelligence (AI) based DTC scheme has gained prominence in recent years and is making a remarkable impact on modern research areas. Fuzzy logic, adaptive neural networks, adaptive neuro fuzzy inference systems, particle swarm optimizations and genetic algorithms are the major families that constitute AI. In [11], the authors introduced AI methods to enhance the dynamic behavior of the DTC scheme under different operating conditions with a reduction in ripples of the torque and flux and an increase in efficiency and energy savings. The use of the voltage source inverter (VSI) develops a three phase voltage with controllable amplitude and frequency. A classic two-level VSI supplying an input voltage to a three phase induction motor is shown in Figure 6. An optimal advanced discontinuous PWM (ADPWM) algorithm has been proposed to train the actual value of gamma (γ) according to a set policy for a DTC controlled IM drive. The SVPWM technique provides a solution to a few hardships with traditional PWM schemes. The proposed ADPWM algorithm lowered the ripple in the steady state line current, acoustic noise and switching losses compared with traditional schemes [12]. The combination of three switching states gives out eight possible voltage vectors. At any interval, the inverter has to operate one of these voltage vectors. Among the eight voltage vectors, two are zero voltage vectors (V0 and V7) and the remaining six (V1 to V6) are active voltage vectors. In the space vector plane, all of the voltage vectors can be represented as shown in Figure 7. In the SVPWM algorithm, the boundary for the modulation index is 0.866. In this strategy, the total time interval of the zero voltage vector is equally distributed between V0 and V7. In addition, the zero voltage vector time is distributed symmetrically at the start and end of the sub cycle in a symmetrical manner. Furthermore, to lessen the switching actions of the VSI, it is required that switching should take place in one phase in one transition from one state to another. Consequently, the SVPWM uses 0127-7210 in first sector, 0327-7230 in the second sector and so on [13]. The block diagram The combination of three switching states gives out eight possible voltage vectors. At any interval, the inverter has to operate one of these voltage vectors. Among the eight voltage vectors, two are zero voltage vectors (V0 and V7) and the remaining six (V1 to V6) are active voltage vectors. In the space vector plane, all of the voltage vectors can be represented as shown in Figure 7. In the SVPWM algorithm, the boundary for the modulation index is 0.866. In this strategy, the total time interval of the zero voltage vector is equally distributed between V0 and V7. In addition, the zero voltage vector time is distributed symmetrically at the start and end of the sub cycle in a symmetrical manner. Furthermore, to lessen the switching actions of the VSI, it is required that switching should take place in one phase in one transition from one state to another. Consequently, the SVPWM uses 0127-7210 in first sector, 0327-7230 in the second sector and so on [13]. The block diagram of the proposed intelligent adaptive neural network based DTC scheme for an eCAR propulsion system is shown in Figure 8. of the proposed intelligent adaptive neural network based DTC scheme for an eCAR propulsion system is shown in Figure 8.  At first, the three phase induction motor is modelled in a synchronously rotating reference frame and the developed adaptive motor model calculates the approximate torque, flux and speed from the direct and quadrature axis voltages and current magnitudes. The speed of the reference drive cycle, converted into the angular speed (rad/sec) ωr*, is compared with the actual angular speed, ωr, calculated with the help of an adaptive motor model block. The obtained speed error is given as an input to the speed controller or driver model, which produces reference torque magnitude, Te*. The reference torque is compared with the actual torque, Te, generated by the adaptive motor model and processed through the torque controller that produces the reference slip speed ωsl*. of the proposed intelligent adaptive neural network based DTC scheme for an eCAR propulsion system is shown in Figure 8.  At first, the three phase induction motor is modelled in a synchronously rotating reference frame and the developed adaptive motor model calculates the approximate torque, flux and speed from the direct and quadrature axis voltages and current magnitudes. The speed of the reference drive cycle, converted into the angular speed (rad/sec) ωr*, is compared with the actual angular speed, ωr, calculated with the help of an adaptive motor model block. The obtained speed error is given as an input to the speed controller or driver model, which produces reference torque magnitude, Te*. The reference torque is compared with the actual torque, Te, generated by the adaptive motor model and processed through the torque controller that produces the reference slip speed ωsl*. At first, the three phase induction motor is modelled in a synchronously rotating reference frame and the developed adaptive motor model calculates the approximate torque, flux and speed from the direct and quadrature axis voltages and current magnitudes. The speed of the reference drive cycle, converted into the angular speed (rad/sec) ω r *, is compared with the actual angular speed, ω r , calculated with the help of an adaptive motor model block. The obtained speed error is given as an input to the speed controller or driver model, which produces reference torque magnitude, T e *. The reference torque is compared with the actual torque, T e , generated by the adaptive motor model and processed through the torque controller that produces the reference slip speed ω sl *.
The addition and integration of the reference slip speed with the actual angular speed generated by the adaptive motor model produces reference theta θ e *. The direct and quadrature axis reference voltages are calculated by the reference voltage vector calculator (RVVC) using Equation (20).
where F seq 2 is the root mean square (RMS) value of stator flux ripple of a particular sequence and V ref is reference voltage vector at an angle α. Considering these two vectors as inputs, the magnitude and position of the reference voltage vector are calculated according to the set value of γ. The SVPWM block generates gating pulses to the inverter based on the space vector approach. The inverter voltage amplitude and frequency are varied in such a way as to achieve the desired speed [14,15].

ANN Controller
The application of artificial intelligence into the electric vehicle propulsion motor control enhances the performance in terms of higher efficiency, a low ripple in torque and flux, a higher drive range and a low battery discharge rate. Various optimization methods have been adopted in the literature where the Ziegler-Nichols tuning method is a classical method and artificial intelligence based adaptive methods such as fuzzy logic, ANNs, adaptive neural fuzzy inference systems (ANFISs), global optimization (genetic algorithm, GA) and particle swam optimization (PSO) also exist. In this paper an adaptive neural network based tuning method is considered for torque controller parameter optimization alone.
An adaptive neural network algorithm is the most suitable for an eCAR control due to its simple structural design, ability to approximate complex nonlinear functions and effortlessness of training the algorithm and robustness to parameter variations. ANNs with DTC schemes have been introduced by many researchers for the parameter determination of the motor control system, state estimation, the design of speed and torque controllers, motor speed estimation and also for vector selection strategies. A variety of neural networks is available such as the feed forward multilayer neural network and recursive neural network [16]. The basic block diagram of an ANN is shown in Figure 9. The addition and integration of the reference slip speed with the actual angular speed generated by the adaptive motor model produces reference theta θe*. The direct and quadrature axis reference voltages are calculated by the reference voltage vector calculator (RVVC) using Equation (20).
where Fseq 2 is the root mean square (RMS) value of stator flux ripple of a particular sequence and Vref is reference voltage vector at an angle α. Considering these two vectors as inputs, the magnitude and position of the reference voltage vector are calculated according to the set value of γ. The SVPWM block generates gating pulses to the inverter based on the space vector approach. The inverter voltage amplitude and frequency are varied in such a way as to achieve the desired speed [14,15].

ANN Controller
The application of artificial intelligence into the electric vehicle propulsion motor control enhances the performance in terms of higher efficiency, a low ripple in torque and flux, a higher drive range and a low battery discharge rate. Various optimization methods have been adopted in the literature where the Ziegler-Nichols tuning method is a classical method and artificial intelligence based adaptive methods such as fuzzy logic, ANNs, adaptive neural fuzzy inference systems (ANFISs), global optimization (genetic algorithm, GA) and particle swam optimization (PSO) also exist. In this paper an adaptive neural network based tuning method is considered for torque controller parameter optimization alone.
An adaptive neural network algorithm is the most suitable for an eCAR control due to its simple structural design, ability to approximate complex nonlinear functions and effortlessness of training the algorithm and robustness to parameter variations. ANNs with DTC schemes have been introduced by many researchers for the parameter determination of the motor control system, state estimation, the design of speed and torque controllers, motor speed estimation and also for vector selection strategies. A variety of neural networks is available such as the feed forward multilayer neural network and recursive neural network [16]. The basic block diagram of an ANN is shown in Figure 9. In this paper an adaptive neural network based torque controller is developed for the inner current loop; that is, the conventional torque controller is replaced with the proposed ANN tuned torque controller as shown in Figure 8 in order to minimize the torque In this paper an adaptive neural network based torque controller is developed for the inner current loop; that is, the conventional torque controller is replaced with the proposed ANN tuned torque controller as shown in Figure 8 in order to minimize the torque ripple and to improve the efficiency of the propulsion motor that in turn improves the performance of an eCAR.
The structure of a developed ANN controller is 2, 40, 1, which means that the network has two neurons in the input layer, 40 neurons in the hidden layer and one neuron in the output layer. The steady state error output of an ANN is given as an input to the PI controller in order to obtain the reference slip speed ω sl and is shown in Figure 10. The MATLAB Simulink model of a developed ANN structure with two inputs, a hidden layer and one output is shown in Figure 11. World Electr. Veh. J. 2021, 12, x FOR PEER REVIEW 10 of 17 ripple and to improve the efficiency of the propulsion motor that in turn improves the performance of an eCAR. The structure of a developed ANN controller is 2, 40, 1, which means that the network has two neurons in the input layer, 40 neurons in the hidden layer and one neuron in the output layer. The steady state error output of an ANN is given as an input to the PI controller in order to obtain the reference slip speed ωsl and is shown in Figure 10. The MATLAB Simulink model of a developed ANN structure with two inputs, a hidden layer and one output is shown in Figure 11.  The inputs to the network are sampled from the torque error 'Terr' and the change in torque error '∆_Terr' data. The parameters of the ANN are tabulated in Table 3. The network output is used to tune the torque controller with the input layer and the hidden layer as a hyperbolic tangent sigmoid transfer function and the output layer as a pure line transfer function where weights and bias values are updated corresponding to the Levenberg-Marquardt optimization algorithm [17,18]. The ANN algorithm is elaborated in the following steps: Step 1: Firstly, torque error and the change in torque error are given as inputs to the network. The input vector matrix is given by [X] 2 × 1 with two inputs.
Step 2: Subsequently, the targets are chosen in order to attain the desired variables of the network. The target vector matrix is given by [t] 1 × 1 with one output.
Step 3: The weights and biases are then initialized and are updated corresponding to Levenberg-Marquardt optimization algorithm. The output vector matrix is given by [y] where [w]° and [b]° are the weights and biases row matrices, respectively.
Step 4: The ANN is trained by using the data provided in Step 1 and Step 2, respectively, and by fixing the goal parameter to a minimum. The error data in the form of an error vector matrix (E) is generated to confirm that the desired convergence of the specified goal parameters or epochs during training has been met then training stops.
where E is the error data matrix obtained using a mean squared error as the objective function, n is the total number of outputs and I is the number of iterations. ripple and to improve the efficiency of the propulsion motor that in turn improves the performance of an eCAR. The structure of a developed ANN controller is 2, 40, 1, which means that the network has two neurons in the input layer, 40 neurons in the hidden layer and one neuron in the output layer. The steady state error output of an ANN is given as an input to the PI controller in order to obtain the reference slip speed ωsl and is shown in Figure 10. The MATLAB Simulink model of a developed ANN structure with two inputs, a hidden layer and one output is shown in Figure 11.  The inputs to the network are sampled from the torque error 'Terr' and the change in torque error '∆_Terr' data. The parameters of the ANN are tabulated in Table 3. The network output is used to tune the torque controller with the input layer and the hidden layer as a hyperbolic tangent sigmoid transfer function and the output layer as a pure line transfer function where weights and bias values are updated corresponding to the Levenberg-Marquardt optimization algorithm [17,18]. The ANN algorithm is elaborated in the following steps: Step 1: Firstly, torque error and the change in torque error are given as inputs to the network. The input vector matrix is given by [X] 2 × 1 with two inputs.
Step 2: Subsequently, the targets are chosen in order to attain the desired variables of the network. The target vector matrix is given by [t] 1 × 1 with one output.
Step 3: The weights and biases are then initialized and are updated corresponding to Levenberg-Marquardt optimization algorithm. The output vector matrix is given by [y] where [w]° and [b]° are the weights and biases row matrices, respectively.
Step 4: The ANN is trained by using the data provided in Step 1 and Step 2, respectively, and by fixing the goal parameter to a minimum. The error data in the form of an error vector matrix (E) is generated to confirm that the desired convergence of the specified goal parameters or epochs during training has been met then training stops.
where E is the error data matrix obtained using a mean squared error as the objective function, n is the total number of outputs and I is the number of iterations. The inputs to the network are sampled from the torque error 'T err ' and the change in torque error '∆_Te rr ' data. The parameters of the ANN are tabulated in Table 3. The network output is used to tune the torque controller with the input layer and the hidden layer as a hyperbolic tangent sigmoid transfer function and the output layer as a pure line transfer function where weights and bias values are updated corresponding to the Levenberg-Marquardt optimization algorithm [17,18]. The ANN algorithm is elaborated in the following steps: Step 1: Firstly, torque error and the change in torque error are given as inputs to the network. The input vector matrix is given by [X] 2 × 1 with two inputs.
Step 2: Subsequently, the targets are chosen in order to attain the desired variables of the network. The target vector matrix is given by [t] 1 × 1 with one output.
Step 3: The weights and biases are then initialized and are updated corresponding to Levenberg-Marquardt optimization algorithm. The output vector matrix is given by [y] where [w] • and [b] • are the weights and biases row matrices, respectively.
Step 4: The ANN is trained by using the data provided in Step 1 and Step 2, respectively, and by fixing the goal parameter to a minimum. The error data in the form of an error vector matrix (E) is generated to confirm that the desired convergence of the specified goal parameters or epochs during training has been met then training stops.
where E is the error data matrix obtained using a mean squared error as the objective function, n is the total number of outputs and I is the number of iterations.
Step 5: After the training the network, the optimized value of the steady state error as the output is yielded.
Step 6: The optimized steady state error output is applied as the input to the PI controller in order to produce the slip speed. The input data, output data, target data and error data obtained by the plant process to train the ANN is shown in Table 4. The complete vehicle model is simulated for step input and the responses are calculated for neural network input, output, target and error data, respectively. Primarily the bias is taken as 1 and the values are added along with the weights and the updated weights that in turn minimize the torque error. The optimum solution occurs at 14th epoch with a value of 1.0155 × 10 −7 which is accurate and is termed to be zero. The network is developed by typing "nntool" into the MATLAB command window. The Simulink model is generated using the command "genism(network)" and is shown in Figure 12 Subsystems of the neural network are shown in Figures 13-15, respectively [19]. Table 5 depicts conventional and the ANN controller parameters.

Simulation Analysis of an eCAR
The MATLAB Simulink model of a direct torque controlled eCAR propulsion system was developed using the "Powertrain toolbox" R2019b version and is shown in Figure 16. The Simulink model of a lithium-ion battery, a three phase induction motor, a glider model, gear transmission and voltage source inverter are modelled using their mathematical relations as discussed in Section 2. The developed model is simulated under European Cycle (ECE-R15), High Way Fuel Economy Test (HWFET) and New York City Cycle (NYCC) drive cycles to validate the performance of the proposed ANN tuned torque controller and the improvement in the performance of an eCAR is observed. The obtained simulation results for the proposed ANN tuned torque controller are compared with the conventional PI controller and are shown in the following waveforms.

Simulation Analysis of an eCAR
The MATLAB Simulink model of a direct torque controlled eCAR propulsion system was developed using the "Powertrain toolbox" R2019b version and is shown in Figure 16. The Simulink model of a lithium-ion battery, a three phase induction motor, a glider model, gear transmission and voltage source inverter are modelled using their mathematical relations as discussed in Section 2. The developed model is simulated under European Cycle (ECE-R15), High Way Fuel Economy Test (HWFET) and New York City Cycle (NYCC) drive cycles to validate the performance of the proposed ANN tuned torque controller and the improvement in the performance of an eCAR is observed. The obtained simulation results for the proposed ANN tuned torque controller are compared with the conventional PI controller and are shown in the following waveforms.

Simulation Analysis of an eCAR
The MATLAB Simulink model of a direct torque controlled eCAR propulsion system was developed using the "Powertrain toolbox" R2019b version and is shown in Figure 16. The Simulink model of a lithium-ion battery, a three phase induction motor, a glider model, gear transmission and voltage source inverter are modelled using their mathematical relations as discussed in Section 2. The developed model is simulated under European Cycle (ECE-R15), High Way Fuel Economy Test (HWFET) and New York City Cycle (NYCC) drive cycles to validate the performance of the proposed ANN tuned torque controller and the improvement in the performance of an eCAR is observed. The obtained simulation results for the proposed ANN tuned torque controller are compared with the conventional PI controller and are shown in the following waveforms.

Simulation Analysis of an eCAR
The MATLAB Simulink model of a direct torque controlled eCAR propulsion system was developed using the "Powertrain toolbox" R2019b version and is shown in Figure 16. The Simulink model of a lithium-ion battery, a three phase induction motor, a glider model, gear transmission and voltage source inverter are modelled using their mathematical relations as discussed in Section 2. The developed model is simulated under European Cycle (ECE-R15), High Way Fuel Economy Test (HWFET) and New York City Cycle (NYCC) drive cycles to validate the performance of the proposed ANN tuned torque controller and the improvement in the performance of an eCAR is observed. The obtained simulation results for the proposed ANN tuned torque controller are compared with the conventional PI controller and are shown in the following waveforms.

Simulation Analysis of an eCAR
The MATLAB Simulink model of a direct torque controlled eCAR propulsion system was developed using the "Powertrain toolbox" R2019b version and is shown in Figure 16. The Simulink model of a lithium-ion battery, a three phase induction motor, a glider model, gear transmission and voltage source inverter are modelled using their mathematical relations as discussed in Section 2. The developed model is simulated under European Cycle (ECE-R15), High Way Fuel Economy Test (HWFET) and New York City Cycle (NYCC) drive cycles to validate the performance of the proposed ANN tuned torque controller and the improvement in the performance of an eCAR is observed. The obtained simulation results for the proposed ANN tuned torque controller are compared with the conventional PI controller and are shown in the following waveforms.  From Figure 17a-c, at intervals of 55 s, 90 s and 185 s, it is seen that for the desired speed there are spikes in the torque waveform due to the conventional torque controller that draws more power and these ripples are suppressed using an ANN tuned torque PI (ANN-PI) controller under an ECE (R15) cycle. The corresponding distance travelled, fuel consumption and %SOC are also shown in Figure 17d-f. Similarly, in Figure 18a-c, at intervals of 140 s and 645 s the torque ripple is suppressed using an ANN-PI controller under a HWFET cycle. The corresponding distance travelled, fuel consumption and %SOC are shown in Figure 18d-f. In Figure 19a-c, at intervals of 98 s, 240 s and 508 s torque ripple is suppressed using an ANN-PI controller under an NYCC cycle. The corresponding distance travelled, fuel consumption and %SOC are shown in Figure 19d-f. A spike in the torque magnitude increases the power demanded by the propulsion motor as it needs more tractive force. The motor output power and power loss for standard drive cycles is calculated using Equation (11a) and are tabulated in Table 6 below. From Figure 17a-c, at intervals of 55 s, 90 s and 185 s, it is seen that for the desired speed there are spikes in the torque waveform due to the conventional torque controller that draws more power and these ripples are suppressed using an ANN tuned torque PI (ANN-PI) controller under an ECE (R15) cycle. The corresponding distance travelled, fuel consumption and %SOC are also shown in Figure 17d-f. Similarly, in Figure 18a-c, at intervals of 140 s and 645 s the torque ripple is suppressed using an ANN-PI controller under a HWFET cycle. The corresponding distance travelled, fuel consumption and %SOC are shown in Figure 18d-f. In Figure 19a-c, at intervals of 98 s, 240 s and 508 s torque ripple is suppressed using an ANN-PI controller under an NYCC cycle. The corresponding distance travelled, fuel consumption and %SOC are shown in Figure 19d-f. A spike in the torque magnitude increases the power demanded by the propulsion motor as it needs more tractive force. The motor output power and power loss for standard drive cycles is calculated using Equation (11a) and are tabulated in Table 6 below.      From the above data, it is evident that with the use of an ANN controller, the torque ripple and the power required by the motor is reduced, thereby increasing the motor efficiency, fuel efficiency and drive range. Thus, the proposed ANN controller offers a good dynamic performance under city driving environments.

Conclusions
In this paper, an application of an intelligent adaptive neural network tuned torque controller for a direct torque controlled eCAR propulsion system was presented. The glider model (which is a summation of inertial force, aerodynamic drag, rolling resistance force and gradient force) and the driver model were modelled using mathematical equations. A DTC scheme with a reference flux voltage vector control strategy for a three phase voltage source inverter fed an eCAR propulsion motor using a two-level SVPWM algorithm that was developed to control the torque and flux in order to meet the vehicle power requirements. An ANN tuned torque PI controller was designed to mitigate the torque ripple and improve the eCAR performance in terms of drive range, fuel economy and energy efficiency. The proposed two input, one output ANN network was trained using the Levenberg-Marquardt back propagation algorithm. A MATLAB Simulink model of an ANN based DTC controlled eCAR propulsion system consisting of a 30 kwh, 100 Ah, 40 V lithium-ion battery and a 90 kw induction motor fed by a two-level SVPWM based inverter with a vehicle mass of 1645 kg was designed and analyzed. The model was tested to validate the performance of the proposed ANN tuned torque controller under ECE (R15), HWFET and NYCC drive cycles. It was proven that the proposed intelligent controller had a good dynamic stability under most driving environments.