1 Introduction

The dairy industry, as is typical in the agri-food sector, requires large volumes of water. Studies on the water footprint of animal products estimate that up to 1000 L of H2O are necessary to produce 1 L of milk [1]. As a result, this sector generates huge amount of wastewater, around 0.2–10 L per liter of processed milk [2]. Dairy wastewater is characterized by high organic matter content, hardly biodegradable and with tendency to form colloidal suspensions [1], which can damage the natural water streams in the event of inadequate handling [3]. Its composition includes pollutants that result from the processed raw materials, chemicals, and technological additives. Hence, when these effluents are discharged into rivers, they contribute to eutrophication due to the surplus of nutrients like phosphorus and N-compounds. Treating dairy effluents is of crucial importance not only for environmental preservation, but also for water reuse in industrial processes [2]. In recent years, the regulations have become more stringent and thus, to stay in compliance with the discharge limits is becoming a burden for most dairies [4,5,6].

Anaerobic biological methods are popular to treat dairy effluents [4, 7,8,9,10,11], despite the long times required to ensure a good performance. Physicochemical methods such as coagulation and adsorption [6, 12], as well as chemical processes [13], have been employed as well. The former methods can only transfer the contaminants between different phases, whereas the second ones are able to destroy them, eventually leading to high removal of chemical oxygen demand (COD) and total organic carbon (TOC). Greater effectiveness has been achieved by means of electrochemical technologies. However, little information is still available on their use, being limited to either single electrocoagulation (EC) with Fe or Al anodes [14,15,16,17,18,19], EC coupled with chemical Fenton and ozonation [20] and electro-oxidation (EO) with Pt [21] or dimensionally stables anodes (DSA®) [3, 22]. More research is then needed to clarify the feasibility of sequential electrochemical processes for treating cheese whey wastewater.

Lately, EC and several electrochemical advanced oxidation processes (EAOPs) are receiving great attention for the removal of organic pollutants from water because they allow efficient decontamination in compact reactors at moderate costs [23,24,25,26]. EC, an alternative phase separation method to chemical coagulation, is a traditional electrochemical technology based on the release of Fe2+ or Al3+ cations from dissolution of a sacrificial Fe or Al anode, respectively, as follows [25, 27,28,29,30]:

$${\text{F}}{{\text{e}}_{({\text{s}})}} \to {\text{F}}{{\text{e}}^{2+}}_{{({\text{aq}})}}+2{{\text{e}}^ - }$$
(1)
$${\text{A}}{{\text{l}}_{({\text{s}})}} \to {\text{A}}{{\text{l}}^{3+}}_{{({\text{aq}})}}+3{{\text{e}}^ - }$$
(2)

Simultaneously, the cathode generates H2 bubbles and OH anions. This leads to the formation of active coagulants such as insoluble metal hydroxides by reactions (3) and (4). Flocs are formed, being aggregated in particles of large surface area that remain as a gelatinous suspension able to remove pollutants by coagulation, whereas H2 gas promotes flotation of the aggregates.

$$4{\text{F}}{{\text{e}}^{2+}}_{{({\text{aq}})}}+10{{\text{H}}_2}{\text{O}}+{{\text{O}}_{2({\text{g}})}} \to 4{\text{Fe}}{({\text{OH}})_{3({\text{s}})}}+8{{\text{H}}^+}$$
(3)
$${\text{A}}{{\text{l}}^{3+}}_{{({\text{aq}})}}+3{{\text{H}}_2}{\text{O}} \to {\text{Al}}{({\text{OH}})_{3({\text{s}})}}+3{{\text{H}}^+}$$
(4)

The electrolytic dissolution of Fe anode produces insoluble flocs of Fe(OH)2 at pH > 9 and Fe(OH)3 at pH > 3 in the presence of dissolved O2 gas from reaction (3) [25]. On the other hand, the Al(OH)3 flocs can also polymerize to Aln(OH)3n species.

The effectiveness of EAOPs for the degradation of organic pollutants is due to the generation of hydroxyl radicals (OH) on site. They include EO, electro-Fenton (EF) and photoelectro-Fenton (PEF) as main technologies. EO is the most popular EAOP, in which pollutants are destroyed in an undivided electrolytic cell via direct oxidation at the anode M, at high current, pre-eminently by indirect mediated oxidation with physisorbed hydroxyl radicals (M(OH)) formed at the anode surface from water oxidation via reaction (5) [23, 24]:

$${\text{M}}+{{\text{H}}_2}{\text{O}} \to {\text{M}}{(^ \bullet }{\text{OH}})+{{\text{H}}^+}+{{\text{e}}^ - }$$
(5)

