Note: This page has been translated by MathWorks. Click here to see

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

Compensate for carrier frequency offset

The `comm.CarrierSynchronizer`

System object™ compensates for carrier frequency and phase offsets in
signals that use single-carrier modulation schemes. The carrier synchronizer algorithm is
compatible with BPSK, QPSK, OQPSK, 8-PSK, PAM, and rectangular QAM modulation schemes.

This System object does not resolve phase ambiguities created by the synchronization algorithm. The Examples demonstrate resolution of phase ambiguity.

To compensate for frequency and phase offsets in signals that use single-carrier modulation schemes:

Create the

`comm.CarrierSynchronizer`

object and set its properties.Call the object, as if it were a function.

To learn more about how System objects work, see What Are System Objects? (MATLAB).

`carrSynch = comm.CarrierSynchronizer`

`carrSynch = comm.CarrierSynchronizer(Name,Value)`

creates
a System
object that compensates for carrier frequency offset and phase offset in signals
that use single-carrier modulation schemes.`carrSynch`

= comm.CarrierSynchronizer

sets properties using one or more name-value pairs. Enclose each property name in
quotes.`carrSynch`

= comm.CarrierSynchronizer(`Name`

,`Value`

)

**For versions earlier than R2016b, use the step
function to run the System object algorithm. The arguments to
step are the object you created, followed by
the arguments shown in this section.**

**For example, y = step(obj,x) and y = obj(x) perform equivalent operations.**

`[outSig,phErr] = carrSynch(inSig)`

To use an object function, specify the
System
object as the first input argument. For
example, to release system resources of a System
object named `obj`

, use
this syntax:

release(obj)

The `comm.CarrierSynchronizer`

System object is a
closed-loop compensator that uses the PLL-based algorithm described in [1]. The output of the
synchronizer, *y*_{n}, is a frequency-shifted version of
the complex input signal, *x*_{n}, for the nth sample.
The synchronizer output is

$${y}_{\text{n}}={x}_{\text{n}}{e}^{i{\lambda}_{\text{n}}}\text{\hspace{0.17em}},$$

where *λ*_{n} is the output of the
direct digital synthesizer (DDS). The DDS is the discrete-time version of a voltage-controlled
oscillator and is a core component of discrete-time phase locked loops. In the context of this
System object, the DDS works as an integration filter.

To correct for the frequency offset, first the algorithm determines the phase error,
*e*_{n}. The value of the phase error depends on the
modulation scheme.

Modulation | Phase Error |
---|---|

QAM or QPSK | For a detailed description of this equation, see [1]. |

BPSK or PAM | For a detailed description of this equation, see [1]. |

