Design of a master power factor controller for an industrial plant with solar photovoltaic and electric vehicle chargers

The power factor of industrial facilities is typically inductive. The case study in this paper was based on a typical Malaysian 11-kV on-grid industrial system with renewable energy sources and electric vehicle charging station connected. The integration of renewable energy sources reduces energy consumption from the grid; it consecutively reduces greenhouse gas emissions. However, the integration of renewable energy sources such as solar photovoltaic operating at unity power factor results in a reduction of the industry’s power factor. According to the Malaysian Distribution Code, the power factor of a medium voltage industrial system should be more than 0.85 lagging. A long-term low power factor will reduce the related electrical equipment lifespan and increase the monthly electricity bills. A classic method to overcome this issue was by installing reactive power compensator devices, such as the synchronous condenser, static VAr compensator and static synchronous compensator. Studies had revealed that solar photovoltaic with appropriate control system design could perform short-term reactive power compensation. The control techniques used are either power factor control, active power control, reactive power control or any combination of them. However, neither the reactive power compensator devices nor the solar photovoltaic with a control system can regulate the industry’s power factor to an intended value throughout its operation. Thus, this paper presents a simple, relatively cost-effective design of a master power factor controller that is capable of regulating the industry’s power factor to an intended value throughout its operation with a single preset reference. In this research, an industry-grade system comprises an industrial load installed with a power factor-controlled capacitor bank, a power factor-controlled solar photovoltaic system, a bidirectional current-controlled electric vehicle charging system based on CHAdeMO 1.1 standard charging protocol and a master power factor controller was designed using the Matrix Laboratory/Simulink software. This paper has provided simulation results as proof that each of the designed equipment was functioning appropriately. The results also proved that the proposed master power factor controller was capable of regulating the power factor of the industrial system to above 0.85 lagging throughout its operation.


C bankneed
Capacitor bank needed to operate to achieve power factor reference of the industrial load C dclink DC  Three-phase active power output from the solar photovoltaic system PF Power factor PF ind Power factor of the industrial system PF load Power factor of the industrial load PF mref Master power factor reference PF needPV Power factor needed for the solar photovoltaic system to achieve master power factor reference PF refEV Power factor reference for the electric vehicle charging system PF reflimitPV Limit power factor reference for the solar photovoltaic system PF refload Power factor reference for the industrial load PF refPV Power factor reference for the solar photovoltaic system P ind Overall active power received by the industrial system PLL Phase-locked loop P maxPV Maximum active power output from the solar photovoltaic system P PV Active power output from the solar photovoltaic system PV Photovoltaic Q Reactive power Q ind Overall reactive power received by the industrial system Q max Maximum reactive power output Q maxPV Maximum reactive power output from the solar photovoltaic system