Non-active and active anodes show different ability to produce M(OH) [23, 31,32,33,34]. The best non-active anodes are boron-doped diamond (BDD) thin films, which yield much larger amounts of M(OH) as compared to active anodes like Pt and DSA®. The latter anodes possess lower O2-evolution overpotential and higher M–OH interaction, leading to a significant transformation of M(OH) into weak chemisorbed oxidant MO [23,24,25].

The EF and PEF processes are based on the in situ generation of H2O2 from O2 gas reduction by reaction (6), which is very effective using carbonaceous cathodes such as carbon felt [35,36,37,38], or carbon-polytetrafluoroethylene (PTFE) in air-diffusion devices [31,32,33]. The presence or addition of a catalytic quantity (0.1–1.0 mM) of Fe2+ allows a high production of homogeneous OH radicals following Fenton’s reaction (7), optimal at pH ~ 3. Moreover, the cathodic regeneration of Fe2+ from Fe3+ reduction ensures the maximum production of OH in the bulk. In an undivided cell, organic pollutants are attacked by both strong oxidants, M(OH) and OH. The PEF process involves the solution irradiation with UVA light [24, 39, 40], whose action is quite complex. Photons can prevent the large accumulation of Fe(III) species, responsible for a gradual deceleration of decontamination, thanks to the reductive photolysis of [Fe(OH)]2+ via reaction (8). Moreover, this enhances the Fe2+ regeneration and the production of additional amounts of OH [25, 39]. UVA photons can also photolyze organic intermediates like Fe(III)-carboxylate complexes, originated from the destruction of aromatic pollutants, via the general reaction (9) [25, 41, 42].

$${{\text{O}}_2}+2{{\text{H}}^+}+2{{\text{e}}^ - } \to {{\text{H}}_2}{{\text{O}}_2}$$
(6)
$${\text{F}}{{\text{e}}^{2+}}+{{\text{H}}_2}{{\text{O}}_2}+{{\text{H}}^+} \to {\text{F}}{{\text{e}}^{3+}}{+^ \bullet }{\text{OH}}+{{\text{H}}_2}{\text{O}}$$
(7)
$${[{\text{Fe}}({\text{OH}})]^{2+}}+h\upnu \to {\text{F}}{{\text{e}}^{2+}}{+^ \bullet }{\text{OH}}$$
(8)
$${[{\text{Fe}}({\text{OOCR}})]^{2+}}+h\upnu \to {\text{C}}{{\text{O}}_2}+{{\text{R}}^ \bullet }$$
(9)

Recently, the effectiveness of the procedures described and other EAOPs like photoelectrocatalysis for the treatment of real wastewater has been discussed in several authoritative reviews [43,44,45,46].

The aim of this work is to study in depth the sequential EC/EAOP treatment of dairy wastewater, in particular whey from cheese production. The assays were performed at small (100 mL) and pre-pilot (2.5–3.5 L) scale to assess their viability. The EC pretreatment was optimized upon use of different anode/cathode pairs, including Fe, Al and stainless steel (AISI 304 and AISI 316L) as electrodes, to achieve the maximum organic matter removal. The effluent resulting from the optimum EC was conditioned at pH 3.0 and post-treated by PEF or EO using BDD, Pt, or DSA® (IrO2-based and RuO2-based) as the anode to destroy the dissolved organic matter. The evolution of main physicochemical parameters of the cheese whey sample was analyzed as well.

2 Materials and methods

2.1 Chemicals

Fresh cheese whey wastewater was treated in the present work. For the application of EAOPs, the EC-pre-treated wastewater was adjusted to pH 3.0 with analytical grade HClO4 purchased from Merck. Solutions for analysis were prepared with ultrapure water from a Millipore Milli-Q system (resistivity > 18 MΩ cm). The organic solvents and other chemicals were of HPLC or analytical grade from Sigma-Aldrich, Merck and Panreac.

2.2 Samples of cheese whey wastewater

The raw wastewater was obtained from a small dairy located in Lliçà d’Amunt (northeastern Spain). The sample was collected in polyethylene (HDPE) bottles and kept at 4 °C in a refrigerator prior to usage. This dairy produces daily about 1000 L of whey, which are currently managed using a simple physicochemical treatment (coagulation followed by filtration). Since it usually contains a high organic and mineral load that cannot be added all at once because the system would collapse, large addition of clean water to smaller volumes of whey is required. The resulting treated water is discharged into a river, whereas the sludge is buried. The usual physicochemical parameters of the raw wastewater were determined and its organic components were identified by gas chromatography–mass spectrometry (GC–MS).

2.3 Electrochemical systems

