Submitted:
30 October 2026
Posted:
02 November 2026
You are already at the latest version
Abstract
Color measurements from consumer cameras are difficult to compare because device-specific image processing is variable and often undocumented. We present a fully smartphone-based workflow, in which the sample and a color reference are captured simultaneously, enabling image-specific correction. Nile Red-based test strips were measured in a compact PhotoBox with an integrated ColorChecker chart. A color-correction matrix derived individually for each image reduced the mean hue error across the chromatic range of the strips from 5.1 to 1.6°. Using calibrated hue angle as the sole analytical parameter, eight fuels and ethanol–gasoline blends formed largely distinct clusters, with a mean within-fuel scatter of 1.5°. The regulatory-relevant nominal E10 and E20 reference samples were separated by 14.2°. Within the reference dataset, leave-one-strip-out cross-validation correctly assigned 46 of 48 strips (95.8%); both misassignments were from E5 to E10 clusters. Between-batch differences were ≤0.6°, and the inter-device standard deviation for a fixed paper target was 2.0°. Two nominally identical E10 fuels differing in matrix composition deviated by approximately 12°, suggesting that hue reflects effective fuel polarity rather than ethanol content alone. This compact workflow enables reproducible fuel discrimination using a consumer smartphone. A blind validation using unknown samples has yet to be conducted.
Keywords:
digital image colorimetry
; color correction matrix
; smartphone colorimetry
; ColorChecker
; hue angle
; solvatochromism
; Nile Red
; colorimetric test strips
; fuel screening
; fuel quality
; fuel testing
; point-of-need testing
1. Introduction
Smartphone-based colorimetric sensing has become an established approach to low-cost, point-of-need chemical analysis, with applications spanning environmental, food, and biomedical testing [1,2,3]. Its appeal is structural: the camera, processor, and display needed for image-based quantification are already in the hands of nearly every potential field user, thereby eliminating the dedicated instrumentation required by conventional optical analysis [4]. For fuels in particular, the need for rapid on-site classification is growing. Across most of the EU, the current maximum ethanol content in petrol is E10, but the European Commission confirmed in 2026 that it would consider authorizing E20 and revising the Fuel Quality Directive accordingly [5,6]. Since the composition of fuels is becoming increasingly variable and has both fiscal and technical implications, we present here a portable method for determining the general composition class of a fuel on site.
The chemical basis for our method is solvatochromism: the shift of a dye’s absorption or emission with the polarity of its microenvironment [7]. Nile Red is among the most widely used solvatochromic probes, exhibiting a pronounced positive solvatochromism driven by intramolecular charge transfer in its excited state [8,9]. Its color response correlates well with established empirical polarity scales such as Reichardt’s ET(30), and it remains usable in the weakly polar, hydrocarbon-dominated regime where Reichardt’s own betaine dye is insoluble [10,11]. This last point is decisive for fuel analysis. Paper-based optical sensors have already been applied to fuel adulteration detection [12,13], and solvatochromic probes have accordingly been used to visualize polarity differences in ethanol- and biofuel-containing systems [14]. More recently, a dual-emissive dye incorporated into a crosslinked polymer enabled smartphone-assisted monitoring of ethanol content in E10 gasoline [15].
A recent review of optical fuel-monitoring probes highlights the current predominance of fluorescence-based sensing approaches [16]. Hydrocarbon-dominated fuels (diesel, biodiesel, etc.) cluster at the lower-polarity end of the scale and are individually hard to separate on polarity alone. In other fuels, the analytically useful signal emerges from polarity-raising components ethanol, ethers, and other oxygenates whose presence and proportion shift the effective polarity, and therefore the Nile Red hue, in a measurable way [17,18].
Translating this principle from solution-based spectroscopy to a smartphone readout introduces two practical challenges. First, incorporating Nile Red into a stable, reproducible test-strip format requires careful material development to combine dye retention and analyte accessibility with a useful solvatochromic response. Embedding the dye within a polymer matrix alters the local environment of the dye and therefore its solvatochromic response [19,20]. Consequently, polarity–color relationships established in homogeneous solution cannot be transferred directly to the test-strip system and must instead be interpreted within the specific dye–polymer–analyte environment. Second, the camera response must be made at least semi-quantitative. Consumer cameras apply device-specific, nonlinear, and largely undocumented processing, so color values are not directly comparable across devices [21,22]. This is most commonly addressed by imaging a reference chart and fitting a color-correction transform, usually a 3×3 matrix mapping measured red–green–blue (RGB) to a reference color space, optimized against a perceptual error metric such as the color difference (ΔE) in the Commission Internationale de l’Éclairage (CIE) 1976 L*a*b* (CIELAB) color space [23]. The inexpensive 24-patch X-Rite ColorChecker is widely used for this purpose and yields good results with a simple 3×3 correction matrix [24,25]. A related smartphone approach used a 3D-printed light box with a paper-printed reference chart and a higher-order color-adaptation model in CIE u′v′ space to stabilize camera-dependent color for pH readout [26]; here we instead combine a standardized in-frame ColorChecker with a lightweight 3×3 correction to keep the entire measurement pipeline on-device. Hardware-based strategies address the same reproducibility problem optically: a recent smartphone-coupled integrating-sphere device (DUNI) provides controlled, device-independent illumination for reliable colorimetric readout [27]. The developed PhotoBox with its integrated sample holder and ColorChecker arrangement is shown in Figure 1.
Building on solvatochromic Nile Red test strips of the same chemistry previously investigated in [28], we present a portable proof-of-concept workflow for calibrated smartphone colorimetry of fuels. The system combines (1) a dye–polymer test strip, (2) a compact, mechanically fixed PhotoBox providing controlled illumination, defined imaging geometry, and an integrated color reference, and (3) a smartphone-based acquisition and calibration pipeline that returns the hue angle as the primary analytical readout.
In this work, paper chemistry, controlled imaging, and per-image color calibration were integrated into a single workflow. We translate established diffuse-reflectance coating principles into a portable PhotoBox that provides homogeneous, low-glare illumination. We evaluated whether the computed hue response could discriminate a defined panel of fuel and ethanol–gasoline samples under controlled experimental conditions. Preliminary effects of independently manufactured strip batches and different smartphone cameras were also assessed briefly to underline a possible device and test-strip combination for real-world applications. The method is intended as a rapid screening approach for broad fuel classes in the field and is not presented as a fully validated system for identifying or attributing unknown fuel samples. Figure 2 shows representative test-strip responses for the investigated fuels and ethanol–gasoline blends, with the image closest to the median hue of the replicate measurements selected for each class.
2. Materials and Methods
2.1. Test Strip Manufacturing and Chemicals
Blank test strips (MQuant®, cat. no. 1.11860.0001; Merck KGaA, Darmstadt, Germany) were selected as the base substrate for sensor fabrication. A polymer coating solution was prepared for the testing pad by adding 250 mg of poly(acrylic acid sodium salt) (PAA-Na, Mw ≈ 2,100 g mol⁻¹, CAS 9003-04-7, Sigma-Aldrich, Merck KGaA, Darmstadt, Germany) and 125 mg of poly(vinyl alcohol) (PVA, 87–90% hydrolyzed, Mw 30,000–70,000 g mol⁻¹, CAS 9002-89-5, Merck KGaA, Darmstadt, Germany) to 40 mL of an aqueous sodium dodecyl sulfate solution (SDS) (0.001%, w/v) under constant stirring at 60 °C for 30 min. After cooling to room temperature, 4 mg of Nile Red (Carl Roth, Karlsruhe, Germany; CAS 7385-67-3) was added. The mixture was homogenized with a high-power ultrasonic disperser (Hielscher UP200St, Sonotrode S26d2) at 100% amplitude for 12 min, followed by ultrasonic treatment in a bath sonicator (Elma TI-H-5, 45 kHz) for an additional 10 min to ensure uniform dye distribution. Excess non-suspended dye was removed from the emulsion by filtration using a Whatman® polytetrafluoroethylene (PTFE) syringe filter with 0.2 µm pore size.
The blank strips were coated by dip-coating for 20 s into the prepared polymer/dye mixture. Coated test strips were dried overnight at room temperature. After drying, the test strips were stored in sealed containers at 4 °C until use. Stored under these conditions, the test strips remained functional for at least eight weeks without obvious deterioration of the color response. The resulting test strips appeared white under ambient light and exhibited distinct color changes upon contact with liquid fuels and other organic solvents. The strips were developed as a rapid colorimetric screening format for differentiating broad fuel classes under controlled imaging conditions, including internal color calibration. For sample exposure, the test strip was immersed in the respective liquid for 0.5 to 1 seconds, just enough to wet the sample pad. This immersion-based procedure was selected to approximate practical handling conditions and to ensure complete wetting of the reaction pad. For each fuel, six independent test-strip replicates of one batch were measured using one fuel aliquot. All measurements were carried out under ambient laboratory conditions (22 ± 2 °C, 40–60% relative humidity). After each test strip was brought into contact with the fuel sample, imaging was performed 60 ± 2 s after contact to allow the color response to develop under a defined and reproducible timing window. The fixed readout time was adopted from our previous characterization of the same Nile Red-based test-strip system [28]. In that study, gasoline-type fuels produced an essentially immediate response, whereas diesel-type fuels required up to approximately 30 s to reach a stable hue; a 1 minute interval was therefore selected to ensure sufficient equilibration across the investigated fuel classes. The previous study also demonstrated that the hue changes over time as volatile fuel components evaporate. Accordingly, all measurements in the present work were performed at the same defined 60 ± 2 s time point, and the reported hue values should be regarded as time-defined analytical readouts rather than stable equilibrium values.
Analytes: Commercial fuels were procured as follows: gasoline 95E5 (Super E5, 95 research octane number (RON); HEM, Deutsche Tamoil GmbH, Hamburg, Germany), an unleaded gasoline containing up to 5% (v/v) ethanol; gasoline 95E10 (Super E10, 95 RON; HEM), containing up to 10% (v/v) ethanol; gasoline 98E5 (Super Plus E5, 98 RON; HEM), containing up to 5% (v/v) ethanol; and automotive diesel (EN 590; HEM), a low-sulfur diesel that may contain up to 7% (v/v) fatty acid methyl ester (FAME). All fuels were purchased at a HEM retail station in Berlin, Germany.
Further analytes: Hydrotreated vegetable oil (HVO100) from TOOL-FUEL Services GmbH, Hamburg, Germany; biodiesel (FAME, EN 14214) from Münzer Deutschland GmbH, Rosenheim, Germany. e-fuel RON98E10 was supplied by Lother GmbH (Hamburg, Germany) and Ethanol 99.9% (CHEMSOLUTE®), cat. no. 2222-2.5L; Th. Geyer GmbH & Co. KG, Renningen, Germany; CAS 64-17-5, which was used in pure form and produced the 95E20 and 95E50 mixtures in combination with 95E5. The laboratory-prepared blends were produced in 100 mL batches by adding ethanol to RON95 E5 (E20 and E50) or RON98 E5 (E10). Nominal blend compositions were calculated, assuming an ethanol content of 5% (v/v) in the E5 starting fuels.
The panel spanned E5 to E50 plus neat ethanol, covering the range around the current E10 limit and the proposed E20 revision as well as high-ethanol reference points; fuels above E50 were not investigated as they fall outside conventional automotive petrol specifications. The fuel panel was selected based on these compositional criteria.
2.2. Device Design
To ensure a reproducible measurement setup, a custom photo box was designed and fabricated to provide a mechanically fixed imaging environment for colorimetric measurements of the test strips. The system consists of a computer numerical control (CNC)- milled cast aluminum base plate (GEMPLAN®, supplied by Hans-Erich Gemmel & Co. GmbH, Berlin, Germany) and a housing 3D-printed from glycol-modified polyethylene terephthalate filament (PETG; PolyLite™, Polymaker, Changshu, China), combining a dimensionally stable reference plane with a compact, enclosed optical chamber. The device dimensions are 13 cm × 8 cm × 8.5 cm (width × depth × height).
The smartphone camera is positioned above the sample plane through a fixed optical access opening, resulting in a defined camera-to-sample distance of approximately 8.5 cm. Images are acquired using the main camera at the native 1× setting without zoom or manual focus adjustment. Test strips are introduced into the measurement position using a dedicated slide-in holder that secures the lateral position, orientation, and insertion depth of each strip. This mechanical constraint reduces operator-dependent placement variability and ensures that all samples are recorded under the same geometric conditions. A ColorChecker Nano is permanently mounted in the same imaging plane and remains within the camera field of view during each measurement, allowing the sample and color reference to be imaged simultaneously under identical illumination conditions.
Illumination is provided by six COB (chip-on-board) light-emitting diodes (LEDs), model HC-8MM-320LEDS-6500K, with a color rendering index (CRI)>95; Tayire Lighting Co., Ltd., Zhongshan, China. These were arranged as three LEDs on each side of the sample area. The LEDs are positioned symmetrically at an inclination angle of 45° relative to the sample plane. This geometry was selected to improve bilateral illumination homogeneity while reducing direct specular reflections from possible solvent residues. A homogenizing diffuser was placed between the LEDs and the measurement area to ensure uniform irradiance. The illuminance at the sample plane was 2000 lx, measured using a Voltcraft MS-200LED luxmeter (Conrad Electronic SE, Hirschau, Germany). The LEDs are operated using a high-frequency 250 kHz (212–280 kHz) flicker-reduced driver configuration, with a modulation frequency well above the range typically producing rolling-shutter banding artifacts in camera image sensor readout. The LEDs were driven by a constant-current LED driver (RCD-24-0.70/PL/A, RECOM Power GmbH, Gmunden, Austria) providing a regulated output current of 700 mA and operated using analogue dimming (capped constant for all measurements). The driver supports an input-voltage range of 4.5–36 V DC and a load-dependent output-voltage range of 2–35 V.
Passive thermal management is implemented through the mechanical mounting concept and housing ventilation features in order to limit temperature-induced variation of LED output during measurement. Ventilation openings in the housing limit the accumulation of volatile fuel vapors and heat, and the wetted sample area is physically separated from the electrical components. The device was used under laboratory conditions but not presented as an explosion-protected or Atmosphères Explosibles (ATEX)-certified instrument. The system is powered via a USB-C power supply, providing a standardized and compact electrical interface for laboratory operation. In the final configuration, the inner chamber surfaces were prepared with a matte white coating to reduce non-uniform reflections and improve the diffuse light distribution; the coating formulation and its influence on image quality are described separately in Section 2.3 and Section 3.1. Overall, the hardware design fixes the relevant optical geometry, reduces ambient-light interference, minimizes placement variability, and provides a stable illumination environment for quantitative image-based colorimetric analysis. The resulting mechanical and optical arrangement of the PhotoBox is illustrated schematically in Figure 3, with additional computer-aided design (CAD) renderings provided in Figure S1.
2.3. Diffuse Interior Coating Formulation
To enable accurate smartphone-based colorimetric measurements, the interior surfaces of the PhotoBox were largely coated with a custom water-based diffuse white coating. The formulation was designed to achieve high broadband reflectance in the visible range and spectral neutrality, properties which are critical for eliminating illumination and geometric biases in camera-based color measurements. This was done mainly to circumvent the reflective metal parts, which made an analysis of the color values difficult.
The coating used in this study consisted of 30 g barium sulfate (BaSO₄, 1 µm to 3 µm particle size, CAS 7727-43-7, Sigma-Aldrich, Merck KGaA, Darmstadt, Germany) as the primary broadband scatterer [29,30], supplemented with 6 g rutile titanium dioxide (TiO₂, 0.2 µm to 0.5 µm, CAS 13463-67-7, Merck KGaA, Darmstadt, Germany). The two particle-size regimes broaden the effective scattering size distribution, while the high refractive index of rutile TiO₂ (n ≈ 2.7) provides a substantially larger optical contrast with the surrounding binder than BaSO₄ (n ≈ 1.6), increasing scattering efficiency and opacity [31]. The TiO₂ fraction was included solely to raise the diffuse reflectance and brightness of the enclosure [32], as the coating homogenizes the internal illumination rather than serving as the spectral white reference; the weak absorption of rutile (~410 nm, Eg ≈ 3.0 eV [33,34]) lies at the extreme violet end of the visible range and is therefore expected to have only a minor influence on the recorded sample hue. Any residual color bias introduced by the enclosure coating is further accounted for empirically by the per-image in-frame ColorChecker calibration. The aqueous binder system consisted of 2.2 g PVA, following the heritage of BaSO₄/PVA optical metrology coatings, with 0.3 g PAA-Na, pH 8 to 9 adjusted with sodium hydroxide (NaOH). The components were dispersed in 400 mL of deionized water under constant stirring for 2 h at 60 °C, with 0.15 g fumed silica (CAS 112945-52-5, Sigma-Aldrich, Merck KGaA, Darmstadt, Germany) added as a rheological modifier to suppress pigment sedimentation and sagging.
The coating was applied via airbrush (0.5 mm nozzle, 2.5 bar) in multiple thin passes with 60 min flash-off between layers and finally overnight drying at ambient conditions. The same procedure was repeated the next day, adding up to 5 layers of coating in total. The resulting surface exhibited a uniform matte appearance under D65 LED illumination.
2.4. Camera Calibration and Color Correction
Images were acquired with a Huawei P30 smartphone (model [ELE-L29]; Leica-branded optics, 40 MP main camera based on a red–yellow–yellow–blue (RYYB) SuperSpectrum complementary metal–oxide–semiconductor (CMOS) Sony IMX600y sensor, 1/1.7″, f/1.8, 27 mm equivalent, details in Table S1). Images underlying the reported measurements were acquired using Open Camera app (v1.56.2). All parameters were held constant across sessions: white balance fixed to the D65 preset, zoom factor 1 and focus locked, ISO 50 and exposure time 1/165 s. Published spectral-sensitivity measurements of the camera sensor response show a particularly broad yellow channel, comparatively lower blue sensitivity, and a strong red response [35]. Consequently, conversion of the native RYYB mosaic into conventional RGB/sRGB requires a specific color reconstruction. In the Huawei P30 implementation used here, this RYYB-to-RGB conversion is performed internally by the image signal processor, while the native RYYB sensor data are not exposed through the Android Camera2 RAW interface. Direct analysis of the unprocessed sensor signal was therefore not possible, and images were saved in PNG (quality setting of 100%) format rather than in a RAW format. The stored data are pre-processed, having passed through the camera’s internal demosaicing, white-balance, and non-linear tone-mapping stages before being written. For further image processing and data analysis, Python (version 3.9.5) was used.
Rather than attempting to invert this pipeline, a per-image color-correction transform was fitted against the in-frame ColorChecker, absorbing the combined effect of illumination, sensor response, color filter array, and in-camera processing into a single empirical mapping. All hue values reported in this work are therefore defined operationally relative to this per-image calibration rather than as absolute colorimetric quantities.
Calibration was performed using an X-Rite ColorChecker Classic Nano (Calibrite LLC, Wilmington, DE, USA) positioned inside the PhotoBox and imaged within the same frame as the sample under identical illumination. Region-of-interest (ROI) selections were defined for each of the 24 patches, and robust statistics (10% trimmed mean of the pixel values within each ROI) were computed within each ROI to mitigate sensor noise and residual specular highlights. A color-correction transform mapping the measured camera RGB triplets to the ColorChecker reference values was estimated by least-squares regression. These reference targets were taken from the manufacturer’s Committee for Graphic Arts Technologies Standards (CGATS) colorimetric data for the post-November-2014 ColorChecker (D50 illuminant), chromatically adapted to D65 via the Bradford transform and converted to gamma-encoded sRGB; the resulting 24 reference triplets are listed in Table S2. The cyan reference lies outside the sRGB gamut. Conversion of its D50 CIELAB reference values to D65-adapted sRGB yielded a negative red component, which was clipped to zero when generating the 8-bit sRGB calibration target (R, G, B = 0, 133, 165; Table S2).
The correction was fitted directly on the gamma-encoded sRGB values. Because an affine color-correction transformation cannot fully compensate for the camera’s non-linear tone curve, hue deviations remain at the extremes of the tonal range. The transform consisted of a 3×3 matrix plus an offset vector, fitted per image from the in-frame ColorChecker; corrected values falling outside the valid [0, 255] range were clipped before hue extraction.
2.5. Statistical Analysis and Classification
Statistical differences between neighboring fuel classes were calculated using two-sided Welch’s t-tests. For hue values near the 0°/360° boundary, hue angles greater than 180° were shifted by −360° before the pairwise testing, thereby representing the observations on a continuous angular scale. For the fuel panel described in Section 2.1, the seven comparisons between neighboring clusters in the experimentally determined hue order were exploratory; their p-values were adjusted using a Bonferroni correction for these seven comparisons. Differences were considered statistically significant at an adjusted p < 0.05.
Pairwise class separations were characterized by using non-parametric bootstrap confidence intervals. For each class, the six individual hue measurements were resampled with replacement, and the circular mean hue was computed for each resampled dataset. The separation between two classes was then defined as the shortest angular distance between their circular means. This was repeated 10,000 times using each neighboring class pair, and 95% confidence intervals were then derived from the 2.5th and 97.5th percentiles of the resulting bootstrap distribution.
For the comparison between the laboratory-prepared RON98 E10 and the commercial e-fuel, the magnitude of the observed difference was additionally quantified using Cohen’s d, calculated as the absolute difference between the group means divided by the pooled standard deviation.
Internal classification performance was evaluated by leave-one-strip-out cross-validation (LOSO-CV). For each iteration, one strip measurement was excluded, the circular mean hue of each fuel class was recalculated from the remaining measurements, and the excluded measurement was assigned to the reference class with the smallest circular angular distance. The 95% confidence interval of the resulting accuracy was calculated using the Wilson score method. This analysis evaluates discrimination among the investigated reference samples under identical fuel-aliquot, strip-batch, device, and acquisition conditions; it does not estimate performance for independent fuel samples, strip batches, devices, or measurement sessions.
Calibration quality was assessed both on the training set and by leave-one-out cross-validation (LOOCV) to estimate interpolation performance across the ColorChecker patch gamut. Colorimetric accuracy was quantified using CIEDE2000 (ΔE₀₀); hue accuracy was evaluated as the shortest angular difference (Δh) between corrected and reference values. For CIEDE2000 calculations, both image-derived and reference CIELAB values were expressed relative to the D65 white point.
The hue angle was computed in hue-saturation-value (HSV) space from the color-corrected RGB values and served as the analytical readout throughout this work. The RGB-to-HSV conversion requires no additional white-point parameter; however, the resulting hue values depend on the underlying RGB color space and white-balance processing.
For sample analysis, the color-correction matrix was applied to the full image, after which a fixed-coordinate ROI was extracted from the reaction zone of the test strip, excluding the strip edges to avoid boundary artifacts. Each pixel within the ROI was first transformed to HSV, and the representative hue value was obtained as the circular mean of the per-pixel hue angles, appropriate for angular data that may wrap across 0°. Because hue is ill-defined and noise-dominated at low chroma, a minimum-chroma criterion (CIELAB chroma C* > 5, computed per patch from the mean corrected CIELAB values) was applied in the ColorChecker evaluation, excluding the six nominally achromatic patches from the hue-error statistics. This procedure was again repeated for all 48 strip measurements. Bootstrap confidence intervals for pairwise class separations are provided in Table S3
2.6. Cross-Device and Batch Reproducibility Tests
Cross-device reproducibility was tested using a fixed target prepared from commercially available paper (ASIN B08C9ZKDJG, Boao, HR-Boao-1920; Dongguan Boao Network Technology Co., Ltd., Dongguan, Guangdong, China). The material was selected empirically because its apparent color under the PhotoBox illumination was similar to that of the Nile Red reaction zone. The target was therefore used solely as a physically invariant sample to isolate camera-dependent differences. It was placed at the same position and with the same dimensions as the test-strip reaction zone. Three images were recorded with each of three smartphones (Huawei P30, Google Pixel 7a, and Samsung Galaxy S22) under identical PhotoBox illumination. Image acquisition was performed using Open Camera with the same fixed settings applied throughout the study, including D65 white balance, ISO 50, an exposure time of 1/165 s, fixed focus, and a zoom factor of 1. Each image was subsequently processed using the corresponding in-frame ColorChecker calibration.
Batch-to-batch repeatability was evaluated using a second, independently prepared batch of test strips. Ethanol, RON95 E10, and diesel were selected as representative analytes and measured using four independent strips per fuel. Measurements were performed with the Huawei P30 under the same PhotoBox geometry, illumination, acquisition settings, and 60 ± 2 s readout interval used for the primary dataset.
2.7. Artificial Intelligence (AI)
Claude (Anthropic) was used at various stages of manuscript preparation to refine the manuscript’s focus, identify target audiences, optimize the title, suggest appropriate journals, identify missing citations, and review the draft manuscript and supplement for inconsistencies and calculation errors.
3. Results
3.1. Effect of the Diffuse Interior Coating
The contribution of the matte white interior coating (Section 2.3) to colorimetric accuracy was assessed by comparing per-patch CIEDE2000 (ΔE₀₀) errors across the 24-patch ColorChecker before and after application of the coating. Illumination, geometry, and acquisition settings were held constant; only the interior surface treatment differed between the two acquisitions. All values in this section were computed on uncorrected images, prior to the color-correction matrix, in order to isolate the optical contribution of the coating from that of the subsequent numerical correction.
Coating reduced the mean per-patch error from 6.38 to 3.90 (−39%) and the median from 6.15 to 3.75 (−39%). The close agreement between mean and median indicates a broad improvement across the chart rather than the suppression of a few outliers. The standard deviation across the 24 patches fell from 2.86 to 2.01 (−30%), and the number of patches exceeding ΔE₀₀ = 5 dropped from 18 to 7 (Table 1). The improvement was larger for the six achromatic patches (mean 7.15 → 3.90, −45%) than for the 18 chromatic ones (6.13 → 3.90, −36%).
The spatial distribution of the improvement is shown in Figure 4. The achromatic extremes, white and black, showed the largest pre-coating errors (13.4 each) and were among the patches that improved most after coating, dropping to 7.1 and 8.9, respectively. This is consistent with a diffuse surface suppressing both specular hotspots, which clip bright, high-reflectance patches, and stray light, which alters the apparent value of dark, low-reflectance patches. The coating therefore acts most strongly where non-diffuse reflections dominate the error budget.
A residual mean error of ΔE₀₀ ≈ 3.9 on uncorrected images is moderate in absolute terms. Absolute colorimetric fidelity is, however, not the target quantity of this system: the discriminating readout is the hue angle at moderate chroma, evaluated after color correction (Section 3.2).
3.2. Hue Accuracy After Color Correction
Since the analytical readout of this system is the hue angle rather than absolute color, calibration performance was evaluated as the angular hue deviation Δh from the reference values. Achromatic patches were excluded, as hue is undefined at vanishing chroma (Section 2.5).
Applying the color-correction matrix reduced the mean hue deviation across the 18 chromatic patches from 5.4° to 3.6° (−34%), with the maximum falling from 15.4° to 9.8° (Figure 5). The full per-patch breakdown, including cross-validated hue errors and the alternative CIE L*C*h° (LCh*) metric, is shown in Figure S2.
This global figure understates the improvement in the region relevant to the assay. The color-reaction zone of the Nile Red test strips is only moderately saturated, represented by five chromatic patches which are closest in hue to the actual strip responses: light skin (a2), orange (b1), moderate red (b3), orange yellow (b6) and magenta (c5). Across these five patches, the mean hue deviation fell from 5.1° to 1.6° (−70%), with a maximum residual of 4.1° (Table 2). Under leave-one-out cross-validation, i.e., with each patch predicted while excluded from the fit, the mean deviation over the same five patches was 1.8° (4.2° across all 18 chromatic patches; Figure S2a), confirming that the accuracy is not merely a training-set artifact. Calibration accuracy is therefore highest in precisely the hue and chroma range occupied by the samples, while the largest residual deviations remain confined to highly saturated patches that lie outside the analytical working range.
3.3. Substance Discrimination
Within the investigated reference dataset, the corrected hue values formed distinguishable clusters for the tested fuel and ethanol–gasoline samples.
Across the six replicate strips per fuel, the within-fuel scatter was small, with circular standard deviations between 0.6° and 3.5° (mean 1.5°, Table 3). The diesel-type fuels occupied the low positive-hue region (HVO100 7.7°, diesel 17.2°, biodiesel 22.6°), while the gasoline–ethanol blends formed a continuous, monotonic sequence spanning the 0° boundary from 95E5 (358.0°) to neat ethanol (319.6°).
Within the ethanol series, the hue angle shifted systematically with nominal ethanol content, with the largest step occurring between 95E10 and 95E20 (14.2°), the transition of principal regulatory interest. Adjacent blends were separated by 8.0° (E5→E10), 14.2° (E10→E20), 8.6° (E20→E50), and 7.7° (E50→ethanol), all substantially exceeding the replicate scatter.
The discriminating power can be placed on a common scale with the calibration accuracy of Section 3.2. The replicate scatter (mean circular SD 1.5°) is well below the hue separations between adjacent E5 to E20 reference blends (8 to 14°), while the calibration yielded a mean hue deviation of 1.6° (1.8° under leave-one-out cross-validation) across the five selected ColorChecker patches.
All neighboring fuel pairs differed significantly in hue angle (Welch’s t-test, Bonferroni-corrected, p < 0.05; Figure 6). Bootstrap confidence intervals for the pairwise circular-mean separations are provided in Table S3.
Internal LOSO-CV correctly assigned 46 of the 48 individual strip measurements to their corresponding reference classes, resulting in an internal classification accuracy of 95.8% (95% CI: 86.0 to 98.8%). All measurements of HVO100, diesel, biodiesel, 95E10, 95E20, 95E50, and ethanol were assigned correctly. Two 95E5 measurements were assigned to the 95E10 reference class; all misassignments were therefore restricted to the 95E5/95E10 pair. In particular, all 95E10 and 95E20 measurements were correctly distinguished. As the analysis was performed within the existing reference dataset, these results represent internal cross-validation rather than independent validation using unknown samples. The complete confusion matrix is provided in Table S4.
These results demonstrate analytical separability among known reference samples under the investigated conditions. However, statistical differences between the reference groups should not be interpreted as validated classification performance for unknown samples. The same measurements were used to characterize the fuel-specific hue distributions and to assess their separation. An independent blinded dataset is therefore recommended to determine the rates of correct, incorrect, and ambiguous assignments for previously unseen samples.
As an additional matrix-composition test, a laboratory-prepared RON98 E10 (obtained by adjusting RON98 E5 to a nominal 10% ethanol content) and a commercial ethanol-based e-fuel of the same nominal ethanol content were analyzed. Although both contained nominally 10% (v/v) ethanol, their mean hue values differed by approximately 12° (RON98 E10, 353.7 ± 2.1°; e-fuel, 342.0 ± 4.9°; n = 5 each; Table S5), a highly significant separation (Welch’s t-test, p = 0.004; Cohen’s d = 3.1; Figure S3), indicating that the solvatochromic response depends on the overall fuel matrix rather than on ethanol content alone.
3.4. Preliminary Assessment of Device and Strip-Batch Effects
Cross-device reproducibility was assessed using the fixed reference target described in Section 2.6. After individual ColorChecker correction, the mean hue angles obtained with the Huawei P30, Google Pixel 7a, and Samsung Galaxy S22 were 334.3°, 335.6°, and 338.3°, respectively (Table 4). The resulting inter-device standard deviation was 2.0° (range 4.0°), indicating that only a small residual camera-dependent variation remained after calibration.
Batch-to-batch repeatability was evaluated using a second, independently prepared batch of test strips. For three representative fuels, the hue values obtained with the new batch differed from those of the initial batch by only 0.2–0.6° (ethanol, 319.2° vs. 319.6°; 95E10, 349.4° vs. 350.0°; diesel, 17.4° vs. 17.2°, Table 5). Measurements of the second batch were based on four independent strips per fuel, with within-batch circular standard deviations of ≤1.2°. Both sources of variability were small relative to the analytical signal. The inter-device standard deviation (2.0°) and the within-batch replicate scatter (≤1.2°) were comparable to the mean within-fuel scatter of the primary dataset (1.5°) and remained well below the ~8° to 14° hue separation between neighboring ethanol blends in the principal analytical range (Section 3.3). These preliminary results indicate low device- and batch-related variability under the investigated conditions.
3.5. Integrated Smartphone Application
Based on the reference data acquired with Open Camera, a browser-based smartphone application was subsequently developed to illustrate how the workflow could be applied in practice (Figure 7). The app requires no manual colorimetric evaluation or external data processing: the user captures a single image of the test strip together with the in-frame ColorChecker, and the result is calculated on-device.
Because the strip and the calibration target occupy fixed positions in the PhotoBox holder, the per-image color correction described in Section 2.4 is applied automatically using predefined patch coordinates, without manual region selection. After correction, the hue angle of the reaction zone is computed and assigned to the nearest reference fuel cluster by shortest angular distance.
To reduce overconfident outputs near cluster boundaries, an operational 2:1 distance-ratio criterion was implemented. A single reference match is displayed only when the angular distance to the second-nearest cluster is at least twice that to the nearest cluster. Otherwise, both candidate classes are displayed. The ratio is a user-adjustable parameter in the app (default 2:1). The default of 2:1 was chosen pragmatically based on the reference dataset (Table S6), increasing the ratio reduced misassignments from 2 (no criterion) to 1 (1.5:1 and 2:1) and 0 (3:1), at the cost of 4, 6, and 9 ambiguous outputs, respectively. The criterion is therefore an operational ambiguity rule rather than a statistically established classification threshold.
This implementation confirms that the calibration, region extraction, and hue evaluation developed in the preceding sections can be executed end-to-end on consumer hardware. We present it as a proof-of-concept realization of the workflow rather than as an independently validated classification system; a systematic assessment of classification accuracy across blind samples remains the subject of ongoing work.
4. Discussion
The results show that a calibrated smartphone hue readout can separate a broad panel of fuels and ethanol–gasoline blends under controlled imaging conditions. Three aspects merit closer discussion: the role of camera calibration, the chemical basis and limits of the discrimination, and the scope of the validation presented here.
The camera output was initially expected to approximate a linear representation of the sensor response. Subsequent analysis showed that the available Camera2 implementation did not expose unprocessed RAW data, so the recorded images inevitably contain device-specific demosaicing and non- linear tone processing. Rather than attempting to reconstruct the proprietary pipeline, we treated the transformation as an empirical, per- image calibration between recorded RGB and the in- frame ColorChecker. More rigorous colorimetric workflows may additionally linearize RGB data and transform them into device- independent spaces such as CIE XYZ or CIELAB; however, the present approach deliberately retains HSV hue as a simple operational readout for fuel discrimination. This contrasts with more elaborate calibration schemes, e. g., a 20- parameter third- order polynomial adaptation in CIE u ′ v ′ space with thin- plate- spline interpolation computed off- device; our in- frame 3 × 3 correction trades some colorimetric rigor for a fully on- device, portable workflow [26]. Likewise, whereas hardware approaches such as a smartphone- coupled integrating sphere enforce reproducibility through controlled illumination optics [27], our method achieves it computationally via the in- frame reference, requiring no attached optics. This choice is central to the method’ s portability. Because the reference and the sample are imaged in the same frame under identical illumination, a single per- image mapping can compensate for much of the combined illumination, sensor, and processing differences, without any device-specific pre-calibration. This correction cannot fully remove non- linear tone effects or device-specific differences. After per- image calibration, the residual scatter across the three camera sensors (the RYYB system used here and two Quad- Bayer- RGB devices) was only 2.0° (SD), indicating that the in- frame correction yields good cross- device agreement for the fixed paper target rather than merely reproducing the reference chart [36]. Broader cross- device validation nonetheless remains necessary to record more device-specific datasets. Because the color reference and the sample occupy different image regions (Figure 1b), the global 3 × 3 correction does not compensate for position- dependent differences in illumination or lens vignetting; the symmetric 45° diffuse illumination is expected to minimize this, but spatial homogeneity was not explicitly characterized.
More advanced calibration strategies may further reduce residual device- and illumination-dependent differences. Root-polynomial color correction provides a non-linear extension of conventional matrix-based calibration while maintaining exposure homogeneity [23]. More recently, CCMNet has demonstrated that calibrated camera-specific color correction matrices can be exploited to improve cross-camera color constancy and generalization to previously unseen sensors [37]. Physics-informed raw-to-raw approaches such as Neural Physical Model (NPM) additionally incorporate sensor and illumination characteristics into the mapping between cameras [38]. These approaches were not evaluated here and, particularly in the case of raw-domain methods, are not directly transferable to the processed RGB images available from the present smartphone workflow. Nevertheless, they represent promising directions for further reducing cross-device residuals in future implementations.
A further consideration is the intrinsic fluorescence of Nile Red, which contributes to the camera-recorded color in addition to reflected light [39]. For fluorescent materials, the measured color generally represents a combination of reflected and luminescence-derived radiation, with the latter depending on the illumination’s spectral power distribution [40]. In the present setup, broadband white LEDs were used without selective fluorescence excitation or emission filtering; thus, reflected and fluorescent contributions were not separated. Consequently, the ColorChecker-based correction should be regarded as an empirical correction of the total measured color rather than a rigorous spectral correction of the fluorescent component.
Chemically, the discrimination between liquids follows the expected solvatochromic behavior of Nile Red. The ethanol series showed a monotonic change in hue with increasing nominal ethanol content. The approximately 12° difference between the laboratory-prepared RON98 E10 and the commercial e-fuel shows that the same nominal ethanol content does not guarantee an identical hue response as described before. Because 95E20 and 95E50 were blended from 95E5 while 95E10 was a commercial product, adjacent steps may partly reflect base-gasoline differences. The exact ethanol contents of the commercial fuels were not measured separately. Deviations from the nominal compositions and differences in the base gasoline may therefore have contributed to the two E5-to-E10 misassignments. However, the laboratory-prepared RON98 E10 deviated from the commercial 95E10 by only ~3.7°, well below the 14.2° E10→E20 step, and commercial 95E5 fuels from four brands showed no significant hue differences in our previous study [28].
Water-content effects are expected to depend on the ethanol fraction. Preliminary experiments with RON95 E5 showed no apparent hue change when the fuel was contacted with water up to its miscibility limit. At higher ethanol fractions, greater amounts of water can remain dissolved in the fuel phase [41,42]. If present, this additional water would be expected to further increase the local polarity experienced by Nile Red and, in the present sensor system, shift the visible hue further toward the magenta/blue region.
Hue was intentionally used as a single feature because it is comparatively insensitive to overall intensity and gain variations and provides a simple and interpretable classification variable. However, this simplicity comes at the cost of discarding potentially useful information contained in saturation, value, or alternative color-space descriptors such as CIE LCh°. Multivariate feature combinations (hue with saturation) or supervised classification approaches could therefore further increase class margins. Such approaches were not evaluated in the present study and remain a subject for future work.
The validation presented here is deliberately internal. Cross-validation on the reference dataset yielded 95.8% correct assignment. Because the reference classes were established from measurements of the same fuel samples, this value reflects classification performance within the studied dataset rather than predictive accuracy for new samples. No blinded external validation was performed in the present study. Although the Leave-One-Strip-Out (LOSO) cross-validation scheme rigorously prevents data leakage at the individual strip level, it remains an internal validation framework within a defined set of reference samples. However, previous experiments using the same Nile Red sensor chemistry included commercially sourced RON95 E5 fuels from multiple suppliers and showed no significant supplier-dependent differences in the hue response. This provides preliminary evidence for robustness against supplier-related fuel variation but does not replace prospective blinded validation of the present classification workflow. The batch- and device-robustness tests, while encouraging, cover only a single additional batch and three devices; with two batches, the observed ≤ 0.6° difference is a pairwise comparison and does not quantify batch-to-batch variance. A blind study with independent samples, additional strip batches, and a wider device range is required before the method can be regarded as a validated classification tool. Temperature and humidity were not actively controlled; both may affect the evaporation kinetics in a field use case. Within these limits, the results support the intended use: a rapid, low-cost field pre-screen for the broad compositional class of a fuel.
5. Conclusions
We have demonstrated a portable, calibrated smartphone-colorimetry workflow that uses the hue shift of solvatochromic Nile Red test strips to discriminate a broad panel of fuels and ethanol–gasoline blends. By imaging a ColorChecker reference in the same frame as the sample within a mechanically fixed PhotoBox, the method achieves a per-image color calibration that makes the hue readout reproducible across strip batches (≤0.6°) and three devices using a fixed target (2.0°), well below the 8–14° separation between the regulatorily relevant blends. The calibrated hue tracks the effective polarity of the fuel matrix rather than ethanol content alone, enabling broad-class discrimination and revealing matrix effects that a nominal ethanol figure would miss. Integration of the full pipeline into an on-device application illustrates the practical implementation of the workflow towards a field-deployable device usable without colorimetric expertise. We present the system as a rapid screening tool for broad fuel classes; extending it toward validated identification of unknown samples, through blinded testing across additional batches, devices, and fuel matrices, is the logical next step. Beyond fuel analysis, the in-frame calibration approach could be transferred to other colorimetric test strips. This could include the controlled characterization of pH-sensitive paper sensors used as passive smart dust for drone-based hazard localization [43]. Such distributed sensing concepts are also discussed in the context of spatial chemical mapping [44].
Rapid classification of liquid fuels is most directly applicable to fresh samples, for example in cases of incorrect refueling or blend screening at the pump. Fluorescent test strips have also been used to detect petroleum hydrocarbons extracted from water and soil [45]. Extension to weathered, water- or soil-contacted samples such as tanker-truck accidents or tank leaks would first require assessment of water and ageing effects and is therefore left as a perspective. The on-device app handles acquisition, calculation, and result display, so that the readout itself requires no colorimetric expertise.
Supplementary Materials
The following supporting information is available on Preprints.org: Figure S1: 3D CAD renderings of the PhotoBox and test-strip holder; Table S1: Specifications of the Huawei P30 main camera sensor; Table S2: ColorChecker reference targets used for color correction; Table S3: Pairwise separation of neighboring fuel classes with 95% bootstrap confidence intervals; Table S4: Confusion matrix of the internal leave-one-strip-out cross-validation (LOSO-CV); Figure S2: HSV and CIE LCh* hue errors of the ColorChecker patches before and after color correction and under LOOCV; Table S5: Hue angles and statistical comparison of laboratory-prepared RON98 E10 and commercial e-fuel; Figure S3: HSV hue distributions of RON98 E10 and e-fuel; Table S6: Effect of the distance-ratio criterion on internal fuel-class assignments.
Author Contributions
Conceptualization, T.N., H.K., and M.G.W.; methodology, T.N., M.G.W., and P.P.N.; software, T.N.; validation, T.N.; formal analysis, T.N.; data curation, T.N.; writing original draft preparation, T.N.; writing review and editing, T.N., P.P.N., and M.G.W. All authors have read and agreed to the published version of the manuscript.
Funding
This research was supported by the MI-Ideen Typ 1 funding line of the Federal Institute for Materials Research and Testing (BAM) under the funding number Ideen_2021_005.
Data Availability Statement
The analysis scripts and raw ColorChecker/hue data are available from the corresponding author upon reasonable request. The smartphone application is not publicly released, as it is subject to potential further development and commercialization; its algorithm is fully described in Section 2.4 and Section 2.5, and 3.5.
Conflicts of Interest
The authors declare no conflicts of interest.
References
- Fan, Y.; Li, J.; Guo, Y.; Xie, L.; Zhang, G. Digital Image Colorimetry on Smartphone for Chemical Analysis: A Review. Measurement 2021, 171, 108829. [Google Scholar] [CrossRef]
- Quesada-González, D.; Merkoçi, A. Mobile Phone-Based Biosensing: An Emerging “Diagnostic and Communication” Technology. Biosens. Bioelectron. 2017, 92, 549–562. [Google Scholar] [CrossRef] [PubMed]
- Soares, S.; Fernandes, G.M.; Rocha, F.R.P. Smartphone-Based Digital Images in Analytical Chemistry: Why, When, and How to Use. TrAC Trends Anal. Chem. 2023, 168, 117284. [Google Scholar] [CrossRef]
- Aydindogan, E.; Guler Celik, E.; Timur, S. Paper-Based Analytical Methods for Smartphone Sensing with Functional Nanoparticles: Bridges from Smart Surfaces to Global Health. Anal. Chem. 2018, 90, 12325–12333. [Google Scholar] [CrossRef] [PubMed]
- European Commission. Fuel Quality. Directorate-General for Climate Action. Available online: https://climate.ec.europa.eu/eu-action/transport-decarbonisation/fuel-quality_en (accessed on 23 July 2026).
- ePURE. The EU and E20: European Commission Confirms Important Role of Higher Ethanol Blends in De-Fossilising Road Transport, Securing Energy Supply. 24 April 2026. Available online: https://www.epure.org/press-release/the-eu-and-e20-european-commission-confirms-important-role-of-higher-ethanol-blends-in-de-fossilising-road-transport-securing-energy-supply/ (accessed on 23 July 2026).
- Reichardt, C. Solvatochromic Dyes as Solvent Polarity Indicators. Chem. Rev. 1994, 94, 2319–2358. [Google Scholar] [CrossRef]
- Gajo, C.; Shchepanovska, D.; Jones, J.F.; Karras, G.; Malakar, P.; Greetham, G.M.; Hawkins, O.A.; Jordan, C.J.C.; Curchod, B.F.E.; Oliver, T.A.A. Nile Red Fluorescence: Where’s the Twist? J. Phys. Chem. B 2024, 128, 11768–11775. [Google Scholar] [CrossRef] [PubMed]
- Deye, J.F.; Berger, T.A.; Anderson, A.G. Nile Red as a Solvatochromic Dye for Measuring Solvent Strength in Normal Liquids and Mixtures of Normal Liquids with Supercritical and Near-Critical Fluids. Anal. Chem. 1990, 62, 615–622. [Google Scholar] [CrossRef]
- Cataldo, F. Conventional and Green Rubber Plasticizers Classified through Nile Red [E(NR)] and Reichardt’s Polarity Scale [ET(30)]. Liquids 2024, 4, 305–321. [Google Scholar] [CrossRef]
- Yablon, D.G.; Schilowitz, A.M. Solvatochromism of Nile Red in Nonpolar Solvents. Appl. Spectrosc. 2004, 58, 843–847. [Google Scholar] [CrossRef] [PubMed]
- Gotor, R.; Bell, J.; Rurack, K. Tailored Fluorescent Solvatochromic Test Strips for Quantitative On-Site Detection of Gasoline Fuel Adulteration. J. Mater. Chem. C 2019, 7, 2250–2256. [Google Scholar] [CrossRef]
- Bordbar, M.M.; Tashkhourian, J.; Hemmateenejad, B. Paper-Based Optical Nose Made with Bimetallic Nanoparticles for Monitoring Ignitable Liquids in Gasoline. ACS Appl. Mater. Interfaces 2022, 14, 8333–8342. [Google Scholar] [CrossRef] [PubMed]
- El Seoud, O.A.; Loffredo, C.; Galgano, P.D.; Sato, B.M.; Reichardt, C. Have Biofuel, Will Travel: A Colorful Experiment and a Different Approach to Teach the Undergraduate Laboratory. J. Chem. Educ. 2011, 88, 1293–1297. [Google Scholar] [CrossRef]
- Li, Z.; Sahoo, S.R.; Shen, S.; Sun, H.; Ågren, H.; Zhang, M.; Baryshnikov, G.; Zhu, L. Charge-Rearrangement Averaged Dye Design for Precise, Real-Time, and Portable Monitoring of Complex Solvent Environments. Angew. Chem. Int. Ed. 2025, 64, e202513349. [Google Scholar] [CrossRef] [PubMed]
- Toledo, V.P.; Rodembusch, F.S. Optical Molecular Sensing Strategies for Fuel Quality Monitoring: From Polarity-Sensitive Probes to Emerging Portable Technologies for Adulterant Detection. ACS Sens. 2026, 11, 7791–7812. [Google Scholar] [CrossRef] [PubMed]
- Poblete, T.; Millán, D.; Rezende, M.C. Synergism in the Solvation of Solvatochromic Probes in Binary Mixtures with Ionic Liquids. J. Mol. Liq. 2023, 391, 123227. [Google Scholar] [CrossRef]
- Spange, S. Polarity of Organic Solvent/Water Mixtures Measured with Reichardt’s B30 and Related Solvatochromic Probes—A Critical Review. Liquids 2024, 4, 191–230. [Google Scholar] [CrossRef]
- Hou, Y.; Bardo, A.M.; Martinez, C.; Higgins, D.A. Characterization of Molecular Scale Environments in Polymer Films by Single Molecule Spectroscopy. J. Phys. Chem. B 2000, 104, 212–219. [Google Scholar] [CrossRef]
- Li, D.; Mills, C.A.; Cooper, J.M. Microsystems for Optical Gas Sensing Incorporating the Solvatochromic Dye Nile Red. Sens. Actuators B Chem. 2003, 92, 73–80. [Google Scholar] [CrossRef]
- Fan, K.; Liu, W.; Miao, Y.; Li, Z.; Liu, G. Engineering Strategies for Advancing Optical Signal Outputs in Smartphone-Enabled Point-of-Care Diagnostics. Adv. Intell. Syst. 2023, 5, 2200285. [Google Scholar] [CrossRef]
- Cebrián, P.; Pérez-Sienes, L.; Sanz-Vicente, I.; López-Molinero, Á.; de Marcos, S.; Galbán, J. Solving Color Reproducibility between Digital Devices: A Robust Approach of Smartphones Color Management for Chemical (Bio)Sensors. Biosensors 2022, 12, 341. [Google Scholar] [CrossRef] [PubMed]
- Finlayson, G.D.; Mackiewicz, M.; Hurlbert, A. Color Correction Using Root-Polynomial Regression. IEEE Trans. Image Process. 2015, 24, 1460–1470. [Google Scholar] [CrossRef] [PubMed]
- Yu, H.; Cao, T.; Li, B.; Dong, R.; Zhou, H. A Method for Color Calibration Based on Simulated Annealing Optimization. In Proceedings of the 2016 3rd International Conference on Information Science and Control Engineering (ICISCE), Beijing, China, 8–10 July 2016; IEEE: Piscataway, NJ, USA, 2016; pp. 54–58. [Google Scholar] [CrossRef]
- Mutlu, A.Y.; Kılıç, V.; Özdemir, G.K.; Bayram, A.; Horzum, N.; Solmaz, M.E. Smartphone-Based Colorimetric Detection via Machine Learning. Analyst 2017, 142, 2434–2441. [Google Scholar] [CrossRef] [PubMed]
- Kim, S.D.; Koo, Y.; Yun, Y. A Smartphone-Based Automatic Measurement Method for Colorimetric pH Detection Using a Color Adaptation Algorithm. Sensors 2017, 17, 1604. [Google Scholar] [CrossRef] [PubMed]
- Cebrián, P.; Escuín, J.M.; Salafranca, J.; Jarne, C.; López-Molinero, Á.; de Marcos, S.; Galbán, J.; Sanz-Vicente, I. DUNI: A Portable Smartphone-Coupled Integrating Sphere for Controlled Illumination and Reliable Colorimetric Sensing: Analytical Applications. Sensors 2026, 26, 3329. [Google Scholar] [CrossRef] [PubMed]
- Nerger, T.; Rathsack, T.; Neumann, P.P.; Weller, M.G. Passive Smart Dust for Detecting and Classifying Fuel Spills: Drone-Based Colorimetric Imaging Using Solvatochromic Paper Sensors. Drones 2026, 10, 522. [Google Scholar] [CrossRef]
- Grum, F.; Luckey, G.W. Optical Sphere Paint and a Working Standard of Reflectance. Appl. Opt. 1968, 7, 2289–2294. [Google Scholar] [CrossRef] [PubMed]
- Gibertoni, G.; Rovati, L. Characterization of High-Reflectance Diffuse Coatings for 3D-Printed Optics. Acta IMEKO 2026, 15(2), 1–10. [Google Scholar] [CrossRef]
- Altamimi, M.M.S.; Saeed, U.; Al-Turaif, H. BaSO₄/TiO₂ Microparticle Embedded in Polyvinylidene Fluoride-Co-Hexafluoropropylene/Polytetrafluoroethylene Polymer Film for Daytime Radiative Cooling. Polymers 2023, 15, 3876. [Google Scholar] [CrossRef] [PubMed]
- Su, L.; Zhao, Z.; Tang, M.; He, C.; Wang, S. Self-Cleaning BaSO₄/TiO₂/HGM/Epoxy Diffuse Reflection Composite Coating for Improving the Lighting Level. ACS Appl. Nano Mater. 2024, 7, 10293–10302. [Google Scholar] [CrossRef]
- Li, L.; Yan, J.; Wang, T.; Zhao, Z.-J.; Zhang, J.; Gong, J.; Guan, N. Sub-10 nm Rutile Titanium Dioxide Nanoparticles for Efficient Visible-Light-Driven Photocatalytic Hydrogen Production. Nat. Commun. 2015, 6, 5881. [Google Scholar] [CrossRef] [PubMed]
- Zhang, J.; Zhou, P.; Liu, J.; Yu, J. New Understanding of the Difference of Photocatalytic Activity among Anatase, Rutile and Brookite TiO₂. Phys. Chem. Chem. Phys. 2014, 16, 20382–20386. [Google Scholar] [CrossRef] [PubMed]
- Wang, N.; et al. Bayesian Optimized ANFIS Network Using Grid Partition and Feature Spectrum for Urban Light Pollution Assessment. IEEE Photonics J. 2025, 17, 6800311. [Google Scholar] [CrossRef]
- Quoc, T.N.; Phan, M.-V.; Dang, K.P.; Ngo, H.G.; Nguyen, P.T.T.; Hoang, V.T.; Do, T.-L.; Tran, T.-B.; Do, M.-H.; Nguyen, L.-K.T.; et al. Smartphone-Based Colorimetric Sensing with Reference Calibration and Ensemble Machine Learning for Enhanced Detection of Nitrite and Ammonium Ions. Anal. Chim. Acta 2026, 1388, 345097. [Google Scholar] [CrossRef] [PubMed]
- Kim, D.; Afifi, M.; Kim, D.; Brown, M.S.; Kim, S.J. CCMNet: Leveraging Calibrated Color Correction Matrices for Cross-Camera Color Constancy. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), 2025; pp. 6198–6208. [Google Scholar] [CrossRef]
- Grönquist, P.; Tulyakov, S.; Dai, D. Beyond Calibration: Physically Informed Learning for Raw-to-Raw Mapping. arXiv 2025, arXiv:2506.08650. [Google Scholar] [CrossRef]
- Dutta, A.K.; Kamada, K.; Ohta, K. Spectroscopic Studies of Nile Red in Organic Solvents and Polymers. J. Photochem. Photobiol. A Chem. 1996, 93, 57–64. [Google Scholar] [CrossRef]
- Imura, K.; Nagai, Y. Multi-Wavelength Excitation Method for Measuring FWA-Treated Paper. Color Res. Appl. 2018, 43, 17–26. [Google Scholar] [CrossRef]
- Gramajo de Doz, M.B.; Bonatti, C.M.; Sólimo, H.N. Water Tolerance and Ethanol Concentration in Ethanol-Gasoline Fuels at Three Temperatures. Energy Fuels 2004, 18, 334–337. [Google Scholar] [CrossRef]
- French, R.; Malone, P. Phase Equilibria of Ethanol Fuel Blends. Fluid Phase Equilib. 2005, 228–229, 27–40. [Google Scholar] [CrossRef]
- Nerger, T.; Neumann, P.P.; Weller, M.G. Drone-Based Localization of Hazardous Chemicals by Passive Smart Dust. Sensors 2024, 24, 6195. [Google Scholar] [CrossRef] [PubMed]
- Mondal, I.; Haick, H. Smart Dust for Chemical Mapping. Adv. Mater. 2025, 37, 2419052. [Google Scholar] [CrossRef] [PubMed]
- Mansurova, M.; Gotor, R.; Johann, S.; Neumann, P.P.; Bartholmai, M.; Rurack, K.; Bell, J. Fluorescent Hydrophobic Test Strips with Sterically Integrated Molecular Rotors for the Detection of Hydrocarbons in Water and Soil with an Embedded Optical Read-Out. Energy Fuels 2023, 37, 10544–10549. [Google Scholar] [CrossRef]
Figure 1.
External image of the mobile photo box with sample holder/slider (a). Internal view of the box showing sample pad region of interest (ROI) of test strips and ColorChecker Nano used for calibration (b).
Figure 1.
External image of the mobile photo box with sample holder/slider (a). Internal view of the box showing sample pad region of interest (ROI) of test strips and ColorChecker Nano used for calibration (b).