Introduction
The electrification of the transportation sector is significantly contributing to a lesser carbon footprint [1]. The sales of electric vehicles (EVs) are increasing, where more on-road EVs are predicted in the foreseeable future [2]. The twenty-first century saw the rapid development of EV technology, where some EVs were shown to have a better performance than regular internal combustion engine vehicles (ICEVs) in terms of energy conversion efficiency, maximum torque and distance covered per full charge [3]. Hence, the projection of EV to replace the ICEV in the nearest future is quite inevitable [4]. In Malaysia, the National Automotive Policy had distributed soft loans amounting to RM 100 million per year to the EVs vendor for installing and developing advanced EV technology and machinery [5]. Meanwhile, the International Energy Agency had reported that, in the most recent time, the industrial sector has the highest electricity consumption worldwide [6]. Fortunately, the adoption of renewable energy sources (RES) has slowly reduced the world's dependency on fuel-based electric generators. The deployment of distributed solar photovoltaic (PV) systems is growing exponentially over the last decade [7]. Many countries have started promoting rooftop solar PV for homes, commercial buildings and industry [8]. The Sustainable Energy Development Authority, a statutory body in Malaysia, had introduced several solar PV policies, such as Feed-in-Tariff, Self-Consumption and Net Energy Metering (NEM) for residential, commercial, agricultural and industrial sectors [9]. The NEM is a scheme that consumes the electrical energy produced by the solar PV system and exports any excess to the distribution licensees. The installation of solar PV can provide a long-term investment.
Unfortunately, the pure RES installation can cause the power factor (PF) at the industry's incomer (PF ind ) to reduce drastically. The minimum PF ind value stipulated by the electrical utility in Malaysia is 0.85 lagging [10]. A PF ind lower than that will result in a greater power loss where it leads to equipment overloads, equipment overheating and a shorter service life [11]. So, if the owner of the industry fails to fulfill the regulation, the utility will penalize them with a higher monthly electricity bill [10]. Due to this reason, a need to install a master PF controller to regulate the PF ind to an intended value without additional installed equipment is imperative.
The literature in [12] had mentioned installing reactive power (Q) compensating devices such as the synchronous condenser, static VAr compensator (SVC) and static synchronous compensator to solve low PF ind . Authors in [13] proposed the hybrid control strategies of SVC for Q compensation. However, the authors further added that maintenance is difficult and expensive. Another study in [14] had discussed in-depth the power factor (PF), active power (P) and Q control techniques used in the solar PV system. The control techniques are designed with either quadrature frame-based (dq), alpha-beta frame-based (αβ) or abc frame-based (abc) structures. Authors in [15] had listed five control techniques used for Q management in the RES system, namely sliding mode control, model predictive control, soft computing methods, droop speed control and current mode control. The soft computing method has the fastest response speed among all these control techniques, but its algorithm is rather complicated. Elsewhere, a reliable and flexible bidirectional EV charging system with multi-controller was designed [16], where it can perform discharging control (D-control), current control (I-control), voltage control (V-control), Q-control and PF-control. However, the Q compensating devices and controllers mentioned in [12][13][14]16] are incapable of regulating PF ind to attain an intended value throughout its operation, and the control techniques mentioned in [15] are complex, correspondingly expensive. This paper proposes a master PF controller that can regulate the PF ind to attain the desired value by a single preset reference throughout its operation. This case study involves the operation of a medium voltage industrial system comprising an 11-kV industrial load with C bank , PF-controlled 400 kW pk solar PV system, bidirectional I-controlled EV fast-charging system and a master PF controller to coordinate them all. This paper discusses the details of each equipment design and control processes involved. The key contributions of this paper are (1) the design of the master PF controller which encompass RES, EV and C bank to regulate the PF ind to any preset reference value, (2) the mathematical formula for calculating the C dclink and LC filter sizing and (3) validation of the robustness of the master PF controller.

Overview of the industrial plant
This case study was formulated based on a typical Malaysian 11-kV industrial system integrated with a PF-controlled 400 kW pk solar PV system and a bidirectional I-controlled EV fast-charging system with three charging ports. The ANSI/ IEEE 1585-2002 standard stated that 11-kV is a medium level voltage [17], used in industrial facilities with their stepdown transformers for connecting to low-rated voltage systems. In this case study, the installation utilized an 11-kV/ 400 V transformer for connecting to the solar PV system and EV charging system. The EV model used is the Nissan LEAF 2019, which is powered by lithium-ion (Li-Ion) battery with a capacity of 40 kWh, 114.3 Ah and a nominal voltage of 350.4 V [18]. There are three EVs in total, which act as flexible and dynamic loads. Each of them receives approximately 50 kW with 125 A current transfer during charge mode [19]. The case study in this paper only focuses on charge mode. The proposed master PF controller was connected to the industry's current transformer (CT), voltage transformer (VT) and the PF-controlled DC/AC converter of the solar PV system. Figure 1a, b illustrates a general diagram of the industrial system and a detailed framework of the interconnection of RES and EV, respectively [20].
For the base case in this research, the industrial load has an unimproved PF (PF load ) of 0.8 lagging. It was then installed with C bank to ensure that the PF ind is maintained at 0.95 lagging. Next, the industrial system was connected to the solar PV system operating at unity PF and the EV charging system where it causes further reduction and alternation in PF ind, respectively. Finally, the industrial system was installed with the proposed master PF controller to regulate the PF ind at 0.95 lagging by utilizing the PF-controlled solar PV system for Q support. The master PF controller sends a dynamic control signal to the PF-controlled solar PV system as its instantaneous PF reference (PF refPV ) during the controlling process. A detailed explanation of the proposed control algorithm is given in the control section.

Capacitor bank control
The capacitor bank (C bank ) with a control system [21] is reliable and capable of regulating PF ind to an intended value.

3
The size of the C bank varies according to the load and the intended PF [22]. The industrial load was installed with a 600 kVAr C bank to improve the PF ind from 0.8 lagging to 0.95 lagging. The industrial load reference (PF refload ) was set to 0.95 lagging because it is more than 0.85 lagging and includes an additional safety margin. The designed C bank comprises thirty fixed stackable and switchable 20 kVAr capacitors. The amount of Q needed to attain PF refload , and the number of 20 kVAr capacitors that need to be operated (C bankneed ) is the base calculation of this PF control. A too large and fixed capacitor size was not preferred as it can cause the PF ind to be in over and under correction [23]. Figure 2 shows the flow algorithm of the C bank operated at PF refload of 0.95 lagging.

