# Disturbance Observer-Based Discrete Sliding-Mode Control for a Marine Diesel Engine with Variable Sampling Control Technique

Authors: Xuemin Li; Yufei Liu; Haoyu Shu; Runzhi Wang; Yunlong Yang; Chunyue Feng
Journal: Journal of Control Science and Engineering
 (2020)

---

## Abstract

This paper proposes a disturbance observer-based discrete sliding-mode control scheme with the variable sampling rate control for the marine diesel engine speed control in the presence of system uncertainties and disturbances. Initially, a sliding-mode controller based on the fast power reaching law is employed, which has a good dynamic quality of the arrival stage and can suppress chattering. To satisfy the practical requirements in the digital controller and the crank angle-based fuel injection in engine speed control, the proposed method is discretized under the variable sampling rate condition. A disturbance observer based on the second-order sliding-mode control is designed to compensate the system uncertainties and disturbances, by doing such the requirement of the parameters of the sliding-mode controller to be reduced significantly. In addition, a cylinder-by-cylinder mean value engine model (MVEM) is built by restructuring the combustion torque model, based on which numerical simulations are carried out by comparing the proposed method with PID and the extended state observer (ESO)-based sliding mode controllers. The common operation situations of the marine diesel engines are taken into account, including starting process, acceleration and deceleration, load variation, and varied propulsion system parameters. The results demonstrate that the proposed disturbance observer-based sliding-mode controller has prominent control performance and strong robustness.


---

## Body

## 1. Introduction

In the ship domain, diesel engines have been widely used as marine main engines for propulsion [1]. These engines are usually controlled to work at the specified rotating speed to keep the ship sailing at the appropriate speed, although this adds unknown load disturbances to the main engines [2]. The speed fluctuation and overshoot will cause harm to the whole propulsion system and even paralyze the entire system. Hence, for ship propulsion, good speed control performance of the marine main engines must be guaranteed even in the face of the strong nonlinearity in diesel engines and harsh marine environments. In addition, the emergence of new technologies in recent years also presents new challenges for speed control. Some new techniques greatly introduce additional dynamic nonlinearity for diesel engines, and some put forward higher requirements for speed control [3]. Therefore, it is necessary to design an accurate and robust speed controller for marine diesel engines.Since the implementation of electronic-controlled fuel control system, proportion-integration-differentiation (PID) has always been the most widely used algorithm for the speed control of diesel engines because of its simplicity and reliability [4]. Nevertheless, the PID controller can hardly maintain good control performance in all working conditions for the nonlinear system [5]. To overcome such problem, the PID controller is often studied to combine with other algorithms, such as fuzzy logic control [5], genetic algorithm [6], H∞ algorithm [7], and model predictive control (MPC) [8]. These composite algorithms improve the control performance by optimizing the PID parameters in real time. Meanwhile, some scholars try to use some other control methods to replace PID. The active disturbance rejection control (ADRC) is introduced to improve the performance of marine main engine under complex operating conditions in [9–11]. Ouladsine et al. established a neural controller with pollution constraints which realizes the multivariable control of engine speed and emission [12]. Sliding-mode control (SMC), known as a robust control method [13–15], also has been studied in engine speed control. A simple SMC is designed by Zhang for speed control of generators, but the control performance is not satisfactory [16]. Yuan and his collaborators propose discrete sliding-mode variable structure control in the literature [17] and verify the control performance for diesel engine through simulation and experiment, and the results show that its control effect is better than the traditional PID. Afterwards, multisliding surface control is proposed in his literature [18], and different sliding surfaces are selected in the acceleration and steady-state conditions to achieve better control performance in the various working conditions of the marine diesel engine. However, both of these methods rely on the accurate model. However, it should be noted that the simplified and accurate diesel engine model is hard to build, which severely limits the use of these controllers. In [19], the diesel engine model is approximated by the RBF neural network, based on which a sliding-mode controller is developed. Khan [19] and Li [18] use the supertwisting scheme to control engine speed, where the accurate diesel engine model is no longer required but with the sacrifice of robustness.It is well known that the traditional SMC requires the switching gain larger than the total disturbance, which sacrifices its control performance. Meanwhile, the chattering problem is hard to avoid [20]. Faced with this situation, one way is used to compensate the system disturbance by means of the disturbance observer. By doing such, the switch gain is only required to be larger than the estimated disturbance error rather than the total disturbance. On the basis of such idea, Wei proposes a controller via combining the disturbance observer and terminal SMC for a class of multiple-input-multiple-output continuous nonlinear systems subject to disturbances [21]. In [22], a disturbance observer-based SMC is designed for a class of fractional-order nonlinear systems. By combining the disturbance observer with SMC for the staring-mode spacecraft, the stability of the spacecraft platform is improved and the chattering is reduced [23]. Motived by the statements above, in this study, the disturbance observer-based SMC is employed to regulate the marine diesel engine speed.There is another issue should be considered in engine speed control, although the output speed of the diesel engine is continuous, its working process is not continuous with inherent event-triggered property [11, 24–26], making the output of the controller can only be executed once per cylinder per cycle. For this reason, the disturbance observer-based SMC employed in this paper should be discrete. To avoid the chatting phenomena caused by high-frequency switching, the fast power reaching law is adopted by referring to [27]. The disturbance observer is structured based on a second-order sliding-mode algorithm which can significantly reduce the chattering in the discrete system. Considering that the controller output can only be executed at a fixed segment on the crank-angle domain, variable sampling rate control is adopted instead of traditional timing control, which guarantees that the controller calculates once per working cycle for each cylinder at any engine speed (refer to [11] and the references therein for more details). In addition, a cylinder-by-cylinder mean value engine model (MVEM) is built for the validation of the proposed controller. Compared with the conventional MVEM, the adopted engine model is closer to the actual diesel engine, making the verification of the control algorithm more practical and reasonable.The rest of the paper is organized as follows. First, the cylinder-by-cylinder MVEM is introduced. Then, a simplified discrete mathematical model of the diesel engine is described, based on which a discrete sliding-mode controller and a sliding-mode disturbance observer are designed. After that, based on the proposed cylinder-by-cylinder MVEM, simulation verification is carried out with vast comparative results to demonstrate the superior control performance of the proposed method. Finally, the conclusion about the whole work is summarized, and further research of this paper is discussed.


## 2. Cylinder-by-Cylinder Mean Value Model of Marine Diesel Engine

Diesel engine is a complicated system with thermodynamic system, hydraulic system, electronic system, rotary and reciprocation machinery system, etc. Hence, it is difficult to establish an accurate mathematical model. As a compromise, MVEMs composed with primary empirical formula are widely used in correlation control research because of their easier implementation and higher calculating speed compared with detailed models [28]. Besides, it is very convenient to analyse the whole system and design qualified controllers with its intuitive system equations. However, as mentioned above, the actual working process of the diesel engine is periodic and cylinder-by-cylinder, while the traditional MVEMs only consider the average effect of the periodic work. For a four-stroke diesel engine, its working process includes the following features:(1)
The working process is cylinder-by-cylinder(2)
Each cylinder completes a cycle every two revolutions, including the suction stroke, the compression stroke, the power stroke, and the exhaust stroke(3)
The control input, i.e., fuel injection quantity per cylinder per cycle, produces output only after a cylinder has completed its power strokeIt can be seen that no matter for the individual cylinder or the whole diesel engine, the working process is discontinuous. Therefore, although the study of continuous control algorithm based on continuous MVEMs can realise the rigorous theoretical analysis, there are still some differences with the actual control of diesel engine. To improve the situation, a cylinder-by-cylinder MVEM of a marine diesel engine is presented in this study, which can reflect the practical working characteristics mentioned above. This cylinder-by-cylinder engine model is based on the MVEM with the remodel of the combustion torque model which is the most critical part of the diesel engine model. Figure1 shows the main structure of the developed model.Figure 1
Structure of the marine diesel engine in a ship.


### 2.1. Mean Value Engine Model

