Particle Swarm Optimisation Algorithm to Determine the Effect of Working Electrode Thickness on Dye-sensitised Solar Cell Internal Parameters

Observation of the dye-sensitised solar cell (DSSC) physical mechanism cannot be carried out experimentally; therefore, an analysis using a model is needed to explain the mechanism. In this article, DSSC is modelled as a series comprising a diode and other electronic components, including a photocurrent (Iph), saturation current (I0), series resistance (Rs), parallel resistance (Rp) and the ideality factor of the diode (n). These electronic components are called DSSC internal parameters. This study aims to find the value of DSSC internal parameters with variations of working electrode thickness. The particle swarm optimisation (PSO) algorithm as an optimisation method is used to achieve the aim. The model indicates that by increasing the thickness, the photocurrent rises and the parallel resistance decreases.


INTRODUCTION
The dye-sensitised solar cell (DSSC) is a third-generation solar cell. The DSSC utilises dyes to absorb light. [1][2][3] The DSSC consists of a working electrode (anode) and a counter electrode (cathode) connected using an electrolytic solution, as shown in Figure 1. The thickness of the working electrode affects the DSSC efficiency. An alternative way to improve the DSSC efficiency is to increase the thickness of the TiO 2 layers on the working electrode. 4 A study shows that by using a transparent TiO 2 with a thickness of 4.5 ± 0.8 µm, the efficiency was 2.42%. 5 Figure 1: The configuration of the DSSC. 2 An organic DSSC has advantages in terms of aesthetics and the low cost of processing. [6][7][8] This is due to the simplicity of deposition of metal oxide on the working electrode. 9 However, organic DSSC efficiency is still low. 10,11 The DSSC internal parameters cannot be observed experimentally. 12 To understand them, a model is needed.
Modelling offers a simpler depiction of an object. 13 It can be in the form of a mathematical equation or a graph. The DSSC can be modelled as a series comprising a diode with the internal parameters. The internal parameters consist of a photocurrent (I ph ), saturation current (I 0 ), series resistance (R s ), parallel resistance (R p ) and ideality factor of the diode (n). [14][15] These internal parameters can be used to explain the physical mechanisms that occur within the DSSC.
Particle swarm optimisation (PSO) is an optimisation method based on swarm behaviour. If a bird knows where food is located, the other birds follow it. The behaviour of the bird can be likened to a particle having certain characteristics. Each particle is assumed to have position and velocity characteristics. The position represents the solution. Learning for PSO particles involves two factors, namely cognitive and social learning. Cognitive learning is used to find Pbest, which is the best position ever found. Social learning is used to find the Gbest, which is the best position of all the particles. 16,17 In this study, the five internal parameters of the DSSC were optimised. The possible values of the parameters were very wide. Thus, PSO was suitable for solving the problem as each particle represents the solution. A particle that at first has a bad position could have the best position in the next iterations. This research used PSO, which was applied to MATLAB software. PSO is easy to implement as it uses fewer operational functions. In addition, it uses physical derivatives, namely speed and position, by which its concept can be easily understood. Moreover, it has been shown to perform well.

EXPERIMENTAL
This study used I-V data from Dewi et al. 5 The study resulted in a DSSC in high efficiency. In addition, the finding of variation of the working electrode is interesting to explore further. The DSSC working electrode used transparent TiO 2 layers with thicknesses of 1.5 μm, 2.9 μm, 3.5 μm and 4.5 μm. It was then soaked in dye solution for 24 h. The results of the study were modelled using PSO.
PSO is one of the swarm intelligence-based optimisation methods. PSO has speed and position components that can change with iteration. 18 The following are the equations for velocity and position updates.
Velocity update: 17 Position update: 17 Each particle i at iteration t has position xi t and velocity vi t . Inertia weight (w) is used to control the effect of the velocity. Coefficients c 1 and c 2 are used to control the movement of the particle. The range of the acceleration coefficient is 0-4. r 1 and r 2 are random values. This study searched for the appropriate c and w to find the optimal DSSC. c and w were determined using a trial and error approach.
The equivalent circuit of one diode can be used to determine the electrical characteristics of the DSSC.
I model is the electric current of the modelling results. V is the voltage of the experimental resulted by Dewi et al. 5 I is the current of the experimental results. 5 k is the Boltzmann constant and e is the electron charge. T 0 is the temperature when the I-V characteristic data is obtained.
The internal parameters in the equivalent circuit of one diode include: I 0 (saturated current), I ph (photocurrent) resulting from the light irradiation process, R s (series resistance) assumed to be an obstacle during the electron transfer process, R p (parallel resistance) assumed to be an obstacle in the recombination process, and n for the ideality factor of the diode.