Figure 2.
Representative color responses of the Nile Red test strips after exposure to the investigated fuels and ethanol–gasoline blends, recorded 1 min after sample contact. The dashed outline marks the additional comparison between eFuel and nominal standard fuel samples.
Figure 2.
Representative color responses of the Nile Red test strips after exposure to the investigated fuels and ethanol–gasoline blends, recorded 1 min after sample contact. The dashed outline marks the additional comparison between eFuel and nominal standard fuel samples.

Figure 3.
Schematic of the colorimetric PhotoBox for smartphone-based readout. (a) Side view of the complete assembly; (b) top view of the colorimetric measurement unit, corresponding to the region marked.
Figure 3.
Schematic of the colorimetric PhotoBox for smartphone-based readout. (a) Side view of the complete assembly; (b) top view of the colorimetric measurement unit, corresponding to the region marked.

Figure 4.
CIEDE2000 (ΔE₀₀) error heatmaps of the 24-patch ColorChecker before (a) and after (b) application of the diffuse interior coating. Values were obtained from uncorrected images; lower values indicate closer agreement with the reference colors.
Figure 4.
CIEDE2000 (ΔE₀₀) error heatmaps of the 24-patch ColorChecker before (a) and after (b) application of the diffuse interior coating. Values were obtained from uncorrected images; lower values indicate closer agreement with the reference colors.

