Application of B Splines to Identifi cation of the Movement Equations of the Floating Objects Primjena B-splajna na identifi kaciju jednadžbi kretanja plovnih objekata

Summary The paper presents the possibilities of using B-splines to determine a mathematical model in the form of linear diff erential equations describing the change of the motion parameters of fl oating objects depending on the values of the control signals. The elaborated identifi cation system is a collection of algorithms including: approximation of input and output signals, optimal selection of diff erential equation coeffi cients and model verifi cation. The basic spline functions were used to approximate the values of the input and output signals. The developed method was illustrated by an example of identifi cation of underwater submarine motion equations describing the change in draft depth and trim angle depending on the diff erence between buoyancy force and ship’s weight.


INTRODUCTION / Uvod
The rapid development of technical progress creates the need to identify control objects. Most objects can be treated as dynamical systems. Intuitively, a dynamical system is understood as an object considered from the point of view of its behavior over time. Identifi cation is closely related to the mathematical modeling of real systems and its task is to create some methods for establishing the best mathematical model in a specifi c sense. The course of actions, the eff ect of which is the construction of a mathematical model, recognized in accordance with the adopted evaluation criterion as suffi ciently well describing the behavior of a real object, we will call the identifi cation system. The identifi cation system of the dynamic systems includes: a) the description of the inputs and outputs; b) the mathematical model of the relationship between input and output signals; c) the model verifi cation.
The mathematical model of the real system correctly obtained as a result of identifi cation enables to determine the control algorithm as well as the design of devices implementing that algorithm.
Despite many works devoted to the identifi cation of dynamical systems the new methods of identifi cation systems suitable for electronic computing are still necessary.
The Authors use splines to describe the signals. The fi rst spline functions presented by I.J.Schoenberg in 1946 were 'glued up' from pieces of third-degree polynomials.
In practice it is very useful to present polynomial spline functions by means of B -splines (B -functions) ( [6], [9]). Their application in the description of signals and the identifi cation of systems was presented in the articles [2], [9], [12].
The theory of splines is currently a very extensive mathematical theory and it is developing in an algebraic and variational direction. In the algebraic approach splines are treated as a set of functions with the same structure. The structure includes the so-called L -splines. The application of those splines for identifi cation has been presented in [13].
In the variational approach the functions that minimize some specifi ed functionals are called splines. That group includes smoothing spline functions. In [14] the smoothing splines were used for signals description. They can also be applied for the identifi cation of the dynamical systems described by diff erential equations up to the second order.
The algorithm presented in this paper enables the identifi cation of dynamic systems described by the diff erential equations of the n-th order.
The purpose of the identifi cation is to establish a mathematical model that describes the considered phenomena occurring in real systems as part of the adopted assessment criteria in the way. For a wide class of dynamical systems, the dependence between input uЄU and yЄY output quantities can be described by means of the linear diff erential equation of n-th order with constant coeffi cients The set U is called the space of inputs of (1) while its elements u are called inputs signals. The set Y is called the space of outputs while its elements y are called outputs. The response of the system is determined by: -the initial conditions; -input quantities (forced inputs); -parameters which characterized the inner systems structure and which are appearing as coeffi cients in equations. Let denote the signals determined by approximation of values of inputs and values of outputs (which are known from measurements on the real system)) at the moments where As the example of the equation (1) we can the jest equation of the ship's maneuverability (2) which is called 'Nomoto 2nd order model' ( [1], [5], [7], [8]) describing the relationship between the rudder defl ection angle δ(t) and the course angle ψ(t). The coeffi cients K 1 , T 1 , T 2 , T 3 characterize the ship's steering ability.
The developed method will be illustrated by an example of the identifi cation of the diff erential equation describing the change of the increment of the submersion depth and the increment of the trim angle of a submarine depending on the weight of the water taken by the compensation tank of torpedo tubes.

THE ALGORITHM OF APPROXIMATION BY MEANS OF B SPLINES OF II TYPE / Algoritam aproksimacije pomoću B splajna tipa II
Let N  be the system of points denotes the set of continuous functions f and their derivatives Defi nition 1.
s is a polynomial of the order at most r in every We accept that In practical, real problems the B-splines of II type are usually applied.
The base of B-splines of II type of 0 order has the following form The base of splines of II type: for n > 1 can be determined by using the De Boor equations [9]: On the basis of the measurements k ỹ determined in the moments of the real signal we are going to defi ne a function (5) such that for any fi xed the random variable k ỹ has a normal distribution with the mean value (6) and standard deviation σ. Moreover, we assume that the random variables k y are independent.
The coeffi cients will be determined using the maximum likelihood method by minimalizing the density function (7) of random variables . The problem of choice the optimal coeffi cients minimalizing the density function (7) comes down to solve the systems of equations: (8) where .
The matrix of systems of equations (8) is symmetric, regular and ribbon (the so-called (2r + 1) -diagonal). Therefore the coeffi cients can be determined recursively [10].