As shown in Figure1, the engine model is mainly composed of the engine body (cylinders, crankshaft, etc.), turbocharger (turbine and compressor), exhaust manifold, and intake manifold. Except for the indicated torque in the engine body, the rest parts are modelled according to the empirical formula as MVEMs.The main function of a diesel engine is to output the effective torqueMe through the crankshaft and then drive the load rotation. Here, the loads are the gearbox, the spindle system, and its connected propeller. For the sake of analysis, assume that there is only one propeller and that the gear box has a reduction ratio of 1. Thus, the rotational dynamics of the total propulsion system including the diesel engine and the loads can be given as(1)dnedt=30πJMi−Mp−Mf−Ml,where ne is the engine speed, i.e., the rotation speed of crankshaft, J is the total rotational inertia of the moving parts of the propulsion system, Mf is the total frictional loss torque, Ml is the load torque, and Mi and Mp denote the total indicated torque and the total pump loss torque for all cylinders, respectively.For MVEMs,Mi and Mp are usually calculated by empirical formulas:(2)Mi=mfqHVηiN4π,(3)Mp=Vd4πPem−Pim,where mf is the fuel injection quantity per cylinder per cycle, qHV is the fuel low calorific value, ηi is the gross indicated efficiency, N is the number of cylinders, Vd is the total displacement of the engine, and Pim and Pem, respectively, denote the pressure in intake manifold and exhaust manifold. One can see that only cyclic averages are obtained. In this paper, they are simulated via the cylinder-by-cylinder combustion torque model which will be described in the next subsection.When a diesel engine runs, friction loss is caused by all moving parts, especially crankshaft and pistons. It is generally believed that these losses are mainly related to engine speed. Here, the frictional loss torqueMf is assumed to be a quadratic polynomial of engine speed as follows [29]:(4)Mf=Vd4πkf1ne2+kf2ne+kf3,where kf1, kf2, and kf3 are the experimental coefficients.Ignoring the relatively small friction loss of the gearbox and the spindle system, the load torqueMl is considered to be mainly from the propeller torque which can be approximated by(5)Ml=klne2,where kl is a coefficient depending on the propeller torque coefficient KM, the density of water ρw, and the propeller diameter Dp. The relationship between them can be described by as kl=KMρwDp5 [30]. For a propeller, Dp is invariable, but KM varies with the advance coefficient and propeller pitch. So, KM is also varying. Here, two form variations will be taken into account during controller validation as follows.Remark 1.
As equation (2) shows, the gross indicated efficiency is an important index for diesel engines. Meanwhile, it is affected by many factors among which the excess air coefficient α and engine speed ne are the most important. Referring to [31], it can be described as(6)ηi=a1ne2+a2ne+a3×1−a4αa5,where a1,a2,…,a5 are coefficients. If an accurate indicated torque is desired, the excess air coefficient is also needed to be accurately modelled. For this purpose, the turbocharger model, exhaust manifold model, and intake manifold model should be considered well. The air mass flow into the cylinders is calculated according to the air pressure and temperature in the intake manifold and the volumetric efficiency which is a function of the pressure and the engine speed [29]. The turbocharger model mainly provides boundary conditions and inlet gas flow to the intake manifold. The exhaust manifold model determines the rotation speed and working state of the turbocharger. For simplicity, the detailed modelling approach is not described here and more details are available in [32].


### 2.2. Cylinder-by-Cylinder Combustion Torque Model

As mentioned above, only averages ofMi and Mp are calculated by empirical formulas for MVEMs. It is essential that the torque applied to the crankshaft by the cylinder pressure should be through the crank link mechanism. The force diagram of a single crank link mechanism is shown in Figure 2.Figure 2
The force diagram of a single crank link mechanism.From the figure, the following relationship formulas can be obtained:(7)lsinϕ=rsinθ,Fθ=π4d2Pθ,Fcθ=Fθcosϕ,Ftθ=Fcθsinϕ+θ,where l is the connecting rod length, r is the crank arm length, and d is the piston diameter. It should be noted that ϕ denotes the tilt angle of the connecting rod and θ denotes the angle at which the crankshaft rotates from the top-dead-center (TDC). Meanwhile, it is supposed that ∈−90°,90° , θ∈0°,720°, and θ=360° mean that the crankshaft is at the TDC of the compression phase. According to equation (7), the torque produced by a certain cylinder on the crankshaft can be obtained by(8)Mcylθ=Ftθr=πsinϕ+θ4cosϕrd2Pθ.The model of the cylinder pressurePθ is the core of the cylinder-by-cylinder engine model. According to the working process of the individual cylinder, it is divided into three stages to simulate for a working cycle. The first stage is the working stage, where only the intake valve is open. The second stage is the most complex stage, where both the intake and exhaust valves are closed. The third stage refers to the working stage where only the intake valve is open. In the first and third stages, Pθ is considered to be approached to the pressure in the intake manifold model and exhaust manifold model, respectively. The second stage includes the compression phase and the power phase, and the cylinder pressure can be treated as the interpolation of that in two ideal processes, namely, the pure compression process and ideal combustion process.The pure compression process refers to the second stage process with no fuel supply, and the cylinder pressure can be measured by the motoring test method. For simulation, it can be regarded as a polytropic process. The pressurePc and temperature Tc can be given as(9)Pcθ=PivcVincVθkc,(10)Tcθ=TivcVincVθkc−1,where Pivc, Tivc, and Vinc, respectively, represent the cylinder pressure, temperature, and volume at the intake valve closing, Vθ denotes the instantaneous volume of the cylinder, and kc is the polytropic exponent.The ideal combustion process refers to the second stage process with a negligible time from the start of combustion to the end of combustion. Before combustion, the pressure and temperature of this ideal process are the same as the pure compression process, and after combustion, they can be modelled as another polytropic process as follows:(11)Peθ=P¯eocV¯eocVθke,(12)Teθ=T¯eocV¯eocVθke−1,where ke is the polytropic exponent and P¯eos, T¯eos, and V¯eos denote the cylinder pressure, temperature, and volume of the ideal combustion process at the end of combustion, respectively. According to the description, the combustion process can be regarded as a constant volume combustion, and the T¯eoc and P¯eoc are determined by(13)T¯eoc=Tcθsoc+mfqHVηfcvmf+mei,(14)P¯eoc=PcθsocT¯eocTcθsoc,where θsoc denotes the θ at the start of combustion, cv is the specific heat at constant volume of mixture in the cylinder. And it is important to note that mf keeps the value at the start of combustion during the whole second stage and is updated only once in the next cycle. ηf is the fuel conversion efficiency, and it is considered to be proportional to the gross indicated efficiency ηi of the MVEM. That is,(15)ηf=kfηi.The pressure ratio proposed by Matekunas is defined as [33](16)PRθ=PθPcθ−1.Eriksson has found that the pressure ratio curve is similar to the proportion of fuel already burned [27]. If maxPRθ represents the pressure ratio when it has completely combusted at θ, which can be given as(17)PRθmaxPRθ=ηmθ,where ηm is the percentage of fuel that has been burned which can be described by the well-known Vibe function. According to the ideal combustion process, one can get(18)maxPRθ=PeθPcθ−1.Combining equations (16)–(18), it yields to(19)Pθ=1−ηmθPcθ+ηmθPeθ.As known,ηmθ=0 until the start of combustion and ηmθ=1 since the end of combustion, which leads to Pθ=Pcθ and Pθ=Peθ, respectively [34].In summary, the cylinder pressure of a working cycle can be described as(20)Pθ=Pimθ,θevc<θ<θivc,1−ηmθPcθ+ηmθPeθ,θivc<θ<θevo,Pemθ,θevo<θ<θivo.For the blowdown phase and the transitions between these three stages, the pressure can be calculated by interpolation using a cosine function.Above all, for a six-cylinder diesel engine, the total torqueMtotθ generated by the cylinders can be obtained as(21)Mtotθ=∑j=16πsinϕj+θj4cosϕjrd2Pjθj.Combined with equation (21), one can see the Mi−Mp in MVEMs is the cyclic average of Mtotθ. Therefore, the rotational dynamics (1) can be rewritten as(22)dnedt=30πJMtotθ−Mf−Ml.Thus, together with other parts of the original MVEM, the new cylinder-by-cylinder MVEM is formed. Some simulation results of this model are presented in Figures3 and 4.Figure 3
The trajectories ofPe, Pc, and P for one cycle of a cylinder.Figure 4
The speed responses of the original MVEM and the new cylinder-by-cylinder MVEM with the same fuel injection input. (a) The speed responses. (b) The fuel injection quantity.
(a)(b)The cylinder pressureP based on equation (19) is shown in Figure 3, and the three stages described above can be observed. This cylinder pressure produces cyclical fluctuation for the engine speed as shown in Figure 4, which cannot be given by the MVEMs. Moreover, by choosing the appropriate coefficient in equation (15), the speed responses are also similar except for the cyclic fluctuation when the fuel injection of the two models is the same. As can be seen from the acceleration at 3 s, the cylinder-by-cylinder model does not respond to the change of the fuel injection until the next cycle. This also causes the delay in the acceleration process. All these make the model closer to the actual working process of the diesel engine.Remark 2.
It should be noted that the original MVEM is borrowed from the work [32], which has been verified by extensive experiments. Hence, as shown in Figure 4, the mean effect of engine speed in the proposed engine model is almost the same as that in the original MVEM, which can be regarded as the verification of the proposed engine model.


