1 Introduction

Africa faces huge challenges with multiple issues that adversely affect public health. One major challenge is the ability for both rural and urban Africans to access electricity. Thus, the number of water sanitation stations is limited. Indeed, only 16% of people in sub-Saharan Africa had access to drinking water through a household connection [1]. Not only there is a problem of availability, even when this water is available, there are risks of contamination due to several factors, especially in the case of surface water sources, which makes the presence of water disinfection systems a must; but as previously mentioned the limited access to the grid reduces the options of water filtering, leaving renewable energy resources the unique solution.

Renewable energy can be converted into electrical energy for the household applications. The most available form of renewable energy in Africa is the solar energy; hence, it can be used for all types of domestic appliances. These strategies must be environmentally friendly. O3 is an excellent and powerful oxidizer and germicide. The disinfection potential of O3 is significantly higher than chlorine and other disinfectants. Nowadays, O3 is widely used as a substitute to chlorine for disinfecting and oxidizing due to by-products of chlorine, such as smell, bad taste and the production of carcinogenic agents. Clearly, O3 produces considerably less by-products and is transformed into oxygen within a few hours. The O3 technology has various applications, including disinfection, water and air purification, and medicine [2,3,4,5].

Several methods allow production of ozone with various levels of maturity. Most of the ozone produced in the world comes from network supply. A little is mainly produced by the solar generator. This latter method seems to be the most ecological solution for producing ozone. Artificially ozone can be generated in many ways such as dielectric barrier discharge, corona discharge, electrolysis and radiochemical method [6,7,8,9] for that the solar inverters are most commonly used in this system. The solar inverter should be able to operate the home appliances smoothly. Most of the inverters available in market are designed as square wave and quasi-wave inverters, which is not suitable for most of the electrical appliances. The outputs of these types of inverters are with more harmonics and are less efficient [10, 11]. If sinusoidal waveform is not provided to the appliances, the lifetime of the appliances will reduce day by day. The generated sinusoidal output waveform from the inverter is to overcome this type of disadvantages. The sinusoidal output waveform can be obtained by implementation of sinusoidal pulse width modulation (SPWM) technique to the inverter circuit. The SPWM technique can be implemented by continuous switching [12,13,14,15,16] in a particular sequence of the inverter. The switching technique is characterized by a constant pulse amplitude with a variable duty cycle for each period. The most common method to implement this technique is to compare the sinusoidal waveform with triangular carrier waveform [17,18,19,20]. The application of this type of inverter can be for the household appliances and high-power applications. An inverter is basically a device, which converts electrical energy of DC form into that of AC form. The DC power can be obtained from battery or PV source and converts it to AC. Recently, the inverters are also playing an important role in various renewable energy applications as these are used for grid connection of wind energy system or photovoltaic system. In addition to this, the control strategies used in the inverters are also similar to those in DC-to-DC converters. Both current-mode control and voltage-mode control are employed in practical applications. The DC-to-AC inverters usually operate on pulse.

Width modulation (PWM) technique. The PWM is a very advanced and useful technique, in which the width of the gate pulses is controlled by various mechanisms. PWM inverter is used to keep the output voltage of the inverter at the rated voltage (depending on the user’s choice) irrespective of the output load. In a conventional inverter, the output voltage changes according to the changes in the load. To nullify this effect of the changing loads, the PWM inverter corrects the output voltage by changing the width of the pulses, and the output AC depends on the switching frequency and pulse width, which is adjusted according to the value of the load connected at the output so as to provide constant rated output. The inverters usually operate in a PWM and switch between different circuit topologies, which means that the inverter is a nonlinear, specifically piecewise smooth system. Both current-mode control and voltage-mode control are employed in practical applications. In this study, we used low-cost PIC16F628A microcontroller that reduced the complexity of the circuit in single half-bridge inverter [21, 22]. The microcontroller has built in dead time control, which is complex because the conduction drops in the transistor and in the diode depends on the related current and temperature of the semiconductor [23]. In the last decade, studies of complex behavior in switching power converters have gained increasingly more attention from both the academic community and industry [24].

2 The photovoltaic ozone system

2.1 Circuit diagram

O3 generator is connected to the PV system as shown in Fig. 1.

Fig. 1
figure 1

Synoptic diagram of the PV system supplying the ozone generator

The PV system includes the following:

  1. 1.

    A polycrystalline PV panel composed of 36 elementary cells that can provide, under standard test conditions, a power of 135 W and a maximum current of 8.28 A at an optimum voltage of 12 V. Power specifications at STC (standard condition): 1000 W/m2, 25 c°, AM1.5 (Table 1). Sun module SW 135 poly R6A.

    Table 1 Standard test conditions of panel 135w
  2. 2.

    A charge regulator (12 V/20 A) to maintain the output voltage at 12 V.

  3. 3.

    A solar battery of 80 Ah to store energy.

  4. 4.

    A half-bridge inverter to convert the voltage from DC to AC. A 16F628A microcontroller was used to control this inverter.

