Main Content

RF Budget Analyzer

Analyze gain, noise figure, IP2, and IP3 of cascaded RF elements and export to RF Blockset

Description

The RF Budget Analyzer app analyzes the gain, noise figure, and nonlinearity of proposed RF system architecture.

Using this app, you can:

  • Build a cascade of RF elements.

  • Calculate the per-stage and cascade output power, gain, noise figure, SNR, and IP3 of the system.

  • Compute nonlinear effects such as output power, IP2, NF, and SNR using harmonic balance analysis.

  • Compare Friis and harmonic balance budget results.

  • Plot:

    • rfbudget results across bandwidths and over stages.

    • S-parameters of the RF System on a Smith® Chart and a polar plot.

    • Magnitude, phase and real, and imaginary parts of S-parameters of the RF System and over stages.

  • Export:

    • Per-stage and cascade values to the MATLAB® workspace.

    • System design to RF Blockset™ for simulation.

    • System design to the RF Blockset Testbench as a device under test (DUT) subsystem and verify the results using simulation.

    • System design to rfsystem System object™.

  • Visualize:

    • Budget results, S-parameters over stages and frequencies.

    • Amplifier power characteristics. (since R2023a)

    • One- and two-tone harmonic balance results of the RF budget chain. (since R2023b)

    • Mixer spurs and spur-free zones of the IMT Mixer. (since R2024a)

  • Treat an N-port element with multiple ports as a 2-port element. (since R2024b)

  • Increase the number of harmonics for higher fidelity harmonic balance (HB) simulation and reduce the number of harmonics for faster harmonic balance simulation. (since R2024b)

Note

  • The RF Budget Analyzer app assumes a reference temperature of 290 K when calculating the SNR of an RF chain.

  • If you use:

    • A stripline element in your system, then the app does not support exporting your system to RF Blockset.

    • An antenna element, the app does not support exporting to a testbench in the RF Blockset using the Measurement Testbench option.

Available Blocks

The app toolstrip contains these nonlinear elements that you can use to create an RF system:

  • Amplifier

  • Modulator

  • Demodulator

  • Generic

  • Mixer IMT

The app toolstrip contains these linear elements that you can use to create an RF system:

  • S-Parameters

  • Filter

  • Transmission Line

  • Series RLC

  • Shunt RLC

  • Attenuator

  • Transmitter Antenna

  • Receiver Antenna

  • Transmit-Receive Antenna

  • LC Ladder

  • Phase Shift

  • Mutual Inductor

Available Templates

The app toolstrip contains these templates that you can use to design a transmitter or a receiver system:

  • Receiver

  • Transmitter

RF Budget Analyzer app

Open the RF Budget Analyzer App

  • MATLAB Toolstrip: On the Apps tab, under RF and Mixed-Signal, click the app icon.

  • MATLAB command prompt: Enter rfBudgetAnalyzer.

Examples

expand all

Design and analyze an RF transmitter using the RF Budget Analyzer app.

Enter rfBudgetAnalyzer to open the app.

Select New and then select select Transmitter to use the transmitter template to create a basic transmitter.

The transmitter template is displayed as follows.

rfb_ex_img3_24b.png

In System Parameters, specify the RF transmitter requirements:

  • Input Frequency815 MHz

  • Available Input Power0 dBm

  • Signal Bandwidth100 MHz

Click the IFAmplifier in the design canvas and delete the element using the Delete Element button on the toolstrip.

Add a Generic element in the place of the IFAmplifier using the toolstrip. In the Element Parameters pane, specify:

  • NameIFFilter

  • Available Power Gain — –3.6 dB

  • Select Apply.

Click the Modulator element. In the Element Parameters pane, specify:

  • NameMixer

  • Available Power Gain — –6.5 dB

  • OIP311.5 dBm

  • LO Frequency4.97 GHz

  • Converter TypeUp

  • Select Apply.

Delete the S-Parameters element named BandpassFilter. Add a Generic element. In the Element Parameters pane, specify:

  • NameRFFilter1

  • Available Power Gain — –1.4 dB

  • Select Apply.

Select the PowerAmplifier element and in the Element Parameters pane, specify:

  • NamePowerAmplifier1

  • Available Power Gain20 dB

  • OIP343 dBm

  • Select Apply.