## 2.1. Mean Value Engine Model

As shown in Figure1, the engine model is mainly composed of the engine body (cylinders, crankshaft, etc.), turbocharger (turbine and compressor), exhaust manifold, and intake manifold. Except for the indicated torque in the engine body, the rest parts are modelled according to the empirical formula as MVEMs.The main function of a diesel engine is to output the effective torqueMe through the crankshaft and then drive the load rotation. Here, the loads are the gearbox, the spindle system, and its connected propeller. For the sake of analysis, assume that there is only one propeller and that the gear box has a reduction ratio of 1. Thus, the rotational dynamics of the total propulsion system including the diesel engine and the loads can be given as(1)dnedt=30πJMi−Mp−Mf−Ml,where ne is the engine speed, i.e., the rotation speed of crankshaft, J is the total rotational inertia of the moving parts of the propulsion system, Mf is the total frictional loss torque, Ml is the load torque, and Mi and Mp denote the total indicated torque and the total pump loss torque for all cylinders, respectively.For MVEMs,Mi and Mp are usually calculated by empirical formulas:(2)Mi=mfqHVηiN4π,(3)Mp=Vd4πPem−Pim,where mf is the fuel injection quantity per cylinder per cycle, qHV is the fuel low calorific value, ηi is the gross indicated efficiency, N is the number of cylinders, Vd is the total displacement of the engine, and Pim and Pem, respectively, denote the pressure in intake manifold and exhaust manifold. One can see that only cyclic averages are obtained. In this paper, they are simulated via the cylinder-by-cylinder combustion torque model which will be described in the next subsection.When a diesel engine runs, friction loss is caused by all moving parts, especially crankshaft and pistons. It is generally believed that these losses are mainly related to engine speed. Here, the frictional loss torqueMf is assumed to be a quadratic polynomial of engine speed as follows [29]:(4)Mf=Vd4πkf1ne2+kf2ne+kf3,where kf1, kf2, and kf3 are the experimental coefficients.Ignoring the relatively small friction loss of the gearbox and the spindle system, the load torqueMl is considered to be mainly from the propeller torque which can be approximated by(5)Ml=klne2,where kl is a coefficient depending on the propeller torque coefficient KM, the density of water ρw, and the propeller diameter Dp. The relationship between them can be described by as kl=KMρwDp5 [30]. For a propeller, Dp is invariable, but KM varies with the advance coefficient and propeller pitch. So, KM is also varying. Here, two form variations will be taken into account during controller validation as follows.Remark 1.
As equation (2) shows, the gross indicated efficiency is an important index for diesel engines. Meanwhile, it is affected by many factors among which the excess air coefficient α and engine speed ne are the most important. Referring to [31], it can be described as(6)ηi=a1ne2+a2ne+a3×1−a4αa5,where a1,a2,…,a5 are coefficients. If an accurate indicated torque is desired, the excess air coefficient is also needed to be accurately modelled. For this purpose, the turbocharger model, exhaust manifold model, and intake manifold model should be considered well. The air mass flow into the cylinders is calculated according to the air pressure and temperature in the intake manifold and the volumetric efficiency which is a function of the pressure and the engine speed [29]. The turbocharger model mainly provides boundary conditions and inlet gas flow to the intake manifold. The exhaust manifold model determines the rotation speed and working state of the turbocharger. For simplicity, the detailed modelling approach is not described here and more details are available in [32].


## 2.2. Cylinder-by-Cylinder Combustion Torque Model

As mentioned above, only averages ofMi and Mp are calculated by empirical formulas for MVEMs. It is essential that the torque applied to the crankshaft by the cylinder pressure should be through the crank link mechanism. The force diagram of a single crank link mechanism is shown in Figure 2.Figure 2
The force diagram of a single crank link mechanism.From the figure, the following relationship formulas can be obtained:(7)lsinϕ=rsinθ,Fθ=π4d2Pθ,Fcθ=Fθcosϕ,Ftθ=Fcθsinϕ+θ,where l is the connecting rod length, r is the crank arm length, and d is the piston diameter. It should be noted that ϕ denotes the tilt angle of the connecting rod and θ denotes the angle at which the crankshaft rotates from the top-dead-center (TDC). Meanwhile, it is supposed that ∈−90°,90° , θ∈0°,720°, and θ=360° mean that the crankshaft is at the TDC of the compression phase. According to equation (7), the torque produced by a certain cylinder on the crankshaft can be obtained by(8)Mcylθ=Ftθr=πsinϕ+θ4cosϕrd2Pθ.The model of the cylinder pressurePθ is the core of the cylinder-by-cylinder engine model. According to the working process of the individual cylinder, it is divided into three stages to simulate for a working cycle. The first stage is the working stage, where only the intake valve is open. The second stage is the most complex stage, where both the intake and exhaust valves are closed. The third stage refers to the working stage where only the intake valve is open. In the first and third stages, Pθ is considered to be approached to the pressure in the intake manifold model and exhaust manifold model, respectively. The second stage includes the compression phase and the power phase, and the cylinder pressure can be treated as the interpolation of that in two ideal processes, namely, the pure compression process and ideal combustion process.The pure compression process refers to the second stage process with no fuel supply, and the cylinder pressure can be measured by the motoring test method. For simulation, it can be regarded as a polytropic process. The pressurePc and temperature Tc can be given as(9)Pcθ=PivcVincVθkc,(10)Tcθ=TivcVincVθkc−1,where Pivc, Tivc, and Vinc, respectively, represent the cylinder pressure, temperature, and volume at the intake valve closing, Vθ denotes the instantaneous volume of the cylinder, and kc is the polytropic exponent.The ideal combustion process refers to the second stage process with a negligible time from the start of combustion to the end of combustion. Before combustion, the pressure and temperature of this ideal process are the same as the pure compression process, and after combustion, they can be modelled as another polytropic process as follows:(11)Peθ=P¯eocV¯eocVθke,(12)Teθ=T¯eocV¯eocVθke−1,where ke is the polytropic exponent and P¯eos, T¯eos, and V¯eos denote the cylinder pressure, temperature, and volume of the ideal combustion process at the end of combustion, respectively. According to the description, the combustion process can be regarded as a constant volume combustion, and the T¯eoc and P¯eoc are determined by(13)T¯eoc=Tcθsoc+mfqHVηfcvmf+mei,(14)P¯eoc=PcθsocT¯eocTcθsoc,where θsoc denotes the θ at the start of combustion, cv is the specific heat at constant volume of mixture in the cylinder. And it is important to note that mf keeps the value at the start of combustion during the whole second stage and is updated only once in the next cycle. ηf is the fuel conversion efficiency, and it is considered to be proportional to the gross indicated efficiency ηi of the MVEM. That is,(15)ηf=kfηi.The pressure ratio proposed by Matekunas is defined as [33](16)PRθ=PθPcθ−1.Eriksson has found that the pressure ratio curve is similar to the proportion of fuel already burned [27]. If maxPRθ represents the pressure ratio when it has completely combusted at θ, which can be given as(17)PRθmaxPRθ=ηmθ,where ηm is the percentage of fuel that has been burned which can be described by the well-known Vibe function. According to the ideal combustion process, one can get(18)maxPRθ=PeθPcθ−1.Combining equations (16)–(18), it yields to(19)Pθ=1−ηmθPcθ+ηmθPeθ.As known,ηmθ=0 until the start of combustion and ηmθ=1 since the end of combustion, which leads to Pθ=Pcθ and Pθ=Peθ, respectively [34].In summary, the cylinder pressure of a working cycle can be described as(20)Pθ=Pimθ,θevc<θ<θivc,1−ηmθPcθ+ηmθPeθ,θivc<θ<θevo,Pemθ,θevo<θ<θivo.For the blowdown phase and the transitions between these three stages, the pressure can be calculated by interpolation using a cosine function.Above all, for a six-cylinder diesel engine, the total torqueMtotθ generated by the cylinders can be obtained as(21)Mtotθ=∑j=16πsinϕj+θj4cosϕjrd2Pjθj.Combined with equation (21), one can see the Mi−Mp in MVEMs is the cyclic average of Mtotθ. Therefore, the rotational dynamics (1) can be rewritten as(22)dnedt=30πJMtotθ−Mf−Ml.Thus, together with other parts of the original MVEM, the new cylinder-by-cylinder MVEM is formed. Some simulation results of this model are presented in Figures3 and 4.Figure 3
The trajectories ofPe, Pc, and P for one cycle of a cylinder.Figure 4
The speed responses of the original MVEM and the new cylinder-by-cylinder MVEM with the same fuel injection input. (a) The speed responses. (b) The fuel injection quantity.
(a)(b)The cylinder pressureP based on equation (19) is shown in Figure 3, and the three stages described above can be observed. This cylinder pressure produces cyclical fluctuation for the engine speed as shown in Figure 4, which cannot be given by the MVEMs. Moreover, by choosing the appropriate coefficient in equation (15), the speed responses are also similar except for the cyclic fluctuation when the fuel injection of the two models is the same. As can be seen from the acceleration at 3 s, the cylinder-by-cylinder model does not respond to the change of the fuel injection until the next cycle. This also causes the delay in the acceleration process. All these make the model closer to the actual working process of the diesel engine.Remark 2.
It should be noted that the original MVEM is borrowed from the work [32], which has been verified by extensive experiments. Hence, as shown in Figure 4, the mean effect of engine speed in the proposed engine model is almost the same as that in the original MVEM, which can be regarded as the verification of the proposed engine model.