The microcontroller generates SPWM. SPWM signal is a square wave of the variable cyclic ratio with 4-kHz frequency and controls the transistor converter. The O3 generator is represented by a constant load.

2.2 Description of proposed inverter

The schematic of the working principle of the inverter is shown in Fig. 2.

Fig. 2
figure 2

The schematic of the working principle of the inverter

The basic circuit of the single-phase half-bridge inverter is shown in Fig. 3.

Fig. 3
figure 3

The basic circuit of the single-phase half-bridge inverter

PIC microcontroller is the heart of the control circuit of this system. This microcontroller was designed particularly to generate SPWM. The PIC16F628A microcontroller generates two PWM and rectangular pulse signals, as shown in Fig. 4, which are modified to an SPWM signal. RB5 and RB6 are the output pins for the SPWM that feeds the amplifier stage. The transistor control, based on the amplification stage, is conducted using two types of transistors, BC547 and BD140.

Fig. 4
figure 4

The PIC16F628A microcontroller diagram

2.3 Flowchart

Figure 5 shows the flowchart of the single-phase SPWM signal. In this flowchart, “initializing variables” indicates the initialization of the memory cell defined by the user. Furthermore, “initialization sine lookup table” then stores the sample value of the sine wave. These sampling values are transmitted to the PWM duty cycle register.

Fig. 5
figure 5

Flowchart of the SPWM generation

The CCP1 (Timer0) register generates the triangular wave. The signal then becomes an SPWM signal with a dead time. The microcontroller checks whether the generation is complete. If the generation is complete, the microcontroller acquires another sampling from the sine wave table; else it waits until the end. To generate the SPWM signal, each half-cycle sine wave is divided into 32 parts and the value of the sine wave is then measured at each interval for calculating the cycle service of each pulse.

$$ {\text{Carrier}}\;{\text{frequency}}\;fc \, = 4000\;{\text{Hz}} $$
(1)

The largest PWM value for PIC16F628A is 255 (a duty cycle of 100%). The interval between the points is given by:

$$ \Delta \theta \, = 1/180 = 5.625{^\circ } $$
(2)

The equation of cyclic ratio is given by:

$$ Y = 255\;\sin wt = 255\sin \eta \delta \theta $$
(3)
$$ \eta = 0, \, 1, \, 2, \, 3, \ldots ,31 $$
(4)

2.4 Gate driver circuit

To control the transistor gate, the two-transistor-based amplifier stage was used, as shown in Fig. 6.

Fig. 6
figure 6

Schematic of the amplifier stage

The gate driver was required to switch 12 V DC to the transistor gate. Different methods can be used to generate the grid voltage (VBS) [3,4,5,6,7,8,9,10].

2.5 Practically implemented circuit

The system consists of two parts:

  1. 1.

    The control part contains a power supply and control unit (micro controller, Figs. 7 and 8).

    Fig. 7
    figure 7

    Control circuit diagram

    Fig. 8
    figure 8

    Control signals

  2. 2.

    The power part comprises the power circuit connection diagram as shown in Fig. 9.

    Fig. 9
    figure 9

    Diagram of power circuit

The power circuit is a half-bridge inverter. Two 2N3055-type transistors are connected in series in each arm of the inverter. Two transistors are used to amplify the nominal current of the circuit. The entire circuit comprises eight transistors. The maximum output voltage of the microcontroller is 5 V, which is directly applied to the transistor gate. However, the transistor is only active at 12 V.

2.6 Experimental results

The inverter setup is shown in Fig. 10. Figure 11 shows the SPWM switches gating signals at a frequency of 4 MHz and amplitude 5 V; the output of the inverter is shown in Fig. 12; it is a sine wave with an amplitude of 12 V and frequency 50 Hz.

Fig. 10
figure 10

Complete inverter with transformer

Fig. 11
figure 11

SPWM signals

Fig. 12
figure 12

Waveform of inverter output

The transformer output voltage is 282 V.

3 Principle of ozone generation

The surface reactor (SDBD) is made with the same glass tube, where in the outer stainless steel electrode was replaced by an aluminum tape stuck onto the outer surface of the glass tube, and the inner electrode has been replaced by a stainless steel mesh of 0.75 mm thickness and 1 mm2 mesh square surface, in contact with the inner surface of the glass tube. In this configuration, the discharge occurs on the surface of the mesh electrode in contact with the glass, where a second smaller diameter tube in Teflon (PTFE), of 35 mm outer diameter, is inserted inside the reactor, almost in contact with the mesh electrode, the gas lows into the narrow space two coaxial tubes (Fig. 13a, b).

Fig. 13
figure 13

a Ozone generator, b surface dielectric barrier discharge. 1 Grounded electrode. 2 HV mesh electrode. 3 Glass tube. 4 Gas flow. 5 Plasma