Add another Amplifier element using the toolstrip. In the Element Parameters pane, specify:

  • NamePowerAmplifier2

  • Available Power Gain20 dB

  • OIP343 dBm

  • Select Apply.

Add another Generic element. In the Element Parameters pane, specify:

  • NameRFFilter2

  • Available Power Gain — –1.4 dB

  • Select Apply.

rfb_ex_img1_24b.png

Save the system. The app saves the system in a MAT file.

Plot the output power of the transmitter using the 3D Plot button. Select 3D Plot and choose Output Power - Pout.

tx_result_update.png

Select the PowerAmplifer1 element and from the Element Parameters pane, and then click the Plot Power Characteristics button to plot amplifier power characteristics of the PowerAmplifer1 element. Alternatively, to plot the amplifier power characteristics of the PowerAmplifer1 element, select the PowerAmplifer1 element and using the 2-D Plot button, choose Plot Power Characteristics.(Since 2023a)

rfb_ex_img2_24b.png

This example uses an RF transmitter design from the RF Transmitter System Analysis example.

Follow the RF Transmitter System Analysis example to design an RF transmitter. Select the antenna element from the Elements section and add the element at end of this RF transmitter. In the Element Parameters pane, select Antenna Designer from the Antenna Source drop-down list.

rfb_2_1.png

Click Create Antenna in the Element Parameters pane.

rfb_2_2.png

The Antenna Designer app opens. Click New to explore the antenna library. This example uses a dipoleFolded antenna element with a center frequency of 815 MHz. To do this, select Folded element from the Antenna Gallery, set Design Frequency to 815 MHz, and click Accept.

rfb_2_3.png

The updated antenna shows in the window.

rfb_2_4.png

Click Update Element to update the Antenna element in the RF Budget Analyzer app. Click OK in the Confirm Update dialog box.

rfb_2_5.png

The Antenna Designer app window closes and the Antenna element is updated in the RF Budget Analyzer app. The Results pane is automatically updated for Friis analysis with EIRP and Directivity of the Antenna element.

rfb_ex2_img1_24b.png

Design and analyze an RF receiver using the RF Budget Analyzer app.

Enter rfBudgetAnalyzer to open the app.

Click the New button and select Receiver to use the receiver template option to create a basic receiver.

The receiver template is displayed as follows:

rfb_ex3_img1_24b.png

In System Parameters, specify the RF receiver requirements:

  • Input Frequency5.745 MHz

  • Available Input Power — –65 dBm

  • Signal Bandwidth100 MHz

Click RFFilter in the design canvas. This RFFilter is an S-parameters element. It accepts a Touchstone® file in the S2P file type. Update the Element parameters pane as follows:

  • Name: BandpassFilter

  • S2P file: Choose an S2P file by clicking the Browse button.

  • Select Apply.

Click the RFAmplifier element. In the Element Parameters pane, specify the element requirements:

  • NameLNA1

  • Available Power Gain12 dB

  • OIP320 dBm

  • Select Apply.

Add another Amplifier element using the toolstrip. In the Element Parameters pane, specify the element requirements:

  • NameLNA2

  • Available Power Gain12 dB

  • OIP320 dBm

  • Select Apply.

Add a Generic element. In the Element Parameters pane, specify the element requirements:

  • NameIRFilter

  • Available Power Gain — –4.05 dB

  • Select Apply.

Click the Demodulator element. In the Element Parameters pane, specify the element requirements:

  • NameMixer

  • Available Power Gain — –6.5 dB

  • OIP311.5 dBm

  • LO Frequency4.93 GHz

  • Converter TypeDown

  • Select Apply.

Delete the IFFilter, S-parameters element. Add a Generic element in its place. In the Element Parameters pane, specify the element requirements:

  • NameCSFilter

  • Available Power Gain — –9.55 dB

  • Select Apply.

Click the IFAmplifier element. In the Element Parameters pane, specify the element requirements:

  • NamePowerAmp1

  • Available Power Gain16 dB

  • OIP326 dBm

  • Select Apply.

Add two more Amplifier elements. For each element, in the Element Parameters panes specify the element requirements:

  • Name PowerAmp2 | PowerAmp3

  • Available Power Gain16 dB | 20 dB

  • OIP326 dBm | 33 dBm

  • Select Apply.

