Optimal Placement and Sizing of PV-STATCOM in Power Systems Using Empirical Data and Adaptive Particle Swarm Optimization

Solar energy is a source of free, clean energy which avoids the destructive effects on the environment that have long been caused by power generation. Solar energy technology rivals fossil fuels, and its development has increased recently. Photovoltaic (PV) solar farms can only produce active power during the day, while at night, they are completely idle. At the same time, though, active power should be supported by reactive power. Reactive power compensation in power systems improves power quality and stability. The use during the night of a PV solar farm inverter as a static synchronous compensator (or PV-STATCOM device) has recently been proposed which can improve system performance and increase the utility of a PV solar farm. In this paper, a method for optimal PV-STATCOM placement and sizing is proposed using empirical data. Considering the objectives of power loss and cost minimization as well as voltage improvement, two sub-problems of placement and sizing, respectively, are solved by a power loss index and adaptive particle swarm optimization (APSO). Test results show that APSO not only performs better in finding optimal solutions but also converges faster compared with bee colony optimization (BCO) and lightening search algorithm (LSA). Installation of a PV solar farm, STATCOM, and PV-STATCOM in a system are each evaluated in terms of efficiency and cost.


Introduction
In power systems, active power should be supported by reactive power for power system requirements [1].Reactive power is required due to loaded generators and transmission lines [2].The technique of reactive power generation at loadside is called compensation.Many reactive compensation devices are used, each device having its own properties and constraints.Among reactive compensation devices, flexible AC transmission devices (FACTS) play an important role in regulating the reactive power flow in the power system, which affects the fluctuations and stability of the system voltage [3].The static synchronous compensator (STATCOM), as one of most the important members of the FACTS family, is a shunt compensator which is increasingly used in modern power systems.The STATCOM has various applications for the operation and management of a power system [4].
Solar energy is a unique renewable energy source, the source of all available energy on Earth.It can be directly or indirectly transformed into other forms of energy, and a photovoltaic (PV) system is one of the most used applications of renewable energies.However, a photovoltaic solar farm can only produce active power during the day, while at night, it is completely idle, meaning that this expensive component is not utilized during the night.In any PV system, the voltage source converter/inverter is a key component, and it is also the most important element of a static synchronous compensator (STATCOM) [5].The idea of utilizing a PV solar farm inverter as a STATCOM during the night was proposed by Varma et al. in [5].According to this idea, during the night, the entire inverter capacity can be utilized for STATCOM, and during the day, the remaining inverter capacity can be utilized for STATCOM.
The application of a 10 kW solar system as STATCOM in the local distribution company London Hydro was presented in [6].Many advantages have been suggested for the proposed concept, such as an increase in the utility of a PV solar farm, acceptable voltage regulation, improvement in the power factor, electrical system performance improvement and additional revenue earning for solar power system owners during both the day and night.The optimal utilization of a PV solar system inverter as a STATCOM for controlling the voltage and improving the power factor of the Bluewater Power Corporation distribution network was evaluated in [7].The proposed PV-STATCOM was installed in 2011 after testing in the lab.A real-time digital simulation of the PV-STATCOM controller in a digital real-time simulator was presented in [8].The controller's performance was checked in both steady-state and transient modes for both the voltage regulation mode and the power factor correction mode.
Another PV-STATCOM model was proposed in [9] as a voltage control with auxiliary damping control for increasing the transient stability and, consequently, the power transmission limit.The results demonstrated that a PV-STATCOM was not only applicable in distribution networks but that it can also substantially improve the stable transmission limits during both the day and night, even while generating tens of megawatts of real power [9].The topology of a PV-STATCOM device connected to a transmission system is illustrated in Figure 1.
Sustainability 2018, 10, x FOR PEER REVIEW 2 of 16 synchronous compensator (STATCOM) [5].The idea of utilizing a PV solar farm inverter as a STATCOM during the night was proposed by Varma et al. in [5].According to this idea, during the night, the entire inverter capacity can be utilized for STATCOM, and during the day, the remaining inverter capacity can be utilized for STATCOM.The application of a 10 kW solar system as STATCOM in the local distribution company London Hydro was presented in [6].Many advantages have been suggested for the proposed concept, such as an increase in the utility of a PV solar farm, acceptable voltage regulation, improvement in the power factor, electrical system performance improvement and additional revenue earning for solar power system owners during both the day and night.The optimal utilization of a PV solar system inverter as a STATCOM for controlling the voltage and improving the power factor of the Bluewater Power Corporation distribution network was evaluated in [7].The proposed PV-STATCOM was installed in 2011 after testing in the lab.A real-time digital simulation of the PV-STATCOM controller in a digital real-time simulator was presented in [8].The controller's performance was checked in both steady-state and transient modes for both the voltage regulation mode and the power factor correction mode.
Another PV-STATCOM model was proposed in [9] as a voltage control with auxiliary damping control for increasing the transient stability and, consequently, the power transmission limit.The results demonstrated that a PV-STATCOM was not only applicable in distribution networks but that it can also substantially improve the stable transmission limits during both the day and night, even while generating tens of megawatts of real power [9].The topology of a PV-STATCOM device connected to a transmission system is illustrated in Figure 1.The benefits of active/reactive power compensation greatly depend on the placement and size of the added controllers.Although there are many different models proposed for new applications and constraints of PV-STATCOM, there are only a few published studies about the optimal placement and sizing of this device in a power system.In [10], an optimal distributed generation placement and sizing of a PV solar farm utilized as a STATCOM was proposed which concerned the necessity of fast reactive power compensation during voltage recovery processes under voltage sag or post-fault conditions.By adding weighted voltage support ability index analysis to the distributed generation planning constraints, the problem was solved to minimize the total annual cost.
In the present paper, a simple, novel method of optimal PV-STATCOM placement and sizing is proposed using empirical data.If solar irradiance data, solar power generation data and load data for all 8760 h of the year for a specific case study are available, then by modelling the active and reactive power of a PV-STATCOM in all time intervals, we can find the maximum portion of load that should be considered in the simulation.After that, we can find the candidate buses by calculating and sorting the power loss index, and finally, we can use an optimization technique to find the optimum PV-STATCOM size for those candidate buses.The benefits of active/reactive power compensation greatly depend on the placement and size of the added controllers.Although there are many different models proposed for new applications and constraints of PV-STATCOM, there are only a few published studies about the optimal placement and sizing of this device in a power system.In [10], an optimal distributed generation placement and sizing of a PV solar farm utilized as a STATCOM was proposed which concerned the necessity of fast reactive power compensation during voltage recovery processes under voltage sag or post-fault conditions.By adding weighted voltage support ability index analysis to the distributed generation planning constraints, the problem was solved to minimize the total annual cost.
In the present paper, a simple, novel method of optimal PV-STATCOM placement and sizing is proposed using empirical data.If solar irradiance data, solar power generation data and load data for all 8760 h of the year for a specific case study are available, then by modelling the active and reactive power of a PV-STATCOM in all time intervals, we can find the maximum portion of load that should be considered in the simulation.After that, we can find the candidate buses by calculating and sorting the power loss index, and finally, we can use an optimization technique to find the optimum PV-STATCOM size for those candidate buses.The case study selected for this research is the power network of Northern Cyprus, which has quite high, almost uniform solar irradiation in all regions.In the Turkish Republic of Northern Cyprus (TRNC), the demand for electrical energy keeps increasing, and consequently, so does its price.However, the quality and price of electrical energy should be maintained at an optimum level.Unfortunately, electrical energy authorities in the TRNC have not set rules or regulations for reactive power compensation, and as a result, voltage drop, harmonics, overvoltage, noises and unnecessary reactive power on lines often occur.In fact, these cause a lack of quality electricity [11].
In this study, a multi-objective function is considered to minimize total power loss, voltage deviation and cost; the results of the optimal placement and sizing of one PV-STACOM using three different optimization techniques are also presented and compared.
The results show that installing one PV-STATCOM in a system can produce a greater reduction in power loss and voltage deviation than installing only one solar farm or only one STATCOM.In this study, the installation costs of a PV solar farm and a PV-STATCOM are also approximated, according to their size.Since PV-STACOM can both generate active power and improve the system power quality, its annual profit is much higher than a PV solar farm.