8-PSK | $${e}_{\text{n}}=\{\begin{array}{c}\mathrm{sgn}\left(\mathrm{Re}\left\{{x}_{\text{n}}\right\}\right)\times \mathrm{Im}\left\{{x}_{\text{n}}\right\}-\left(\sqrt{2}-1\right)\mathrm{sgn}\left(\mathrm{Im}\left\{{x}_{\text{n}}\right\}\right)\times \mathrm{Re}\left\{{x}_{\text{n}}\right\}\text{,}\text{\hspace{1em}}\text{for}\text{\hspace{1em}}\left|\mathrm{Re}\left\{{x}_{\text{n}}\right\}\right|\ge \left|\mathrm{Im}\left\{{x}_{\text{n}}\right\}\right|\\ \left(\sqrt{2}-1\right)\mathrm{sgn}\left(\mathrm{Re}\left\{{x}_{\text{n}}\right\}\right)\times \mathrm{Im}\left\{{x}_{\text{n}}\right\}-\mathrm{sgn}\left(\mathrm{Im}\left\{{x}_{\text{n}}\right\}\right)\times \mathrm{Re}\left\{{x}_{\text{n}}\right\}\text{,}\text{\hspace{1em}}\text{for}\text{\hspace{1em}}\left|\mathrm{Re}\left\{{x}_{\text{n}}\right\}\right|<\left|\mathrm{Im}\left\{{x}_{\text{n}}\right\}\right|\end{array}$$ For a detailed description of this equation, see [2]. |

OQPSK |

To ensure system stability, the phase error passes through a biquadratic loop filter governed by

$${\psi}_{\text{n}}={g}_{\text{I}}{e}_{\text{n}}+{\psi}_{\text{n}-1}\text{\hspace{0.17em}},$$

where *ψ*_{n} is the output of the loop filter at
sample n, and *g*_{I} is the integrator gain. The
integrator gain is determined from the equation

$${g}_{\text{I}}=\frac{4\left({\theta}^{2}/d\right)}{{K}_{\text{p}}{K}_{\text{0}}}\text{\hspace{1em}},$$

where *θ*, *d*,
*K*_{0}, and
*K*_{p} are determined from the System object
properties. Specifically,

$$\theta \text{\hspace{0.17em}}\text{=}\text{\hspace{0.17em}}\frac{{B}_{\text{n}}}{\left(\zeta +\frac{1}{4\zeta}\right)}\text{\hspace{0.17em}}\text{and}\text{\hspace{0.17em}}d\text{\hspace{0.17em}}=\text{\hspace{0.17em}}1+2\zeta \theta +{\theta}^{2},$$

where *B*_{n} is the normalized loop
bandwidth, and *ζ* is the damping factor. The phase recovery gain,
*K*_{0}, is equal to the number of samples per symbol.
The modulation type determines the phase error detector gain,
*K*_{p}.

Modulation | K_{p} |
---|---|

BPSK, PAM, QAM, QPSK, or OQPSK | 2 |

8-PSK | 1 |

The output of the loop filter is then passed to the DDS. The DDS is another biquadratic loop filter whose expression is based on the forward Euler integration rule

$${\lambda}_{\text{n}}=\left({g}_{\text{P}}{e}_{\text{n-1}}+{\psi}_{\text{n-1}}\right)+{\lambda}_{\text{n-1}}\text{\hspace{0.17em}},$$

where *g*_{P} is the proportional gain that is
expressed as

$${g}_{\text{P}}=\frac{4\zeta \left(\theta /d\right)}{{K}_{\text{p}}{K}_{\text{0}}}\text{\hspace{0.17em}}.$$

The `info`

object function of this System object returns estimates of the
normalized pull-in range, the maximum frequency lock delay, and the maximum phase lock delay.
The normalized pull-in range, (Δ*f*)_{pull-in}, is expressed in radians and estimated as

$${\left(\Delta f\right)}_{\text{pull-in}}\approx \mathrm{min}\left(1,2\pi \sqrt{2}\zeta {B}_{\text{n}}\right)\text{\hspace{0.17em}}.$$

The expression for (Δ*f* )_{pull-in} becomes less accurate as $$2\pi \sqrt{2}\zeta {B}_{\text{n}}$$ approaches 1.

The maximum frequency lock delay, *T*_{FL}, and phase
lock delay, *T*_{PL}, are expressed in samples and
estimated as

$${T}_{\text{FL}}\approx 4\frac{{\left(\Delta f\right)}_{\text{pull-in}}^{2}}{{B}_{\text{n}}^{3}}\text{\hspace{0.17em}}\text{and}\text{\hspace{0.17em}}{T}_{\text{PL}}\approx \frac{1.3}{{B}_{\text{n}}}\text{\hspace{0.17em}}.$$

[1] Rice, M. *Digital Communications: A Discrete-Time
Approach*. Upper Saddle River, NJ: Prentice Hall, 2009, pp.
359–393.

[2] Zhijie, H., Y. Zhiqiang, Z. Ming, and W. Kuang. “8PSK
Demodulation for New Generation DVB-S2.” *2004 International Conference on
Communications, Circuits and Systems.* Vol. 2, 2004, pp. 1447–1450.