From Equation 3
, it is possible to find the objective function (z) to apply in the PSO programme.
The objective function used in this study is: where I is the electric current obtained from the Keithley I-V meter data. I model is the electric current from the modelling. The objective equation is z. Therefore, the objective equation showed the correction of the data from the modelling results. The steps to create a PSO programme can be seen in Table 1. In this study, the five internal parameters of solar cells were optimised, namely I ph , I 0 , n, R s and R p . Each variable was given the value limit, as shown in Table 2.

RESULTS AND DISCUSSION
DSSC internal parameters were obtained by the PSO algorithm. Each particle tended to be its personal best. In the population, the best position (or the global best) was available for each particle. The global best is an array with size 1 × 5, indicating DSSC internal parameters optimised during the iteration. Furthermore, the optimal internal parameters were affected by the variations of the thickness of the working electrode. The variations might increase the efficiency of DSSC.  In this study, w was varied, where c was 1.5. The values of w were 0.2, 0.4, 0.6, 0.8 and 1. The iteration number and the PSO free parameters affected the runtime.
Higher constants and iteration number can increase the runtime. The runtime with iteration number, c and w of 500, 1.5 and 1, respectively, was 30 min. This runtime was not too slow and indicated that the algorithm might be effective for solving the problem. From the values of c and w, the correction values for different w and c obtained from the modelling are shown in Table 3.   Figure 4 is the correction graph with the smallest value of each variation of w, where c was 1.5. The graph shows that the smallest correction value occurred when w was 1. So this variation was chosen to determine the DSSC internal parameters.
The study presented by Dewi et al. obtained current from the DSSC sample examined using Keithley I-V 2602A. 5 In this study, we obtained current from a model. Both currents were compared, and there was a similarity.  Figure 5 shows the I-V graph from the experiment compared to the model. The I-V graphs from the experiment and the model show the same pattern. This indicates that the model using PSO provided results that agree with the experimental result. However, the patterns from the experiment and the model do not coincide perfectly. This could be due to the correction value ( Figure 3).  Table 4 shows that the increases in the working electrode thickness increased the photocurrent. Increasing the TiO 2 thickness increased the absorbed dye so that more electrons were excited by the photoelectric effect.
The parallel resistance changes significantly depending on the thickness of the working electrode. Increasing the thickness of the working electrode can reduce parallel resistance. This means that the recombination process is easier. A large amount of recombination that occurs can reduce the efficiency of DSSC.
The ideality factor of the diode value tends to be constant, which is between 1 and 2. This means that in the DSSC, the dominant factor influencing efficiency is the recombination process and the photoelectric effect. 21 This can be proven by observing significant changes in the photocurrent and parallel resistance depending on the thickness of the working electrode, where the photocurrent occurs due to the photoelectric effect and parallel resistance shows the resistance of the recombination process.
Saturation current is the current that flows when the bias voltage is zero. Saturation current can also be referred to as the limit current at the diode so that the current value of the photo is greater than the saturation current. This happens because there is series resistance. 19 Series resistance is related to electron mobility. It is assumed that by increasing the thickness of the TiO 2 layer, the distance between the electrons and the conductive layer on the fluorine-doped tin oxide (FTO) glass also increased, thereby reducing electron mobility. We added the errors between the model and the experimental study. The errors for different thicknesses are presented in Table 5. It is shown that the errors of the model and the experiment are very small. This could indicate that the model performs well.
In this study, we optimised the multi variables simultaneously using PSO. Triyana et al. conducted the optimisation for the same multivariable, but they did it individually. 12 They used a physical approach to find each of the multi variables. Thus, the optimisation method using PSO is more efficient and could have better results.

CONCLUSION
This research creates a model for an equivalent circuit of one diode to find the internal parameters of DSSC using PSO. The photocurrent and parallel resistance change significantly by increasing the working electrode thickness. Thereby, the photocurrent increases and the parallel resistance decreases. Furthermore, the increase does not significantly affect the saturation current or the ideality factor of the diode. The highest efficiency, 2.41%, is obtained with a thickness of 4.5 µm.
Conversely, the lowest efficiency is found with a thickness of 1.5 µm. The highest thickness provides the highest values of all internal parameters except parallel resistance. The highest parallel resistance is obtained with the lowest thickness.