1. Introduction
The accelerated development of internal combustion engines in recent years has enhanced the complexity of their composing elements. As a result, the machinery monitoring task gains relevance for the progressively difficult and correct engine calibration and operation [
1]. Among the many variables to watch, the in-cylinder pressure of an internal combustion engine (ICE) provides the most information about the combustion process needed to optimize fuel consumption, improve machinery efficiency, and reduce pollution rates [
2]. For instance, homogeneous charge compression ignition (HCCI) combustion significantly reduces emissions while maintaining a high fuel efficiency [
3]. However, HCCI demands a complex control of the combustion process that the pressure measuring can alleviate [
4,
5]. As another application, cylinder pressure measuring revealed the influence of fuel borne additives on ternary fuel blend operated in single-cylinder diesel engines [
6]. Another study analyzed the effect of fuel injection pressure on a diesel engine run with butanol-diesel blend by measuring the in-cylinder pressure signal [
7]. Such a signal also allowed correlating the advancing pilot injection timing on the engine performance, combustion, and emissions under high loads with variation pilot injection timing [
8]. Therefore, researchers put effort into implementing reliable pressure monitoring for accurately modeling the engine behavior [
9].
Conventionally, directly measuring the pressure requires installing transducers in the combustion chamber, which is highly invasive and usually carried out under laboratory conditions. In the commercial scenario, engines lack the sensors needed due to the high cost and short useful life [
10]. Therefore, several techniques estimate the in-cylinder pressure signal from non-intrusive measurements such as vibration [
11,
12,
13,
14], crankshaft position [
15], and other easily measured variables [
16]. Despite the vibration signals reach reasonable prediction rates, locating the accelerometers over the engine is an open research field, even being necessary to add more sensors to cope with the spatial variability [
17,
18,
19]. The heat transfer and release rates have also been considered to be wrapper features to estimate pressure from a mathematical model [
20,
21]. Nonetheless, the task of inferring the heat transfer demands assumptions as treat engine gases as ideals, which cannot be true [
22,
23], reducing the prediction performance at varying recording conditions [
24].
The crankshaft kinematics bypasses the inherent spatial uncertainty of vibration recordings relying on detailed mathematical models as the developed in [
25], where the authors estimate in-cylinder pressure from shaft speed fluctuations in an ICE. Their experiments show that the faster the engine, the more complicated the crankshaft motion, and the least accurate the model. In [
10] the crankshaft acceleration is used to estimate cylinder pressure accurately. However, the hand-crafted feature kinematic extraction from the crank position demands powerful machine learning tools, as the recurrent neural networks, to unravel the patterns related to the pressure signal non-linearly. In [
26], the authors develop a single hidden layer feedforward neural network to predict the pressure of a spark-ignition single-cylinder engine (achieving an R2 score of 0.993) from crankshaft angle, duct pressure, and temperature signals. Similarly, the work presented in [
27] developed a model to estimate the pressure in a single-cylinder HCCI engine using a multilayer neural network, operating as predictors the crank angle and the engine speed. In [
28], the authors introduced a unified approach to reconstruct engine cylinder pressure using time-delay neural networks with crank kinematics or block vibration measurements. The authors in [
29] estimate a four-cylinder engine pressure using a Kalman Filter-based approach from structural vibration signals. Indeed, they evaluate the coherence between cylinder pressure and vibrations records. Of note, the combustion process periodicity allows extracting relevant information from spectral analysis to develop straightforward methodologies with enhanced interpretation. For example, the spectrum of in-cylinder vibration and acoustic pressure signals provided relevant harmonics for diagnosing the combustion [
30] and evaluating the working regimen [
14].
In this paper, a time-delay neural networks (TDNN)-based approach is proposed for in-cylinder pressure prediction in an ICE from crankshaft angular position fluctuations. To this end, the TDNN is introduced as a Finite Impulse Response (FIR) filter perspective by taking advantage of the propagation equations of feed-forward networks. A spectral analysis through the Fourier series is used to obtain the most relevant signal harmonics according to the prediction task. Pressure estimation is carried out from the angular velocity signal directly measured from the shaft with a cheap and easily constructed encoder. The recording system acquired signals on twelve different operating states of the engine by varying loads and velocities. The TDNN performance is validated mainly using the R2 score and the Magnitude-Squared Coherence (MSC) spectral metric. For the latter, an MSC over 0.9 in the harmonics explaining 90% of the signal pressure power proves that TDNNs outperform more elaborated methodologies from state-of-the-art [
10,
11,
12,
13,
14,
15,
16,
25]. Also, the peak-based measures are computed for comparison purposes. Besides, the pressure derivative is calculated from the TDNN predictions to get insights about possible heat transfer and release rates estimation enhancement [
20,
21]. It is worth noting that the proposed pipeline lacks complex preprocessing stages as the TDNN performs as a data-tuned filter.
The manuscript is organized as follows:
Section 2 describes the TDNN as FIR filter and the performance metrics.
Section 3 shows the experimental set-up.
Section 4 depicts the results and discussion. Lastly,
Section 5 presents the work conclusions and future research directions.
4. Results and Discussion
Figure 6 reports the R2-based assessment. The time delay (TDNN complexity represented by the number of units
K), the engine velocity (in rpm), and the load (as the current applied to the dynamometer) are studied. The
value marks the time delay matching the fundamental period as a reference value to analyze the prediction assessment. As seen, R2 values above
are obtained regardless of the fixed time delay, speed, and load. Hence, our TDNN-based strategy is robust against different engine configurations, which validates the proposed scheme’s capability for cylinder pressure prediction. Namely the introduced TDNN can be appropriately adapted regarding the required time-delay (network complexity) to deal with the minimal and maximal engine operation conditions (as exposed in
Table 4). Overall, our strategy can be adapted to the predictor behavior regarding the required network representation space (time delay). Notably, the performance increases over
after the fundamental period reference as time delay (
). Indeed, the R2 performance for time-delays between
and 300 ms remains steady. Beyond such a limit, the performance presents a slight decrease, possibly due to the TDNN’s overfitting. Nonetheless, predictions above
are always attained. Therefore, a suitable time delay is fixed at 100ms as it provides the best trade-off between performance and model complexity.
Now, as an illustrative example,
Figure 7 plots the target (blue) and output prediction (orange) for a test pressure sample with the engine running at 2400 RPM with 0.5 A load in the dynamometer (time delay is fixed as 100 ms). As seen, the TDNN prediction properly follows the pressure trend. The performance slightly reduces near the pressure peaks due to the higher-order harmonics existing in this plot section. However, our approach achieves a decent estimation of the target signal. Besides, the R2 provides high-performance rates despite such errors. Notably, the number of high-pressure time instants is considerably smaller than the low-pressure ones where the low frequencies are dominant. The regression plot in
Figure 8 (target vs. TDNN-based predictions of the samples studied in
Figure 7) proves that most of the data is located at a low pressure where the TDNN easier predicts the output due to the slow dynamics. By contrast, high-pressures present larger prediction errors related to the drastic changes near the signal peaks but preserving a reasonable estimation in general (
).
Figure 9 shows the magnitude spectrum of the TDNN’ weights by varying the
K-value (maximum time delay), the engine velocities (measured in rpm), and the load (by changing the current in amperes applied to the dynamometer). The color indicates the normalized spectrum magnitude from blue to yellow within
. As seen, the spectrum gathers most of the energy for frequency values below 200 Hz. Regarding the speed, the TDNN amplifies more the harmonics closer to 200 Hz for 1800 and 2400 RPM than for 3000 RPM. Concerning the load parameter, the higher the load value, the more flatten is the spectrum magnitude. Specifically, for the slowest engine’s velocity, the trained TDNN tends to behave as constant gain filters. Since such a kind of filter slightly adapts the input, the network finds a higher correlation between the angular velocity and the pressure signal. Furthermore, if the load is decreased, then the harmonics gain magnitude. Thus, TDNN aims to model the emerging lower frequencies with a higher power. Therefore, our training procedure highlights the relevant harmonics demanded by the target signal. For the time delay (vertical axes in
Figure 9), which accounts for the TDNN complexity, the spectra appear even across the frequency for delay windows smaller than 100 ms, proving that the TDNN misses harmonics. On the other hand, most of the networks present similar frequency responses for delay windows larger than 100 ms, although they can converge to different weighting values. Then, time delays shorter than the fundamental period hinder the learning of the whole machine dynamics (
Figure 6), yielding low R2 scores and poorly fitted filters.
Aiming to estimate the goodness of harmonic prediction, the MSC between the target and predicted pressure signals is calculated.
Figure 10 depicts the MSC and the accumulated power over the testing set for our cross-validation scheme. The mean and the confidence interval are shown for all the studied engine velocities and loads (time delay is fixed as 100 ms). Of note, the first 30 harmonics hold 90% of the signal power, where the mean MSC is over 80%. Concerning the remaining harmonics, representing 10% of the power, the average MSC decreases, and its standard deviation increases because their faster change rate makes them harder to predict. The interpretation of the above findings is two-fold. Firstly, better fitting the low harmonics, with most of the power, considerably reduces the prediction error, explaining the TDNN behavior as a low-pass filter. Secondly, underperforming at higher-ordered harmonics, usually dominated by noise, lacks relevance for the TDNN training at high signal-to-noise ratio conditions.
Next, to elucidate the TDNN capability following pressure derivatives, i.e., to test the TDNN applicability for heat transfer and release rates engine analysis [
20,
21], the derivative of the TDNN predicted signal is computed.
Figure 11 displays an illustrative example of the pressure derivative after the TDNN prediction. The target and output pressure derivative prediction are presented for one record lasting 60 ms for the engine running at 1800 RPM with 0 BMEP load (TDNN’s time delay is fixed as 100 ms). As seen, the estimated derivative follows the primary target trend. As expected, slight fluctuations are obtained, and an abrupt change is present near the pressure peak. Furthermore,
Figure 12 presents the mean absolute error (MAE)-based performance along with the time instants for both the predicted pressure and pressure derivative (the 12 engine states are studied). For such a purpose, for each engine state, the pressure segments’ central peaks are detected. From the computed peak position, 60 ms are considered around it (30 ms to the left of the peak position and 30 ms to the right of the peak position) to build equal-sized datasets holding pressure and pressure derivatives segments. The MAE is computed for each time instant with respect to the considered segments. Here, the MAE is computed instead of the R2-score to avoid unstable computations when the variance for a given time instant along the studied peak-based centered segments tends to zero. The latter is significantly often near flatten regions of the pressure signal. After visual inspection of the obtained MAE performances in
Figure 12, the higher the speed and the load, the higher the time-dependent error. For the highest load (3.22 BMEP), the MAE is shifted concerning the other loads, which can be explained by the abrupt change and fluctuations of the pressure derivative near the prominent signal peak. Nevertheless, considering that the introduced TDNN method is applied on a cheap and modest mechanical framework, the obtained results seem to be promising regarding the prediction of signals involving pressure derivatives.
Then, the TDNN efficiency around the pressure peaks is also computed. In particular, the normalized peak error (Pmax) is computed as the ratio (as a percentage) of the error between the reconstructed and recorded peak divided by the maximum measured cylinder pressure [
28]. Besides, the peak localization error (Ploc) is computed as the difference in degrees between the location of peak pressure in the reconstructed and the measured signal. Again, as can be observed in
Table 5, the increasing of the load and speed decreases the estimation performance.
Lastly, the method comparison results are shown in
Table 6. The Pmax and Ploc errors are shown as the lower bound–upper bound reported (concerning the analyzed engine states). Furthermore, the best R2 is presented. As seen, the works presented in [
26,
27] attain suitable R2 scores. However, three input signals are studied, and only five states are tested. Besides, the peak-based measures are not computed, lacking an appropriate insight into the method’s capability to follow pressure fluctuations around the main peaks. In contrast, the work exposed by authors in [
28] deals with two predictors (input signals) and studies a three-cylinder engine within nine states. Indeed, such a method obtains the best peak-based measures. Similarly, the approach presented in [
29] estimates a four-cylinder engine pressure from only one predictor. Nonetheless, the achieved peak measures are the lowest. Remarkably, the introduced TDNN is the best trade-off between the required number of predictors and the obtained peak and R2-based assessments. Though only a one-cylinder engine is considered, 12 states are studied from a cheap and simple framework, involving a descent and interpretable prediction (from spectral analysis).
5. Conclusions and Future Work
A single-layered TDNN was trained to predict the in-cylinder pressure signal in a single-cylinder internal combustion engine using angular velocity fluctuations. The proposed approach avoids complex pre-processing stages and is only fed by the angular velocity, easily measured from the engine, reducing the signal acquisition devices’ expenses to record in-cylinder pressure directly. The approach was tested in unseen data, over 12 different engine states varying the speed and load, yielding stable prediction performances. Besides, a spectral analysis is carried out to detect the harmonics and their relevance for the prediction. Attained results found that noise is located in frequencies over 200 Hz, where the harmonics have low power content. Additionally, the tuned time-delay (network complexity represented by the number of required units) for the TDNN is slightly higher than the fundamental period that depends on the engine speed.
Moreover, the pressure derivative is computed from the predicted signal to show the TDNN applicability concerning heat transfer and release rates engine analysis [
20,
21]. Also, peak-based measures were computed, besides the well-known R2 score, to favor method comparison. Overall, the introduced TDNN is a cheap and straightforward approach to favor estimating the pressure signal, holding spectrum interpretability. It is worth mentioning that the proposed method can be adapted to “real-time” environments. In short, TDNN can be evaluated through the convolution between the network weights and the input velocity signal comprising a computational complexity in the order of
operations. However, optimized implementations as the well-known Fast Convolution algorithm can reduce the computational complexity to
where
[
35].
As future work, the authors plan to test the proposal on a real-time implementation from an internal combustion engine with varying angular velocity and load (including angular velocity sensors with higher sample rates). The evaluation of the methodology under changing injection timing is also a research line of interest [
8]. Additionally, the performance using different fuel injection systems as common rail direct fuel injection must be assessed [
36]. The development of a spectral interpretation scheme of deeper dynamic neural networks is also required to enhance the prediction horizon. Indeed, TDNN will be extended to different multi-cylinder engines [
28,
29,
37]. Since the introduced TDNN-based method is data-driven, it can be easily coupled with other pressure estimation tasks. More elaborate machine learning frameworks could be used from the proposed approach to favor the estimation of heat transfer and release rate engine variables [
20].