#### Abstract

The transfer function of the wave compensation system is deduced. The interference signal acting on the system is eliminated by the feed-forward compensation correction method. The pole assignment of the system is carried out after eliminating the interference signal. The genetic PID algorithm is proposed, and the genetic PID controller is designed. The control block diagram of the wave compensation system based on the genetic PID control algorithm is established, and the optimal index and PID parameters are optimized by the crossover and mutation operators of the genetic particle swarm optimization algorithm. The simulations and experiments of the system show that the control performance of the wave compensation system based on the genetic PID algorithm is greatly improved. The higher control precision is obtained. The anti-interference ability and the robustness of the system are increased. The accuracy of the control method is verified.

#### 1. Introduction

The research of the wave compensation technologies originates from the demand of offshore drilling. The wave compensation technologies have been developed from the single compensation to the comprehensive compensation. The wave compensation technologies are divided into active compensation, passive compensation, and hybrid active-passive compensation according to the different dynamic sources [1]. The wave compensation technologies are divided into velocity compensation, displacement compensation, force compensation, and comprehensive compensation according to the different physical quantities controlled by the system. Korde [2] proposed an active heave compensation on drill-ships in irregular waves. In order to maintain the high compensation accuracy and reduce the energy consumption, Huang et al. [3] designed a semiactive drilling winch heave compensation system based on an active compensation winch. Due to the complexity of the sea conditions, the objects controlled by the wave compensation system have the characteristics of multivariable strong-coupling, nonlinearity, and time-varying, requiring that the wave compensation system has good control characteristics. In order to meet the strict requirements of the safety and efficiency of the wave compensation crane working in harsh sea conditions, Neupert et al. [4] presented a heave compensation system based on the lifting motion prediction and a control strategy based on the inversion, as well as a trajectory tracking disturbance decoupling controller combined with the prediction algorithm. Küchler and Sawodny [5] presented an active compensation system and designed an algorithm to directly control the hydraulic winch of offshore crane to compensate the vertical motion of the ship, while achieving the trajectory tracking of payload. Do and Pan [6] proposed a method to construct a nonlinear controller of the active heave compensation system using electrohydraulic system driven by two-bar actuators to reduce the influence of ship heave motion on riser response. At present, PID control, fuzzy control, adaptive control, and active disturbance rejection control have been applied to the wave compensation system [7–12]. Mei et al. [7] designed the PID control system based on the variable parameters, considering the instability and conditions of the marine environment and realize speed compensation. Tang et al. [8] implemented the fuzzy logic control to the deep-sea heave compensation system under the four-level sea condition and achieved satisfactory results. Feng et al. [9] proposed a control strategy based on a fuzzy adaptive method and a motion prediction model to overcome the delay problem in the wave compensation actuator and the nonlinear time-varying problem in the wave motion. Li et al. [10] applied a newly developed second-order active disturbance rejection controller to the control strategy of the heave compensation tension, which improved the control accuracy. Chen and Liang [11] applied the integrated design of intelligent control algorithms such as hybrid fuzzy PID control algorithm, force feedback control algorithm, and feed-forward control algorithm to the wave compensation platform, which improved the control performance of the system. Wang et al. [12] applied a nonparametric model adaptive control to the underwater towed heave compensation system, making the control system have a good dynamic performance and the anti-interference ability. In this paper, the mathematical model of the wave compensation system based on the feed-forward compensation correction is established, and the pole assignment of the system is carried out. It improves the anti-interference ability and the robustness of the system. However, its fast responsiveness is worse than that of the system without the pole assignment. The genetic PID controller is designed to optimize the optimal index and PID parameters of the system. This method is applied to the system after the pole assignment, which improves the fast responsiveness of the system while maintaining the stability and the accuracy of the system. Furthermore, the control performance of the systems is simulated by MATLAB, and YH25 wave compensation hoist is used as the experimental platform to carry on the experiments of the genetic PID algorithm. The results indicate that the control characteristics of the wave compensation system based on the genetic PID algorithm reach the optimal state.