rfb_ex3_img2_24b.png

Save the system. The app saves the system in a MAT file.

Plot the output OIP3 of the receiver using the 3D Plot button. Select the 3D Plot button and choose Output Third-Order Intercept Point - OIP3.

rxpr4.png

Create an amplifier with a gain of 4 dB.

a = amplifier('Gain',4);

Create a modulator with an OIP3 of 13 dBm.

m = modulator('OIP3',13);

Create an nport using passive.s2p.

n = nport('passive.s2p');

Create an RF element with a gain of 10 dB.

r = rfelement('Gain',10);

Calculate the rfbudget of a series of RF elements at an input frequency of 2.1 GHz, an available input power of -30 dBm, and a bandwidth of 10 MHz.

b = rfbudget([a m r n],2.1e9,-30,10e6);

Run this command in the command window, to open the system in RF Budget Analyzer app.

show(b)

rfb_ex4_img1_24b.png

Set OIP2 value of Amplifier to 60 dBm using Elements Parameters pane and select Apply. In System Parameters section, set the Available Input Power to 50 dBm and run harmonic balance analysis using HB-Analyze button.

The results are displayed as shown below.

rfb_4_2.png

Select Auto-Analyze checkbox from the Harmonic Balance section to automatically recompute the harmonic balance analysis calculations.

Set OIP2 value of RFelement as 50 dBm using Elements Parameters pane and select Apply.

Select Compare View checkbox in the Results pane to compare the calculated Friis and harmonic balance solver results. You can use Select Results drop-down from the Results pane to filter the results and to compare between Friis and harmonic balance solver.

rfb_4_3.png

Design an input matching network for a two-stage amplifier using the Transmission Line element in the RF Budget Analyzer app.

Enter rfBudgetAnalyzer to open the app.

In System Parameters, specify the requirements:

  • Input Frequency2.45 GHz

  • Available Input Power0 dBm

  • Signal Bandwidth2 GHz

Add two Transmission Line elements. In the Element Parameters pane, specify:

  • NameMicrostrip1 | Microstrip2

  • Type Microstrip | Microstrip

  • Width0.0034173 | 0.0034173 meters

  • Height0.001524 | 0.001524 meters

  • Thickness3.5e-06 | 3.5e-06 meters

  • EpsilonR3.48 | 3.48

  • LossTangent0.0037 | 0.0037 meters

  • SigmaCond Inf | Inf S/m

  • LineLength0.0089 | 0.0147 meters

  • StubModeShunt | NotAStub

  • TerminationOpen

  • Select Apply.

Add two S-Parameters elements. In the Element Parameters pane, specify:

  • Name Sparams1 | Sparams2

Load the Touchstone® file (f551432p.s2p) to the S-Parameters elements provided in this example and select Apply.

rfb_ex5_img1_24b.png

Plot the input reflection coefficient of the system using the 3D Plot button. Select the 3D Plot button, choose S-Parameters and select S11.

txlinepr3.png

Design an RF system and plot S-parameters, output power, and transducer gain using RF Budget Analyzer app.

Enter rfBudgetAnalyzer to open the app.

In System Parameters, specify the requirements:

  • Input Frequency2.1 GHz

  • Available Input Power-30 dBm

  • Signal Bandwidth45 MHz

Add a S-Parameters element. In the Element Parameters, specify:

  • Name RFBandpassFilter

Load the Touchstone® file (RFBudget_RF.s2p) to the S-Parameters element provided in this example and select Apply.

Add an Amplifier element. In the Element Parameters, specify:

  • NameRFAmplifier

  • Available Power Gain11.53 dB

  • NF1.53 dB

  • OIP335 dBm

  • Select Apply.

Add the Demodulator element. In the Element Parameters, specify:

  • NameDemodulator

  • Available Power Gain-6 dB

  • NF — 4 dB

  • OIP350 dBm

  • LO Frequency2.03 GHz

  • Converter TypeDown

  • Select Apply.

Add another S-Parameters element. In the Element Parameters, specify:

  • Name IFBandpassFilter

Load the Touchstone file (RFBudget_IF.s2p) to the S-Parameters element provided in this example and select Apply.