Solar PV control
The PF-controlled solar PV system was designed by referring to previous studies [14,24,25]. The DC link voltage (V dclink ) control was used for improving the system stability. The solar PV system design was based on the DC-DC-AC inverter topology, also known as two-stage power conversion [24]. The DC/DC converter was placed in between the solar PV panel and the DC/AC converter to enhance the design flexibility, voltage gain and energy harvesting capability [24]. A detailed configuration of the PF-controlled solar  The DC/DC converter was installed with a maximum power point tracking (MPPT) device for maximizing the instantaneous DC power output of the solar PV panel. The MPPT device controls the duty ratio of the DC/DC converter (D con ) until the DC supply voltage (V S ) of the solar PV panel is reached and maintained at the maximum power point voltage (V MPP ) [25]. The best MPPT method for a 400 kW pk solar PV system is the incremental conductance method [25]. The DC link voltage reference (V dclinkref ) should not be too low and too high, respectively, for an admirable dynamic control and to avoid redundant switching losses [16]. In this case study, the V dclinkref for the solar PV system is permanently set at 950 V. The relationship between the V S , V dclink and D con is expressed as per mathematical Eq. (1) [16]: The V dclink and PF controller was constructed based on the dq control structure due to easy controlling and filtering accomplishment [14]. Based on Figs. 3 and 4, initially, the instantaneous three-phase phase-to-ground voltages (V abc ) and three-phase phase-to-ground currents (I abc ) output of the solar PV system were obtained by tapping at the AC  Detailed control configuration for the designed solar PV system side after passing the LC filter. The V abc and I abc were converted into a three-phase active power (P PV ) form. The P PV and PF refPV then undergo a mathematical transformation to obtain current quadrature reference (I qref ).
Meanwhile, the instantaneous three-phase phase-toground voltages were obtained at the grid side (V gabc ) and sent to the phase-locked loop (PLL) device to get the V gabc phase angle (ωt). In this control system, the PLL device was used for synchronizing the grid phase signal and the solar PV system phase signal [26]. The phase angle was then used in Park and inverse Park transformation. Park transformation is a process of simplifying the fundamental equation, whereas inverse Park transformation is vice versa [27]. In this solar PV system control process, the I abc was simplified to be a direct and quadrature current (I d and I q ). The instantaneous V dclink was obtained by tapping at the C dclink . It was then compared to the DC link voltage reference (V dclinkref ) to get the current direct reference (I dref ). Next, the I d and I q were compared to the I dref and I qref , respectively. The output of these comparisons goes through the PI controller to reduce the offset [28]. It becomes a current direct control (I dcontrol ) and a current quadrature control (I qcontrol ) before undergoing the inverse Park transformation and finally, Sine Pulse Width Modulation (SPWM) process. The proportional gain (K P ) value and integral gain (K I ) value of the PI controller were manually tuned based on experiences [28]. Finally, the output of SPWM was fed to the DC/AC converter switches (S1-S6), as shown in Figs. 3 and 4.
The instantaneous PF refPV and the instantaneous P PV will determine the amount of instantaneous Q delivered from the solar PV system (Q PV ) to the industrial system. The designed solar PV system has a maximum active power output (P maxPV ) of approximately 400 kW. As referred to the guidelines [29], if the P PV is equal or greater than 20% of the DC/AC converter rated power, the PF refPV value should not be lower than 0.9 leading or else the DC/AC converter will get exhausted. So, the PF refPV limit (PF reflimitPV ) parameter was set at 0.9 leading. The mathematical equation to calculate the amount of Q PV and Q maxPV based on trigonometric power theory is shown in Eq. (2) and (3). Equation (2) indicates that the closer the PF refPV is to unity, the lower the Q PV . The Q maxPV value is vital for C dclink sizing calculation.

