rfmixer

Digital up- or downconversion.

Syntax
[tOut,signalOut] = rfmixer(tIn,signalIn,mwFreq,type)
[tOut,signalOut] = rfmixer(tIn,signalIn,mwFreq,type,Opt)
Description

This function mixes the input signal (signalIn as a function of the time axis tIn in microseconds) with the LO frequency specified in the field mwFreq. Depending on the mixer type is specified in type, the function acts as a double-sideband (DSB) mixer, single-sideband (SSB) mixer or performs IQ modulation, demodulation or frequency shifting.

The output contains the time axis data in tOut (in microseconds) and the output signal in signalOut. For up- or downconversion with a digital double-sideband (DSB) mixer, single-sideband (SSB) mixer or IQ modulation, only the in-phase component of the output is returned. For IQ demodulation or frequency shift, the in-phase and quadrature parts of the up- or downconverted signal are contained in the real and imaginary part of signalOut.

Resampling of the input signal before up/downconversion can be performed by specifying a new sampling time step in Opt.dt. If no time step is given, the time step for the output signal is computed based on the maximum frequency of the signal.

If you don't request any output, rfmixer plots the up/downconverted signal.

The possible input arguments to the function are:

tIn
Time axis vector for the input signal, in microseconds.
signalIn
Input signal. In-phase (real) signal for up/downconversion (IF or RF) for DSB or SSB mixer or IQ demodulation; in-phase and quadrature components in the real and imaginary part of signalIn for IQ modulation or IQ frequency shift.
mwFreq
LO frequency, in GHz. For the 'IQshift' option, the sign indicating the direction of the frequency shift needs to be included.
type
Specifies the mixer type. The available options for this field are:
Opt (optional)
Calculation options, see below.

Opt is a structure containing different options for the digital up/downconversion. The available fields are listed below.

dt
Time step for the output signal, in microseconds. If no time step for resampling is given and the input time step is too large, a new time step is computed as 1/(2*Opt.OverSampleFactor*maxfreq).
OverSampleFactor
Factor for the determination of the new time step in signal resampling (default = 1.25), relative to Nyquist-required time step to avoid aliasing of the highest frequency in the signal.
InterpolationMethod
Interpolation method for signal resampling with Matlab's built-in function interp1 (default = 'spline').
BandwidthThreshold
Threshold for input bandwidth determination (the relative signal amplitude used as cutoff in determining the bandwidth of the input signal from its Fourier transform). The default is 0.1.
HilbertThreshold
Threshold for amplitude and phase FT overlap for the recovery of the Q signal from the I signal using Hilbert transformation. The default is 0.05.
NoiseCutoffThreshold
Threshold for selection of part of the input signal used to compute amplitude and cos(phase) FT overlap (the evaluation of the validity of the Hilbert transform is affected by the noise level in the signal and baseline). The default is 0.1.
Algorithm

The digital up/downconversion is performed as

[eqn]

For single-sideband up/downconversion and IQ demodulation, the quadrature signal Q is determined from the real input signal I by Hilbert transformation. The Hilbert transform of I corresponds to Q only if the Fourier transforms of the amplitude and phase contributions to I do not overlap (Bedrosian's product theorem, see Boashash, B., Estimating and interpreting the instantaneous frequency of a signal. I. Fundamentals. Proc. IEEE 80, 520 (1992), DOI: 10.1109/5.135376). rfmixer checks for validity of this assumption and returns an error if it is not satisfied. In some cases, noise contributions to the signal lead to increased overlap. The calculation can still be performed if Opt.HilbertThreshold is increased.

The different options available in rfmixer are listed below with schematic block diagrams of the corresponding types of mixers and a simple example of operation.

See also

hilberttrans, pulse