Algorithm Simulation of Ship Dynamic Positioning Using Adaptive Fading Memory Filter
2018-01-04ZHANGShnZOUZojin
ZHANG Shn,ZOU Zo-jin,b
(a.School of Naval Architecture,Ocean and Civil Engineering;b.State Key Laboratory of Ocean Engineering,Shanghai Jiao Tong University,Shanghai 200240,China)
Algorithm Simulation of Ship Dynamic Positioning Using Adaptive Fading Memory Filter
ZHANG Shana,ZOU Zao-jiana,b
(a.School of Naval Architecture,Ocean and Civil Engineering;b.State Key Laboratory of Ocean Engineering,Shanghai Jiao Tong University,Shanghai 200240,China)
Due to the complexity and nonlinearity of ship motion at seas,an accurate mathematical model for ship dynamic positioning system is difficult to establish.In order to achieve efficient control,it is necessary to obtain the required signals of low frequency motion by means of a filter algorithm for state estimation.Using the conventional Kalman filter,the correction effect of new measurement data of state variables on the prediction decreases,while the influence of the old measurement data increases with the time step,which is the main reason of filter divergence.To solve the problem of inaccurate model,inaccurate expression of system noises and measurement noises when applying Kalman filter in a ship dynamic positioning system,an adaptive fading memory filter is employed to estimate the low frequency motion.By introducing the fading memory factor in the state estimation algorithm,the effect weight of the old measurement data on the state estimation is decreased,and the impact of the new measurement data is increased.Besides,according to the criterion for filter divergence,a proper fading memory factor is chosen to restrain the filter divergence and to make the controller output relatively smooth,so that the unnecessary energy consumption of the thruster system is reduced.The simulation results show that the designed adaptive filter is superior to Kalman filter in convergence and traceability,and the positioning precision and stability of the system are effectively improved.
ship dynamic positioning;state estimation;adaptive fading memory filter;Kalman filter
0 Introduction
Due to the disturbance of wind,waves and current,the ship motion at seas is complicated and nonlinear.In the ship dynamic positioning system,the sensor signals are always polluted by external environment and internal physical properties itself,which has negative impact on the controller performance.In this sense,a model-based filter is necessary for the control system.A filter is used to restrain or avoid the disturbing components of input signals,and modifies the frequency values and phases to enhance the precision of the output signals.Itdeals with the signals of ship motion and eliminates the high frequency components,the system noises and measurement noises to make the output of the controller tend to be smooth and stable[1].
Kalman filter[2]is generally restricted to a stochastic linear system with accurate model,and requires the system noises and measurement noises to be specified Gaussian white noise sequences.However,the complexity of the environment and the inertia of the vessel lead to the discrepancy between the low frequency motion model established and the actual situation,which reflects the limitations of using Kalman filter[3].Moreover,for a complex and nonlinear system like a surface vessel at seas,it is difficult to guarantee the existence of the optimal solution when using an optimal estimation algorithm.If the mean square errors of state prediction could not be updated adaptively,they will accumulate with the recursive calculation steps,which is destined to cause distortion of the gain matrix and deterioration of the global asymptotic stability.As a result,the low frequency motion tracking is hard to ensure[4].
An adaptive filter can effectively compensate the errors as well as suppress the disturbances caused by the imprecise system model and insufficient statistical characteristic of system noises and measurement noises,so that the convergence and stability are improved with a certain reliability[5].Extended Kalman filter[6]and unscented Kalman filter[7]are mainly used to solve the problem of model nonlinearity.The adaptive filter constructed with neural network[8]requires a large quantity of training samples as foundation and has heavy computational burden.Adaptive fuzzy filter[9]is applied with prior knowledge of the environment and appropriately regulates the membership functions according to the noise characteristics.
In this paper,an adaptive fading memory filter is designed to estimate the low-frequency motion including the position and heading information of a given vessel.Particularly,a fading memory factor is introduced into the conventional Kalman filter algorithm.A digital suboptimal filter is formed to alleviate the dependence on prior estimations and at the same time to raise the weight of current measurements of state variables.Simulation experiments using the proposed adaptive fading memory filter and the conventional Kalman filter are conducted,and the results are compared to evaluate the effects of the filters.It confirms that higher positioning precision can be achieved by using the proposed filter.
1 Mathematic models
Since a vessel is at a slow speed when operated under dynamic positioning control,the motions of heave,roll and pitch have little influence on the dynamic positioning operation,while the motions of surge,sway and yaw with small heading angle are usually the main concern[10].The mathematical model with disturbances in the vessel-fixed frame is expressed as[11]:where M is the inertia matrix of the system including added mass,D is the damping matrix;ν=[u,v,r]Tdenotes the velocity components and yaw rate,τ represents the force and moment acting on the vessel;η=[x,y, ψ ]Tis the position and heading in the earth-fixed frame,R(ψ)is the rotation matrix for transformation;Eυrepresents the maximum amplitudes of system noise,while ωυis a Gaussian white noise vector which reflects model uncertainty due to the wind,current and second-order waves.b is the slowly varying environment force and moment,and always presented as a one-order Gauss-Markov model:
where Tbis a diagonal matrix which contains time constants,ωbis a Gaussian white noise vector and Ebis the maximum amplitudes of the noise.
The linear wave-frequency motion of state space model can be described as:
where ηw=[xw,yw,ψw]Tis the high frequency motion induced by the first-order waves;Ew=[03×3Eh]T,where Ehrepresents the maximum amplitude of Gaussian white noise ωw.The other coefficient matrices in the model are:
where ω21and ω22are related to the main frequency of waves ω0and the relative damping ζ.They are given as:
The measurement data of the system are always corrupted by noise.They can be expressed as:
where ωyis the measurement noise and set as Gaussian white noise.
Eqs.(1),(2),(3)and(6)constitute the mathematical model for the ship dynamic positioning system,which is copied by the filter for state estimation.
The equations of state and measurement in discrete form can be written as:
The characteristics of the initial state variables x0and ωk, υkare independent of each other,namely,
2 Adaptive fading memory filter
In this paper,an adaptive fading memory filter is proposed to improve the Kalman filter algorithm.It also consists of two parts:firstly,update time to estimate the low frequency motions;then,update measurement to correct the previous state estimation by utilizing the known observations.P0,the variance of the deviation between x0and the initial estimationis used to describeRk,the variance of υk,is used to describe the measurement yk.The improved filter can automatically determine the utilization of the observation samples andwhen calculating the variableswhere n is the number of the measured historic observations.In this way,the impact ofand yoncan be reduced by increasing Pand R[12].
k0k
A fading memory factor f,a specific scalar,is introduced in the Kalman filter for the propose of adaptively correcting P0and Rk:
To simplify the filtering process,the system noise is put in another transformation:
Similarly,other variables in the Kalman filter are defined by
The converted filter equations can be written as:
In the conventional Kalman filter,the optimal control gain matrix is solved only according to the priori variance matrix and the noise variance.The inaccuracy or extreme change of priori information may lead to filter divergence.Therefore,in order to correct the estimated values,f in the fading memory filter is applied not only to adjust weightedly the system noise and measurement noise,but also to adjust the variance of measurement noise adaptively and the control gain matrix completely.Setting f>1,it always holds thatsimultaneously.Furthermore,since
the weight of priori estimated valuesis decreased,while the measurements ykhave higher confidence level.
The covariance matrixes of the system errors will become infinite when the filter diverges.k→∞ may cause the gain matrixesresulting in the actual estimated errors much more higher than the theoretical values.An inequality is set up as the judgment condition to limit the divergence:
where the left term is the sum of the squares of the new sequences,and the right term is the trace of the covariance matrix,λ is the redundancy coefficient and λ≥1;rkis the deviation of the measurements from their estimations,including errors caused by the difference between the actual ship motion and that determined by the simulation model.It can be written as:
The judgment condition to evaluate the divergence can be further expressed as:
where λ=1 means the most strict standard.
If the coefficient matrix cannot satisfy Eq.(16)when circular computations are implemented by using the filter equation,Eq.(12),it suggests that the estimated values are larger than the theoretical values or are λ times of the theoretical values.
Considering rkas the white noise term,with λ=1,it follows
and the formula for solving fkautomatically is given as:
where d is the dimension of the measurements.In the present study,d=3.
Substituting Eq.(18)into Eqs.(8)-(11),it yields from Eq.(12)the complete fading memory filter process.
3 Simulation experiment and result analysis
The control system for ship dynamic positioning is a closed-loop system consisting of an estimator,a controller and a thrust allocation module.With the help of the measurement system,it detects the deviations between the actual positions,headings and the target ones of the vessel,as well as the impact of external disturbances such as wind,waves,and current.Then the estimator estimates the slowly varying external disturbances to which the vessel has to respond,and the controller outputs the instructions for thrust system to implement to ensure the vessel to maintain the desired position and heading as much as possible.
To verify the effectiveness of the improved filter,simulations are carried out,and a LQ controller was connected with the improved filter in the simulations.Some parameters in the simulations are set as follows:The sampling period is 0.2 s,the simulation time is 500 s;and the variance matrix of the system noise Q,the measurement noise R and some other environment parameters are set as:
3.1 Ship model
Tab.1 Principal dimensions of the ship model
Take a ship model of a 75m-platform supply vessel with scale ratio 1:20 as the study object[13].The principal dimensions of the ship model are given in Tab.1.
The simulation begins with η0=[0 m 0 m 0°]Tas the initial position and heading,and the vessel is desired to move to the setpoint ηd=[10 m 10 m 0°]T.The inertia matrix M and hydrodynamic damping matrix D of this ship model are obtained by CFD method using Fluent software,the dimensionless M and D are given as follows[13]:
3.2 Effects of the adaptive fading memory filter
A description of the low frequency ship motion estimated by the designed adaptive fading memory filter is illustrated in Fig.1,where the measured position is composed of the dead reckoning of the ship,system noise,measurement noise and environment noise.The estimated position is obtained from the measured value by the filter.
The comparison of the measured position and the estimated position indicates that the designed adaptive fading memory filter can effectively eliminate the disturbances.Particularly,the curves of the estimated position are significantly smoother than the measured position and stably converge to the vicinity of the desired values,which confirms that the filter can suppress the positioning error to a certain extent,thus improve the positioning accuracy of the control system.On the other hand,as can be seen from Fig.1(c),the filtering effect on the yaw motion is less than those on the surge and sway motions.This is mainly due to the fact that the input in the yaw motion is torque which is harder to perform than force input with equal flexibility.
Fig.2 depicts the trajectory of the ship in the horizontal plane.It shows that the ship reaches the target location in both longitudinal and transverse directions almost simultaneously,which is in line with the law of actual ship motions.The filter operates as expected to let the vessel follow a smoother trajectory,and tend to converge to a stable state,thereby the accuracy of the control system is improved effectively.
Fig.1 Filter effect in ship dynamic positioning
Fig.2 Trajectory of the ship on the horizontal plane in ship dynamic positioning
Fig.3 e varying with number n of historical observation data,when f=1.003
In view of the fading memory factor f and the number of historical observations n,the deviation between the estimated state variables by the filter and the dead reckoning values obtained from the mathematical model is taken for further comparison,which is defined as:where xfidenotes the filtering value at time step i,xmidenotes the corresponding mathematical model value.
As an example,Fig.3 shows the results at a fixed f(f=1.003)with a varying n.It reveals that for a fixed value of f,the deviation increases with the amount of the historical observations,which further validates the impact of the historical data on the estimated values.
In order to testify the superiority of the proposed filter over the conventional Kalman filter,the deviations are calculated with both filters under the same initial external conditions,defined as:
Fig.4 demonstrates that the adaptive fading memory filter has a better convergence and target position tracking performance than the conventional Kalman filter,resulting in better disturbance rejection and considerably reducing the oscillation amplitude of the control output.Consequently,the unnecessary operation of the actuators can be avoided.
Fig.4 Comparison of adaptive fading memory filter and conventional Kalman filter
4 Conclusions
An improved filtering algorithm for control system of ship dynamic positioning is proposed.An adaptive fading memory filter is designed by introducing a fading memory factor f and making use of n historical observation data to estimate the ship’s position and heading in low-frequency motion.It overcomes the restrictions of needing to know the exact mathematical model while using the conventional Kalman filter.Furthermore,it can amend the unknown or uncertain model error,system noise and measurement noise in real-time or online according to environment changes,therefore the influences of the historical observations on the estimated values are reduced and more emphasis can be put on the new measurements,which provides the control system with the advantages of adaptability and higher accuracy.
The simulation results show that the proposed algorithm has better filtering effects compared to those of the conventional Kalman filter,and the convergence and tracking ability are improved.On the other hand,the control output of the ship dynamic positioning system is optimized,reducing the unnecessary operations of the thrust system,thereby reducing the energy consumption and avoiding wear and tear of the mechanical system.
Acknowledgements
This work is supported by the project of the Ministry of Industry and Information Technology of China for Ships with High Technology:Independent Development of Semi-submersible Engineering Vessels of 100 000 Tonnage.
[1]Xiong Jianbin,Wang Qinruo,Liu Yijun,et al.A linear signal filtering smoothing algorithm for ship dynamic positioning[C]//Proceedings of the 31st Chinese Control Conference,IEEE.Hefei,China,2012:3718-3722.
[2]Fossen Thor I,Perez Tristan.Kalman filtering for positioning and heading control of ships and offshore rigs[J].IEEE Control Systems Magazine,2009,29(6):32-46.
[3]Guo Juan,Zou Zaojian.Analysis and comparison of two filtering methods for ship dynamic positioning system[J].Journal of Ship Mechanics,2013,17(6):592-603.
[4]Ran Chenjian,Deng Zili.Self-tuning weighted measurement fusion Kalman filter and its convergence analysis[C]//Proceedings of the 48th IEEE Conference on Decision and Control/28th Chinese Control Conference.Shanghai,China,2009:1830-1835.
[5]Ding Weidong,Wang Jinling,Rizos Chris,et al.Improving adaptive Kalman estimation in GPS/INS integration[J].Journal of Navigation,2007,60(3):517-529.
[6]Mauro Candeloro,Sørensen Asgeir J,et al.Observers for dynamic positioning of ROVs with experimental results[C]//Proceedings of the 9th IFAC Conference on Manoeuvring and Control of Marine Craft.Arenzano,Italy,2012:85-90.
[7]Hu Gaoge,Gao Shesheng,Zhong Yongmin,et al.Modified strong tracking unscented Kalman filter for nonlinear state estimation with process model uncertainty[J].International Journal of Adaptive Control and Signal Processing,2015,29(12):1561-1577.
[8]Negin Musavi,Jafar Keighobadi.Adaptive fuzzy neuro-observer applied to low cost INS/GPS[J].Applied Soft Computing,2015(9):82-94.
[9]Sung W J,Lee S C,You K H.Ultra-precision positioning using adaptive fuzzy-Kalman filter observer[J].Precision Engineering,2010(34):195-199.
[10]Sørensen Asgeir J.A survey of dynamic positioning control systems[J].Annual Reviews in Control,2011,35(1):123-136.
[11]Fossen Thor I,Handbook of marine craft hydrodynamics and motion control[M].United Kingdom:John Wiley&Sons,Ltd.,2011:133-157.
[12]Gao Shesheng,He Pengjü,Yang Bo.The principle and application of integrated navigation system[M].Xi’an:Northwestern Polytechnic University Press,2012:63-74.(in Chinese)
[13]Ke Xiaobing,Luo Wei,Zhao Xiaosa,et al.The regression formula of location hydrodynamic derivatives of supply vessels based on CFD method[J].Chinese Journal of Ship Research,2014,9(4):50-54.(in Chinese)
基于渐消记忆自适应滤波的船舶动力定位算法仿真
张 闪a, 邹早建a,b
(上海交通大学a.船舶海洋与建筑工程学院;b.海洋工程国家重点实验室,上海 200240)
由于船舶在海上运动的复杂性和非线性,精确的船舶动力定位系统数学模型难以建立。为了实现有效的动力定位控制,需要应用一定的状态估计滤波算法得到所需的船舶运动低频信号。采用常规的Kalman滤波,状态变量的新测量值对预测值的修正作用下降,旧测量值的影响随着计算步数的累积而相对提高,这是引起滤波发散的主要原因之一。文章针对船舶动力定位系统中使用常规的Kalman滤波而存在的模型不精确、不能准确表达系统噪声和测量噪声等问题,采用渐消记忆自适应滤波估算低频运动信息,在状态估计算法中引入渐消记忆因子,减小旧测量值对状态估计值的影响权重,从而增大新测量值的作用;并根据滤波发散判断准则,选择适当的渐消记忆因子值来抑制滤波器的发散,使控制器输出较为平稳,从而降低推力系统不必要的能耗。仿真实验表明,所设计的自适应滤波器的收敛性、跟踪性优于常规的Kalman滤波,有效地提高了系统的定位精度和稳定性。
船舶动力定位;状态估计;渐消记忆自适应滤波;Kalman滤波
U661.3
A
张 闪(1990-),女,上海交通大学硕士生;
邹早建(1956-),男,上海交通大学教授,博士生导师。
U661.3 Document code:A
10.3969/j.issn.1007-7294.2017.12.006
date:2017-07-25
Supported by the Projet of the Ministry of Industry and Information Technology of China for Ships with High Technology
Biography:ZHANG Shan(1990-),female,master student of Shanghai Jiao Tong University,E-mail:shancheung@sjtu.edu.cn;ZOU Zao-jian(1956-),professor/tutor,E-mail:zjzou@sjtu.edu.cn.
1007-7294(2017)12-1497-10
猜你喜欢
杂志排行
船舶力学的其它文章
- Low-Cycle Fatigue Crack-Propagation Behavior for Ship Cracked Plate Considering Accumulative Plastic Damage
- Numerical Simulation of Deterministic Freak Wave Based on Energy Distribution
- Method of Estimating the Effect of Marine Fouling on Frictional Resistance of Ships
- Evaluation of Viscous Effect on Wave Excitation Force of a Vessel with Transom Stern
- Numerical Predictions of the PPTC Propeller Tip Vortex Cavitation in Uniform Flow
- Enhanced Extinction Curve Method for Roll Damping Estimation