Figure 5.
Absolute HSV hue errors of the 18 chromatic ColorChecker patches before (a) and after (b) color correction. Values indicate angular deviations from the reference hues in degrees. Achromatic patches are shown as n/a.
Figure 5.
Absolute HSV hue errors of the 18 chromatic ColorChecker patches before (a) and after (b) color correction. Values indicate angular deviations from the reference hues in degrees. Achromatic patches are shown as n/a.

Figure 6.
HSV hue angles of ethanol, ethanol–gasoline (RON95) blends, HVO100, diesel, and biodiesel (n = 6 strips per fuel). Brackets indicate Welch’s t-tests between neighboring groups, Bonferroni-corrected for seven comparisons (* p < 0.05, ** p < 0.01, *** p < 0.001).
Figure 6.
HSV hue angles of ethanol, ethanol–gasoline (RON95) blends, HVO100, diesel, and biodiesel (n = 6 strips per fuel). Brackets indicate Welch’s t-tests between neighboring groups, Bonferroni-corrected for seven comparisons (* p < 0.05, ** p < 0.01, *** p < 0.001).

Figure 7.
Workflow of the smartphone web application for image-specific color calibration and hue-based fuel classification on a mobile device.
Figure 7.
Workflow of the smartphone web application for image-specific color calibration and hue-based fuel classification on a mobile device.