EV charger control
The designed EV charging system comprises three bidirectional I-controlled half-bridge non-isolated DC/DC converter and a V dclink and PF-controlled DC/AC converter, as illustrated in Fig. 1. The previous studies [16,30] are the reference for designing the bidirectional EV charging system. Figure 5 presents a detailed configuration of the designed EV charging system with one charging port.
The V dclink and PF control system used in the designed EV charging system is identical to the control system used in the designed solar PV system; thus, the control process is the same as in Fig. 4. The advantages of a bidirectional half-bridge non-isolated DC/DC converter are the high-efficiency, low active component and relatively cost-effective [30]. The PF reference for the designed EV charging system (PF refEV ) was set to unity. The designed EV charging system can single-charge EV battery with a maximum DC power transfer of 62.5 kW with 125 A of current transfer (I EV ) based on CHAdeMO 1.1 standard charging protocol. It can cater simultaneous charge up to three EVs.
The C dclink and LC filter are two vital components in the solar PV and EV charging system. The C dclink is typically utilized to reduce the ripples of V dclink [31] and for providing 5 A detailed configuration of the designed EV charging system Q support [32]. Oversized and undersized C dclink will result in over expenditure and system failure, respectively. An LC filter is used for smoothening the AC signal [33]. Improper LC filter design will lead to low system power quality.

DC link capacitor modeling
The C dclink is an intermediary electronic component located between the DC/DC converter and the DC/AC converter, as shown in Fig. 1. The Q maxPV is the maximum limit of the amount of Q (Q max ) that C dclink can support. The mathematical steps to calculate the sizing of C dclink based on Q max start with the three-phase apparent power (S) equation as per Eq. (4): Since only alternating current (AC) is involved, the resistance (R) is replaced with impedance (Z) by using Ohm's law and shown in Eq. (5): Substituting Eq. (4) and Eq. (5) gives Eq. (6): By considering Q only, the impedance is replaced by capacitor reactance (X C ) as per Eq. (7): where Eq. (8) gives X C : Finally, the size of the capacitor (C) in terms of Q max and V dclink derived by Eq. (9): By considering 25% as a safety margin, the C dclink is assumed to be 25% larger than in Eq. (9). Hence, Eq. (10) established: The size of C dclink is measured in Farad (F). The system frequency (f s ) regulated by Malaysian Distribution Code is 50 Hz [34]. Equations (9) and (10) show that a higher Q max consumed larger C dclink , and a higher V dclink will increase C dclink 's Q max support. Table 1 shows the important parameter value used in this PF-controlled solar PV system design.

LC filter modeling
The LC filter is also known as the low-pass second-order filter. It was installed at the AC side of the designed solar PV system and EV charging system. It can block high-frequency signals and allow only low-frequency signals to pass through it [33]. Figure 6 shows the basic configuration of an LC filter.
The switching frequency (f sw ) is 10 kHz. The cut-off frequency (f c ) of the LC filter is the allowable frequency signals upper limit, and it should be less than 1/10 th of f sw [33]. Meanwhile, one research [35] has reported that the f c value is recommended to be more than 1/14 th of the f sw for less attenuation effect. By considering less attenuation effect and within 0.3% distortion as in IEEE1547 guidelines [35], a mathematical equation for f c and f sw expressed by Eq. (11): As to prevent less than 3% voltage drop across the L filter , the size of L filter is calculated by Eq. (12) [33]: where I Lmax is the maximum RMS load current value, and U inv is the unfiltered output voltage of the DC/AC converter. Finally, the size of C filter is calculated as per Eq. (13) [33]:  Table 2 presents the important parameter's value used in the designed LC filter.

Master PF control
The proposed master PF controller is specialized for regulating the PF ind to attain an intended value by using a single preset reference. The control process is based on the trigonometric power theory calculation. Figure 7 illustrates the flowchart of the master PF control process.
The master PF reference (PF mref ) was preset to 0.95 lagging because of the same reason stated in industrial load's capacitor bank section. The industry's CT and VT sends the total instantaneous currents and voltages received by the industrial system and converted into active power (P ind ), reactive power (Q ind ) and PF ind forms. The proposed controller had used the PF mref , P ind and Q ind to get the amount of Q needed to achieve PF mref (Q need ). Then, the Q need was converted into PF form and fed to the PF-controlled solar PV system (PF needPV ) regarding control of the Q PV . In short, in this master control process, the value of Q need is the same as Q PV . Equations (14) and (15) show the mathematical equations to obtain the Q need and PF needPV .

