Coffee is one of the hot beverages most consumed worldwide. The scent produced by coffee after its brewing process can provide useful information to assess the quality of its industrial production. Despite the large quantity of information that can be extracted from analyzing the aroma that recently brewed coffee emanates, its large number of complex, volatile compounds usually requires the use of large, expensive spectrometer devices to analyze it [1
]. This paper addresses this problem by assessing the application of a custom low-cost electronic nose (eNose) to discriminate between the aromas of encapsulated caffeinated and decaffeinated expresso coffee varieties after being brewed.
In general, an eNose consists of an array of nonspecific, low-selective electrochemical sensors with high stability and cross-selectivity toward volatile compounds, odors, or aromas. The information gathered by the array of sensors is processed with pattern recognition algorithms [3
] in order to generate a fingerprint of the perceived volatile compound, odor, or aroma [4
]. The continuous evolution of low-cost metal–oxide (MOX) gas sensors is currently fostering the development of compact arrays [5
], which are able to provide the multivariate information required to implement an eNose. In general, low-cost MOX gas sensors suffer from drift in sensitivity and low specificity [5
] that can be compensated [11
] by applying signal processing techniques or by implementing specific calibration procedures [12
]. Despite these known drawbacks, the recent advances and growing popularity of eNoses equipped with MOX gas sensors are promoting their use in areas in which traditional spectroscopy was deemed unviable because of its high cost, power consumption, and size, such as waste management [13
] and disease detection [15
]. In general, the number of gas sensors used in an eNose used to be lower than 20 [16
]. As recent examples, Teixeira et al. [17
] proposed the development of a custom eNose composed of 9 different MOX gas sensor types, and Burgués et al. [18
] applied a custom eNose composed of 27 MOX from five family types.
Alternatively, this paper is based on the use of a custom eNose composed of 16 single-type (identical type) miniature MOX gas sensors implemented as a low-cost microelectromechanical system (MEMS). The underlying idea of this alternative eNose proposal was to take advantage of the small but inherent sensing variability of the 16 identical MOX gas sensors [5
] to provide a multivariate description of volatile compounds, odors, or aromas. This custom eNose proposal, named Osmee One, has been proven capable of distinguishing between two [16
] or three [20
] single volatile compounds, and this paper presents the first assessment with complex aromas such as the ones generated by caffeinated and decaffeinated coffee after being brewed.
Buratti et al. [21
] stated that “the espresso coffee overall quality is affected by many factors related to coffee (variety, roasting conditions and storage conditions) [22
], to water composition [26
] and to the parameters of the percolation (temperature and pressure of water, grinding grade, dose of coffee, coffee/water ratio, pressure on the upper surface of coffee cake, extraction time) [27
]”. In this first eNose application example with complex aromas, these factors will be controlled by using an encapsulated espresso ground coffee, using soft mineral water to brew the coffee, and using a new semiautomatic coffee machine in order to guarantee similar brewing conditions that do not affect the aroma of the coffee.
At this moment, the specific problem of discriminating between caffeinated and decaffeinated coffee is addressed using expensive laboratory equipment. Souto et al. [31
] used Ultraviolet–Visible (UV-VIS) spectroscopy and chemometric techniques to classify the type (caffeinated or decaffeinated) and the conservation state (expired or nonexpired) of aqueous extracts of Brazilian ground roast coffee. Yulia et al. [32
] discriminated between caffeinated and decaffeinated coffee using UV-VIS spectroscopy. Zou et al. [33
] analyzed caffeinated and decaffeinated coffee using a headspace solid-phase microextraction two-dimensional gas chromatography time-of-flight mass spectrometry (HS-SPME-GC×GC-TOFMS), identifying 20 discriminatory features and specific markers that could enable a distinct classification between caffeinated and decaffeinated coffee. Specifically, eNoses have also been applied to evaluate bean ripening and to detect bean defects [34
], classify different coffee brands [35
], discriminate geographical origin and roasting degree of the coffee [36
], evaluate the aromatic profile [37
], and to estimate coffee intensity [38
]. Brudzewski et al. [39
] proposed the recognition of high-quality arabica coffee specie using a differential eNose composed of two identical eNoses [40
]. Greco et al. [41
] compared four kinds of powder and encapsulated espresso coffees with an eNose in order to provide a user-friendly tool that can be used in the food quality control chain.
The new contribution of this paper is the demonstration that a low-cost eNose based on 16 single-type commercial MOX gas sensors can be applied to discriminate the aromas of encapsulated caffeinated and decaffeinated expresso brewed coffee. At this moment, this challenging discrimination can be made with spectrometers that cost 100 times more than the eNose used in this paper, a fact that limits their application to quality control in laboratory facilities. Therefore, the complete development of inexpensive eNoses has the potential to decentralize and improve the quality control of different industrial productions, such as goods and commodities. Regarding the eNose application presented in this paper, caffeine is a soluble and nonvolatile compound that does not directly affects the aroma but its presence indirectly affects the generation of other volatile substances originally present in the aroma of coffee [42
], so its presence should be detectable from the aroma of the brewed coffee. The experimental analysis conducted in this work has demonstrated that an eNose using 16 single-type commercial and low-cost MOX gas sensors has enough multisensory information and enough sensitivity to successfully discriminate the complex aroma of the coffee by applying a linear discriminant analysis (LDA) to the raw resistance information gathered from the eNose.
In the future, this low-cost eNose will be deployed either as a fixed net of multiple sensors or embedded in autonomous omnidirectional mobile robots [43
] in order to compare its gas and odor detection performances.
2. Background: Brewed Coffee Beverage
The brewed coffee beverage is prepared from roasted and ground coffee beans harvested from coffee plants cultivated around the world. The brewing of coffee is a process that extracts the volatile compounds and soluble and insoluble compounds from the ground coffee [28
]. The volatile compounds are responsible for the aroma and are composed of ketones, aldehydes, pyrazines, and many other volatiles [46
]. The soluble and nonvolatile compounds define the taste of coffee and are composed of caffeine, acids, phenolic compounds, sugars, and many other substances [46
]. The insoluble molecules affect the body and foam of coffee and are composed of proteins, polysaccharides, lipids, melanoidins, and many other molecules [46
]. The main characteristics of green coffee beans depend on the origin, location, and climate where coffee is cultivated (altitude, land composition, and temperature) and the processing method of each coffee variety.
The coffee beans are seeds of trees belonging to the botanical family Rubiaceae
, genus Coffea
. Currently, there are around 100 coffee species within the genus Coffea
]; however, only two of them are widely cultivated and commercialized on a large scale: the arabica coffee (Coffea Arabica
) and the robusta coffee (Coffea Canephora
), representing the 58.61% and the 41.39% of the coffee cultivated and commercialized worldwide [48
These two coffee species are very different. Arabica is cultivated on the slopes of mountains at high altitudes, mainly in Eastern Africa and Central and South America, and its beans have a sweet and delicate flavor, with an average of 0.9–1.4% of caffeine [46
]. Alternatively, robusta is cultivated on lower altitudes, mainly in West Africa and South-East Asia, because it is resistant to hot and humid tropical climates, and its beans have a strong flavor with around 1.5–2.6% of caffeine [46
]. Belitz et al. [46
] reported that of the 850 volatile compounds identified in the aroma of coffee, only 40 contribute to generating the characteristic aroma of coffee.
In general, any commercialized coffee beverage type is composed of a mixture of arabica and robusta beans from different origins. This mixture is usually strictly supervised in order to maintain the characteristic aroma profile and coffee intensity of a commercial coffee type. The coffee beans can be processed to significantly reduce their caffeine content, allowing the simultaneous commercialization of the same coffee mixture type in caffeinated and decaffeinated versions. In general, the decaffeination processes are usually applied to arabica rather than robusta because arabica has lower initial caffeine content and requires less processing [49
3. Materials and Methods
The materials and methods used in this paper are an eNose-based coffee measurement setup, one selected caffeinated and decaffeinated encapsulated espresso coffee type, one semiautomatic coffee machine, the mineral water used to brew the coffee, the procedure for espresso coffee brewing and aroma measurement, and the linear discriminant analysis (LDA) method applied for dimensional reduction and classification.
3.1. eNose-Based Coffee Measurement Setup
shows two images of the eNose-based coffee measurement setup used in this paper to discriminate between encapsulated caffeinated and decaffeinated espresso coffee. The measurement setup (Figure 1
a) consists of a support structure and the Osmee One eNose composed of an array of 16 single-type (identical) metal–oxide semiconductor (MOX) gas sensors embedded as a microelectromechanical system (MEMS) in the commercially available BME680 sensor device (Bosch Sensortec, Reutlingen, Germany). The parameter used to modulate the array is the working temperature of the 16 different sensors. As reported in Table 5 of the previous publication [16
], the targeted heating temperature is varied from 200 °C to 400 °C. This eNose was designed with 16 sensors in order to be suitable in size for the intended applications. The support structure is 3D printed with polylactic acid (PLA), with the shape of a circular pipe with a variable section. The lower part of the pipe is laid on the ground and has the widest circular section in order to allow a cup to be placed inside. The upper part of the pipe has the minimum circular section in order to hold the MOX gas sensors of the electronic board of the eNose inside the pipe (Figure 1
b) and in close contact with the coffee aromas. The lower part of the support structure has an aperture to slide a cup of espresso coffee inside the pipe. This lower part also has a set of holes to allow the generation of natural convection and the circulation of the coffee aroma inside the pipe.
3.2. Caffeinated and Decaffeinated Encapsulated Espresso Coffee Type
The caffeinated and decaffeinated encapsulated espresso coffee types analyzed in this work are Volluto and Volluto Decaffeinato. These two encapsulated espresso coffee types are manufactured by Nespresso (Nestlé Nespresso, Lausanne, Switzerland) using a proprietary single-dose sealed aluminum capsule that has the advantage of preserving the freshness and aromas of the ground coffee [50
summarizes the main features of the Volluto and Volluto Decaffeinato types. In both cases, the coffee specie is arabica, but their specific aromatic profile and notes result from a mixture sourced from different locations and roasting processes. The intensity of each type is quantified with a scale ranging from 1 to 13, and the acidity, bitterness, and roast level are quantified using scales from 1 to 5. According to the manufacturer, the features that define the intensity of a coffee are its body, bitterness, and the degree of roasting, which are strongly related to the origin and type of beans used in the coffee mixture. The coffee intensity is also dependent on the concentration of the coffee, and it does not refer to the amount of caffeine it has.
also provides an unverified estimation of the caffeine contained in each capsule, which does not correspond to the caffeine extracted during the brewing, nor the caffeine ingested. Then, according to the information shown in Table 1
, the difference between these two coffee types is the decaffeination process that has been applied during the manufacturing of the Volluto Decaffeinato type. So, it must be expected that a generation of very similar aromas during the brewing of these two coffee types will make discrimination difficult.
3.3. Coffee Machine
The semiautomatic coffee machine used in this paper is a brand-new Nespresso C40 Inissia coffee machine (Nestlé Nespresso, Lausanne, Switzerland). This machine brews coffee from Nespresso aluminum capsules that contain roasted ground coffee mixtures. This coffee machine is able to brew espresso (40 mL) or lungo (110 mL) coffee brews. The capsules are inserted into the machine, and then they are pierced in order to inject hot pressurized water through them and obtain the brewed coffee. According to the manufacturer specifications, the brewing pressure is 19 MPa, and the temperature of the extracted coffee at the coffee outlet is between 83 and 86 °C, although it might cool quickly if the cup where it is brewed is cold. The recommended cup size of the coffee types analyzed in this paper is espresso or 40 mL, which corresponds to the default espresso volume setting already programmed in the coffee machine (standard preset espresso), which is selected and automatically initiated by pressing a button on the coffee machine.
3.4. Natural Mineral Water
The water used to brew the coffee samples analyzed in this paper is the Font Boix natural mineral water [51
] manufactured by Aguas Minerales de Caldas de Bohi S.A (La Vall de Boí, Crta. De Caldes, Km 18.5, 25528 Caldes de Boí, Lleida, Spain). This natural mineral water comes from the Aigüestortes National Park, in the Catalan part of the Pyrenees, at an altitude of 1500 m. The water has been provided in a set of 8 L bottles made of transparent Polyethylene Terephthalate (PET) plastic, with a cap made of high-density polyethylene (HDPE).
Navarini et al. [52
] analyzed the effect of water composition on the quality of espresso coffee beverages. In particular, they analyzed the interactions between water and coffee components during the brewing process and discussed the role played by alkalinity and selected cations on sensory properties. In general, about 98% of brewed coffee is water, and the use of hard or saturated water prevents the correct extraction of the aromatic components during the coffee brew.
shows the chemical composition of the bottled water used in the experiments, which was externally provided and certified by the laboratory of Dr. Oliver Rodés (c/de les Moreres 21, 08820 El Prat de Llobregat, Barcelona, Spain). In our country, Spain, this natural mineral water is classified as very low mineralized water, a category that can have up to 50 mg/L of dry residue at 180 °C. Additionally, the amounts of calcium (6.8 mg/L) and magnesium (0.7 mg/L) in this water generate a permanent total hardness of 19.9 mg/L (or ppm) of calcium carbonate (
), allowing its classification as soft water (range up to 60 mg/L of
3.5. Procedure for Espresso Coffee Brewing Aroma Measurement
The complete procedure used in this paper for espresso coffee brewing aroma measurement has 17 steps:
Insert the eNose in the coffee measurement setup;
Power the eNose with an external power supply for at least 12 h in order to guarantee that the MOX gas sensors are at their ideal working temperature;
Connect the eNose to a computer using a USB connection in order to record the data gathered during the experiment;
Revise the level of the water tank of the coffee machine, refill if necessary;
Turn on the coffee machine (the coffee machine reaches the operating temperature after approximately one minute);
Place an espresso-sized glass cup on the cup tray of the coffee machine;
Insert the coffee capsule into the coffee machine;
Initiate the registering of the data provided by the eNose;
Press the espresso button of the coffee machine, and when the water reaches the correct temperature, the espresso coffee is brewed;
Remove the cup of coffee without sudden movements from the cup tray of the coffee machine and place it inside the coffee measurement setup;
Continue registering the data provided by the eNose for another 10 min from the insertion of the cup inside the coffee measurement setup;
After these 10 min, stop the recording of data;
Weigh the coffee cup of coffee with a precision scale;
Rinse the cup with tap water and dry it with a single-use paper cloth;
Remove the used capsule from the coffee machine and prepare to recycle it;
If this is the last experiment of a planned sequence, or if the next experiment will brew a different coffee type, brew espresso without a capsule (with only water) to clean the coffee machine, pull up the lever, and rinse the drip tray and the capsule container with tap water;
Ventilate the room for at least 10 min.
During the brewing of the coffee cups performed in this paper, the amount of water used to make an espresso coffee was 49.73 g with a standard deviation of ±0.34 g, and the mean temperature of the water measured after coffee extraction was 72.76 °C with a standard deviation of ±0.41 °C.
3.6. Linear Discriminant Analysis (LDA)
The linear discriminant analysis (LDA) [53
] is a supervised statistical method for dimensionality reduction that computes the eigenvectors and the covariance matrix of a set of data. The LDA procedure assumes that the different classes included in the set of data are based on different Gaussian distributions and looks for linear combinations of the features that best explain the classes of data while maximizing the variance and separation between them. The result of the computation of the LDA is a projection that reduces the dimensionality of the data. The discriminant analysis part of the LDA procedure also predicts the class of a new sample by computing its proximity to the centroid of the original classes evaluated in the projected space [54
7. Discussion and Conclusions
This paper has assessed the performance of a single-type electronic nose design applied to differentiate between the complex aromas of caffeinated and decaffeinated espresso coffee varieties. The eNose used in this paper is composed of 16 single-type (identical) metal–oxide semiconductor (MOX) gas sensors embedded as a microelectromechanical system (MEMS) in a versatile digital sensor. The hypothesis explored with this eNose is that the small but inherent variability of MOX gas sensors can be exploited to provide the multisensorial description required to identify a volatile or aroma. In previous works, this eNose was assessed with different single volatile compounds, and in this paper, this eNose has been first exposed to the chemistry of a complex coffee aroma, composed of more than 850 mixed volatile compounds, although it is known that the characteristic aroma of coffee is dominated by fewer compounds [46
This paper has assessed the discrimination of the aromas of a caffeinated and decaffeinated Volluto and Volluto Decaffeinato encapsulated espresso coffee variety manufactured by Nespresso. The use of a single-dose sealed aluminum encapsulated ground coffee has the advantage of preserving the constant freshness and aroma of the coffee [50
]. These two coffee types are based on the arabica specie and are almost identical, the only difference being their caffeine content. The caffeine is not a volatile, so it should not affect the aroma of the brewed coffee, but the coffee aroma can be affected by the procedure used to extract the caffeine from the beans, which can affect the formation of other volatiles during the brewing [42
]. Discriminating between caffeinated and decaffeinated coffee has so far been approached using expensive laboratory equipment [31
], so analyzing the complex aromas of brewed coffee has been considered an ideal, challenging application for the low-cost Osmee One eNose.
The aroma measurement experiments conducted in this paper have been performed in a controlled environment [21
] using a specific measurement setup to facilitate the circulation of the aromas of the brewed coffee around the eNose. The raw resistance data gathered by the eNose have been analyzed with LDA because the achieved supervised dimensional reduction maximizes the variance and separation between the analyzed classes.
In this application with complex coffee aromas, the use of the raw resistance of the MOX gas sensors as a classification feature has provided better classification results than the use of the raw resistance normalized according to the resistance of reference air samples. This is probably because all the MOX gas sensors are of the same type, so the homogenization of their resistance has no effect on the classification. The evolution of the aroma profiles gathered during the brewed coffee experimentation has shown that exposing the eNose to the coffee aromas causes a significant drop in the MOX gas sensors, followed by a characteristic stable zone, which has been used to identify the aroma of each experiment.
Different LDA projections have been computed using a training dataset and validated using an additional validation dataset. The LDA projection trained to discriminate between AIR, HOT WATER, and COFFEE has proven that the eNose is able to differentiate the humidity generated by hot water from the aroma of coffee samples. This LDA projection provides feasible and logical projection trajectories when analyzing its complete transitory evolution. The LDA projection trained to discriminate between AIR, HOT WATER, VOLLUTO, and VOLLUTO DECAFFEINATO has shown some difficulties in the discrimination of the caffeinated and decaffeinated aromas, probably because the effort required to model the air and hot water hides some differences between the caffeinated and decaffeinated aromas. Finally, the LDA projection computed to discriminate between VOLLUTO and VOLLUTO DECAFFEINATO has yielded a superior validation classification performance—100% for the caffeinated coffee data points and 98% for the decaffeinated coffee data points, although this classification rises to 100% when classifying the average value of one measurement instead of classifying sequentially all the points obtained during a measurement.
The conclusion of this paper is that an eNose composed of single-type MOX gas sensors is able to differentiate the aromas of caffeinated and decaffeinated encapsulated espresso coffee types. This conclusion agrees with Zou et al. [33
], who also discriminated between caffeinated and decaffeinated coffee from the volatile point of view using gas chromatography techniques. According to the results obtained, a practical application of the Osmee One eNose in the detection of caffeinated and decaffeinated encapsulated espresso coffee types first applied an LDA dimensional reduction optimized to differentiate between coffee aroma, air, and hot water, and second, in case of detecting a coffee aroma, to discriminate between caffeinated and decaffeinated coffee varieties. The first LDA projection can have a direct application in detecting machine malfunctions in automatic brewing machines. The second LDA projection computes a dimensional reduction that is able to successfully discriminate caffeinated and decaffeinated coffee types, although the training data used to compute the dimensional reduction performed by the LDA need to be as representative as possible of the variability of the response of the eNose in different temperature and humidity conditions.
In future work, this low-cost eNose will be deployed either as a fixed net of multiple sensors or embedded in autonomous omnidirectional mobile robots in order to compare its dynamic and static gas and odor detection performances in a large building.