Frequency Domain Identification Toolbox
  Go to function:
    Search    Help Desk 
msinclip    Examples   See Also

Minimize crest factor of multisine using the clipping algorithm.

Syntax

Description

msinclip iterates towards an optimum set of phases for which the crest factor of the multisine with the given amplitudes (or the larger of the crest factors of the two multisines at the input and the output of a linear system) is minimum.

freqv is the vector of frequencies where the nonzero amplitudes are given. The elements must be integer multiples of a df value, and the minimum number of sines is 2. freqv must be monotonously increasing.

ampv contains the absolute values of the desired nonzero complex amplitudes at the corresponding frequencies (halves of the real amplitudes). If any element of ampv is complex, the phases of ampv will be used as starting values, otherwise the Schroeder multisine is used.

tf contains the complex transfer function values at the given frequencies. If tf is given, input-output optimization will be performed.

If gmod is given with the value 'nograph', iteration results will not be plotted, if with the value 'lastgraph', the result of the last iteration only, if with the value 'graph10' or 'graph100', the result of every 10th or 100th iteration, if with 'graph', the result of every iteration will be plotted.

When gmod contains the string 'ZOH' (e. g., its value is 'graphZOH', or just 'ZOH'), a zero-order hold multisine will be designed, instead of the band-limited one. This means that a stepwise function will be designed (prepared for a D/A converter), the number of samples will not be rounded up to the next power of two, and the maximum overshoots between samples will not be calculated.

itno contains the maximum number of iteration cycles. If itno = 0, the starting values will be returned (the Schroeder multisine or the one externally given).

ovs determines the minimum resolution of the peak factor calculation; the sampling frequency will chosen according to fs  ovs*2*fmax. If the resolution is small, and a band-limited design is requested (that is, not a zero-order hold design), the grid is often not dense enough to "catch" the maximum values with certainty. The default value of ovs = 16 usually provides errors less than 1%.

N offers a direct control of the length of the time series used for crest factor calculation, often necessary in ZOH design. The point number in the time series will be chosen equal to N in the ZOH design if the above condition for fs can be fulfilled when generating just one period, otherwise the condition will determine the point number. In the BL design the point number will be rounded up to the next power of 2 to use a base-2 FFT, and the condition has to be fulfilled again.

N must be an even number for msinclip.

If N is not given, it will be chosen to provide that each frequency be an integer multiple of fs/N.

The last input argument, cl0, lets the user set the initial clipping level of the algorithm between (0,1).

The output arguments are as follows.

The vector cx contains the complex amplitudes of the multisine (their absolute values are equal to the halves of the real amplitudes).

crx is the crest factor of the generated multisine, calculated with the given oversampling factor. However, the true value of the crest factor may be somewhat larger because the true peak value is usually slightly larger than the peak value on the grid.

crxmax is the upper limit of the crest factor of the multisine, calculated for the maximum possible peak value. This calculation is based on the determination of the maximum curvature of the time function:

cry is the crest factor of the multisine, calculated with the given oversampling factor, at the output of the linear system. crymax contains the worst-case crest factor of the output multisine.

Typical plots of the results of msinclip are shown in the figures. The first one illustrates a usual multisine design, the second one a zero-order hold one.

crf denotes the calculated crest factor of the multisine, followed by the worst case value. The actual clipping level is given next, and is shown by two dotted lines on the plot. In cycle 0 or if the iteration has converged, the clipping level is set equal to 1. The next number gives the number of performed iterations, and "opt. cyc." denotes the cycle in which the smallest crest factor was found (the last plot of a run shows this multisine).

Default Argument Values

The number of iterations: itno = 250.

ovs = 16 for band-limited design, ovs = 1 for zero-order hold design. In the case of band-limited design, the sampling frequency will be

or higher, when the given value of N prescribes it.

The clipping level will be chosen depending on the crest factor: for small crest factors (around 1.5) as 0.9, and smaller if the crest factor is larger.

Examples

Multisine design:

Multisine design, iteration started from random phases:

Calculation of a Schroeder multisine:

Calculation of a zero-order hold multisine:

Diagnostics

ovs must be at least 1, and the frequency vector must increase strictly monotonously. If a dc value is also given (freqv(1) = 0), the corresponding amplitude must not be zero.

The frequency resolution (df) is also calculated from freqv (the smallest common divider). If the maximum harmonic number is found to be larger than 1023 (which may well mean that the frequency vector was given erroneously), a warning message is sent:

Algorithm

The algorithm is based on swapping between time domain and frequency domain: the time domain waveform is clipped, then transformed to the frequency domain, and the amplitudes are restored to the desired values. The clipping level is slowly adjusted according to the evolution of the crest factor: when the result is improved, the clipping level is decreased, otherwise it is increased.

If input-output minimization is performed, the worse crest factor is minimized.

See Also

msinprep, dibs

References

[1] E. van der Ouderaa, J. Schoukens and J. Renneboog, "Peak Factor Minimization, Using Time--Frequency Domain Swapping Algorithm," IEEE Trans. on Instrumentation and Measurement, 1988, Vol. 37, No. 1, pp. 144-147.

[2] K. R. Godfrey, ed.: Perturbation Signals for System Identification. Englewood Cliffs, Prentice-Hall, 1993.



[ Previous | Help Desk | Next ]