#### 2. Transfer Function of the Wave Compensation System

##### 2.1. Structure and Working Principle of the Wave Compensation System

The wave compensation system is composed of servo valve, force sensor, hydraulic motor, servo amplifier, and other main hydraulic components. It is used to reduce the alternating load of the hoisting rope caused by the influence of sea waves and to avoid the phenomenon that the breakage of the hoisting rope endangers the safety of people and materials. The working process of the wave compensation system is shown in Figure 1. The computer sends out the command signal *X*, and the signal *X* passes through D/A converter to form the input voltage signal *U* (V). It is compared with the detection feedback signal *U*_{f} (V) of the tension of the hoisting rope, and the deviation voltage signal Δ*U* (V) is obtained. The deviation voltage signal is input into the servo amplifier, and the output electric current signal *I* (A) of the servo amplifier is sent to the valve-controlled hydraulic motor device to drive the hydraulic winch to rotate. The hydraulic winch hoists the heavy objects by hoisting rope. *T*_{m} (N·m) and *T*_{L} (N·m) are the output torque and the external load torque acting on the hydraulic motor shaft, respectively. *F* (N) is the tension of the hoisting rope.

##### 2.2. Transfer Function of the Valve-Controlled Hydraulic Motor

The valve-controlled hydraulic motor consists of four-way valve II and hydraulic motor III [14], as shown in Figure 2, where *P*_{f} is the pressure difference (pa), *q*_{r} is the hydraulic motor’s displacement (m^{3}·rad^{−1}), and *θ*_{m} is the hydraulic motor’s angular velocity (rad·s^{−1}).

The Laplace transformation of the load-flow equation of the valve is derived, as follows:where *K*_{q} is the flow gain of the servo valve (*K*_{q} = 1.7 × 10^{−3} m^{3}·A^{−1}·s^{−1}), *K*_{c} is the pressure coefficient of the valve, and is the complex frequency-domain function of the flow of the valve-controlled hydraulic motor.

The Laplace transformation of the flow continuity equation of the valve-controlled hydraulic motor is derived, as follows:where *C*_{m} is the total leakage coefficient of the valve-controlled hydraulic motor, *s* is the complex frequency, *V*_{t} is the total capacity of two chambers and connecting pipes of the hydraulic motor (*V*_{t} = 3.6 × 10^{−3} m^{3}), *β*_{e} is the volumetric elastic modulus of the hydraulic oil (*β*_{e} = 7 × 10^{8} pa), and *q*_{r} is the displacement of the hydraulic motor (*q*_{r} = 8.76 × 10^{−5} m^{3}·rad^{−1}).

The Laplace transformation of the dynamic torque balance equation of the hydraulic motor shaft is derived, as follows:where is the complex frequency-domain function of the output torque of the hydraulic motor, *J*_{m} is the total inertia converted from the hydraulic motor and the load to the output shaft of the hydraulic motor (*J*_{m} = 10 kg·m^{2}), *B*_{m} is the resistance coefficient of the hydraulic motor and the load (*B*_{m} = 150 N·m·s^{−1}), *G* is the load torque spring stiffness of the output shaft of the hydraulic motor (N·m·rad^{−1}), and *T*_{L} is the external load torque acting on the hydraulic motor shaft (*T*_{L} = 1700 N·m).

is derived by equations (1)–(3), as follows:wherewhere is made up of and . is generated by *I*, and is generated by *T*_{L}. The feed-forward compensation corrected method is used to eliminate to make the wave compensation system to be a single-input single-output system [15]. The control process block diagram of the feed-forward compensation corrected system is presented in Figure 3, and the relationship between and is expressed as follows:where *K*_{a} = 0.035 A·V^{−1}.

is derived by equation (6), as follows:

From Figure 3, it is known that is eliminated. is derived by equation (4), as follows:where *K*_{ce} is the total pressure-flow coefficient (*K*_{ce} = 7.22 × 10^{−13} m^{3}·s^{−1}·pa^{−1}), *K*_{ce} = *K*_{c} + *C*_{m}, and *H* = *J*_{m}*·s*^{2} + *B*_{m}*·s* + *G*.