Objective Function
In the literature, there are too many publications in the field of optimal allocation of STATCOM in the power systems with different objective functions [12,13].Moreover, in the examination of solutions for the problem of distributed generation placement and sizing, various objective functions have been presented in numerous publications [14].The most common objectives which have been considered for two problems of optimal distributed generation allocation and optimal STATCOM placement are presented in Figure 2.Among these objectives, active power loss mitigation, voltage improvement and cost reduction are considered in this study for optimal PV-STATCOM placement and sizing.The objectives which are related to system dynamic support can be evaluated in the future works.The case study selected for this research is the power network of Northern Cyprus, which has quite high, almost uniform solar irradiation in all regions.In the Turkish Republic of Northern Cyprus (TRNC), the demand for electrical energy keeps increasing, and consequently, so does its price.However, the quality and price of electrical energy should be maintained at an optimum level.Unfortunately, electrical energy authorities in the TRNC have not set rules or regulations for reactive power compensation, and as a result, voltage drop, harmonics, overvoltage, noises and unnecessary reactive power on lines often occur.In fact, these cause a lack of quality electricity [11].
In this study, a multi-objective function is considered to minimize total power loss, voltage deviation and cost; the results of the optimal placement and sizing of one PV-STACOM using three different optimization techniques are also presented and compared.
The results show that installing one PV-STATCOM in a system can produce a greater reduction in power loss and voltage deviation than installing only one solar farm or only one STATCOM.In this study, the installation costs of a PV solar farm and a PV-STATCOM are also approximated, according to their size.Since PV-STACOM can both generate active power and improve the system power quality, its annual profit is much higher than a PV solar farm.

