Main Content

commsrc.combinedjitter

Construct combined jitter generator object

Description

example

combJitt = commsrc.combinedjitter constructs a default combined jitter generator object, combJitt, with all jitter components disabled.

Use the object to generate jitter samples that include any combination of random, periodic, and Dirac components.

example

combJitt = commsrc.combinedjitter(Name,Value) creates a combined jitter generator object with the specified property Name set to the specified Value. You can specify additional name-value pair arguments in any order as (Name1,Value1,...,NameN,ValueN).

Properties

A combined jitter generator object includes these properties. You can edit all properties, except those explicitly noted.

PropertyDescription
Type

Type of object, Combined Jitter Generator. This property is not writable.

SamplingFrequency

Sampling frequency of the input signal in hertz. Default value 1e4.

RandomJitter

Variable to enable the random jitter generator. Specify as either 'off' (default) or 'on'.

RandomStd

Standard deviation of the random jitter generator in seconds. Applies when RandomJitter is 'on'. Default value 1e-4.

PeriodicJitter

Variable to enable the periodic jitter generator. Specify as either 'off' (default) or 'on'.

PeriodicNumber

Number of sinusoidal components. The PeriodicNumber must be a finite positive scalar integer. Applies when PeriodicJitter is 'on'. Default value 1.

PeriodicAmplitude

Amplitude of each sinusoidal component of the periodic jitter in seconds. Applies when PeriodicJitter is 'on'. Default value 5e-4.

PeriodicFrequencyHz

Frequency of each sinusoidal component of the periodic jitter measured in Hz. Applies when PeriodicJitter is 'on'. Default value is 200.

PeriodicPhase

Phase of each sinusoidal component of the periodic jitter in radians. Applies when PeriodicJitter is 'on'. Default value 0.

DiracJitter

Variable to enable the Dirac jitter generator. Specify as either 'off' (default) or 'on'.

DiracNumber

Number of Dirac components. The DiracNumber must be a finite positive scalar integer. Applies when DiracJitter is 'on'. Default value 2.

DiracDelta

Time delay of each Dirac component in seconds. Applies when DiracJitter is 'on'. Default value [-5.e-4 5.e-4].

DiracProbability

Probability of each Dirac component represented as a vector of length DiracNumber. The sum of the probabilities must equal one. Applies when DiracJitter is 'on'. Default value [0.5 0.5].

Object Functions

A combined jitter generator object has three object functions, as described in this section.

generate

This object function generates jitter samples based on the jitter generator object. It has one input argument, which is the number of samples in a frame. Its output is a single-column vector of length N. You can call this object function using this syntax:

x = generate(combJitt,N)
where combJitt is the generator object, N is the number of output samples, and x is a real single-column vector.

reset

This object function resets the internal states of the combined jitter generator. You can call this object function using this syntax:

reset(combJitt)
where combJitt is the generator object.

disp

Display the properties of the combined generator object, combJitt. You can call this object function using this syntax:

disp(combJitt)

where combJitt is the generator object.

Examples

collapse all

Generate 500 jitter samples composed of random and periodic components.

Create a commsrc.combinedjitter object configured to apply a combination of random and periodic jitter components. Use name-value pairs to enable RandomJitter and PeriodicJitter, and to assign jitter settings. Set the standard deviation of the random jitter to 2e-4 seconds, the periodic jitter amplitude to 5e-4 seconds, and the periodic jitter frequency to 2 Hz.

numSamples = 500;
combJitt = commsrc.combinedjitter(...
    'RandomJitter','on', ...
    'RandomStd',2e-4, ...
    'PeriodicJitter','on', ...
    'PeriodicAmplitude',5e-4, ...
    'PeriodicFrequencyHz',200)
combJitt = 
                   Type: 'Combined Jitter Generator'
      SamplingFrequency: 10000
           RandomJitter: 'on'
              RandomStd: 2.0000e-04
         PeriodicJitter: 'on'
         PeriodicNumber: 1
      PeriodicAmplitude: 5.0000e-04
    PeriodicFrequencyHz: 200
          PeriodicPhase: 0
            DiracJitter: 'off'