ALGORITHM OF CHOOSING THE OPTIMAL COEFFICIENTS OF THE DYNAMIC SYSTEM / Algoritam izbora optimalnih koefi cijenata dinamičkog sustava
To choose the optimal coeffi cients we present (1) as , where . By identifi cation of the dynamic system (1), we understand the problem of choice of the coeffi cients of (1) with determined signals (10) in such a way that the functional (the identifi cation index): (11) reaches its minimum value.
The problem of choice the optimal coeffi cients of (9) minimalizing the functional (11) comes down to solve the system of linear equations (included in the scheme of the below presented algorithm).
Algorithm of the identifi cation of the dynamic system / Algoritam identifi kacije dinamičkog sustava START Input data: Compute: The algorithm of approximation the signals: The coeffi cients can be determined in analytic way [2], [8]., Verifi cation of the model: Solve the equation: No Yes A computer program in Turbo Pascal was written for identifi cation the coeffi cients of the diff erential equations up to the fourth order. In the example below, Mathematica program was used to solve the diff erential equations and signal plots.

NUMERICAL EXAMPLE / Numerički primjer
The submarine, fl owing on the surface of the sea, is subjected to the same laws as any surface ship. There are two forces acting on the ship: the force of gravity P directed downwards and the buoyancy force D directed upward. The diff erence A = D -P between the buoyancy force and the force of gravity P is often referred to as residual buoyancy. If A > 0 then we deal with positive residual buoyancy and the ship will have a tendency to fl oat to the surface. If A < 0 then the buoyancy is negative and the ship will tend to increase its depth.
If A = 0 then we have the case of the so-called zero buoyancy. The infl uence of the residual buoyancy on the behavior of the ship depends on its value, its place of occurrence (distance from the center of gravity of the ship) and the speed of the ship.
To balance the force of gravity P with buoyancy force D the regulating trim and compensating tanks are used. Filling those tanks with water from behind the side or removing water overboard causes that ship's weight increases or decreases.
In order to keep the submarine at the intended depth and to change the draft, depth rudders as well as regulation and trim systems are commonly used. Through the depth rudders and the regulation and trim system, independent constraints are generated to control the longitudinal movement of the ship in weariness. Due to the variety of physical (hydrodynamic) phenomena aff ecting the movement of the real submarine, the motion equations obtained on the basis of mathematical dependences describing physical (hydrodynamic) phenomena defi ne only the movement of a specifi c submarine. In this case, we will determine certain equations of motion of the submarine based on the measurements of the depth of immersion i , the trim angle i , the weight of water Ã i fl owing into the compensation tanks in t i , i = 0, 1, ...,n 1 moments of time.
The computer program is applied to determine the diff erential equations describing the dependence of changes in the depth of immersion and the increment of the trim angle of the submarine on the weight of water assumed by the aft reservoir of the torpedo tubes at constant speed . The measured data are presented in Table 1. where denotes the measured weight of water the aft reservoir of the torpedo tubes at the moment of time , while and denote the measured values of immersion depth and trim angle of the submarine correspondingly. Those data were approximated by means of the B-splines of 3 rd order and they were denoted as .
The solutions of (12) and (13) when are shown in Table 2. and on Figure 3. In that case the maximal To determine the optimal number N of base regression functions (7)   The F statistics has the Snedecor distribution with and degrees of freedom. It enables to test the hypothesis that the diff erence in variance of both regression functions is equal to zero. From the Snedecor distribution tables, for a given level of signifi cance α and with and degrees of freedom we read the critical value . If then the hypothesis that the two variances are equal is rejected and it means that the regression functions diff er from each other. If the matching coeffi cients diff er slightly with a larger number of basic splines, there is no clear need to expand the regression function. The use of an excessive number of basic functions signifi cantly extends the calculation time.
To assess the correctness of the determined equations (12) -(13), a test checking whether the rest of models undergoes the fi rst -order autocorrelation. Then the von Neuman test [6] can be used to check it.

CONCLUSION / Zaključak
The method of identifying selected underwater motion equations presented in the article allows to obtain diff erential equations describing the change of the depth of immersion and the trim angle for any change in residual buoyancy. The analyzed case of fi lling the aft compensation tank is an example of the possibility of the described method. The accuracy of identifi cation depends on the order of the diff erential equation and on the accuracy of the approximation of the input and output signals. The determined equations of movement of the submarine can be used for optimal control in the vertical plane.
The advantage of the algorithm of signal approximation is that the measurement data do not have to be registered in equidistant moments. The formulas of scalar products of the basic functions of the third degree spline can be determined in an analytic way and then the formulas (12) do not contain any defi nite integrals. This is important in numerical calculations. In this way, the time is signifi cantly reduced and also the calculation error is reduced.
The elaborated method of identifi cation can be used to determine the optimal ratios of mathematical models describing systems: economic, biological, mechanical, etc.