Results and discussion
The Matrix Laboratory/Simulink software was used to simulate each of the designed equipment. One second in simulation presented as an hour. This section starts with the base case scenario where industrial load without C bank . The industrial load profile was adopted from another study [36]. Figure 8a, b show the simulation result of the power load profile and the instantaneous PF ind before PF-controlled C bank was installed, respectively.
Based on Fig. 8a, in a daytime (0700 -1700), the P load reached around 1 MW and 1.2 MW. The daily average of unimproved PF load was nearly 0.8 lagging. The designed PF-controlled 600 kVAr C bank then was installed to improve the PF ind within 0.95 lagging. Figure 9a shows the simulation result of the PF ind after installed with the designed PF-controlled C bank at 0.95 lagging PF refload . The simulation result of the total Q compensated by the PF-controlled C bank is shown in Fig. 9b.
Results in Figs. 8a and 9b prove that the PF ind had improved from around 0.8 lagging to nearly 0.95 lagging. In Fig. 9a, the PF ind had experienced slightly over and under correction due to fixed capacitors size [23]. The maximum Q compensated by the C bank was nearly 600 kVAr. Next, the industrial system was connected to the designed PF-controlled solar PV system. Figure 10a, b shows the simulation results of the instantaneous power output of the designed solar PV system at unity PF refPV . Figure 10c shows the simulation result of the instantaneous PF ind and PF refload value after the designed solar PV system was installed. Figure 10b shows that the designed solar PV system started to deliver P at the 5 th to 19 th second (0500 -1900). It reached P maxPV of approximately 400 kW at 11 th second (1100). There was no Q PV because the PF refPV was set at unity. Figure 10c proves the instantaneous PF ind drops drastically after the installation of the solar PV system at unity PF. The larger P PV leads to lower PF ind . Hence, this will be a critical case scenario in this case study. Figure 10c also shows that the PF ind was not affected by 0.95 lagging PF refload as the PF refload is only for PF load (14)  correction. The fluctuations occurred in between the 9 th and 13 th second are because of the C bank switching alternately on and off [23].
The total harmonic distortion current (THDi) of the solar PV system is measured at the point of common coupling. According to the Energy Commission of Malaysia [29], the THDi percentage for the solar PV system should be less than 5% to avoid low power quality. The mathematical formula to calculate THD i percentage is given as per Eq. 16 [37]: where I n is the root mean square of the output current and n represents the harmonic number. Figure 11 shows the highest THD i percentage of the designed solar PV system (4.33%) with its relevant spectrum in a graphical form by using a fast Fourier transform analysis feature in Matrix Laboratory/Simulink software. The designed EV fast-charging system with three charging ports subsequently had been connected to the industrial system. An EV charging event will slightly increase the PF ind . Figure 12 shows the amount of power transferred to the first, second and third EV. The negative power value indicates the EV in charge mode. There was no Q transfer as the PF refEV is at unity. Figure 12 illustrates that at the 1st-5th second, the next 6th to 10th second, and the following 11th-15th second, the first, second and third EV is in charge mode, respectively. In the 21st-23rd second, all EVs are simultaneously charged. Thus, this result validates the designed EV charging system can perform a single-charge at nearly 50 kW and can cater a simultaneous charge at almost 150 kW.
Finally, the proposed master PF controller was integrated into the designed industrial system. The PF mref was preset to 0.95 lagging, as shown in Fig. 13c. Figure 13a shows the simulation result of the PF needPV sent from the master PF controller to the solar PV system, which becomes its PF refPV . Figures 13a, b also validates the design of the solar PV system, as per the guidelines [29]. The amount of instantaneous Q PV is related to the instantaneous P PV and the instantaneous PF refPV . Figure 13c shows the simulation result of instantaneous PF ind after the proposed master PF controller was implemented. It shows that the master PF controller is capable of regulating the PF ind to attain 0.95 lagging even though under a critical case scenario.

Conclusion
The main contribution of this paper is the design of a master PF controller, which can regulate the PF ind to an intended value by following the PF mref . In this case study, the master Fig. 10 a PF refPV at unity. b The instantaneous power output of the designed solar PV system. c Instantaneous PF ind and 0.95 lagging PF refload PF controller coordinates with the PF-controlled solar PV system to perform the PF ind regulation. The proposed master PF controller design is simple, correspondingly costeffective. The mathematical formulas for calculating the sizing of C dclink and LC filter for a solar PV system and EV charging system were also included in this paper. The size of C dclink will determine its Q support capability. The LC filter was used instead of L and LCL filters, respectively, because of lesser power losses and cheaper. A bidirectional EV charger was designed in this case study for future research continuation, using the vehicle-to-grid concept. The results and discussion section conclude that the industrial load with a PF-controlled C bank , the PF-controlled solar PV system, the I-controlled EV charging system and the proposed master PF controller are able to operate effectively with the proposed control. The proposed master PF controller can ensure that the PF ind to be at 0.95 lagging throughout its operation even under a critical case scenario. Hence, these also verify the parameter values used for the C dclink and LC filter.