Objective Function
In the literature, there are too many publications in the field of optimal allocation of STATCOM in the power systems with different objective functions [12,13].Moreover, in the examination of solutions for the problem of distributed generation placement and sizing, various objective functions have been presented in numerous publications [14].The most common objectives which have been considered for two problems of optimal distributed generation allocation and optimal STATCOM placement are presented in Figure 2.Among these objectives, active power loss mitigation, voltage improvement and cost reduction are considered in this study for optimal PV-STATCOM placement and sizing.The objectives which are related to system dynamic support can be evaluated in the future works.A multi-objective function is considered in searching for an optimal solution which minimizes power loss, voltage deviation and cost, described as follows.A multi-objective function is considered in searching for an optimal solution which minimizes power loss, voltage deviation and cost, described as follows.

Active Power Loss
In a power system, the total power loss is given by [12,15], as follows: where b is the number of lines, and R l and I l are the resistance and the current, respectively, through line l.V i and θ i are, respectively, the voltage magnitude and angle at bus i, and Y ij and φ ij , respectively, are the magnitude and angle of the line admittance.

Voltage Deviation
The index of improvement of the voltage of a power system is defined as the deviation from the amplitude of the unit voltage on a bus.Thus, for a given system, the index of improvement of the voltage is given by [15]: where n is the number of buses, V iN is the nominal voltage at bus i and V i is the actual voltage at bus i.
The nominal voltage is considered as 1 p.u in this study.

Investment Cost
A PV-STATCOM is an expensive device, and therefore, the investment cost for installing such controllers must be considered to justify the economic viability of the devices.In order to evaluate the profitability of PV-STATCOM owners a cost function should be taken into account.To calculate the cost of a PV-STATCOM, the following equation can be defined: where E loss is the total energy loss.K e is average price of the unsold energy.K a and K b are yearly depreciation of installation and the maintenance costs of PV-STATCOM, respectively.B j is defined as a binary variable and is equal to 1 if a PV-STATCOM is present at bus j and to 0 if no PV-STATCOM is present.S PV-STATCOM is the size of PV-STATCOM.

Operational Constraints
For optimal placement and sizing of PV-STATCOM, the following constraints are considered [12].

Power Flow Balance Equations
The power balance with respect to a bus can be formulated as: where P Gi and Q Gi , respectively, are the generated real and reactive powers, and P Li and Q Li , respectively, are the load real and reactive powers at bus i.The conductance G' ik and the susceptance B' ik represent the real and imaginary components of element Y' ij in the bus admittance matrix.

Size Limit
The apparent power of a PV-STATCOM as an active/reactive power compensator must not exceed its limiting value:

