phased.TimeVaryingGain System object

Package: phased

Time varying gain control


The TimeVaryingGain object applies a time varying gain to input signals. Time varying gain (TVG) is sometimes called automatic gain control (AGC).

To apply the time varying gain to the signal:

  1. Define and set up your time varying gain controller. See Construction.

  2. Call step to apply the time varying gain according to the properties of phased.TimeVaryingGain. The behavior of step is specific to each object in the toolbox.


H = phased.TimeVaryingGain creates a time varying gain control System object™, H. The object applies a time varying gain to the input signal to compensate for the signal power loss due to the range.

H = phased.TimeVaryingGain(Name,Value) creates an object, H, with each specified property Name set to the specified Value. You can specify additional name-value pair arguments in any order as (Name1,Value1,...,NameN,ValueN).



Loss at each input sample range

Specify the loss (in decibels) due to the range for each sample in the input signal as a vector.

Default: 0


Loss at reference range

Specify the loss (in decibels) at a given reference range as a scalar.

Default: 0


cloneCreate time varying gain object with same property values
getNumInputsNumber of expected inputs to step method
getNumOutputsNumber of outputs from step method
isLockedLocked status for input attributes and nontunable properties
releaseAllow property value and input characteristics changes
stepApply time varying gains to input signal


Apply time varying gain to a signal to compensate for signal power loss due to range.

rngloss = 10:22; refloss = 16; % in dB
t = (1:length(rngloss))';
x = 1./db2mag(rngloss(:));
H = phased.TimeVaryingGain('RangeLoss',rngloss,...
y = step(H,x);

% Plot signals
tref = find(rngloss==refloss);
stem([t t],[abs(x) abs(y)]);
hold on;
xlabel('Time (s)'); ylabel('Magnitude (V)');
grid on;
legend('Before time varying gain',...
    'After time varying gain',...
    'Reference range');


[1] Edde, B. Radar: Principles, Technology, Applications. Englewood Cliffs, NJ: Prentice Hall, 1993.

[2] Skolnik, M. Introduction to Radar Systems, 3rd Ed. New York: McGraw-Hill, 2001.

Introduced in R2012a

Was this topic helpful?