The electrochemical trials were performed at two scales, using either a 100-mL cell or a pre-pilot plant. The former system was used for both EC and PEF processes and consisted of an open, undivided, cylindrical glass cell, with a double jacket for circulation of external water to operate at 35 °C. In all the assays, the solution was vigorously stirred with a magnetic bar at 800 rpm. In PEF, it was also illuminated with a Philips TL/6W/08 fluorescent black light blue tube that emitted UVA light (λmax = 360 nm). Prior to PEF assays, the wastewater resulting from EC pre-treatment was conditioned by filtration to remove the sludge, followed by pH adjustment to 3.0 with HClO4. For the pre-pilot study, a methacrylate tank reactor containing 3.2 L of wastewater was used for the EC trials, made under continuous stirring at 800 rpm with a magnetic bar at room temperature. The subsequent EO treatment was performed with 2.0 L of the conditioned wastewater following the procedure mentioned above, using a pre-pilot flow plant described elsewhere [39]. The electrochemical cell was connected to an annular photoreactor of 640 mL capacity, which contained a Philips UVA lamp of 160 W, and the wastewater was recirculated at a flow rate of 200 L h−1 and 35 °C. All the runs were made at direct and constant j provided by an Amel 2053 potentiostat–galvanostat for the small cell, and a Grelco GVD310 power supply to operate at pre-pilot scale. In the small system, some assays were carried out by reversing the polarity every 5 min.

2.4 Electrodes

Fe (mild carbon steel), Al and stainless steel (AISI 304 and AISI 316L) plates of 10 cm2 of immersed area, connected in monopolar parallel configuration as one or two pairs of electrodes, were used for the EC treatments in the 100-mL cell. The same materials, but with 140 cm2 of immersed area and always as two pairs of electrodes, were employed in the 3.2 L tank reactor. Before first use, all plates were mechanically abraded with SiC paper, cleaned with soap and acetone, and washed with Milli-Q water. Prior to each experiment, the electrodes were immersed in 20% (v/v) H2SO4 for 30 s to activate their surface, then cleaned with Milli-Q water in an ultrasonic bath, and finally rinsed with Milli-Q water. They were left at 90 °C for 1 h to reach constant weight and determine their mass.

For PEF process, the 100-mL cell was equipped with one anode of 3 cm2 area, chosen among the following ones: (i) a BDD thin-film electrode supplied by NeoCoat, synthesized by the HFCVD technique on polycrystalline Si wafers (0.1 Ω cm, Siltronix), with 700 ppm of boron and 2.5–3.5 µm thickness, (ii) a Pt sheet (99.99% purity) supplied by SEMPSA, and (iii) a DSA®-O2 (IrO2-based), or (iv) a DSA®-Cl2 (RuO2-based) purchased from NMT Electrodes Ltd. The cathode was always a carbon-PTFE air-diffusion electrode of the same area supplied by E-TEK, mounted as in former works [40] and fed with compressed air at 1 L min−1 for H2O2 generation. The interelectrode gap was about 1.0 cm. The EO treatment in the pre-pilot flow plant was performed using the same kind of BDD anode and Pt cathode, but with 20 cm2 of immersed area and separated 1.2 cm. Before use, all the electrodes were cleaned and/or activated by electrolyzing 0.050 M Na2SO4 solutions in Milli-Q or deionized water at j = 100 mA cm−2 for 240 min.

2.5 Equipment and analytical procedures

All the experiments were made in duplicate and average values with error bars related to 95% confidence interval are shown in the graphs. Samples withdrawn from the raw or treated wastewater were filtered with 0.45 µm PTFE filters from Whatman or nylon filters from Filter-Lab before analysis.

The equipment and procedures for the determination of the physicochemical parameters, including pH, conductivity, TOC, total nitrogen (TN), total suspended solids (TSS), turbidity and the concentration of metals and inorganic ions, were reported in earlier works [47, 48]. UV/Vis spectra of samples were recorded on a Shimadzu 1800 UV/Vis spectrophotometer at 25 °C. The mass of electrodes before and after the EC processes with a stirred Fe/Fe tank reactor at different j values was measured to clarify the anodic Fe dissolution.

The organic components of the raw wastewater were identified by GC–MS upon extraction with CH2Cl2, filtration of the dried sample and concentration up to ca. 1 mL under reduced pressure. GC–MS analysis was made with an Agilent Technologies system under conditions previously reported [49]. Polar HP INNOWax and non-polar Agilent J&W HP-5 ms columns, both of 0.25 µm, 30 m × 0.25 mm, were used. A NIST05 MS library was employed for the identification of the mass spectra of separated organics.

3 Results and discussion

3.1 Characterization of the cheese whey wastewater

Table 1 summarizes the physicochemical parameters determined for the raw wastewater tested. These data reveal a slightly acidic pH with high values of conductivity, TOC, TN, TSS, and turbidity, but low inorganic carbon (IC). K+ was the most abundant cation, followed by Ca2+ and Na+, along with an insignificant amount of total Fe. High quantities of soluble P were detected. The predominant anion was Cl, followed of SO42−, whereas the content of NO3 was lower. A noticeable concentration of soluble S was found as well.

