# PWM Generator (3-Level)

Generate pulses for PWM-controlled three-level converter

## Library

Simscape / Electrical / Specialized Power Systems / Power Electronics / Power Electronics Control

## Description

The PWM Generator (3-Level) block generates pulses for carrier-based pulse-width modulation (PWM) converters using three-level topology. The block can control switching devices (FETs, GTOs, or IGBTs) of three different converter types: single-phase half-bridge (one arm), single-phase full-bridge (two arms), or three-phase bridge (three arms).

The reference signal (Uref input), also called the modulating signal, is naturally sampled and compared with two symmetrical level-shifted triangle carriers.

The following figure shows how the pulses are generated for a single-phase, half-bridge three-level converter.

The converter arm can have three states: +1, 0, or −1. When the reference signal is greater than the positive carrier, the state of the arm is +1; when the reference signal is smaller than the negative carrier, the state of the arm is −1.

Otherwise, the state is 0. Based on the current state of the arm, the appropriate pulses are generated.

StateQ1Q2Q3Q4
11100
00110
−10011

One reference signal is required to generate the four pulses of an arm. For a single-phase full-bridge converter, a second reference signal is required to generate the four pulses of the second arm. This signal is internally generated by phase-shifting the original reference signal by 180 degrees. For a three-phase bridge, three reference signals are required to generate the 12 pulses.

The reference signal also can be internally generated by the PWM generator. In this case, specify a modulation index, voltage output frequency, and phase.

## Parameters

Generator type

Specify the number of pulses to generate. The number of pulses generated by the block is proportional to the number of bridge arms to control.

Select Single-phase half-bridge (4 pulses) to fire the self-commutated devices of a single-phase half-bridge converter. Pulses (1, 2) fire the upper devices and pulses (3, 4) fire the lower devices.

Select Single-phase full-bridge (8 pulses) to fire the self-commutated devices of a single-phase full-bridge converter. Eight pulses are then generated. Pulses (1, 2) and (5, 6) fire the upper devices of the first and second arms. Pulses (3, 4) and (7, 8) fire the lower devices of the first and second arms.

Select Three-phase bridge (12 pulses) (default) to fire the self-commutated devices of a three-phase bridge converter. Pulses (1, 2), (5, 6), and (9, 10) fire the upper devices of the first, second, and third arms. Pulses (3, 4), (7, 8), and (11, 12) fire the lower devices of the three arms.

Mode of operation

When set to Unsynchronized (default), the frequency of the unsynchronized carrier signal is determined by the Carrier frequency parameter.

When set to Synchronized, the carrier signal is synchronized to an external reference signal (input wt), and the carrier frequency is determined by the Switching ratio parameter.

Carrier frequency (Hz)

Specify to determine the frequency, in hertz, of the two triangular carrier signals. Default is 27*60. The Carrier frequency parameter is visible only when the Mode of operation parameter is set to Unsynchronized.

Switching ratio (carrier frequency/output frequency)

Determines the frequency (Fc) of the two triangular carrier signals.

${F}_{c}=SwitchingRatio×OutputVoltageFrequency$

Default is 27. The Switching ratio parameter is visible only when the Mode of operation parameter is set to Synchronized.

Internal generation of modulating signal (s)

When this check box is selected, the block generates the reference signal. Default is cleared.

The parameter is visible only when the Mode of operation parameter is set to Unsynchronized.

Modulation index

Specify the modulation index to control the amplitude of the fundamental component of the output voltage of the converter. Default is 0.8. The modulation index must be greater than 0 and lower than or equal to 1. The parameter is visible only when the Internal generation of modulating signal (s) check box is selected.

Output voltage frequency (Hz)

Specify the output voltage frequency to control the fundamental component frequency of the output voltage of the converter. Default is 60. The parameter is visible only when the Internal generation of modulating signal (s) check box is selected.

Output voltage phase (degrees)

This parameter controls the phase of the fundamental component of the output voltage of the converter. Default is 0. The parameter is visible only when the Internal generation of modulating signal (s) check box is selected.

Sample time

Specify the sample time of the block, in seconds. Default is 0. Set to 0 to implement a continuous block.

## Inputs and Outputs

Uref

The vectorized reference signal used to generate the output pulses. The input is visible only when the Internal generation of modulating signal (s) is not selected. Connect this input to:

• A single-phase sinusoidal signal when the block controls a single-phase half- or full-bridge converter

• A three-phase sinusoidal signal when the PWM Generator block controls a three-phase bridge converter

For linear operation of this block, the magnitude of Uref must be between −1 and +1.

P

The output contains the 4, 8, or 12 pulses used to fire the self-commutated devices (MOSFETs, GTOs, or IGBTs) of a one-, two- or three-arm three-level converter.

## Characteristics

 Sample Time Specified in the Sample Time parameter Continuous if Sample Time = 0 Scalar Expansion No Dimensionalized No

## Examples

The power_PWMGenerator3Level model uses a simple circuit to show how the PWM Generator (3-Level) operates. Run the simulation and use the FFT Analysis tool of the Powergui block to see the harmonics and the THD value of the voltages produced by the three-phase three-level converter.

The model sample time is parameterized by the Ts variable set to a default value of 2e-6. Set Ts to 0 in the command window and change the Simulation type parameter of the Powergui block to Continuous to simulate the model in continuous mode.

## Version History

Introduced in R2013a