## 3. Disturbance Observer-Based Discrete Sliding-Mode Controller

It can be seen from the model description that the diesel engine is a discontinuous system, and the control input will only be valid after the current working cylinder completes the power stroke. Thus, the general used constant sampling rate control will have problems; hence, a variable sampling rate control is employed in this study. The controller calculates only at a few fixed crank angles, which means that the sampling interval varies with the engine speed. Therefore, in this section, the control problem is simplified and discretized with the variable sampling control theory, based on which the controller and observer are designed.


### 3.1. Control Problem Simplification

Although the cylinder-by-cylinder model is closer to the reality engine, it is not convenient for the design of the controller. On the contrary, the MVEM is not realistic but simple in form, which can be regarded as a simplification of the controlled object. According to equations (1), (2), (4), and (5), the control problem equation can be described as(23)dnedt=fne+gtmf−30πJMp,where(24)fne=−30πJMf+Ml,(25)gt=15qLHVNcylηiπ2NstJ.Obviously,gt is not accurate and difficult to obtain for the actual diesel engine or cylinder-by-cylinder model. However, its variation range is limited, so it is regarded as a known constant g0 with some unknown deviations. For the actual situation, both Mf and Ml can be measured experimentally, but there is always some offset. Besides, both of them have all kinds of interference in practical work, especially Ml is strongly affected by the complex marine environment. As a result, some parts of f are also unknown and unmodelable. Assume that Mp is also unknown and treat all these unknown parts as unknown disturbance Dt, given state variable x=ne, and control input u=mf, and equation (23) can be rewritten as(26)x˙=f0x+g0u+Dt,where f0 is the known part of f and Dt=fx−f0x+gtu−g0u−30/πJMp.Equation (26) can be discretized with a variable sampling interval as follows:(27)xk+1=xk+hkf0xk+g0uk+Dk,where hk is the variable sampling interval which is related to the engine speed. This function can be regarded as a simplified discrete mathematical model of the diesel engine and the control problem equation when designing the controller in the below section.


### 3.2. Discrete Sliding-Mode Controller

Most sliding-mode algorithms achieve their control objectives and maintain good robustness by fast switching, resulting in chattering often, especially when the control frequency is not fast enough. The control frequency of a diesel engine is variable and limited by the number of cylinders and the engine speed. Therefore, a suitable sliding-mode controller is needed to suppress chattering. In this study, a sliding-mode controller based on the reaching law proposed in [35] is used for the speed control of a diesel engine. The fast power reaching law is selected, which is helpful to improve the dynamic quality of the arrival stage and suppress chattering [36]. It can be described as(28)s˙=−k1sγsigns−k2s,where the coefficient k1,k2>0 and γ∈0,1. When the initial value s0≠0, the solution of this first-order nonlinear equation can be expressed as(29)s=signs0e−k2ts01−γ+k1k2−k1k2e1−αk2t1/1−γ,t<ln1+k1/k2s01−γk21−α,0,t>ln1+k1/k2s01−γk21−α,which shows that equation (28) converges in finite time.Considering the variable sampling rate control of the diesel engine, equation (28) can be written in discrete form as(30)sk+1−skhk=−k1skγsignsk−k2sk.That is,(31)sk+1=sk1+hk−k1skγ−1−k2.Obviously,(32)sk>k1hk2−hkk21/1−γ,k2<2maxhkis required to ensure the convergence of equation (30). Therefore, the convergence accuracy of the equation in discrete form is k1hk/2−hkk21/1−γ. It can be seen that the smaller coefficients are, the higher the steady-state convergence accuracy. However, it also reduces the transient control performance. This should be taken into account when selecting coefficients.For system 27, lets=x−xd, and its discrete time derivative can be obtained as(33)sk+1−skhk=xk+1−xkhk−xdk+1−xdkhk,where xd denotes the reference speed. Combining equations (27) and (30), it yields to(34)−k1skγsignsk−k2sk=f0xk+g0uk+Dk−xdk+1−xdkhk.Hence, the control law can be set to be(35)uk=g0−1−k1skγsignsk−k2sk+xdk+1−xdkhk−f0xk−Dk,where the disturbance Dk is unknown. If the disturbance is ignored in equation (35), the system equation becomes(36)sk+1−skhk=−k1skγsignsk−k2sk+Dk,the convergence domain of which depends on the bound of the disturbance. This can have serious adverse effects on control performance. Therefore, an SMDO is designed to compensate for it.


### 3.3. Sliding-Mode Disturbance Observer