Add another Amplifier element. In the Element Parameters, specify:

  • NameIFAmplifier

  • Available Power Gain30 dB

  • NF8 dB

  • OIP337 dBm

  • Select Apply.

rfb_ex6_img1_24b.png

Save the system. The app saves the system in a MAT file.

Select S-Parameters Plot button. This allows you to plot Smith® chart, polar plot, magnitude, phase and real, and imaginary parts of S-parameters of the RF System and over stages.

rfb_6_2.png

Set the Plot Bandwidth to 75 and Resolution to 250 under Plots section.

The S-parameters data is displayed as follows.

rfb_6_3.png

Select Phase (deg) from the drop-down menu of XY Plot in S-Parameters pane to plot the phase of the S21.

rfb_6_4.png

The phase plot is displayed as shown.

rfb_6_5.png

Plot the output power of the RF system using the 2D Plot button. Select 2D Plot button and choose Output Power - Pout. 2-D output power is displayed.

sptg2.png

Plot the transducer gain of the RF system using the 2D Plot button. Select 2D Plot button and choose Transducer Gain - GainT.

sptg3.png

Design an RF receiver using the rfsystem system object. View the object in the the RF Budget Analyzer app to perform harmonic balance (HB) analysis.

Create fifth- and seventh-order bandpass RF filters.

f1 = rffilter('ResponseType','Bandpass','FilterOrder',5, ...
        'PassbandFrequency',[4.85 5.15]*1e9);
f2 = rffilter('ResponseType','Bandpass','FilterOrder',7, ...
        'PassbandFrequency',[10 130]*1e6);

Create two amplifier objects with 3 dB and 5 dB gain, respectively.

a1 = amplifier('Gain',3,'NF',1.53,'OIP3',35);
a2 = amplifier('Gain',5,'NF',8,'OIP3',37);

Create a modulator with a local frequency of 4.93 GHz.

d = modulator('Gain',0,'NF',4,'OIP3',50,'LO',4.93e9, ...
        'ConverterType','Down');

Design an RF receiver with the budget elements at an input frequency of 5 GHz, an available input power of – 30 dBm, and a bandwidth of 10 MHz.

rfb = rfbudget([f1 a1 d f2 a2],5e9,-30,10e6);

Create an RF system for the RF receiver using the rfbudget object.

rfs = rfsystem(rfb);

Open an RF Blockset model of the designed RF system using the open_system function.

open_system(rfs)

Type rfBudgetAnalyzer(rfs) command at the MATLAB® command line to open this RF system in the RF Budget Analyzer app.

To conduct HB analysis in the app, click the HB-Analyze button.

Related Examples

Programmatic Use

expand all

rfBudgetAnalyzer opens the RF Budget Analyzer app to analyze the stage-wise and total gain, noise figure, and nonlinearity (IP3) of an RF system.

rfBudgetAnalyzer(rfbmat) opens an RF system saved using the RF Budget Analyzer app. rfbmat is a MAT file.

rfBudgetAnalyzer(rfb) opens an RF system saved using the rfbudget object rfb in the RF Budget Analyzer app.

rfBudgetAnalyzer(rfs) opens an RF system saved using the rfsystem system object rfs in the RF Budget Analyzer app.

Tips

  • The RF Budget Analyzer app accepts 0 Hz as Input Frequency for a system. You can set the Input Frequency in the System Parameters section.

  • The RF Budget Analyzer app does not accept 0 Hz as LO Frequency. This is applicable to Modulator and Demodulator elements.

  • The output frequencies from the RF Budget Analyzer app are always positive.

  • The Filter element allows you to use only the 'Transfer function' implementation when you set the Filter Type to 'InverseChebyshev' in the Element Parameters pane.

  • To design an antenna element using the RF Budget Analyzer app, in the Antenna Element pane, set Antenna Source to Isotropic radiator.You can also design an antenna element using the Antenna Designer app or an antenna object. To use the Antenna Designer app or the antenna object, you need Antenna Toolbox™ license.

  • Antenna elements designed using a default antenna object require larger memory. To speed up the simulation, design your antenna element at a high frequency, 2 GHz or more.

References

[1] Pozar, David M. Microwave Engineering. 4th ed. Hoboken, NJ: Wiley, 2012.

Version History

Introduced in R2016a

expand all