# The Euler-Type Universal Numerical Integrator (E-TUNI) with Backward Integration
## 4 Universal Numerical Integrator (UNI)  
Figure 3 illustrates a general scheme for adequately designing a Universal Numerical Integrator (UNI). Notice that in Figure 3, when one couples a conventional numerical integrator (e.g., Euler, Runge-Kutta, Adams-Bashforth, predictive-corrector, among others) to some kind of universal approximators of functions (e.g., MLP neural networks, RBF, SVM, fuzzy inference systems, among others), the UNI design can be achieved high numerical accuracy through supervised learning using input/output training patterns. This allows for solving real-world problems involving the modeling of non-linear dynamic systems. Still, regarding Figure 3, note that \({}^{k+1}\)\(\dot{y}_{j}^{i}\) is the prediction made at instant \(t_{k+1}\) by the UNI used and \({}^{k+1}\)\(\dot{y}_{j}^{i}\) is the real value generated by the plant at the same instant. Note that these two values are compared in the \"Training Error\" block, and the weights present in the UNI are updated through supervised learning with input/output training patterns. Since artificial neural networks are considered universal approximators of functions, the neural training error can be as small as desired. Notice that \({}^{k+1}\)\(\dot{y}_{j}^{i}\) is the output generated if only the conventional numerical integrator is used. However, in the latter case, training it with real-world training patterns is impossible. As previously mentioned, a Universal Numerical Integrator (UNI) can be of three types, thus giving rise to three distinct methodologies, namely: (i) NARMAX model, (ii) instantaneous derivatives methodology (e.g., Runge-Kutta neural network, Adams-Bashforth neural network, predicted-corrector neural network, among others), and (iii) mean derivatives methodology or E-TUNI. The three types of universal numerical integrators are equally precise, as the Artificial Neural Network (ANN) is a universal approximator of functions [2; 3; 4; 5], every UNI can have its approximation error as close to zero, as much as one likes. To fully understand the difference between the instantaneous and mean derivative methodologies, see Figure 2 again. This figure presents the geometric difference between the instantaneous and mean derivative functions. It is well-known that the mean derivative (\(tan_{\Delta t}{}^{k}a^{i}\)) is the tangent of the angle of the secant line connecting two distinct points of a mathematical function. On the other hand, the instantaneous derivative (\(tan^{k}\theta^{i}\)) is the tangent of the angle of the tangent line to any given point of a mathematical function. The mean derivatives methodology occurs when a universal approximator of functions is coupled to the Euler-type first-order integrator. In this case, the first-order integrator would have a substantial error if instantaneous derivative functions were used. However, when the mean derivative functions replace the instantaneous derivative functions, the integrator error is reduced to zero [16; 27]. In this way, it is possible to train an artificial neural network to learn the mean derivative functions through two possible approaches [16]: (i) the direct approach and (ii) the indirect or empirical approach. Figure 4 schematically represents the direct approach. Figure 5 schematically represents the indirect or empirical approach. In the direct approach, the artificial neural network is trained separately from the first-order integrator. The artificial neural network is trained and coupled to the first-order integrator in the indirect or empirical approach. Both approaches are equivalent to each other. However, the back-propagation algorithm must be recalculated using the indirect or empirical approach. In the direct approach, this is unnecessary [16]. However, in this article, only the direct approach will be used to train the neural network with the mean derivative functions. In this sense, giving a more detailed explanation of Figure 4 is useful. The \"Dynamic System\" block is the state equations of the dynamic system that we want to reproduce through E-TUNI.