For the valve-controlled hydraulic motor, its elastic load is rare and is greatly simplified by equation (8), as follows:where *ω*_{h} is the natural frequency of the hydraulic system (*ω*_{h} = 24.43 rad·s^{−1}) and is the damping ratio of the hydraulic system ().

##### 2.3. Transfer Function of the Feed-Forward Compensation Corrected System

The control process block diagram of the feed-forward compensation corrected system is shown in Figure 4.

The open-loop transfer function of the wave compensation closed-loop system is as follows:where = 21.42, *K*_{f} = 1 × 10^{−5} (V·N^{−1}), , and .

The closed-loop transfer function of the wave compensation closed-loop system is as follows:where

#### 3. Pole Assignment of the Wave Compensation System

##### 3.1. Closed-Loop Frequency-Domain Index Analysis of the Wave Compensation System

The bandwidth of the system refers to the corresponding frequency range, when the logarithmic amplitude of the closed-loop system is not less than −3 dB. The larger the bandwidth of the system is, the faster its responsiveness is. However, the larger the bandwidth of the system is, the worse its anti-interference ability is. The poor ability to distinguish the signal from noises affects its control accuracy. As shown in Figure 5, the bandwidth of the wave compensation system is 1.21 × 10^{5} rad·s^{−1}. It is too larger to meet the control accuracy requirement. Therefore, the pole assignment is carried out to change the defect of the excessive bandwidth of the wave compensation system, making the system have the expected control performance.

##### 3.2. Determination of the Expected Poles of the System

According to the requirement of a marine salvage equipment, the required transient responsiveness indexes of the wave compensation system are as follows: the maximum overshoot of the system *M*_{p} ≤ 8% and the peak time *t*_{P} ≤ 0.5 s. The expected poles of the wave compensation system are as follows:where *ω*_{np} is the natural frequency of the wave compensation system after the pole assignment (rad·s^{−1}) and *ζ*_{p} is the damping ratio of the wave compensation system after the pole assignment.

According to the required transient responsiveness indexes of the wave compensation system, a set of inequalities can be listed as follows:

By solving a set of inequalities (16), *ω*_{np} and *ζ*_{p} are obtained as follows:

The expected poles of the system obtained by introducing *ω*_{np} and *ζ*_{p} into the set of equations (13) are as follows:

The characteristic polynomial consisting of the expected poles is as follows:where and .

According to equation (11), the characteristic polynomial of the wave compensation system is as follows:where and .

The state feedback matrix *K* of the wave compensation system after the pole assignment is as follows:

In order to make the hoisting rope bear the expected tension of the system, the tracking signal error *e*_{p} of the unit step signal that is input into the wave compensation system after the pole assignment is as follows:where is the closed-loop transfer function of the wave compensation system after the pole assignment, as follows:where *k* is the input amplification factor of the wave compensation system after the pole assignment (*k* = 7.8 × 10^{−5}).

The closed-loop transfer function of the pole assignment system is obtained by introducing *k* into the equation (21), as follows:

The block diagram of the control system after the pole assignment is shown in Figure 6. There are two ways to realize the pole assignment of the system: the hardware circuit method and the algorithm program method. The input amplification factor k of the wave compensation system after the pole assignment is too small to realize with the hardware circuit method. In this paper, the algorithm program method is used to realize the pole assignment of the system. The flow chart for realizing the pole assignment of the system is shown in Figure 7. The input signal of the system is transmitted to STC-90C51 single-chip microcomputer with A/D and D/A conversion modules. STC-90C51 chip is the core of 51 single-chip microcomputer. It stores the arithmetic program of realizing the pole assignment of the system. When the chip receives the digital signal from the A/D conversion module, it realizes the pole assignment processing, using the algorithm program stored in the chip, and outputs the processed signal to the controlled object through the D/A conversion module.