TreatingD as an additional state variable z2 and assuming Dk+1=Dk+hkpk, the original first-order system can be described as a second-order system:(37)z1k+1=z1k+hkf0xk+g0uk+z2k,z2k+1=z2k+hkpk,where z1=x.The disturbance observer can be given as(38)z^1k+1=z^1k+hkf0xk+g0uk+z^2k+v1k,z^2k+1=z^2k+hkv2k,which is often used by scholars [37–40]. v1k and v2k are the items that need to be designed.Define observation errore1=z^1−z1,e2=z^2−z2. Considering equations (37) and (38), an error system can be obtained as(39)e1k+1=e1k+hke2k+v1k,e2k+1=e2k+hk−pk+v2k.Therefore, the design of disturbance observer becomes designv1 and v2 to make the error system converge. If v2k=0, z^2==0 and the observer 29 becomes a first-order system. Only v1k needs to be designed so that e1 converges to zero and v1⟶D, as in [40]. However, many scholars usually design both v1 and v2, e.g., the extended state observer (ESO) proposed by Han [37], the nonlinear disturbance observer in [39], and the linear observer with ω0-optimization [38]. The purpose of all these observers is to achieve e1⟶0 and e2⟶0, which is the same as a second-order sliding-mode controller (SOSMC). There are designs and analysis of second-order sliding modes for continuous systems, such as twisting algorithm, suboptimal algorithm, and supertwisting algorithm [41, 42]. However, high control frequency is often required in these algorithms to ensure their control performance and robustness. In this study, the SOSMC controller described in Theorem 1 and the similar controller for discrete control are considered as follows.Theorem 1 (see [43]).
Considering the second-order system,(40)x˙1=x2,x˙2=ωt+u.Suppose there arec1>0 and r1>0 such that the disturbance ωt<1−1/c12r1 and the variable structure control law(41)u=−r1signx1+c1x2c1x22r1,can suppress the disturbance and make system (40) reach the origin after switching at most once in finite time.Like many sliding-mode controllers, it is difficult to switch accurately on the sliding-mode surfacex1+c1x2c1x2/2r1=0 when used for discrete control， which easily causes chattering. To overcome the problem, a similar control law for discrete control is proposed based on the principle of control law (41) by Han [29]. It is defined as(42)u=fhanx1,cx2,r0,h0,d=r0h0,d0=h0d,y=x1+h0cx2,a0=d2+8r0y,a=cx2+a0−d2signy,y>d0,cx2+yh0,y≤d0,fhanx1,cx2,r0,h0=−r0signa,a>d,r0ad,a≤d,where r0, c, and h0 are coefficients corresponding to the r1 and c1 in control law (41) and the sampling step h of the discrete system, respectively. The two control laws converge system (28) in an almost-uniform trajectory, if the step size is small enough and r0=r1, c=c1, and h0=h.Figure5 gives the phase trajectories and the convergence trajectories of these two controllers where the corresponding parameters are the same except for h0. The phase trajectory A shows the second-order sliding-mode characteristics of controller (41). However, it can be seen from phase trajectory B and convergence trajectory B that the control performance becomes worse and chattering occurs easily when the control law is discontinuous. Meanwhile, controller (42) can still guarantee good control performance except for the smaller fluctuation due to discrete calculation. This fluctuation can also be weakened by appropriately increasing h0, and the convergence rate will be slower as a cost as convergence trajectory D shows.According to the above description, controllers (41) and (42) can be used for continuous and discrete observer design, respectively. In this paper, the observer is proposed as(43)z^1k+1=z^1k+hkf0xk+g0uk+z^2k,z^2k+1=z^2k+hk−λe2k+fhane1k,ce2k,r0,khhk,where kh is a coefficient so that h0 will change with the calculated step hk. In order to reduce the overshoot and steady-state fluctuation, a part of the convergence rate needs to be sacrificed when selecting the parameters of fhan. Here, −λe2k is introduced to improve the convergence rate. The error system can be rewritten as(44)e1k+1=e1k+hke2k,e2k+1=e2k+hk−pk−λe2k+fhane1k,ce2k,r0,khhk.The−pk−λe2k can be taken as a new disturbance, and it is bounded in diesel engine systems. According to Theorem 1, there are parameters of fhan⋅ to make error system (44) converge in finite time.In conclusion, based on this sliding-mode disturbance observer (SMDO), the designed discrete sliding-mode controller (DSMC) can be described as(45)k1skγsignsk−k2sk+xdk+1−xdkhk−f0xk−z^2k.Combing with system function (27), it yields to(46)sk+1−skhk=−k1skγsignsk−k2sk−e2k.Comparing with equation (36) shows that the convergence accuracy will be improved if e2k<D which is guaranteed by the SMDO.Figure 5
Comparison of control performance between control laws (41) and (42) under different conditions, i.e., (A) continuous control with control law 41, (B) timing control with control law (41), (C) timing control with control law (42) and h0=h, and (D) timing control with control law (42) and h0=2h. (a) Phase trajectories. (b) Convergence trajectories.
(a)(b)


## 3.1. Control Problem Simplification

Although the cylinder-by-cylinder model is closer to the reality engine, it is not convenient for the design of the controller. On the contrary, the MVEM is not realistic but simple in form, which can be regarded as a simplification of the controlled object. According to equations (1), (2), (4), and (5), the control problem equation can be described as(23)dnedt=fne+gtmf−30πJMp,where(24)fne=−30πJMf+Ml,(25)gt=15qLHVNcylηiπ2NstJ.Obviously,gt is not accurate and difficult to obtain for the actual diesel engine or cylinder-by-cylinder model. However, its variation range is limited, so it is regarded as a known constant g0 with some unknown deviations. For the actual situation, both Mf and Ml can be measured experimentally, but there is always some offset. Besides, both of them have all kinds of interference in practical work, especially Ml is strongly affected by the complex marine environment. As a result, some parts of f are also unknown and unmodelable. Assume that Mp is also unknown and treat all these unknown parts as unknown disturbance Dt, given state variable x=ne, and control input u=mf, and equation (23) can be rewritten as(26)x˙=f0x+g0u+Dt,where f0 is the known part of f and Dt=fx−f0x+gtu−g0u−30/πJMp.Equation (26) can be discretized with a variable sampling interval as follows:(27)xk+1=xk+hkf0xk+g0uk+Dk,where hk is the variable sampling interval which is related to the engine speed. This function can be regarded as a simplified discrete mathematical model of the diesel engine and the control problem equation when designing the controller in the below section.


## 3.2. Discrete Sliding-Mode Controller

Most sliding-mode algorithms achieve their control objectives and maintain good robustness by fast switching, resulting in chattering often, especially when the control frequency is not fast enough. The control frequency of a diesel engine is variable and limited by the number of cylinders and the engine speed. Therefore, a suitable sliding-mode controller is needed to suppress chattering. In this study, a sliding-mode controller based on the reaching law proposed in [35] is used for the speed control of a diesel engine. The fast power reaching law is selected, which is helpful to improve the dynamic quality of the arrival stage and suppress chattering [36]. It can be described as(28)s˙=−k1sγsigns−k2s,where the coefficient k1,k2>0 and γ∈0,1. When the initial value s0≠0, the solution of this first-order nonlinear equation can be expressed as(29)s=signs0e−k2ts01−γ+k1k2−k1k2e1−αk2t1/1−γ,t<ln1+k1/k2s01−γk21−α,0,t>ln1+k1/k2s01−γk21−α,which shows that equation (28) converges in finite time.Considering the variable sampling rate control of the diesel engine, equation (28) can be written in discrete form as(30)sk+1−skhk=−k1skγsignsk−k2sk.That is,(31)sk+1=sk1+hk−k1skγ−1−k2.Obviously,(32)sk>k1hk2−hkk21/1−γ,k2<2maxhkis required to ensure the convergence of equation (30). Therefore, the convergence accuracy of the equation in discrete form is k1hk/2−hkk21/1−γ. It can be seen that the smaller coefficients are, the higher the steady-state convergence accuracy. However, it also reduces the transient control performance. This should be taken into account when selecting coefficients.For system 27, lets=x−xd, and its discrete time derivative can be obtained as(33)sk+1−skhk=xk+1−xkhk−xdk+1−xdkhk,where xd denotes the reference speed. Combining equations (27) and (30), it yields to(34)−k1skγsignsk−k2sk=f0xk+g0uk+Dk−xdk+1−xdkhk.Hence, the control law can be set to be(35)uk=g0−1−k1skγsignsk−k2sk+xdk+1−xdkhk−f0xk−Dk,where the disturbance Dk is unknown. If the disturbance is ignored in equation (35), the system equation becomes(36)sk+1−skhk=−k1skγsignsk−k2sk+Dk,the convergence domain of which depends on the bound of the disturbance. This can have serious adverse effects on control performance. Therefore, an SMDO is designed to compensate for it.


