Range-Lag Ambiguity Function toolbox

By Tom Grydeland <Tom.Grydeland@gmail.com>

When called without arguments, these functions will show help text for themselves. When called with the minimum number of arguments (interval sequence for multipulse codes, number of bauds or complete code set for alternating codes), they will create a plot in the current axis showing the range-lag ambiguity functions (Wt,t' in the notation used by Lehtinen [1986], called Wtt' in the following) for a given modulation. Where arguments are not given or given as an empty matrix, default values will be used instead. For Barker code functions, the length of the Barker code can be specified, defaulting to 13. (bc_wtt requires the length of the code to be specified.) The baud length can be specified, defaulting to 3 for Barker coded modulations and 20 for all others. All functions accept a lag argument, specifying for which lags (in units of bauds) range-lag ambiguity functions are computed.

For the ac_wgate_wtt function, the next argument can be used to specify a vector of weights, one for each scan of the code.

The next argument for each function can be used to specify in what axis to draw the plot, e.g. for use in multi-panel plots. If this argument is empty, (and plotfunction argument is not given, see below) the range-lag ambiguity function is returned (range along the vertical (first) dimension and lag along the horizontal (second) dimension) and no plots are made.

After the axis argument, the name of a 3-D plotting function can be given. This function must accept arguments (X, Y, Z) where X and Y are vectors, and size(Z) == [ length(X) length(Y) ]. Possible plotting functions are surf, contour, image, pcolor and variants thereof.

Any remaining arguments will be passed to the plot function after the X, Y, Z arguments

If a plot is made and an output argument is specified, the handle to the plot is returned.

For alternating codes (random or otherwise), each non-zero lag can be decoded in multiple ways, with different range contributions. The ac_lp_wtt and bcac_lp_wtt functions show a separate ambiguity function for each decoding possibility, corresponding to [Nygrén, 1996, figure 6.6]. To an experimenter trying to interpret a set of measurements from an incomplete code set, it is more interesting to know what range-lag ambiguity to expect in a single range gate from a partially decoded or small random code set. The functions ac_gate_wtt and bcac_gate_wtt average the ambiguity functions for all possible decodings of the desired lags, shifted such that the expected peaks coincide. The range axis of the plot is centered at the center range of the gate. The ac_wgate_wtt function does the same, but allowing for different weights for each code in the set.

For long pulses, the functions lp_lp_wtt and lp_lph_wtt shows the range-lag ambiguity functions of the different lagged products that can be formed, the latter using an arbitrary receiver impulse response. When creating range-gated autocorrelation functions (ACFs) from long pulse data, it is customary to average a number of lagged products, different for each lag, to form a range gate. The function lp_gate_wtt (not implemented yet) shows the range-lag ambiguity functions for the different lags of such a range gate, centered at the nominal center range of the gate.

The variants named *_lph_wtt accept a bandwidth/filter argument, which either specifies the bandwidth of a Butterworth filter (which uses the but_filt function from GUISDAP), or an arbitrary impulse response function. Bandwidth is specified in units of kHz assuming that the time unit is one μs. The programs make no attempt to determine whether the given bandwidths or impulse responses are meaningful.

Long pulse plots

Alternating code plots

Barker codes

Barker coded alternating code plots

Multipulse code plots

Random codes

Supporting functions

Download tarball

Details of the programming

In the code, the unit of time (used for both lag and range) is not specified, but for practical purposes, it can be assumed to be one μs.

The functions do not assume "correctness" or "completeness" of codes or code sets, and will happily accept incomplete or random alternating code sets (indeed this was part of the motivation for writing the functions in the first place), and it will also accept codes that aren't Barker codes as the Barker code argument. This can be used to demonstrate imperfect cancellation of sidelobes and other range and/or lag ambiguities.

Near the top of each function, after argument processing, the transmission envelope env and receiver impulse response h are constructed. For the *_lp_wtt functions, h is given as a boxcar filter equal to the elementary baud in the code, while the *_lph_wtt functions allow for more realistic filters, as described above. From env and h, the amplitude ambiguity function (WAt(u; τ)) is computed [Lehtinen, 1986, eq. (2.10)]. In the functions, this is the variable wta, or cwta{jj} for alternating codes.

From the amplitude ambiguity function, the two-dimensional range-lag ambiguity functions (Wt,t'(τ, S)) for any given lag can be constructed, as a convolution along the delay dimension of the amplitude ambiguity function and a displaced (in the range direction) copy of the same. [Lehtinen, 1986, eq. (2.12)]. In the functions, these two-dimensional ambiguity functions for all desired lags are combined into the variable wtt. When different ambiguity functions overlap (as they often do), the maximum non-zero value is used. Particularly in coding schemes subcoded by a Barker code, this leads to apparent asymmetries that may not be present in the individual ambiguity functions.

For alternating codes, the two-dimensional ambiguity functions for any given scan in the code set is ambiguous in range, only when the code set is decoded are these ambiguities reduced or, (for complete sets of Lehtinen-type alternating codes), eliminated. Furthermore, each lag can be decoded in multiple ways, yielding different (more or less unambiguous) range contributions. In these cases, decoding is done in the temporary variable wtmp and only after decoding is the resulting ambiguity function incorporated into wtt.

The decoding coefficients are computed from the code set, a procedure which works equally well for all kinds of alternating codes.

Examples

Retrieving the amplitude ambiguity function is not provided for, but should be simple enough to read from the code. Follow the link in each example to see the plot made from that particular instruction.

The axes have been made equal using axis image in every plot.

References

Copyright © 2003-2008 Tom Grydeland
$Id: index.html,v 1.6 2008-11-18 05:34:39 tom Exp $
This is free software, licensed under GNU GPL version 2 or later Valid HTML 4.01!