Table 1 Physicochemical characteristics of (i) raw cheese whey wastewater, (ii) sample treated under optimum EC conditions with the stirred Fe/AISI 304 cell at j = 30 mA cm−2 for 60 min, (iii) EC pre-treated sample followed by conditioning at pH 3.0, and (iv) sample treated by PEF with BDD anode under 6 W UVA irradiation at j = 100 mA cm−2 for 420 min

To gain better insight on the organic components of the sample, it was analyzed by GC–MS after extraction with CH2Cl2. As shown in Table 2, nine linear saturated and unsaturated carboxylic acids (fatty acids) and one steraloid, along with 2-methoxy-4-vinylphenol and benzoic acid were identified. Unfortunately, typical whey components such as proteins (β-lactoglobulin, α-lactalbumin, albumin bovine), lactoferrin, lactoperoxidase, lysozyme, casein, and vitamins [8], were not detected by this technique.

Table 2 Organic compounds detected in the raw cheese whey wastewater by GC–MS

3.2 Electrocoagulation in the 100-mL cell

Based on the large content of colloidal and particulate matter in the raw wastewater under study, EC was considered as a suitable pre-treatment method [3]. In order to optimize this process, various sets of experiments were carried out at direct j of 30 mA cm−2 using a single anode/cathode pair, upon combination of Fe, Al, AISI 304 and AISI 316L electrodes. Figure 1a–d shows the percentage of TOC removed after 30 and 60 min of all these treatments. The Fe anode combined with the AISI 304 cathode yielded the greatest TOC removal of 27.0% at 60 min (see Fig. 1a). Some trials were also performed at the same j by reversing the polarity every 5 min for the Fe/Fe, Al/Al, AISI 304/AISI 304 and AISI 316L/AISI 316L pairs. Results of Fig. 1 evidence that, using polarity reversal, the highest TOC decay of 26.4% was achieved with the Fe anode, being superior to 17.4% found for the Fe/Fe pair with no polarity change. Hence, polarity reversal turned out to be an interesting alternative to reach a high TOC removal, which can be accounted for by the destruction of the passive layer typically formed onto the Fe anode surface in monopolar connection mode. However, since the use of the AISI 304 cathode without polarity reversal was already able to ensure even a slightly better performance (27.0 vs. 26.4%), the Fe/AISI 304 system can be considered as more convenient to increase the lifetime of the cathode, thus minimizing its periodical replacement. All the other anode/cathode arrangements led to lower TOC abatements (see Fig. 1a–d), except in the case of the Al/AISI 304 system, which yielded 26.6% TOC abatement, similar to the 27.0% of the Fe/AISI 304 cell (see Fig. 1b). The latter pair was chosen as optimal because the Fe anode allows the generation of iron cations to be further used in Fenton-based electrochemical processes like PEF. In contrast, the two stainless steel anodes presented lower TOC decay than the Fe and Al ones, which can be associated with: (i) the relatively smaller production of insoluble Fe(OH)3, because other metals contained in them (Mo, Mn, Ni and Cr) were also dissolved, and (ii) their inherent greater resistance to corrosion with greater anodic potential than Fe that favors a larger current consumption to evolve O2 from water oxidation.

Fig. 1
figure 1

Percentage of TOC removal after 30 and 60 min of electrocoagulation (EC) of 100 mL of cheese whey wastewater at natural pH using different stirred anode/cathode cells of 10 cm2 electrode area at current density (j) of 30 mA cm−2, at 35 °C. The experiments were performed with direct current and, for the cells with the same anode and cathode material, polarity reversal every 5 min was also tested

Table 1 reveals that after the EC treatment with the optimum Fe/AISI 304 pair, the wastewater became more alkaline, reaching pH 7.5. This is expected by the small production of H+ from water oxidation at the anode, since it is pre-eminently dissolved to Fe2+ by reaction (1). In turn, this means that the sludge formed during EC is mainly composed of Fe(OH)3 with coagulated organic products. This latter aspect was confirmed by the great decrease found for TSS and turbidity (see Table 1). Note that, from the results of Fig. 1a–d, it is evident that the cathode nature has large influence on the EC performance, which is frequently disregarded in articles published on this topic. This suggests the cathodic reduction of some organic pollutants and the coagulation of the resulting products, which is promoted by the Fe(OH)3 flocs formed from Fe, AISI 304 and AISI 316L by reaction (3) or the Al(OH)3 ones formed from Al by reaction (4). Results of Table 1 also show a decay in Cl concentration during EC, as revealed when the pH was conditioned to 3.0. This agrees with the production of strong oxidants such as active chlorine (Cl2/HClO/ClO) during the 60 min treatment, caused by the partial anodic oxidation of Cl via reactions (10)–(12) [25, 41, 42, 50].