Use the generate method to create the combined jitter samples.

y = generate(combJitt,numSamples);
x = [0:numSamples-1];

Plot the jitter samples. You can see the Gaussian and periodic nature of the combined jitter.

plot(x/combJitt.SamplingFrequency,y)
xlabel('Time (seconds)')
ylabel('Jitter (seconds)')

Create a commsrc.combinedjitter object. Display the default object property values.

combJitt = commsrc.combinedjitter;
disp(combJitt)
                 Type: 'Combined Jitter Generator'
    SamplingFrequency: 10000
         RandomJitter: 'off'
       PeriodicJitter: 'off'
          DiracJitter: 'off'

Create a commsrc.combinedjitter object with random, periodic, and Dirac jitters enabled. Display the object property values.

combJitt = commsrc.combinedjitter('RandomJitter','on', ...
    'PeriodicJitter','on','DiracJitter','on');
disp(combJitt)
                   Type: 'Combined Jitter Generator'
      SamplingFrequency: 10000
           RandomJitter: 'on'
              RandomStd: 1.0000e-04
         PeriodicJitter: 'on'
         PeriodicNumber: 1
      PeriodicAmplitude: 5.0000e-04
    PeriodicFrequencyHz: 200
          PeriodicPhase: 0
            DiracJitter: 'on'
            DiracNumber: 2
             DiracDelta: [-5.0000e-04 5.0000e-04]
       DiracProbability: [0.5000 0.5000]

Generate a binary non-return-to-zero (NRZ) signal utilizing the pattern generator object. View the NRZ signal with and without jitter applied to the signal.

Initialize system parameters.

Fs = 10000; % Sample rate
Rs = 50; % Symbol rate
sps = Fs/Rs; % Number of samples per symbol
Trise = 1/(5*Rs); % Rise time of the NRZ signal
Tfall = 1/(5*Rs); % Fall time of the NRZ signal
frameLen = 100; % Number of symbols in a frame
spt = 200; % Number of samples per trace on eye diagram

Create a pattern generator object with no jitter component assigned.

src = commsrc.pattern('SamplingFrequency',Fs, ...
'SamplesPerSymbol',sps,'RiseTime',Trise,'FallTime',Tfall)
src = 
                 Type: 'Pattern Generator'
    SamplingFrequency: 10000
     SamplesPerSymbol: 200
           SymbolRate: 50
            PulseType: 'NRZ'
         OutputLevels: [-1 1]
             RiseTime: 0.0040
             FallTime: 0.0040
          DataPattern: 'PRBS7'
               Jitter: [1x1 commsrc.combinedjitter]

src.Jitter
ans = 
                 Type: 'Combined Jitter Generator'
    SamplingFrequency: 10000
         RandomJitter: 'off'
       PeriodicJitter: 'off'
          DiracJitter: 'off'

Generate an NRZ signal and view the eye diagram of the signal.

message = generate(src,frameLen);
eyediagram(message,spt)

Add inter-symbol-interference (ISI) to an NRZ signal. ISI is modeled by two equal amplitude Dirac functions. Create a combined jitter object with Dirac jitter and assign it to the pattern generator object.

jitterSrc = commsrc.combinedjitter('DiracJitter','on', ...
    'DiracDelta',0.05/Rs*[-1 1]);
src.Jitter = jitterSrc
src = 
                 Type: 'Pattern Generator'
    SamplingFrequency: 10000
     SamplesPerSymbol: 200
           SymbolRate: 50
            PulseType: 'NRZ'
         OutputLevels: [-1 1]
             RiseTime: 0.0040
             FallTime: 0.0040
          DataPattern: 'PRBS7'
               Jitter: [1x1 commsrc.combinedjitter]

Generate an NRZ signal that has jitter added to it and view the eye diagram of the signal.

reset(src);
message = generate(src,frameLen);
eyediagram(message,spt)

Version History

Introduced in R2015a