Bus Voltage Limits
Bus voltages must be maintained within the limits of their nominal value given by: In practice, the difference can reach 10% of the value of the voltage [12].

Fitness Function
An overall fitness function, in which each objective function is normalized with respect to the base system without a PV-STATCOM, is considered.This fitness function is given by: subject to: where P loss , L v and Cost PV-STATCOM are the total active power loss, voltage deviation index and total cost, respectively.ω 1 , ω 2 and ω 3 are the coefficients of the corresponding objective functions, ∑ ∆Loss base is the total active power loss in the network of the base case before installing PV-STATCOM, ∑ V base is the total voltage deviation of the base case and Cost Max is the maximum allowed cost.Considering Equation (3), the cost function consists of two terms.In the first term, the total energy loss is the product of total power loss and 8760 h of a year.In the other words, in the cost function, E loss is directly proportional to P loss which has been already considered as the first objective function component of Equation (8).In addition, the second term of cost function in Equation (3), only varies by the change in size of PV-STATCOM.It means due to consideration of power loss in the fitness function of Equation ( 8), to avoid redundancy, for the case that we are installing only one PV-STATCOM on the system and the size of that single additional device is determinative, rather than considering the cost of PV-STATCOM, it is reasonable to consider its size.In this way, all objectives will be taken to account by a small modification in the fitness function.Hence, in this study, the third objective function component of Equation ( 8), has been defined to have the minimum possible PV-STATCOM sizes regarding the control of a PV-STATCOM instead of considering the total PV-STATCOM cost.Since, in this study, only one PV-STATCOM has been considered, it is reasonable that: For one PV−STATCOM (10) where S PV-STATCOM is the PV-STATCOM size in MVA, and S max is the maximum possible PV-STATCOM size, defined as its maximum apparent power.
According to the importance of any objective function component, the coefficients of ω 1 , ω 2 and ω 3 are different.In this study, due to importance of power loss reduction and voltage improvement, we consider that ω 1 = 40%, ω 2 = 40% and ω 3 = 20%.

Power Loss Index
The power loss in transmission lines between buses i and j can be given by the following equation: where P loss and Q loss , respectively, are the active and reactive power losses.R ij and X ij , respectively, are the resistance and reactance of the line connected to the buses i and j, P j and Q j are the real and reactive powers of the load at bus j, and V j is the voltage magnitude at bus j [16].
Since we only consider real power loss minimization in the objective function, we can define the power loss index as follows [17].
For the case i = j: The power loss index is used to specify which buses are candidates to be a critical bus in the system in order to select locations at which to install a PV-STATCOM.The buses with higher power loss index values are critical buses; therefore, these will be suitable locations at which to install a PV-STACOM.

Adaptive Particle Swarm Optimization (APSO)
Particle swarm optimization (PSO) is a metaheuristic optimization technique based on populations inspired by bird flocking and fish schooling [15].Initially, PSO was used to solve continuous nonlinear optimization problems, but it has now been extended to solutions of constrained nonlinear optimization problems with both discrete and continuous variables [18,19].The basic idea behind the PSO algorithm is that a population called a swarm is generated randomly.The swarm is made up of individuals called particles, where each particle in the swarm represents a potential solution to the problem under consideration.Each particle moves through a dimensional search space at a random velocity.A particle updates its velocity and position according to the following equations: where w is the inertia weight, c 1 and c 2 are acceleration constants, r 1 and r 2 are two random numbers in the range of [0,1], pbest i k is the best position ever visited by a particle i at the kth iteration and gbest i k is the global best position in the entire swarm.
The implementation of the PSO algorithm can be described by the following steps [18]: • Step 1: Randomly initialize a swarm of particles in a D-dimensional search space.

•
Step 2: Evaluate the fitness of the entire swarm.

•
Step 3: Record the best position of each particle, pbest, and the global best position, gbest.

•
Step 4: Update the velocity vector and position vector of each particle.
A global search can be facilitated by a large inertia weight, while a local search can be facilitated by a small inertia weight.In an adaptive version of PSO, the inertia weight can be updated dynamically by increasing the number of iterations [20]: where W max and W min , respectively, are the upper and lower bounds of the inertia weight.This modification can increase the speed of convergence in conventional PSO.

