# Constellation Diagram

Display constellation diagram for input signals

• Library:
• Communications Toolbox / Comm Sinks

Communications Toolbox HDL Support / Comm Sinks

## Description

The Constellation Diagram block displays real and complex-valued floating and fixed-point signals in the I/Q plane. Use this block to perform qualitative and quantitative analysis on modulated single-carrier signals.

In the constellation diagram window you can:

• Input and plot multiple signals on a single constellation diagram. You can define one reference constellation for each input signal. For more information, see Reference constellation.

• Choose which channels are displayed by selecting signals in the legend. Use the Show legend parameter to display the legend.

• Display the EVM / MER Measurements panel, which displays calculated error vector magnitude (EVM) and modulation error ratio (MER) measurements. When a multichannel signal is input, use Trace Selection to choose the signal being measured.

## Ports

### Input

expand all

Connect to the signal or signals you want to visualize as an Nsym-by-1 column vector or Nsym-by-Nsig matrix. Nsym is the number of symbols and Nsig is the number of input signals.

You can specify up to 20 input signals. Specifically, the maximum number of channels through all the ports is 20. For example, if you create a two-channel signal for every input port, then you can define up 10 number of input ports.

Example: `[-1 + 1i; -1 - 1i; 1 + 1i; 1 - 1i]` specifies a 4-symbol input signal.

## Parameters

expand all

### File

From the Constellation Diagram window, select File to view the options available.

Select to open constellation diagram window at start of simulation. Deselect to prevent constellation diagram window from opening at start of simulation.

Specify the number of input ports on the Scope block, specified as an integer in the range [1, 20].

When multichannel input signals are specified, the maximum number of input ports is limited by the total number of input signals defined. The total number of input signal cannot exceed 20.

### Tools > Axes Scaling Properties

From the Constellation Diagram window, under Tools, select Axes Scaling Properties to open the Axes Scaling Properties: Constellation Diagram dialog box. In this dialog box, you can customize the graphical properties of the axes.

Properties

Axes scaling options, specified as:

• `Manual` — Applies the x and y axes limits specified in the Visuals – Constellation Properties: Constellation Diagram dialog box.

• `Auto` — Scales the axes limits as needed during and after simulation.

• `After N Updates` — Scales the axes limits after the specified Number of updates.

Tunable: Yes

Number of updates after which to scale the axes, specified as a positive integer.

Tunable: Yes

#### Dependencies

This parameter appears when Axes scaling is set to `After N Updates`.

Select to scale axes at end of the simulation to the data range percentage limits specified by X-axis Data range (%) and Y-axis Data range (%).

Percentage of x-axis used to display data.

Example: `100` scales the x-axis range to the maximum value of the in-phase amplitude component of the input signal.

Tunable: Yes

Align data along x-axis, specified as `Center`, `Left`, or `Right`.

Example: `Right` aligns the maximum value of the in-phase amplitude component of the input signal toward the upper x-axis limit.

Tunable: Yes

Percentage of y-axis used to display data.

Example: `30` scales the y-axis range so that the maximum value of the quadrature amplitude component of the signal occupies 30% of the y-axis range.

Tunable: Yes

Align data along y-axis, specified as `Center`, `Top`, or `Bottom`.

Example: `Bottom` aligns the maximum value of the quadrature amplitude component of the signal toward the lower y-axis limit.

Tunable: Yes

### Tools > Measurements

From the Constellation Diagram window, under Tools, select Measurements for options to display the Trace Selection and Signal Quality panes. By default these panes are docked in the Constellation Diagram window when displayed.

The Signal Quality pane contains the Settings and EVM / MER subpanes. Both subpanes can be independently expanded or collapsed.

For more information about the signal quality measurements, see EVM / MER Measurements.

Select the signal trace used to compute measurements from the list of available signals. This parameter lists the signals input to the block.

Tunable: Yes

#### Dependencies

To set this parameter, the Trace Selection pane must be visible. The Trace Selection pane automatically appears when you plot multiple signals on the Constellation Diagram window. To hide or display the Trace Selection pane from the Constellation Diagram window, under Tools, select Measurements > Trace Selection to toggle the visibility of the traceback selection measurement.

EVM / MER Settings Pane

Duration of the EVM or MER measurement in symbols, specified as `Current Display`, ```All displays```, or a positive integer. To specify a positive integer, select and then replace `<user-defined>` with your desired value. The value must be positive and less than or equal to Symbols to display. The measurement is computed after the number of input data samples exceeds the measurement interval.

Tunable: Yes

Normalization method used for EVM calculation, specified as `Average constellation power` or `Peak constellation power`. The `comm.EVM` System object™ computes the EVM.

Tunable: Yes

Reference constellation, specified as `BPSK`, `QPSK`, `8-PSK`, `16-QAM`, `64-QAM`, `256-QAM`, or a <user-defined> vector. To specify a custom value, select `<user-defined>`, then in the Custom value property replace the entry with your desired value.

Each input port can have its own reference constellation. For a multichannel input signal, a single reference constellation is applied for all signals in that input port.

To obtain the EVM/MER measurements, you must set Reference constellation to a valid value corresponding to the modulation of the input signal.

Tunable: Yes

Input the reference constellation, specified as a vector.

#### Dependencies

To enable this parameter, set Reference constellation to <user-defined>.

Data Types: `double`
Complex Number Support: Yes

Average power of the reference constellation in watts, specified as a positive scalar and referenced to a one-ohm load.