$$2{\text{C}}{{\text{l}}^ - } \to {\text{C}}{{\text{l}}_{2({\text{aq}})}}+2{{\text{e}}^ - }$$
(10)
$${\text{C}}{{\text{l}}_{2({\text{aq}})}}+{{\text{H}}_2}{\text{O}} \leftrightarrows {\text{HClO}}+{\text{C}}{{\text{l}}^ - }+{{\text{H}}^+}$$
(11)
$${\text{HClO}} \leftrightarrows {\text{Cl}}{{\text{O}}^ - }+{{\text{H}}^+}$$
(12)

The predominant active chlorine species is Cl2(aq) (Eº = 1.36 V|SHE) up to pH 3.0 and HClO (Eº = 1.49 V|SHE) at pH between 3 and 8, whereas the weaker ClO (Eº = 0.89 V|SHE) predominates at pH > 8.0. Furthermore, under the optimum EC conditions, it has been also evidenced that the generated HClO can form the strong oxidant OH with Fe2+ via Fenton-like reaction (13) [51].

$${\text{HClO}}+{\text{F}}{{\text{e}}^{2+}} \to {\text{F}}{{\text{e}}^{3+}}{+^ \bullet }{\text{OH}}+{\text{C}}{{\text{l}}^ - }$$
(13)

Several sets of experiments were made to ascertain the influence of experimental variables on the performance of the Fe/AISI 304 pair in EC, including the interelectrode gap, the number of electrode pairs used and the applied j value. Figure 2a illustrates the gradual drop in TOC removal from 27.0 to 4.9% when the distance between the electrodes grew from 1.0 to 5.0 cm operating with one pair of electrodes at j = 30 mA cm−2 for 60 min. This tendency can be mainly explained by the greater ohmic drop attained as the electrode distance increases, with the consequent enhancement of the cell voltage and the acceleration of water oxidation to O2, decreasing the dissolution rate of the anode. Consequently, a lower generation of Fe(OH)3 flocs is achieved, thus reducing the ability to coagulate the organic matter. The distance of 1.0 cm was the best interelectrode gap between the Fe and AISI 304, being chosen for subsequent trials.

Fig. 2
figure 2

Influence of experimental variables on the percentage of TOC removal after 30 and 60 min of EC of 100 mL of cheese whey wastewater at natural pH using a stirred Fe/AISI 304 cell at 35 °C. a Interelectrode gap for one pair of electrodes at j = 30 mA cm−2, b number of pairs of electrodes connected in monopolar parallel and separated 1.0 cm at j = 30 mA cm−2, and c current density for two pairs of electrodes separated 1.0 cm

The use of two pairs of electrodes in monopolar connection mode, instead of a single pair, was studied under the same conditions, at a distance of 1.0 cm and j = 30 mA cm−2. As can be seen in Fig. 2b, a small drop in TOC abatement (23.5 vs. 27.0% at 60 min) occurred when the two Fe/AISI 304 pairs were utilized. This can be related to the concomitant increase of both individual cell voltages when circulating the same j as in the single pair cell, thus favoring the discharge of water over Fe dissolution with formation of lower amounts of Fe(OH)3 flocs. Worth commenting, the system with two Fe/AISI 304 pairs seems convenient for an industrial application because each Fe anode becomes dissolved more slowly, which minimizes the replacement tasks.

Another key factor affecting the performance of EC is the applied j. This parameter fixes the value of the cell voltage and hence, it determines the amount of Fe dissolved as compared to the extent of the water oxidation reaction. Its influence was tested in cells with two Fe/AISI 304 pairs in monopolar connection mode, with a gap of 1.0 cm. Figure 2c shows the greatest TOC removal at j = 30 mA cm−2, where the relative rate of Fe dissolution following reaction (1) became optimal. At a lower j of 20 mA cm−2, one can expect the release of lower amounts of Fe2+ to the solution, producing smaller decays of organic pollutant concentrations owing to the smaller quantities of Fe(OH)3 flocs formed. More surprising, apparently, is the fact that a greater j of 40 mA cm−2, where more Fe2+ is released, removes a smaller amount of organics by coagulation. This is probably due to the rapid formation of flocs with smaller average size and area, which does not favor a large aggregation of the organic matter onto their surface. These findings demonstrate that the optimum j for the treatment of the raw cheese whey wastewater by EC was 30 mA cm−2 under the present experimental conditions.

3.3 Sequential EC/PEF treatment in the 100-mL cell