Proposed Method for Optimal PV-STATCOM Placement in a Power Network
A PV-STATCOM is a device added to a power network which can inject active power in the daytime period and inject reactive power during the night.Since the apparent power of this device is constant, there is always a specific mathematical relationship between the amounts of active and reactive power injected into the system.The active power depends on the power generated by the solar power system, and the reactive power can be computed as: where S is the PV-STATCOM apparent MVA power, P is the active power in MW produced by PV, and Q is the reactive power of the controller in MVar.
In Figures 3 and 4, two samples of active/reactive power injected by a PV-STATCOM are presented for 24-h periods of different days.Figure 3 shows solar power production through a summer day, where active power of up to 800 kW can be generated.Figure 4 shows solar power production through a winter day, where active power of up to 520 kW can be generated, while the solar generation curve has fluctuations.For both figures, the reactive power graphs have been drawn.(17) where Wmax and Wmin, respectively, are the upper and lower bounds of the inertia weight.This modification can increase the speed of convergence in conventional PSO.

Proposed Method for Optimal PV-STATCOM Placement in a Power Network
A PV-STATCOM is a device added to a power network which can inject active power in the daytime period and inject reactive power during the night.Since the apparent power of this device is constant, there is always a specific mathematical relationship between the amounts of active and reactive power injected into the system.The active power depends on the power generated by the solar power system, and the reactive power can be computed as: where S is the PV-STATCOM apparent MVA power, P is the active power in MW produced by PV, and Q is the reactive power of the controller in MVar.
In Figures 3 and 4, two samples of active/reactive power injected by a PV-STATCOM are presented for 24-h periods of different days.Figure 3 shows solar power production through a summer day, where active power of up to 800 kW can be generated.Figure 4 shows solar power production through a winter day, where active power of up to 520 kW can be generated, while the solar generation curve has fluctuations.For both figures, the reactive power graphs have been drawn.
Apart from the shape of the solar power production graphs, there are two points, indicated by stars, at which the amounts of the active and reactive powers are equal, or Q = P.The times during which Q = P in a PV-STATCOM are a few hours before and a few hours after the maximum solar irradiance time.In the problem of the optimal placement and sizing of a PV-STATCOM, the capacity of the PV-STACOM is defined as its apparent power, but we do not know the amount of apparent power to calculate Q in each step; thus, we use the Q = P points, above, to try to find the apparent power, as follows: in which Q (PV-STATCOM) = P (PV-STATCOM).
At the Q = P points, the load is a portion of the maximum load.There is no need to consider the Apart from the shape of the solar power production graphs, there are two points, indicated by stars, at which the amounts of the active and reactive powers are equal, or Q = P.The times during which Q = P in a PV-STATCOM are a few hours before and a few hours after the maximum solar irradiance time.
In the problem of the optimal placement and sizing of a PV-STATCOM, the capacity of the PV-STACOM is defined as its apparent power, but we do not know the amount of apparent power to calculate Q in each step; thus, we use the Q = P points, above, to try to find the apparent power, as follows: S (PV-STATCOM) = P (PV-STATCOM) + j Q (PV-STATCOM) , (19) in which Q (PV-STATCOM) = P (PV-STATCOM) .
At the Q = P points, the load is a portion of the maximum load.There is no need to consider the given peak load of the case study when doing the power flow calculation.The load ratio in Q = P points can be defined as: Figures 5 and 6 are showing the graphs of load ratio in different time intervals for two different days which were already considered in Figures 3 and 4, respectively.In Q = P points, the load ratio (LR) is obtained and shown.The highest LR on 22/08/2012 was 67.9% which happened on 4:00 p.m. and the maximum LR on 14/02/2012 was 48.8% that happened on 1:00 p.m. Annual peak load for the case study was considered as 313 MW using the load data.In the problem of the optimal placement and sizing of a PV-STATCOM, the capacity of the PV-STACOM is defined as its apparent power, but we do not know the amount of apparent power to calculate Q in each step; thus, we use the Q = P points, above, to try to find the apparent power, as follows: in which Q (PV-STATCOM) = P (PV-STATCOM).
At the Q = P points, the load is a portion of the maximum load.There is no need to consider the given peak load of the case study when doing the power flow calculation.The load ratio in Q = P points can be defined as: Figures 5 and 6 are showing the graphs of load ratio in different time intervals for two different days which were already considered in Figures 3 and 4, respectively.In Q = P points, the load ratio (LR) is obtained and shown.The highest LR on 22/08/2012 was 67.9% which happened on 4:00 pm and the maximum LR on 14/02/2012 was 48.8% that happened on 1:00 pm.Annual peak load for the case study was considered as 313 MW using the load data.After finding all Q = P points for different days of the year and considering the load ratio in those points, the maximum LR value in Q = P points were obtained as 68.3% which was happened on 29 June 2012 at 2:00 pm as shown in Figure 7.The given peak load in the case study should be reduced by this LRmax. .After finding all Q = P points for different days of the year and considering the load ratio in those points, the maximum LR value in Q = P points were obtained as 68.3% which was happened on 29 June 2012 at 2:00 p.m. as shown in Figure 7.The given peak load in the case study should be reduced by this LR max .After finding all Q = P points for different days of the year and considering the load ratio in those points, the maximum LR value in Q = P points were obtained as 68.3% which was happened on 29 June 2012 at 2:00 pm as shown in Figure 7.The given peak load in the case study should be reduced by this LRmax. .The proposed procedure for the optimal placement and sizing of a PV-STATCOM in a power network, when we have all data in terms of solar power production and load for 8760 h of a year for a specific case study, is as follows: (1) Collect all solar irradiance data, solar power generation data and load data for all 8760 h of a year for the case study.(2) Consider a day in the year, find the maximum solar power generated on that day (P max (day) ) and suppose that the apparent power of that day is constant as S (day) = P max (day) .
(3) Find the reactive power for all 24 h of that day by Annual peak load (5) Repeat steps 2 to 4 for all days of a year and find the maximum LR value among all calculated LRs of different days of the year, as LR max .
(6) Multiply all given loads in the case study by the maximum load ratio of LR max and run the power flow for the base case.(7) Find the candidate buses for installing a PV-STATCOM by computing the power loss index.(8) Randomly inject a load to candidate buses as: in which Q (PV-STATCOM) = P (PV-STATCOM) .( 9) Run the power flow program to calculate the bus voltages and total power loss.