Tunable: Yes

Phase offset of the reference constellation in radians, specified as a scalar.

Tunable: Yes

### View > Configuration Properties

From the Constellation Diagram window, select View > Configuration Properties to open the Visuals – Constellation Properties: Constellation Diagram dialog box. In this dialog box, you can customize the graphical properties of the plotted signals.

Main

Specify the number of input ports on the Scope block, specified as an integer in the range [1, 20].

Number of samples used to represent each symbol, specified as a positive integer. When Samples per symbol is greater than 1, the signal is downsampled before it is plotted.

Tunable: Yes

Number of samples to skip before plotting points, specified as a nonnegative integer less than Samples per symbol. This parameter specifies the number of samples to skip when downsampling the input signal.

Tunable: Yes

Maximum number of symbols to display, specified as ```Input frame length``` or a positive integer. To specify a positive integer, select and then replace `<user-defined>` with your desired value.

Use Symbols to display to limit the maximum number of symbols displayed when long signals are input. Symbols plotted are the most recent symbols received.

Tunable: Yes

Display

Select to display plot grid lines.

Tunable: Yes

Select to display plot legend. The names listed in the legend are the signal names from the model.

From the legend, you can control which signals are plotted. This control is equivalent to changing the visibility in the View > Style dialog box. In the scope legend, click a signal name to hide the signal in the scope. To show the signal, click the signal name again. To show only one signal and hide all other signals, right-click the signal name. To show all signals, press Esc.

Tunable: Yes

Select to display the trajectory between constellation points for the plotted signals.

Tunable: Yes

When you select Color fading, the points in the display fade as the interval of time after they are first plotted increases. Color fading is for animation that resembles an oscilloscope.

Tunable: Yes

Minimum x-axis value, specified as a scalar.

Tunable: Yes

Maximum x-axis value, specified as a scalar.

Tunable: Yes

Minimum y-axis value, specified as a scalar.

Tunable: Yes

Maximum y-axis value, specified as a scalar.

Tunable: Yes

Title on plot, specified as a character vector or string.

Tunable: Yes

x-axis label, specified as a character vector or string.

Tunable: Yes

y-axis label, specified as a character vector or string.

Tunable: Yes

Reference constellation

Select to display the reference constellation.

Tunable: Yes

Select the input port number for which you want to view/change the reference constellation and the associated attributes.

#### Dependencies

To enable this parameter, set the Number of input ports parameter to a value greater than 1.

Reference constellation, specified as `BPSK`, `QPSK`, `8-PSK`, `16-QAM`, `64-QAM`, `256-QAM`, or a <user-defined> vector. To specify the value, select and then replace `<user-defined>` with your desired value. When defined by the user, the reference constellation values can be specified as a vector.

Each input port can have its own reference constellation. For a multichannel input signal, a single reference constellation is applied for all signals in that input port.

To obtain the EVM/MER measurements, you must set Reference constellation to a valid value corresponding to the modulation of the input signal.

Tunable: Yes

Data Types: `double`
Complex Number Support: Yes

Average power of the reference constellation in watts, specified as a positive scalar and referenced to a one-ohm load.

Tunable: Yes

Phase offset of the reference constellation in radians, specified as a scalar.

Tunable: Yes

### View > Style

From the Constellation Diagram window, select View > Style to open the Constellation Diagram - Style dialog box. In this dialog box, you can customize the graphical properties of the components in the Constellation Diagram window.

Select the background color within the Constellation Diagram window and outside the scope axes.

Select colors of plot and measurement panes. The first color option specifies the background color of the plot figure and the measurement panes. The second option specifies the color of the plot figure axes (ticks, labels, and grid lines) and the text. For more a description of the measurement panes, see in the Tools > Measurements.

Tunable: Yes

Select a channel to view or change its graphical properties.

Bring the active channel, as indicated by Properties for channel, to the front.

Clear to hide the active channel and its associated reference constellation. Use Properties for channel to select the active channel. The setting is synchronized with actions in the interactive legend, see Show legend.

Set graphical properties of the symbols for the active channel. Adjust style, size, line width, and color of the marker. Use Properties for channel to select the active channel.

#### Dependencies

To set marker shape to `none`, Show signal trajectory must be selected.

Set graphical properties for the signal trajectory of the active channel. Adjust style, width, and color of the line. Use Properties for channel to select the active channel.

#### Dependencies

To adjust signal trajectory properties, Show signal trajectory must be selected. When Show signal trajectory is selected, the Signal trajectory line style cannot be set to ```no line```.

Reference Constellation

View or change the graphical properties for the symbol of the reference constellation for each port individually.

If none of the input are multichannel signals, then the graphical properties of the reference constellation can be adjusted by selecting the channel from the Properties for channel parameter.

#### Dependencies

To enable this parameter, set the Number of input ports parameter to a value greater than 1 and specify at least one multichannel input signal.

Select the graphical properties for the symbols of the reference constellation. Adjust the style, size, line width, and color of the marker.

#### Dependencies

To adjust reference constellation graphical properties, Show reference constellation must be selected.

## Block Characteristics

 Data Types `Boolean` | `double` | `enumerated` | `fixed point` | `integer` | `single` Direct Feedthrough `no` Multidimensional Signals `no` Variable-Size Signals `yes` Zero-Crossing Detection `no`

expand all

## Extended Capabilities

### Topics

Introduced in R2013b