Once the EC process was thoroughly studied, several runs were carried out by treating solutions of 100 mL of wastewater pre-treated under the previous optimum conditions: Fe/AISI 304 cell with the two electrodes separated 1.0 cm, at j = 30 mA cm−2 for 60 min. Such pre-treatment yielded suspensions that were further filtered to remove the sludge. Then, their pH was adjusted to 3.0 with HClO4 (to avoid changes in the SO42− and Cl concentrations) and filtered again to obtain a clarified conditioned wastewater to be post-treated by PEF. As compared to the raw wastewater, Table 1 shows that the clarified samples presented 1.48-fold higher conductivity, along with removals of 27.0% of TOC, 42.4% of TN, 95.1% of TSS, and 96.1% of turbidity. One can also notice a large reduction of Ca2+ and Mg2+ cations, as well as of soluble P and S. In contrast, the total Fe content rose from 0.20 to 243 mg L−1, in agreement with the release of Fe2+ ions in EC, which is interesting to provide the iron source required for reactions (7) and (8) in PEF. Similarly, the concentration of NO3 and SO42− anions increased 6.5- and 4.5-fold, respectively. This confirms the oxidation of N- and S-compounds in solution or in suspended solids directly at the Fe anode or indirectly by active chlorine.

Figure 3a, b exemplifies the evolution of TOC and TN removals, respectively, for the raw wastewater under optimized EC conditions for 60 min, followed by PEF treatment of the conditioned sample using different stirred anode/O2-diffusion cells at j = 100 mA cm−2 for 420 min. Up to 27.0% of TOC was reduced by EC, whereas it decayed by 33.1–34.0% using Pt or the two DSA® anodes and by 42.2% using BDD at the end of the EC/PEF sequence (see Fig. 3a). The smaller TOC removal attained by the three active anodes is indicative of a large recalcitrance of organics to the action of oxidants like OH and active chlorine (HClO) in the bulk, as well as to photolysis by UVA radiation. The superior oxidation ability of the non-active BDD can be related to the parallel quicker attack of the powerful BDD(OH) originated from reaction (5) [17, 18] on organics, enhancing the mineralization process.

Fig. 3
figure 3

Time course of the percentage of a TOC and b TN removals for the sequential EC/photoelectro-Fenton (PEF) treatment of 100 mL of cheese whey wastewater at 35 °C. The EC treatment was carried out at natural pH using an optimum stirred Fe/AISI 304 cell at j = 30 mA cm−2 for 60 min. After conditioning the filtered wastewater at pH 3.0, the PEF treatment using a 6-W UVA lamp was made with a stirred cell equipped with a (circle) boron-doped diamond (BDD), (triangle) Pt, (inverted triangle) IrO2-based, or (diagonal cross) RuO2-based anode and an air-diffusion cathode, all of 3 cm2 area, at j = 100 mA cm−2 and 35 °C for 420 min

A very different behavior can be observed in Fig. 3b for the TN decay. This parameter was largely removed with the three active anodes, especially in the cell with the RuO2-based anode that yielded 95.2% abatement, being less effective the PEF treatment with BDD with only 41.5% removal. These findings suggest an important role of oxidants like active chlorine, formed more largely with active anodes [31, 32], to destroy the N-compounds and giving rise to volatile products like N2 and NxOy species [40,41,42], and volatile chloramines [52]. The last column of Table 1 shows the overall disappearance of NO3 during the PEF process with BDD, which can be related to its photoreduction to NO2 followed by its decomposition to NxOy [53]. Similarly, the Cl concentration was reduced by 44.6%, thus corroborating the oxidation of this ion with formation of active chlorine from reactions (10) and (11). The attack of BDD(OH) and OH onto organics generated acidic products, leading to the acidification of the treated sample with a final pH = 1.61, in concomitance with an increase in conductivity up to 40.2 mS cm−1 (see Table 1). The data of Table 1 also show a significant drop in TSS and turbidity due to the degradation of their components by all the above oxidants. Conversely, no significant change in the concentration of the other ions and soluble S, P and total Fe was found.

The change in sample color during the sequential EC/PEF treatment is depicted in Fig. 4a. The raw cheese whey wastewater had a whitish appearance due to its high TSS concentration and turbidity, whereas it became dark during EC with a sludge floating on surface. After conditioning, the sample acquired again a whitish color with a turbid appearance, which disappeared in PEF. At the end, a transparent yellow–brown sample was obtained, mainly by the presence of Fe ions in solution. Figure 4b illustrates the UV/Vis spectra recorded for the raw and final wastewater. A high absorbance of the raw wastewater within the λ region from 200 to 300 nm can be observed, as expected from a colorless effluent with a large content of carboxylic and aromatic pollutants. The absence of most aromatics in the final wastewater upon sequential electrochemical treatment explains the high decrease in absorbance in such region.