Case Study and Results
The case study in this paper is the electrical transmission network in Northern Cyprus, which has 23 substations as shown in Figure 9.The total power generated in the system is 345 MW.There are two types of transmission lines, depending on the voltage rate, the first being 132 kV and the second 66 kV.

Case Study and Results
The case study in this paper is the electrical transmission network in Northern Cyprus, which has 23 substations as shown in Figure 9.The total power generated in the system is 345 MW.There are two types of transmission lines, depending on the voltage rate, the first being 132 kV and the second 66 kV.

Case Study and Results
The case study in this paper is the electrical transmission network in Northern Cyprus, which has 23 substations as shown in Figure 9.The total power generated in the system is 345 MW.There are two types of transmission lines, depending on the voltage rate, the first being 132 kV and the second 66 kV.The five most critical buses with high power loss index values are illustrated in Table 1.These buses are suitable for installing a PV-STATCOM.The problem of the optimal placement and sizing of PV-STATCOM devices will be solved to find the best size to be installed on a bus among these critical buses.The five most critical buses with high power loss index values are illustrated in Table 1.These buses are suitable for installing a PV-STATCOM.The problem of the optimal placement and sizing of PV-STATCOM devices will be solved to find the best size to be installed on a bus among these critical buses.All solar irradiance data, solar power generation data and load data for all 8760 h of a year were available for this case study [22].The maximum load ratio value among all calculated LRs of different days of the year in Q = P points were obtained, as LR max = 0.683.This meant that the given peak load in the case study should be reduced by 68.3%.In the new load condition, we ran the power flow to obtain the results for the base case without any PV-STATCOM, and afterwards, we conducted the procedure proposed in the previous section in order to find the best location and size of PV-STATCOM at the candidate buses.The total power loss in the base case with the new load condition was obtained as 9.75 MW, and the voltage deviation was 0.249.The maximum apparent power of the PV-STATCOM was supposed to be 2 MVA.Using the base case values, the fitness function could be calculated in each iteration.
For a fair comparison of the results-since the concept of 'particle and population' in PSO is very similar to the term 'scot bee and colony' in bee colony optimization (BCO) [23] and also to the term 'projectile and step leader' used in the lightening search algorithm (LSA) [24], BCO and LSA were also selected for this study [25].The optimal parameters of these three optimization techniques are shown in Table 2.The results for the optimal placement and sizing of one PV-STACOM device, using the three different optimization techniques, were obtained and are presented in Table 3.The optimum locations and sizes of PV-STATCOM devices, obtained by these different methods, differ from each other.The size of PV-STATCOM in terms of apparent power is calculated by where P PV-STATCOM and Q PV-STATCOM are the optimum values of active and reactive power obtained by optimization techniques and they are both equal to each other.Among these three optimization techniques, the results of APSO in terms of power loss reduction, voltage improvement and fitness function value were better.The size for PV-STATOM obtained by PSO was higher than the values obtained using the other objective function components.Even the computational time using APSO was smaller, which meant that the APSO algorithm produced better results in terms of accuracy and speed in optimal PV-STATCOM placement and sizing.
By considering different objective function coefficients in Equation ( 8), the proposed algorithm is implemented and the obtained results are presented in Table 4.According to the importance of any objective function component, the coefficients of ω 1 , ω 2 and ω 3 are different.We can see the lowest fitness function value is for the case that ω 1 = 40%, ω 2 = 40% and ω 3 = 20%.Then we considered and compared the results of three cases as follows: Case 1: Installing only one solar farm in the system, in which |S| = P PV and Q STATCOM = 0. Case 2: Installing only one STATCOM in the system, in which |S| = Q STATCOM and P PV = 0. Case 3: Installing PV-STATCOM in the system, in which |S| = √ A comparison of the results for these three cases obtained by APSO is presented in Table 5.The results show that installing one PV-STATCOM at GIRNE II can reduce power loss and voltage deviation to a greater extent than the cases of installing only a solar farm or only a STATCOM.Since five busbars have been selected as the most critical buses with high power loss index, the best solution to be found by the proposed optimization algorithm is a (1 × 5) matrix where four arrays values are 0. A value of 0 in the matrix means that there is no need to install any additional device at that bus.Consider the best solutions shown in Figure 10 which are obtained for different cases.For any case, the best solution is a (1 × 5) matrix which has only one nonzero array.That array shows the best location and size of the additional devices.
Then we considered and compared the results of three cases as follows: A comparison of the results for these three cases obtained by APSO is presented in Table 5.The results show that installing one PV-STATCOM at GIRNE II can reduce power loss and voltage deviation to a greater extent than the cases of installing only a solar farm or only a STATCOM.Since five busbars have been selected as the most critical buses with high power loss index, the best solution to be found by the proposed optimization algorithm is a (1 × 5) matrix where four arrays values are 0. A value of 0 in the matrix means that there is no need to install any additional device at that bus.Consider the best solutions shown in Figure 10 which are obtained for different cases.For any case, the best solution is a (1 × 5) matrix which has only one nonzero array.That array shows the best location and size of the additional devices.The solutions indicate that the best solar farm, STATCOM and PV-STATCOM placement are at buses i, j, k, respectively.Moreover, the best solar farm, STATCOM and PV-STATCOM sizes are P i , Q j and S k , respectively.The optimal solution in all cases leads to maximum power loss reduction, minimum voltage deviation, considering the size of additional components.
In Table 6, the installation cost of each additional device according to its size is approximated for case 1 and case 3. The installation cost of one PV solar farm is considered as 1.2 USD/W while the installation costs of one PV-STATCOM have been approximated using Ref. [26].From these installation costs, we can see that if the installed solar farm used as PV-STATCOM, the cost of installing a solar farm and after utilizing as PV-STATCOM would be around 100,000 USD.In comparison to the cost of installing a separate STATCOM in [23]; this is certainly more reasonable.
In addition, yearly depreciation of the installation and the maintenance costs, yearly profit by power loss reduction and yearly earning by sold energy for these two case are obtained as shown in Table 6.Consequently, the annual profits of using a single solar farm and a PV-STATCOM are presented and compared.Since PV-STACOM can both generate active power and improve the system power quality, its annual profit is much higher than using a single solar farm.

