RF Mixer Downconversion
Simulation of a superheterodyne downconversion stage using the RFMixer block. A high-frequency RF signal is mixed with a local oscillator (LO) to produce an intermediate frequency (IF) output.
Mixer Model
The RFMixer performs ideal time-domain multiplication:
MATHDISPLAY0ENDMATH
For sinusoidal inputs at frequencies MATHINLINE2ENDMATH and MATHINLINE3ENDMATH, the output contains sum and difference frequencies:
MATHDISPLAY1ENDMATH
System Setup
We set up a downconversion scenario:
- RF signal at 1000 Hz
- LO at 900 Hz
- Expected IF at 100 Hz (difference) and 1900 Hz (sum)
Connections
The RF source connects to the mixer's rf input (port 0), the LO source to the lo input (port 1). The mixer output goes to both a scope and spectrum analyzer.
10:58:24 - INFO - LOGGING (log: True) 10:58:24 - INFO - BLOCKS (total: 5, dynamic: 1, static: 4, eventful: 0) 10:58:24 - INFO - GRAPH (nodes: 5, edges: 6, alg. depth: 2, loop depth: 0, runtime: 0.064ms) 10:58:24 - INFO - STARTING -> TRANSIENT (Duration: 0.10s) 10:58:24 - INFO - -------------------- 1% | 0.0s<1.2s | 760.2 it/s 10:58:24 - INFO - ####---------------- 20% | 0.2s<0.6s | 1193.0 it/s 10:58:24 - INFO - ########------------ 40% | 0.4s<0.4s | 1223.0 it/s 10:58:24 - INFO - ############-------- 60% | 0.5s<0.3s | 1205.8 it/s 10:58:24 - INFO - ################---- 80% | 0.7s<0.2s | 1185.1 it/s 10:58:24 - INFO - #################### 100% | 0.8s<--:-- | 1196.7 it/s 10:58:24 - INFO - FINISHED -> TRANSIENT (total steps: 911, successful: 911, runtime: 848.69 ms)
Time-Domain Results
The mixer output shows the characteristic beat pattern of two closely spaced frequencies.
Frequency-Domain Analysis
The spectrum of the mixer output should show two peaks at the sum and difference frequencies: MATHINLINE0ENDMATH Hz and MATHINLINE1ENDMATH Hz.