## 3.3. Sliding-Mode Disturbance Observer

TreatingD as an additional state variable z2 and assuming Dk+1=Dk+hkpk, the original first-order system can be described as a second-order system:(37)z1k+1=z1k+hkf0xk+g0uk+z2k,z2k+1=z2k+hkpk,where z1=x.The disturbance observer can be given as(38)z^1k+1=z^1k+hkf0xk+g0uk+z^2k+v1k,z^2k+1=z^2k+hkv2k,which is often used by scholars [37–40]. v1k and v2k are the items that need to be designed.Define observation errore1=z^1−z1,e2=z^2−z2. Considering equations (37) and (38), an error system can be obtained as(39)e1k+1=e1k+hke2k+v1k,e2k+1=e2k+hk−pk+v2k.Therefore, the design of disturbance observer becomes designv1 and v2 to make the error system converge. If v2k=0, z^2==0 and the observer 29 becomes a first-order system. Only v1k needs to be designed so that e1 converges to zero and v1⟶D, as in [40]. However, many scholars usually design both v1 and v2, e.g., the extended state observer (ESO) proposed by Han [37], the nonlinear disturbance observer in [39], and the linear observer with ω0-optimization [38]. The purpose of all these observers is to achieve e1⟶0 and e2⟶0, which is the same as a second-order sliding-mode controller (SOSMC). There are designs and analysis of second-order sliding modes for continuous systems, such as twisting algorithm, suboptimal algorithm, and supertwisting algorithm [41, 42]. However, high control frequency is often required in these algorithms to ensure their control performance and robustness. In this study, the SOSMC controller described in Theorem 1 and the similar controller for discrete control are considered as follows.Theorem 1 (see [43]).
Considering the second-order system,(40)x˙1=x2,x˙2=ωt+u.Suppose there arec1>0 and r1>0 such that the disturbance ωt<1−1/c12r1 and the variable structure control law(41)u=−r1signx1+c1x2c1x22r1,can suppress the disturbance and make system (40) reach the origin after switching at most once in finite time.Like many sliding-mode controllers, it is difficult to switch accurately on the sliding-mode surfacex1+c1x2c1x2/2r1=0 when used for discrete control， which easily causes chattering. To overcome the problem, a similar control law for discrete control is proposed based on the principle of control law (41) by Han [29]. It is defined as(42)u=fhanx1,cx2,r0,h0,d=r0h0,d0=h0d,y=x1+h0cx2,a0=d2+8r0y,a=cx2+a0−d2signy,y>d0,cx2+yh0,y≤d0,fhanx1,cx2,r0,h0=−r0signa,a>d,r0ad,a≤d,where r0, c, and h0 are coefficients corresponding to the r1 and c1 in control law (41) and the sampling step h of the discrete system, respectively. The two control laws converge system (28) in an almost-uniform trajectory, if the step size is small enough and r0=r1, c=c1, and h0=h.Figure5 gives the phase trajectories and the convergence trajectories of these two controllers where the corresponding parameters are the same except for h0. The phase trajectory A shows the second-order sliding-mode characteristics of controller (41). However, it can be seen from phase trajectory B and convergence trajectory B that the control performance becomes worse and chattering occurs easily when the control law is discontinuous. Meanwhile, controller (42) can still guarantee good control performance except for the smaller fluctuation due to discrete calculation. This fluctuation can also be weakened by appropriately increasing h0, and the convergence rate will be slower as a cost as convergence trajectory D shows.According to the above description, controllers (41) and (42) can be used for continuous and discrete observer design, respectively. In this paper, the observer is proposed as(43)z^1k+1=z^1k+hkf0xk+g0uk+z^2k,z^2k+1=z^2k+hk−λe2k+fhane1k,ce2k,r0,khhk,where kh is a coefficient so that h0 will change with the calculated step hk. In order to reduce the overshoot and steady-state fluctuation, a part of the convergence rate needs to be sacrificed when selecting the parameters of fhan. Here, −λe2k is introduced to improve the convergence rate. The error system can be rewritten as(44)e1k+1=e1k+hke2k,e2k+1=e2k+hk−pk−λe2k+fhane1k,ce2k,r0,khhk.The−pk−λe2k can be taken as a new disturbance, and it is bounded in diesel engine systems. According to Theorem 1, there are parameters of fhan⋅ to make error system (44) converge in finite time.In conclusion, based on this sliding-mode disturbance observer (SMDO), the designed discrete sliding-mode controller (DSMC) can be described as(45)k1skγsignsk−k2sk+xdk+1−xdkhk−f0xk−z^2k.Combing with system function (27), it yields to(46)sk+1−skhk=−k1skγsignsk−k2sk−e2k.Comparing with equation (36) shows that the convergence accuracy will be improved if e2k<D which is guaranteed by the SMDO.Figure 5
Comparison of control performance between control laws (41) and (42) under different conditions, i.e., (A) continuous control with control law 41, (B) timing control with control law (41), (C) timing control with control law (42) and h0=h, and (D) timing control with control law (42) and h0=2h. (a) Phase trajectories. (b) Convergence trajectories.
(a)(b)


## 4. Results and Discussion

To verify the effectiveness of the proposed SMDO and DSMC, simulation on the cylinder-by-cylinder diesel engine model is carried out and the results are analysed in this section. Moreover, the ESO proposed in Ref. [37] and a PID controller are employed to compare with the proposed observer and controller, respectively.In Table1, the primary parameters of the modelled diesel engine are given. Similar to the general operating conditions of a marine diesel engine, the simulations include the starting process, steady process, acceleration process, deceleration process, and load-changing process. To simulate the starting process in a real engine, the engine is driven by a starting torque until it reaches the set speed 350 rpm, and then it is driven by combustion torque since the controller starts working. After the starting process, the reference speed is increased from 700 rpm to 1900 rpm by 400 rpm each time and then decreased by 600 rpm to 1300 rpm. A slope limit for the reference speed is employed to ensure the safety of the propulsion system as the actual engine runs [30], which is set as 400 rpm/s. When a ship is running in the sea, the propeller torque is affected periodically by waves, which can be simulated by periodic disturbance torque in 13 to 15 seconds. In harsh sea conditions, the propeller inevitably emerges and reenters the water, which would cause dramatic load changing. Given such situation, the load torque Ml is discharged and increased by 50% at 9 s and 10 s to simulate the effect of emerging and reentering. Especially, varied inertia moment J is considered to evaluate the robustness of the proposed controller. Detailed simulation results and analysis are presented below.Table 1
Parameters of the target marine diesel engine.
Working principle4-strokeNo. of cylindersInline, 6Bore/stroke130/160 mmDisplacement12.7 LCompression ratio17.5 : 1Intake systemTurbocharging, intercoolingRated power405 kW (1900 rpm)Maximum fuel delivery250 mg/cycle


### 4.1. Sliding-Mode Disturbance Observer Performance