##### 3.3. Control Characteristics of the System after the Pole Assignment

The bode diagram of the system after the pole assignment is presented in Figure 8. The bandwidth of the system after the pole assignment is 12.4 rad·s^{−1}. It is moderate, which can filter out the high frequency interference signal and enhance the ability to suppress interference.

The unit step signals are input into the system after the pole assignment and the system without the pole assignment, respectively [16], and the unit step responsiveness curves of the system after the pole assignment and the system without the pole assignment are obtained as shown in Figure 9. The peak time and the maximum overshoot of the system without the pole assignment are 0.08058 s and 84.3%, respectively. The overshoot of the system is very large. The system tends to be stable at 2.311 s, and its steady state error rate is 213500%. The peak time and the maximum overshoot of the system after the pole assignment are 0.3286 s and 6.4%, respectively. The system tends to be stable at 1.1 s. Its steady state error is 0%.

Compared with the system without the pole assignment, the maximum overshoot of the system after the pole assignment is greatly reduced by 77.9%, the time for the system to be stable is reduced by 52.4%, and the stability and the anti-interference ability of the system are greatly improved. However, the fast responsiveness of the system after the pole assignment is worse than that of the system without the pole assignment, and the peak time of the system after the pole assignment is increased by 307.8%. Therefore, it is very important to design the genetic PID algorithm to improve the fast responsiveness of the system after the pole assignment.

#### 4. Design of the Genetic PID Controller

##### 4.1. Novelties and the Advantages of Genetic PID Control Algorithm

The genetic PID control algorithm is a combination of the genetic algorithm and the particle swarm optimization algorithm to search for the optimal PID control parameters of the system. It can solve the problem that the structure and the parameters of the system controller must be determined by experience and onsite debugging when the structure and the parameters of the controlled object cannot be completely mastered. The genetic PID algorithm not only keeps the advantage of the global search optimization of the genetic algorithm in solving the problem but also absorbs the advantage of the high search efficiency of the particle swarm optimization algorithm. The algorithm has the strong global search optimization ability, the high efficiency, which adjusts the system’s PID parameters in real time, making the system have good control characteristics.

##### 4.2. Design of the Genetic PID Controller

The control block diagram of the wave compensation system is based on the genetic PID algorithm, as shown in Figure 10. The genetic particle swarm optimization algorithm is applied to tune the PID controller parameters of the wave compensation system, making it have good control characteristics.

In order to obtain satisfactory dynamic characteristics, IAE performance index is used as the minimum objective function for parameter selection [17]. *J* is selected as the optimum index. The optimum index *J* is as follows:where *t*_{u} is the rise time, is the system error, is the output of the genetic particle swarm optimization controller, and *ω*_{1}, *ω*_{2}, and *ω*_{3} are all weights.

In order to avoid the overshoot, the optimum index *J* is as follows:where is the output of the controlled object, , and *ω*_{1}, *ω*_{2}, *ω*_{3}, and *ω*_{4} are all weights, .

In the iteration process, the genetic algorithm inspired by the survival principle of the fittest makes the population evolve to the optimal direction and finally obtains the optimal solution. It is realized by operation coding, group initialization, fitness evaluation, selection, crossover, and mutation. Particle swarm optimization algorithm, inspired by the behavioral characteristics of the biological populations, is used to optimize the problem [18]. A particle in the algorithm represents a possible solution and corresponds to an adaptive value determined by the fitness function [19]. The search in solvable space has a strong generality and does not depend on the problem information, group search, and experience-based learning. It has the advantages of memory, learning ability, saving searching time, simple principle, and easy implementation. However, the search accuracy is not high and the search for global optimal solution cannot be guaranteed. The genetic particle swarm optimization algorithm is the core of the genetic PID algorithm, which combines the genetic algorithm and the particle swarm optimization algorithm to tune the parameters of the PID controller of the system. The flow chart of the genetic particle swarm optimization algorithm is shown in the Figure 11.

#### 5. System Simulations and Analysis