The overall system studied and presented in Fig. 14a, is autonomous, in which the essential element is the battery used to store electrical energy. The system comprises a 135 W photovoltaic module (1) which generates electrical power, a regulator (2) (12/24 V, 20 A) for maintaining the voltage of the panel at 12 V and a solar battery (3) of 80 Ah used to store energy. A half-bridge inverter (4) is used to convert the DC to AC voltage. The latter supplies the high-voltage transformer of the ozone generator (5). Dielectric barrier discharge (DBD) reactors used as ozone generators are well known today and widely used for water treatment and air disinfection.

Fig. 14
figure 14

a Schematic representation of the water treatment process and b photograph of the experimental bench. 1 Solar panel. 2 Charge regulator. 3 Battery. 4 Inverter. 5 High voltage supply. 6 Ozone generator. 7 Water to be treated. 8 Pumping motor. 9 Venturi injector. 10 Treated water

The high-voltage power supply used in this study is a switching type. An AC 220 V voltage is lowered using a step-down transformer and rectified to a DC voltage of approximately 72 V. An IGBT (insulated gate bipolar transistor)-controlled switch is used as an electronic switch and controlled by an oscillator to generate a high-frequency current. A ferrite transformer is used to transform the low-frequency high voltage into a high voltage. A voltage of 1–10 kV at a frequency of 0–30 kHz is obtained. In this work, the oscillation frequency producing the DBD is 20 kHz. All experiments are performed under stable weather conditions of temperature (25–40 °C) and humidity (70–80%).

4 Experimental design methodology

O3 production is powered by a PV system connected to the inverter, which is controlled using the microcontroller, where the water treatment station represent the electrical load. Table 2 represents the experimental result of various electrical quantities such as panel power (current and voltage), irradiance, generator power (current and voltage) and O3 concentration at different times which are plotted in Fig. 15a–h.

Table 2 Experimental measurement
Fig. 15
figure 15figure 15

a Irradiation of PV panel, b daily temperature, c load output power, d load output current, e ozone concentration, f output current of PV panel, g output voltage of PV panel, h output power of PV panel

The solar PV system includes two factors:

  1. 1.

    The East–West orientation angle of the panel

  2. 2.

    The North–South angle of the panel slope

Experiments were conducted as a function of time, where each hour corresponds to a 15° rotation in the East–West direction with a panel fixed at 45° in South.

  1. 1.

    According to Fig. 15a, an increase in illumination was observed from 8:00 am to 10:00 am. A decrease in the amount of illumination at 11:00 am and 13:00 pm occurred due to the cloud passage.

  2. 2.

    Figure 15b shows an increase in temperature during the day with the maximum temperature of 41.5 °C at 14:30 pm, and after 15:00 pm the temperature decreased progressively.

  3. 3.

    Figure 15c shows a rough stability in power consumption from 8:00 am to 13:00 pm. At 13:30 pm, a power drop occurred due to an increase in temperature, negatively affecting the power consumption.

  4. 4.

    The increase in PV panel current between 8:00 am and 11:00 am was due to an increase in irradiation. Between 11:00 am and 13: 00 pm, partial shading (clouds), as shown Fig. 15d, caused current diminution.

  5. 5.

    Figure 15e shows that O3 concentration depended on the change in temperature. An increase in temperature decreased the production of O3 (at 13:00 pm), which indicated that the temperature is inversely proportional to the O3 concentration.

  6. 6.

    For an irradiation of 1176 W/m2, the O3 generator was represented by a resistive load of 28 W, consuming 0.12 A of current. The water treatment reached the maximum value ratio of 93%, as shown in Fig. 15f–h.

  7. 7.

    According to these analyses, water treatment introduced by the O3 generator solely depends on the power supplied by the PV source, and thus on the irradiation.

5 Conclusion

In this study, a new adaptive PV system was integrated for the O3 production process.

Theoretically, this integration can be justified by two techniques that are potentially promising.

  • A low-cost, simple, compact PWM solar inverter was developed. The optimization of O3 production by using a PV source is developed in the simulation and validated practically; the O3 generator was modeled as an electric charge that consumes the same energy when placed under sunshine and temperature imposed by climatic conditions.

  • In spite of the impressive number of developments in the field of solar energy, in recent years we have seen in studies that there is a problem of cloud that causes insufficiency of the energy produced by the solar panels as in our case a panel producing 135 W on a sunny day could only produce 66.3 W (in a cloudy weather) during cloud passage that is enough power to produce ozone.

  • One of the reasons to avoid using surface DBD (SDBD) generators in this study was the nature of the outer electrode. For SDBD generators, an adhesive metal tape or a meshed electrode is required to be used as the outer electrode instead of a metal electrode. Therefore, SDBD generator may be fragile and require more care in handling. Moreover, water treatment with a large flow rate still requires an optimized configuration for a better match between the O2 molecules and plasma. However, the SDBD model should be used frequently in the industry to acquire a more precise idea regarding its robustness and reliability. Here, we emphasize on the fact that the available PV energy is proportional to O3 concentration, and O3 concentration is inversely proportional to temperature.