Conclusions
Recently, the concept of utilizing a PV solar farm inverter as a STATCOM during the night has been proposed.According to this concept, during the night, the entire inverter capacity would be utilized for a STATCOM, while during the day, the remaining inverter capacity would be utilized for a STATCOM.Increasing the utility of a PV solar farm, engaging in acceptable voltage regulation, improving the power factor and electrical system performance and providing additional revenue earnings for solar power system owners during both the day and night are only some of the objectives to be achieved by using PV-STATCOM in power systems.In this paper, a simple, novel method for optimal PV-STATCOM placement and sizing was proposed which used empirical data.The maximum load ratio needed was found from the solar irradiance and load data and was used instead of the peak load.The two sub-problems of placement and sizing were solved, respectively, by the power loss index and adaptive particle swarm optimization, considering the objectives of power loss and cost minimization as well as voltage improvement.The obtained results for the power network of Northern Cyprus, which has quite high and almost uniform solar irradiation in all regions, showed that installing one PV-STATCOM in the system can reduce power loss and voltage deviation to a greater extent than installing one solar farm alone or one STATCOM alone.The annual profit of installing PV-STATCOM is much higher than using solar farm.The problem of optimal PV-STATCOM placement and sizing in both transmission and distribution systems considering the effect of harmonics and the objectives which are related to system dynamic support can be evaluated in the future works.