##### 5.1. Establishment of the PID Control System

The control methods of the wave compensation system are mostly based on the PID algorithm. The wave compensation PID control system after the pole assignment is established, as shown in Figure 12. In engineering, the parameters of the PID controller are usually determined by trial and error or experiential formula. However, the mechanism of the genetic PID algorithm is to use genetic particle swarm optimization algorithm to tune the parameters of the system’s PID controller.

##### 5.2. Determination of the Parameters of the Genetic Particle Swarm Optimization Algorithm

The parameters of the genetic particle swarm optimization algorithm are shown in Table 1, and the mutation probability is related to the fitness *J*. The larger the fitness *J* is, the smaller the mutation probability is.

##### 5.3. Parameters Optimization

The genetic particle swarm optimization algorithm is applied to optimize the parameters. The optimizing process of the wave compensation system after the pole assignment is presented in Figure 13. The results are as follows: the optimum index *J* = 14.5, *K*_{p} = 39.58, *K*_{i} = 0.9842, and *K*_{d} = 0.1043.

##### 5.4. System Simulations and Analysis

The unit step signals are input into the systems, and the simulation results of the systems are shown in Figure 14. The peak time and the maximum overshoot of the system based on the genetic PID algorithm are 0.03723 s and 0.6%, respectively, and the system tends to be stable at 0.2881 s; its steady state error is 0%. The peak time and the maximum overshoot of the system without control algorithm are 0.3286 s and 6.4%, respectively, and the system tends to be stable at 1.1 s, its steady state error is 0%. The peak time and the maximum overshoot of the system that based on the standard PID algorithm are 0.1348 s and 0.9% respectively, and the system tends to be stable at 0.4642 s; its steady state error is 0.6%. Compared with the system without control algorithm, the peak time of the system based on the genetic PID algorithm is reduced by 88.7%, the time for the system to be stable is reduced by 73.8%, and the maximum overshoot of the system is reduced by 90.6%. Compared with the system that based on the standard PID algorithm, the peak time of the system that based on the genetic PID algorithm is reduced by 72.4%, the time for the system to be stable is reduced by 37.9%, and the maximum overshoot of the system is increased by 101.2%. However, its steady state error is reduced by 100%. Through comprehensive evaluation, the control performance of the system that based on the genetic PID algorithm is the best.

#### 6. Experimental Verification

##### 6.1. Structure and Working Principle of YH25 Wave Compensation Hoist

For verifying the accuracy of the genetic PID algorithm, YH25 wave compensation hoist is used as the experimental platform, as shown in Figure 15. The working system of YH25 wave compensation hoist is shown in Figure 16. It consists of two main structures: the luffing mechanism and the hydraulic winch mechanism. The hydraulic winch mechanism is the core device to implement the wave compensation function. The hydraulic winch mechanism consists of the servo valve-controlled hydraulic motor device and the winch device. The implementation process of the wave compensation function is as follows: the tension of hoisting rope is measured by CFBLS tension sensor. The detected signal is sent to the core processor of TMS320C6748 through the A/D conversion module. The processed signal is transmitted to the servo valve-control hydraulic motor device through D/A conversion module, the signal amplification, and the power amplification to make the winch device to receive and place the hoisting rope, preventing the hoisting rope from bearing the large alternating load. The core processor of TMS320C6748 in PC includes the control algorithm module and the signal filtering module. The control card of the tension of hoisting rope under different working conditions is designed by using the core processor of TMS320C6748 [20]. The tension parameters of the hoisting rope are compiled on PC. The genetic PID algorithm is compiled by using the integrated software development system Dynamic C. The processor is connected with YH25 wave compensation hoist through the electro-hydraulical control module.

##### 6.2. Experimental Methods

Before carrying out the experiments, prepare YH25 wave compensation hoist, the heavy objects, and the traffic. The heavy objects are connected with the hoisting rope of the traffic crane and the hoisting rope of the wave compensation hoist, respectively. While the wave compensation hoist is hoisting the heavy objects, the traffic crane is imposing the vertical acceleration on the heavy objects to simulate the periodic acceleration of the sea wave to the heavy objects. The experimental parameters are shown in Table 2. The preset value *F*_{2} of the system is 1 × 10^{4} N.