As described above, the ESO is employed for comparison, and the simulation results of the disturbance observers with optimized parameters are given in Figure6 and 7.Figure 6
The observation performance comparison between the ESO and SMDO.
(a)(b)Figure 7
The detailed disturbance observation comparison of the ESO and SMDO. (a) The convergence process. (b) Unloading process. (c) Acceleration process. (d) Loading process.
(a)(b)(c)(d)Since equation (27) is the average and simplification of the cylinder-by-cylinder model, the observed disturbance is actually an average. However, the combustion torque of the cylinder-by-cylinder model varies periodically with the crank angle; hence, the actual disturbance torque of the model is difficult to calculate. Therefore, the comparison between the observed disturbance and the actual disturbance cannot be given. The following results of the two observers for the engine speed ne are shown in Figure 6. It can be seen that, the speed tracking performance of the ESO is better than that of the SMDO in all the compared situations. However, as the speed estimation error is the input of the observers, too fast speed following is sometimes at the expense of disturbance observation effect. It is obvious that the observation of the SMDO is better than that of the ESO at initial stage (as shown in the downside subplot of Figures 6 and 7(a) due to the faster convergence in the SMDO). More detailed disturbance observation comparison is given in Figure 7.As can be seen from Figure7(a), the observer starts operation at nearly 0.8 seconds where the engine speed reaches 350 rpm. Then, both observers converge quickly, but the ESO converges significantly slower and has a brief oscillation. After that, the two estimated results are close, as shown in Figure 7(c). However, the SMDO is significantly faster than the ESO in response to sudden loading and unloading as present in Figures 7(b) and 7(d), and this will have a great effect on the speed control which will be discussed later. Overall, the SMDO performs better than the ESO. A more intuitive comparison can be seen from the speed tracking effect of the DSMC based on the two observers as shown below.


### 4.2. Discrete Sliding-Mode Controller Performance

For providing better comparison, three controllers are tested; they are SMDO-based DSMC, ESO-based DSMC, and PID. All these controllers perform the calculation of control input at a preset crank angle before fuel injection occurs in the individual cylinder. In order to avoid introducing meaningless periodic fluctuations which is shown in Figure4, the engine speed is averaged between two adjacent calculations. Moreover, the disturbances are added to the engine speed calculation and the load torque separately for simulating the actual situation more closely. Therefore, the average speed is fluctuating even in steady-state condition, which is more likely to cause chattering of SMC.The overall results of engine speed and control signal response curves for the compared controllers are shown in Figure8, and some detailed results are shown in Figures 9–13.Figure 8
The control performance comparison between the PID controller, the ESO-based DSMC, and the SMDO-based DSMC.
(a)(b)Figure 9
Diesel engine speed response after the controllers start working in the starting process.Figure 10
Diesel engine speed response during acceleration and deceleration processes. (a) 700–1100 rpm. (b) 1100–1500 rpm. (c) 1500–1900 rpm. (d) 1900–1300 rpm.
(a)(b)(c)(d)Figure 11
Diesel engine speed response during sudden loading and unloading.Figure 12
Diesel engine speed response under periodic disturbance torque.Figure 13
The control performance comparison between the controllers with different moment of inertia. (a) The starting process. (b) The first loading process. (c) Acceleration process. (d) Deceleration process. (e) The sudden loading and unloading process. (f) The periodic disturbance process.
(a)(b)(c)(d)(e)(f)As can be seen from Figure8, there is no significant chattering under DSMC whether it is based on the ESO or SMDO, and all the compared controllers can achieve satisfactory control performance under the most operation conditions. Detailed presentation and analysis are described below.Case 1.
Starting process
As mentioned above, the diesel engine model is firstly driven by a starting torque until the speed reaches to 350 rpm, and then the controller takes over the control and starts the closed-loop control. Furthermore, to avoid overregulation, the desired speed is set to always be 50 rpm higher than the actual speed before the actual speed approaches the idle speed. The simulation results after the controllers start working in the starting process are shown in Figure9. Visibly, the overshoot and stabilization time of the PID controller reach to 140 rpm and 1.2 seconds, while the overshoots of the DSMC based on the ESO and SMDO are only 31 rpm and 20 rpm, respectively, and the stabilization time is less than 1.0 seconds. Moreover, since the SMDO converges faster and does not oscillate like the ESO, the starting process of the SMDO-based DSMC is significantly smoother. After the speed stabilizes at idle condition, the load torque is added at 2 s. During loading, the three controllers have similar control effects, while the SMDO-based DSMC is slightly better. Hence, it can be concluded that the SMDO-based DSMC has a better starting performance than PID controller and the ESO-based DSMC.Case 2.
Acceleration and deceleration process
Figure10 shows the acceleration and deceleration processes. It can be seen that DSMCs based on the ESO and SMDO have a better tracking effect in all processes, except that there are slight overshoots but almost negligible. Meanwhile, the two DSMC methods maintain similar performance during all three acceleration processes, while the performance of the PID controller becomes worse in the processes in Figures 10(a) and 10(c).Case 3.
Load variation process
Figures11 and 12, respectively, show the engine speed responses of two kinds of load variation mentioned above. During the sudden loading and unloading, one can see that the overshoot of the ESO-based DSMC is higher than that of the other two controllers due to the slow response of the ESO which is shown in Figure 7. The convergence time of the PID controller is almost twice than that of DSMCs. In contrast, the SMDO-based DSMC has the best control performance with the minimum overshoot and the shortest stabilization time. Facing the periodic disturbance, the control performance of the SMDO-based DSMC is still the best with only 31 rpm speed fluctuation, while the PID controller is the worst with 52 rpm speed fluctuation. The DSMC based on the ESO has slightly worse performance than that based on the SMDO, in which the speed fluctuation is 39 rpm. Therefore, it can be concluded that the SMDO-based DSMC is more capable of handling the load variation because of the harsh marine environment.Case 4.
Robustness verification
In practice, a diesel engine may be used to different propulsion systems with different parameters such as inertia moment and torque coefficient. This requires the controller to have good robustness, otherwise the controller parameters need to be recalibrated for different propulsion systems. Here, the simulation is carried out to verify the robustness of the controllers, in which the inertia moment of the propulsion system is increased by 25% and the parameters of the controllers remain unchanged. Some simulation results are given in Figure13.
As can be seen that, during the starting process, the performance of the PID controller is still not satisfactory and the performance of the ESO-based DSMC gets worse with overshoot increasing to 51 rpm. During the first loading process, the control effect of the three controllers becomes better than their original conditions as shown in Figure9 while DSMCs are obviously better than the PID controller. In Figures 13(c) and 13(d), the DSMCs based on the ESO and SMDO maintain the good control performance, but the PID controller gains the worse control performance. Due to the increase of rotational inertia, the control performance of the three controllers gets better when suddenly loading and unloading. However, the DSMC based on the SMDO still has the best performance, and the PID controller is still significantly worse than the DSMCs. Facing the periodic disturbance, the speed fluctuation of the DSMCs based on the ESO and SMDO is 25 rpm and 20 rpm, respectively, which means that, for the DSMCs, the control performance under such condition is better than the original condition as shown in Figure 12. On the contrary, the control effect of the PID controller becomes worse, and the speed fluctuation increases to 58 rpm.
Summarizing the above analysis and comparison, the DSMCs show superior performance over the PID controller. While ensuring the robustness, the chattering is almost eliminated. As can be seen from the above simulation results, the steady-state fluctuation is basically the same as the PID controller. The robustness and control effect of the SMDO-based DSMC are better than that of the ESO-based DSMC, which further indicates that the performance of the designed SMDO is better than that of the ESO. Therefore, control performance of the marine diesel engine speed system can be further improved by the proposed SMDO-based DSMC.


## 4.1. Sliding-Mode Disturbance Observer Performance

As described above, the ESO is employed for comparison, and the simulation results of the disturbance observers with optimized parameters are given in Figure6 and 7.Figure 6
The observation performance comparison between the ESO and SMDO.
(a)(b)Figure 7
The detailed disturbance observation comparison of the ESO and SMDO. (a) The convergence process. (b) Unloading process. (c) Acceleration process. (d) Loading process.
(a)(b)(c)(d)Since equation (27) is the average and simplification of the cylinder-by-cylinder model, the observed disturbance is actually an average. However, the combustion torque of the cylinder-by-cylinder model varies periodically with the crank angle; hence, the actual disturbance torque of the model is difficult to calculate. Therefore, the comparison between the observed disturbance and the actual disturbance cannot be given. The following results of the two observers for the engine speed ne are shown in Figure 6. It can be seen that, the speed tracking performance of the ESO is better than that of the SMDO in all the compared situations. However, as the speed estimation error is the input of the observers, too fast speed following is sometimes at the expense of disturbance observation effect. It is obvious that the observation of the SMDO is better than that of the ESO at initial stage (as shown in the downside subplot of Figures 6 and 7(a) due to the faster convergence in the SMDO). More detailed disturbance observation comparison is given in Figure 7.As can be seen from Figure7(a), the observer starts operation at nearly 0.8 seconds where the engine speed reaches 350 rpm. Then, both observers converge quickly, but the ESO converges significantly slower and has a brief oscillation. After that, the two estimated results are close, as shown in Figure 7(c). However, the SMDO is significantly faster than the ESO in response to sudden loading and unloading as present in Figures 7(b) and 7(d), and this will have a great effect on the speed control which will be discussed later. Overall, the SMDO performs better than the ESO. A more intuitive comparison can be seen from the speed tracking effect of the DSMC based on the two observers as shown below.