Figure 1 .
Figure 1.Topology of a photovoltaic solar farm inverter as a static synchronous compensator (PV-STATCOM) device connected to a transmission system.

Figure 1 .
Figure 1.Topology of a photovoltaic solar farm inverter as a static synchronous compensator (PV-STATCOM) device connected to a transmission system.

Figure 5 .
Figure 5. Load ratio in different time intervals on 22 August 2012.

Figure 6 .
Figure 6.Load ratio in different time intervals on 14 February 2012.

Figure 6 .
Figure 6.Load ratio in different time intervals on 14 February 2012.

Figure 7 .
Figure 7.The maximum load ratio in Q = P points among all days of year (on 29 June 2012).Figure 7. The maximum load ratio in Q = P points among all days of year (on 29 June 2012).

Figure 7 .
Figure 7.The maximum load ratio in Q = P points among all days of year (on 29 June 2012).Figure 7. The maximum load ratio in Q = P points among all days of year (on 29 June 2012).
Find two time intervals of a 1-hour period in that day in which P (hour) − Q (hour) has the smallest value.Read the load for those time intervals and calculate the load ratio as LR = Load (when P=Q)

( 10 )
Evaluate the fitness function.(11) Update the PV-STATCOM location and size as new solution vectors through the optimization technique.(12) Evaluate the fitness function of the new solution vectors.(13) Check whether the PV-STATCOM set (i.e., the new solution vector) has a lower fitness function value than the previous solution vector.If yes, the optimal locations and sizes of the PV-STATCOM devices are replaced with the new solution vectors.Otherwise, go to step 11.(14) Determine the optimum PV-STATCOM placement and sizing which provides minimum power loss, voltage deviation and total cost.

Figure 8
Figure 8 describes the proposed procedure in terms of flowchart.Sustainability 2018, 10, x FOR PEER REVIEW 11 of 16

Figure 8 .
Figure 8. Flowchart of the proposed procedure.

Figure 8 .
Figure 8. Flowchart of the proposed procedure.

Figure 10 .
Figure 10.Investigating the optimal solution for different cases.Figure 10.Investigating the optimal solution for different cases.

Figure 10 .
Figure 10.Investigating the optimal solution for different cases.Figure 10.Investigating the optimal solution for different cases.

Table 1 .
The most critical buses with high power loss index.

Table 2 .
Optimal parameters of different optimization techniques.

Table 3 .
Comparison of the results of different techniques.

Table 4 .
Comparison of the results the proposed algorithm using different objective function coefficients.

Table 5 .
Comparison of the results of three cases obtained by adaptive particle swarm optimization (APSO).

Table 5 .
Comparison of the results of three cases obtained by adaptive particle swarm optimization (APSO).

Table 6 .
Comparison of the costs of Case 1 and Case 3.