serdes.SaturatingAmplifier

Models a saturating amplifier

Description

The serdes.SaturatingAmplifier System object™ scales the input waveform according to a voltage in versus voltage out response. The voltage in versus voltage out response is specified either by the soft clipping response defined by Limit and Linear Gain properties or by the VinVout property. serdes.SaturatingAmplifier System object applies memoryless nonlinearity to incoming waveform.

To limit the voltage output to a specific value:

  1. Create the serdes.SaturatingAmplifier object and set its properties.

  2. Call the object with arguments, as if it were a function.

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

Creation

Description

SatAmp = serdes.SaturatingAmplifier returns an amplifier object that modifies the input signal so that the output voltage is clipped to 1.2 V.

SatAmp = serdes.SaturatingAmplifier(Name,Value) returns an amplifier object with each specified property set to specific value. Unspecified properties have default values.

Example: SatAmp = serdes.SaturatingAmplifier('Limit',5)

Properties

expand all

Unless otherwise indicated, properties are nontunable, which means you cannot change their values after calling the object. Objects lock when you call them, and the release function unlocks them.

If a property is tunable, you can change its value at any time.

For more information on changing property values, see System Design in MATLAB Using System Objects (MATLAB).

Amplifier operating mode, specified as 0 or 1. Mode determines whether the amplifier is bypassed or not.

Mode ValueSaturating Amplifier ModeSaturating Amplifier Operation
0Offserdes.SaturatingAmplifier is bypassed and the input waveform remains unchanged.
1Onserdes.SaturatingAmplifier scales the input waveform according to a voltage in versus voltage out response.

Data Types: double

Input specification for limiting amplifier output:

  • 'Limit and Linear Gain' — Creates a soft clipping voltage in versus voltage out response with the values specified in the Limit and Linear Gain properties.

  • 'VinVout' — Generates output voltages corresponding to input voltage specified in the VinVout property. If any input voltage point falls outside the specified values, the output for that particular input voltage is linearly interpolated.

Data Types: char

Clipping voltage for the limiting amplifier, specified as a real positive scalar in V.

Data Types: double

Amplifier gain in the linear region, specified as a unitless real positive scalar.

Data Types: double

Input and corresponding output voltage response table, specified as an N-by-2 matrix in V.

Data Types: double

Usage

Description

y = SatAmp(x)

Input Arguments

expand all

Input baseband signal.

Output Arguments

expand all

Clipped output voltage, as specified by the serdes.SaturatingAmplifier object.

Object Functions

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)

expand all

stepRun System object algorithm
releaseRelease resources and allow changes to System object property values and input characteristics
resetReset internal states of System object

Examples

expand all

This example shows how to clip an incoming sine wave using the serdes.SaturatingAmplifier system object™.

Define an input sine wave with a frequency of 250 Hz.

Fs = 10000;
L = 100;
t = (0:L-1)'/Fs;
x = sin(2*pi*250*t);

Construct the SaturatingAmplifier system object with a linear gain of 2, and gain limit of 0.8 V.

linearGain = 2;
limit = 0.8;
SaturatingAmplifier = serdes.SaturatingAmplifier('Mode',1,...
          'Limit',limit,'LinearGain',linearGain);
y = SaturatingAmplifier(x);

Plot the input and modified waveforms.

figure, plot(t,x,t,y)
legend('Input','Output')
title('Clipping Waveform Using Saturating Amplifier');
xlabel('Time (s)');
ylabel('Amplitude (V)');

This example shows how to define a serdes.SaturatingAmplifier system object™ using the VinVout property.

Define an input sine wave with a frequency of 250 Hz.

t = (0:99)/10000;
x = sin(2*pi*250*t);

Define the Voltage In/Voltage Out matrix.

M = [-0.6194   -0.8000
     -0.4129   -0.6954
     -0.2065   -0.3966
      0         0
      0.2065    0.3966
      0.4129    0.6954
      0.6194    0.8000];

Define the saturating amplifier with the VinVout table.

SatAmp = serdes.SaturatingAmplifier('Mode',1,'Specification','VinVout','VinVout',M);

Modify the input waveform with the saturating amplifier.

y = SatAmp(x);

Plot the input and modified output waveforms.

figure; 
plot (t,x,t,y)
legend ('SaturatingAmplifier input','SaturatingAmplifier output');
grid on;
xlabel('Time (Seconds)');
ylabel('Amplitude (Volts)');

Extended Capabilities

Introduced in R2019a