## 4.2. Discrete Sliding-Mode Controller Performance

For providing better comparison, three controllers are tested; they are SMDO-based DSMC, ESO-based DSMC, and PID. All these controllers perform the calculation of control input at a preset crank angle before fuel injection occurs in the individual cylinder. In order to avoid introducing meaningless periodic fluctuations which is shown in Figure4, the engine speed is averaged between two adjacent calculations. Moreover, the disturbances are added to the engine speed calculation and the load torque separately for simulating the actual situation more closely. Therefore, the average speed is fluctuating even in steady-state condition, which is more likely to cause chattering of SMC.The overall results of engine speed and control signal response curves for the compared controllers are shown in Figure8, and some detailed results are shown in Figures 9–13.Figure 8
The control performance comparison between the PID controller, the ESO-based DSMC, and the SMDO-based DSMC.
(a)(b)Figure 9
Diesel engine speed response after the controllers start working in the starting process.Figure 10
Diesel engine speed response during acceleration and deceleration processes. (a) 700–1100 rpm. (b) 1100–1500 rpm. (c) 1500–1900 rpm. (d) 1900–1300 rpm.
(a)(b)(c)(d)Figure 11
Diesel engine speed response during sudden loading and unloading.Figure 12
Diesel engine speed response under periodic disturbance torque.Figure 13
The control performance comparison between the controllers with different moment of inertia. (a) The starting process. (b) The first loading process. (c) Acceleration process. (d) Deceleration process. (e) The sudden loading and unloading process. (f) The periodic disturbance process.
(a)(b)(c)(d)(e)(f)As can be seen from Figure8, there is no significant chattering under DSMC whether it is based on the ESO or SMDO, and all the compared controllers can achieve satisfactory control performance under the most operation conditions. Detailed presentation and analysis are described below.Case 1.
Starting process
As mentioned above, the diesel engine model is firstly driven by a starting torque until the speed reaches to 350 rpm, and then the controller takes over the control and starts the closed-loop control. Furthermore, to avoid overregulation, the desired speed is set to always be 50 rpm higher than the actual speed before the actual speed approaches the idle speed. The simulation results after the controllers start working in the starting process are shown in Figure9. Visibly, the overshoot and stabilization time of the PID controller reach to 140 rpm and 1.2 seconds, while the overshoots of the DSMC based on the ESO and SMDO are only 31 rpm and 20 rpm, respectively, and the stabilization time is less than 1.0 seconds. Moreover, since the SMDO converges faster and does not oscillate like the ESO, the starting process of the SMDO-based DSMC is significantly smoother. After the speed stabilizes at idle condition, the load torque is added at 2 s. During loading, the three controllers have similar control effects, while the SMDO-based DSMC is slightly better. Hence, it can be concluded that the SMDO-based DSMC has a better starting performance than PID controller and the ESO-based DSMC.Case 2.
Acceleration and deceleration process
Figure10 shows the acceleration and deceleration processes. It can be seen that DSMCs based on the ESO and SMDO have a better tracking effect in all processes, except that there are slight overshoots but almost negligible. Meanwhile, the two DSMC methods maintain similar performance during all three acceleration processes, while the performance of the PID controller becomes worse in the processes in Figures 10(a) and 10(c).Case 3.
Load variation process
Figures11 and 12, respectively, show the engine speed responses of two kinds of load variation mentioned above. During the sudden loading and unloading, one can see that the overshoot of the ESO-based DSMC is higher than that of the other two controllers due to the slow response of the ESO which is shown in Figure 7. The convergence time of the PID controller is almost twice than that of DSMCs. In contrast, the SMDO-based DSMC has the best control performance with the minimum overshoot and the shortest stabilization time. Facing the periodic disturbance, the control performance of the SMDO-based DSMC is still the best with only 31 rpm speed fluctuation, while the PID controller is the worst with 52 rpm speed fluctuation. The DSMC based on the ESO has slightly worse performance than that based on the SMDO, in which the speed fluctuation is 39 rpm. Therefore, it can be concluded that the SMDO-based DSMC is more capable of handling the load variation because of the harsh marine environment.Case 4.
Robustness verification
In practice, a diesel engine may be used to different propulsion systems with different parameters such as inertia moment and torque coefficient. This requires the controller to have good robustness, otherwise the controller parameters need to be recalibrated for different propulsion systems. Here, the simulation is carried out to verify the robustness of the controllers, in which the inertia moment of the propulsion system is increased by 25% and the parameters of the controllers remain unchanged. Some simulation results are given in Figure13.
As can be seen that, during the starting process, the performance of the PID controller is still not satisfactory and the performance of the ESO-based DSMC gets worse with overshoot increasing to 51 rpm. During the first loading process, the control effect of the three controllers becomes better than their original conditions as shown in Figure9 while DSMCs are obviously better than the PID controller. In Figures 13(c) and 13(d), the DSMCs based on the ESO and SMDO maintain the good control performance, but the PID controller gains the worse control performance. Due to the increase of rotational inertia, the control performance of the three controllers gets better when suddenly loading and unloading. However, the DSMC based on the SMDO still has the best performance, and the PID controller is still significantly worse than the DSMCs. Facing the periodic disturbance, the speed fluctuation of the DSMCs based on the ESO and SMDO is 25 rpm and 20 rpm, respectively, which means that, for the DSMCs, the control performance under such condition is better than the original condition as shown in Figure 12. On the contrary, the control effect of the PID controller becomes worse, and the speed fluctuation increases to 58 rpm.
Summarizing the above analysis and comparison, the DSMCs show superior performance over the PID controller. While ensuring the robustness, the chattering is almost eliminated. As can be seen from the above simulation results, the steady-state fluctuation is basically the same as the PID controller. The robustness and control effect of the SMDO-based DSMC are better than that of the ESO-based DSMC, which further indicates that the performance of the designed SMDO is better than that of the ESO. Therefore, control performance of the marine diesel engine speed system can be further improved by the proposed SMDO-based DSMC.


## 5. Conclusions

In this article, a disturbance observer-based discrete sliding-mode control scheme is proposed for the speed control of the marine diesel engine. The system uncertainties and external disturbances are estimated by the designed disturbance observer based on the second-order sliding-mode control. With such estimate to compensate the uncertainties and disturbances, a discretized sliding-mode controller based on the fast power reaching law is employed as the speed control law. In order to verify the controller, a cylinder-by-cylinder MVEM of a marine diesel engine is established by remodelling the combustion torque model, which can simulate the periodic operation of the diesel engine. The numerical simulations are carried out on this model. To show the superiority of the proposed method, the PID controller and ESO-based DSMC are employed for comparison. Moreover, the common operation situations of the marine diesel engines are taken into account, including starting process, acceleration and deceleration, load variation, and varied propulsion system parameters. The results show that the designed SMDO is more stable and has better tracking performance than the ESO, and the proposed SMDO-based DSMC has better control performance and stronger robustness under various working conditions than the PID and ESO-based DSMC. Therefore, the speed control performance of a marine diesel engine can be significantly improved by using the proposed controller.



---

*Source: 2456850-2020-07-04.xml*