Fig. 4
figure 4

a Photographs during tests shown in Fig. 3. 1 Raw wastewater, along with samples withdrawn after 2 EC, 3 EC + conditioning at pH 3.0, and 4 PEF with BDD anode. b UV/Vis spectra of the wastewater before and after the sequential EC/PEF (BDD) treatment of Fig. 3

3.4 Electrocoagulation at pre-pilot scale

The study of the sequential electrochemical treatment was extended to pre-pilot scale. A set of EC experiments was performed with 3.2 L of the raw wastewater in a stirred tank reactor equipped with two pairs of electrodes separated 1.0 cm and connected in monopolar mode. The anode chosen was a Fe plate of 140 cm2 area, since it was found the best material for EC and subsequent EAOP post-treatment (see previous subsection). Figure 5a shows the percentage of TOC removal after 30 and 60 min using two Fe/Fe pairs at j values from 5 to 40 mA cm−2. As can be seen, greater TOC was removed, attaining 22.1%, at j = 30 mA cm−2, as a result of the progressively faster dissolution of the two anodes from reaction (1) at raising j. However, it decayed to 19.3% at the highest j = 40 mA cm−2, probably due to the formation of smaller flocs with lower ability for organic matter adsorption, as stated above. This trend was also obtained for two Fe/AISI 304 pairs at 100-mL scale (see Fig. 2c). After these trials, it was confirmed that the mass lost by the Fe anodes was of 100, 198, 393, 585 and 774 mg at increasing j from 5 to 40 mA cm−2. This means that it decreased slightly from 96.2 to 93.0%, as compared to the theoretical values assuming the Faraday’s law for reaction (1). These results inform about the pre-eminent anodic reaction of Fe to Fe2+ in all cases, being much less important the water oxidation to O2, although this parasitic reaction was gradually accelerated as j was risen.

Fig. 5
figure 5

Percentage of TOC removal after 30 and 60 min of EC treatment of 3.2 L of a raw cheese whey wastewater at natural pH using a stirred Fe/cathode tank reactor with two pairs of electrodes of 140 cm2 area each, separated 1.0 cm at room temperature. a Effect of current density with Fe cathodes. b Comparison of performance with Al, AISI 304, and AISI 316L cathodes at j = 30 mA cm−2

From the above findings, one can infer again that the best j for the EC treatment of the raw wastewater was 30 mA cm−2. The effect of the cathode material on the EC performance was verified at this scale. Figure 5b shows that after 60 min of electrolysis, 13.5, 22.0 and 12.1% of TOC was abated using an Al, AISI 304 and AISI 316L cathode, respectively. This confirms the aforementioned large influence of the cathode on the EC performance. Our results evidence the greatest TOC removal using the Fe/Fe and Fe/AISI 304 cells at the optimum j = 30 mA cm−2, as also found at 100-mL scale (see Fig. 1). In both cases, the pH of the samples became more alkaline, up to 6.1–6.4, and their conductivity grew < 10%, but the corresponding TN decayed by 51.0 and 59.0%, respectively. As in the case of the 100-mL scale, the use of the AISI 304 cathode is interesting for EC. It presents an analogous behavior as compared to the Fe one, but it has greater corrosion resistance and requires lower maintenance. This cathode was chosen for the next study about the sequential electrochemical treatment of the raw wastewater.

3.5 Sequential EC/EAOP treatment at pre-pilot scale

The previous study at 100-mL scale allowed concluding that BDD is the best anode for the PEF post-treatment of the conditioned wastewater obtained in EC. The superior, but low TOC removal attained after PEF with a BDD/air-diffusion cell (42.2%) after 420 min at j = 100 mA cm−2 (see Fig. 3a) can be explained by a much greater oxidative role of BDD(OH) compared to OH and active chlorine during the EAOP. Based on this, the coupling of EC with EO without and with UVA radiation was explored at pre-pilot scale. Note that the scale-up from 100 mL for an electrochemical process is complicated, not just because of the increment of the volume to be treated, but due to the influence of the geometry of electrodes and cell, as well as the hydrodynamics of the system related to the mass transport and the potential distribution, among other parameters.