##### 6.3. Experimental Results and Comparative Analysis

The experimental results are shown in Figure 17. The periodic acceleration is applied to the heavy objects by the traffic crane, and its value ranges from −1.359 × 10^{4} N to 1.361 × 10^{4} N. At 0.0415 s, the value of the tension of the hoisting rope of YH25 wave compensation hoist based on the genetic PID algorithm rises rapidly to the maximum overshoot of the system, which is 1.032 × 10^{4} N. When the system tends to be stable, its value ranges from 8740 N to 1.053 × 10^{4} N, which is very close to the preset value *F*_{2} of the system, very well compensating the periodic acceleration acting on the heavy objects. At 0.1819 s, the value of the tension of the hoisting rope of YH25 wave compensation hoist based on the standard PID algorithm rises rapidly to the maximum overshoot of the system, which is 1.204 × 10^{4} N. When the system tends to be stable, its value ranges from 9069 N to 1.081 × 10^{4} N, which is very close to the preset value *F*_{2} of the system, very well compensating the periodic acceleration acting on the heavy objects. At 0.0415 s, the value of the tension of the hoisting rope of YH25 wave compensation hoist without the control algorithm is only 2875 N, which is far from the preset value *F*_{2} of the system. When the system tends to be stable, its value ranges from −1820 N to 1.173 × 10^{4} N. The hoisting rope of YH25 wave compensation hoist is subjected to the great alternating load.

Compared with the system without the control algorithm, the amplitude of the alternating load on the hoisting rope of the system based on the genetic PID algorithm is greatly reduced by 93.4%. Compared with the system based on the standard PID algorithm, the amplitude of the alternating load on the hoisting rope of the system based on the genetic PID algorithm is increased by 2.81%. However, its peak time and the maximum overshoot are reduced by 77.2% and 84.3%, respectively.

From Figures 14 and 17, it is known that the simulation result of the wave compensation system based on the genetic PID algorithm is basically consistent with the experimental result of the wave compensation system based on the genetic PID algorithm. The simulation avoids the influence of the external interference signals, while the experiment is easily affected by the external interference signals. It results in certain differences between the simulation result and the experimental result. It is concluded that the transfer function of the wave compensation system is accurate, and the genetic PID control strategy is correct and feasible.

#### 7. Conclusions

(1)The transfer function of the wave compensation system is deduced, and the interference signal acting on the system is eliminated by the feed-forward compensation correction method. The pole assignment of the system of the feed-forward compensation correction is carried out, the anti-interference ability and the robustness of the system are greatly improved. However, the fast responsiveness of the system is worse than that of the system without the pole assignment. Therefore, the genetic PID algorithm is proposed to enhance the fast responsiveness of the system after the pole assignment.(2)The genetic PID controller is designed, the control block diagram of the system based on the genetic PID algorithm is established, and the crossover and mutation operators of the genetic particle swarm optimization algorithm are used to optimize the optimal index and PID parameters. The method is applied to the system after the pole assignment, which improves the fast responsiveness of the system and maintains the stability and the accuracy of the system.(3)The genetic PID algorithm is carried out on the experimental platform of YH25 wave compensation hoist, and good control effect is obtained. It is proved that the transfer function of the wave compensation system is accurate and the genetic PID control strategy is correct and feasible.

#### Data Availability

The data used to support the findings of this study are included within the article.

#### Conflicts of Interest

The authors declare that there are no conflicts of interest regarding the publication of this paper.

#### Acknowledgments

This work was supported by the Chaohu University School-Level Key Discipline Project (Pattern Recognition and Intelligent System and no. ZDXK-201814) and Chaohu University School-Level Industry-University-Research Project (Study on Control Characteristics of Wave Compensator and no. XLY-201707).