# Cover Story- Power Factor Correction Goes Digital

**Power Factor Correction Goes Digital**

*Good PFC techniques improve power quality.*

**by Vinaya Skanda, Senior Applications Engineer, Microchip Technology**

Most power-conversion applications require a DC source, which uses a rectifier that draws non-sinusoidal line currents. As a result, line-current harmonics have become a significant problem and they lead to overheating of transformers and inductive equipment, degradation of system voltages and increased stress on components. In addition, stringent limits imposed on harmonic currents by international groups make the need to improve power quality even more important. Power-factor correction (PFC) can help solve these problems.

Total apparent power has two components, active power and reactive power. Active power--measured in kilowatts (kW)--represents power consumed to create heat, light and motion. Reactive power on the other hand, doesn’t do any useful work, but it maintains electromagnetic fields associated with inductive elements and loads. Reactive power is expressed as volt-amperes reactive (VAR) and it registers on a meter at the utility company in units of kilovolt-ampere reactive (kVAR). The total required power capacity, known as apparent power, is expressed as kilovolt amperes (kVA).

Using the above information, engineers define power factor as the amount of working power used by a system, divided by the total apparent power. An ideal system has a power factor of one. In actual systems, however, the power factor becomes less than one due to:

1. Phase shift of current with respect to voltage, which results in displacement, called a displacement factor.

2. Harmonics in the current that result in waveform distortion, called distortion factor.

Now, you can define power factor as the product of the distortion factor and displacement factor.

**Cause and Effect of Current Harmonics**

On an oscilloscope, current harmonics look like sinusoidal waves at integral multiples of the fundamental frequency and they appear as continuous, steady-state disturbances on an electric network. Don't confuse harmonics with transient distortions or power surges.

Equipment that causes current harmonics includes uninterruptible power supplies, welding machines, arc furnaces, generators, motors and transformers. The problems they cause include nuisance tripping of circuit breakers, damage to sensitive electronics, excessive overheating of equipment, and interference with neighboring electronic equipment.

**Make Converters Look Resistive**

PFC aims to make a power converter look like a linear resistance to the input voltage. Thus, if the input voltage has a sine-wave shape, the input current also should have a sine-wave shape. This arrangement lets the power-distribution system operate more efficiently, which reduces energy consumption.

Engineers can use inductors, capacitors, diodes and switches to design converters that appear as resistive loads. These circuits localize and contain within the PFC converter any reactive energy that would otherwise return to the power grid.

But although large inductors and capacitors can store energy over one power cycle, they add cost and cannot correct for harmonics. Microcontrollers and smaller power-electronic devices let engineers design smaller, more efficient PFC circuits. Under digital control, this type of PFC circuit will only need to store energy for periods of tens of microseconds (Figure 1 --->). This digital approach also decreases harmonics.

After much study, my colleagues and I concluded the boost-type power converter (<--- Figure 2) best suits the implementation of a PFC circuit because of the absence of crossover distortions and the viability of operating the converter in continuous-conduction mode. This mode is more suitable for higher power levels, but it requires a complex control strategy. The continuous-conduction operating mode strives to maintain a non-zero current through the boost inductor, which minimizes peak current levels. This mode will in turn reduce losses when compared to the discontinuous-conduction and critical-conduction operating modes of other power-converter topologies. (A discussion of those converter types goes beyond the scope of this article.)

**Implement Digital PFC**

The block diagram in Figure 3 illustrates how to use a digital signal controller (DSC) as the heart of a PFC design. This method, called average current-mode control, forces the average current flowing through the inductor into a sine-wave-like shape and regulates the output voltage.

Software can create the needed sine values or the DSC can rely on digitized values from the rectified-voltage waveform. The circuit shown in Figure 3 (--->) uses the rectified voltage to obtain the necessary sine-wave shape for the inductor current. The software for the DSC includes two control loops and a compensation scheme.

An "outer" voltage-control software loop measures the reference DC voltage (VDCref) and the sensed output voltage (Vdc), and produces a value that determines the reference current (IACref) for an inner current software loop (described below). A voltage-error compensator (also described below) produces a control value (VCOMP) such that the DC output voltage remains constant at the reference value, regardless of variations in the load current or changes in the supply voltage. For the voltage-control loop we chose a 10-Hz bandwidth, well below the 100- or 120-Hz input frequency from the full-wave rectifier. The output voltage remains constant and still maintains the needed shape of the inductor current, without distorting it. The software also provides a proportional-integral (PI) controller for voltage-error compensation.

The "inner" current-control software loop produces a duty-cycle signal (PWM) that drives the gate of the PFC circuit's MOSFET. This control loop receives the inductor-current value (Iac) from the PFC circuit and the reference-current value from the outer voltage-control loop. The current-error compensator produces a control output so that the inductor current follows the reference current signal. The current-control loop should run at a higher rate than the voltage-control loop; often between five and 10 kHz for a switching frequency of about 100 kHz. A PI controller compensates for any current error.

If the input voltage decreases, the product of the VAC and VPI values, which determines current reference (IACref), decreases in proportion. However, to maintain a constant output power at a reduced input voltage, the current reference must increase. Thus, an input-voltage feed-forward value (VCOMP) maintains a constant power output--as determined by the load--regardless of sudden variations in the input-line voltage. This software compensator calculates the average value of the input-line voltage (Vavg) and uses the result as a divisor for the current reference. The resulting value (IACref) goes to the inner current-control software loop.

The scope traces shown in Figure 4 (<---) illustrate the results of implementing a PFC algorithm in a Microchip dsPIC, a digital signal controller IC. The shape of the input current (yellow) follows that of the input voltage (blue), which results in a near-unity power factor.**For Further reading...**

*Israelsohn, Joshua, "Honest Energy," EDN, April 3, 2008. pg. 28.*www.ednmag.com.

*Skanda, Vinaya, "Power Factor Correction in Power Conversion Applications Using the dsPIC DSC," AN1106. Microchip Technology.*

*Skanda, Vinaya, "Integrated Power Factor Correction (PFC) and Sensorless Field Oriented Control (FOC) System,” AN1208. Microchip Technology.*

**About the author**

Vinaya Skanda works as a senior applications engineer in the Digital Signal Controller Division of Microchip Technology. In his current role, he develops and implements application designs in the areas of digital power conversion, motor drives and communications. He has a Bachelor’s Degree in Electrical and Electronics Engineering from Bangalore Institute of Technology (Bangalore University, Karnataka, India. His personal interests include playing chess, traveling and nature photography.