First, 3.2 L of wastewater were electrolyzed for 60 min using a tank equipped with two Fe/AISI 304 pairs at j = 30 mA cm−2. After that, the resulting sample was conditioned by filtration + pH adjustment to 3.0 with HClO4 + filtration to operate under the same conditions as optimum PEF, and 2.0 L were introduced in the reservoir of the pre-pilot flow plant and recirculated through it at a flow rate of 200 L h−1 keeping its temperature at 35 °C. The liquid circulated through a BDD/Pt cell (without H2O2 generation) coupled to an annular photoreactor containing a 160 W UVA lamp. Figure 6 shows the TOC removed by EO with UVA irradiation at j = 50 mA cm−2 and blank experiments. After 480 min of treatment in batch, the percentage of total TOC removal (also including the 22.0% obtained in EC) was 31.5, 35.2, and 49.1% upon UVA photolysis, EO, and UVA-photoassisted EO, respectively. The contribution of UVA light to TOC decay (i.e., 9.5%) suggests the mineralization of Fe(III)-carboxylate complexes present in the wastewater by photodecarboxylation, according to reaction (9). The 13.2% of TOC abatement arising upon EO treatment confirms the oxidative action of BDD(OH) and, to a smaller extent, of active chlorine on organic pollutants. The 27.1% of TOC removal obtained at the end of EO with UVA light was slightly higher than the sum of 22.7% of the two individual processes, meaning that a synergistic effect between oxidation and photolysis is feasible when the hybrid EAOP is applied.

Fig. 6
figure 6

Percentage of TOC removal with electrolysis time for the sequential EC/electrochemical oxidation (EO) treatment of cheese whey wastewater at 35 °C. The EC treatment of 3.2 L of wastewater at natural pH was performed with the Fe/AISI 304 tank reactor under the conditions of Fig. 5b for 60 min. After that, 2.0 L of filtered EC-treated wastewater were conditioned at pH 3.0 and treated in a pre-pilot flow plant equipped with a BDD/Pt cell of 20 cm2 electrode area, at j = 50 mA cm−2, liquid flow rate of 200 L h−1 and 35 °C for 480 min. The cell was connected to an annular photoreactor of 640 mL capacity containing a 160 W UVA lamp. (Circle) EO with UVA light, (triangle) EO and (inverted triangle) UVA light alone

Finally, the specific energy consumption per unit TOC mass (ECTOC, in kWh (kg TOC)−1) for the above sequential electrochemical treatment was evaluated as follows [24, 25]:

$${\text{E}}{{\text{C}}_{{\text{TOC}}}}=\frac{{1000{\text{ }}{E_{{\text{cell}}}}{\text{ }}I{\text{ }}t}}{{V\Delta {{({\text{TOC}})}_{\exp }}}}$$
(14)

where 1000 is a factor to homogenize units (mg g−1), Ecell is the average cell voltage (in V), I is the applied current (in A), t is the electrolysis time (in h), V is the volume of treated wastewater (in L) and ∆(TOC)exp is the TOC abated (in mg L−1). In the case of the EC pre-treatment for 1 h (Ecell = 8.3 V and I = 8.40 A), a low ECTOC = 3.36 kWh (kg TOC)−1 was found. A greater ECTOC = 14.78 kWh (kg TOC)−1 after the 8 h of EO (Ecell = 11.4 V and I = 1.0 A) was needed. This value increased extraordinarily to 192.16 kWh (kg TOC)−1 when only UVA illumination was employed, due to the high power of the lamp (160 W). This explains the high ECTOC = 109.77 kWh (kg TOC)−1 determined for the most effective post-treatment, i.e., EO with UVA light. To obtain a cost-effective process at industrial level is then necessary to replace the artificial light by a free energy source like sunlight, which has been well-proven to be very efficient for solar Fenton-based electrochemical processes [25, 39].

4 Conclusions

AISI 304 is the most suitable cathode material for the decontamination of cheese whey wastewater at natural pH by EC at small and large scales. Its combination with a Fe anode yields greater TOC removal as compared to cells with Al or stainless steels anodes, which is beneficial for the post-treatment with EAOPs. However, only 22.0–27.0% of TOC was removed using one or two Fe/AISI 304 pairs at optimal interelectrode gap of 1.0 cm and j = 30 mA cm−2 for 60 min at both scales. Coagulation of organics onto the Fe(OH)3 flocs, reduction at the cathode or oxidation with active chlorine explain the decay in TOC, TN, TSS and turbidity. The post-treatment of the EC-treated wastewater, conditioned at pH 3.0, by PEF at 100-mL scale showed the highest TOC removal using a non-active BDD anode, because of the high oxidation power of BDD(OH). In contrast, the TN decayed much more rapidly with active anodes because of the effective attack of active chlorine onto N-compounds. At pre-pilot scale, the conditioned wastewater was post-treated by UVA-photoassisted EO with a BDD/Pt flow cell, leading to the greatest total TOC removal of 49.1% after 480 min at j = 50 mA cm−2. This was ascribed to the synergistic oxidation of BDD(OH) and photolysis. The low energy consumptions found for the sequential EC/EO treatment increased significantly when the UVA lamp power was computed and hence, sunlight-assisted EO would be more suitable for a cost-effective sequential electrochemical treatment at industrial scale.