Table 1.
Effect of the diffuse interior coating on ColorChecker CIEDE2000 (ΔE₀₀) errors. Statistics refer to the 24 patches evaluated in one uncorrected image per condition, before numerical color correction.
Table 1.
Effect of the diffuse interior coating on ColorChecker CIEDE2000 (ΔE₀₀) errors. Statistics refer to the 24 patches evaluated in one uncorrected image per condition, before numerical color correction.
| Metric (n = 24 patches) | Uncoated | Coated | Change |
| Mean ΔE₀₀ | 6.38 | 3.90 | −39% |
| Median ΔE₀₀ | 6.15 | 3.75 | −39% |
| SD of ΔE₀₀ | 2.86 | 2.01 | −30% |
| Maximum ΔE₀₀ | 13.4 | 8.9 | — |
| Patches with ΔE₀₀ > 5 | 18 | 7 | — |
| Chromatic patches (n = 18), mean |
6.13 | 3.90 | −36% |
| Achromatic patches (n = 6), mean |
7.15 | 3.90 | −45% |
Table 2.
Absolute HSV hue deviations (Δh) before and after color correction for five ColorChecker patches representing the test-strip color range. Values correspond to the example in Figure 5; the mean across all 18 chromatic patches is included for comparison.
Table 2.
Absolute HSV hue deviations (Δh) before and after color correction for five ColorChecker patches representing the test-strip color range. Values correspond to the example in Figure 5; the mean across all 18 chromatic patches is included for comparison.
| Patch | Hue analogue | Δh before (°) | Δh after (°) |
| a2 | Light skin | 3.4 | 2.7 |
| b1 | Orange | 3.4 | 0.6 |
| b3 | Moderate red | 6.2 | 0.3 |
| b6 | Orange yellow | 6.5 | 4.1 |
| c5 | Magenta | 6.2 | 0.1 |
| Mean | 5.1 | 1.6 | |
| All chromatic patches (n = 18) | 5.4 | 3.6 | |
Table 3.
Circular mean hue, circular standard deviation (SD), and leave-one-strip-out cross-validation (LOSO-CV) results for the eight reference classes (n = 6 strips per class). Assignments indicate correctly classified strips relative to the total per class.
Table 3.
Circular mean hue, circular standard deviation (SD), and leave-one-strip-out cross-validation (LOSO-CV) results for the eight reference classes (n = 6 strips per class). Assignments indicate correctly classified strips relative to the total per class.
| Fuel class | Circular mean hue (°) | Circular SD (°) | LOSO-CV assignments |
| HVO100 | 7.74 | 1.77 | 6/6 |
| Diesel | 17.19 | 1.09 | 6/6 |
| Biodiesel | 22.58 | 0.82 | 6/6 |
| 95E5 | 358.05 | 3.46 | 4/6 |
| 95E10 | 350.04 | 1.74 | 6/6 |
| 95E20 | 335.88 | 1.86 | 6/6 |
| 95E50 | 327.29 | 0.68 | 6/6 |
| Ethanol | 319.56 | 0.62 | 6/6 |
Table 4.
HSV values of a fixed paper target measured using three smartphones after per-image ColorChecker correction (n = 3 images per device). SD denotes the within-device hue standard deviation.
Table 4.
HSV values of a fixed paper target measured using three smartphones after per-image ColorChecker correction (n = 3 images per device). SD denotes the within-device hue standard deviation.
| Phone | Mean hue (°) | Internal SD | Saturation | Value |
| Huawei P30 | 334.3 | 0.8 | 0.84 | 0.90 |
| Google Pixel 7a | 335.6 | 0.6 | 0.80 | 0.92 |
| Samsung S22 | 338.3 | 0.8 | 0.83 | 0.92 |
Table 5.
Comparison of calibrated hue values between two independently prepared strip batches. New-batch values are circular mean ± circular standard deviation (n = 4 strips per fuel); initial-batch values are circular means (n = 6 strips per fuel). The final column gives the absolute difference between batch means in degrees.
Table 5.
Comparison of calibrated hue values between two independently prepared strip batches. New-batch values are circular mean ± circular standard deviation (n = 4 strips per fuel); initial-batch values are circular means (n = 6 strips per fuel). The final column gives the absolute difference between batch means in degrees.
| Fuel | New (Mean ± SD) | Old (Mean ± SD) | |Δ| (°) |
| RON95E10 | 349.4 ± 0.7° | 350.0 ± 1.7° | 0.6 |
| Ethanol | 319.2 ± 1.0° | 319,6 ± 0.6° | 0.4 |
| Diesel | 17.4 ± 1.2° | 17,2 ± 1.1° | 0.2 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2026 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.