You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This repository contains MATLAB tooling for comparing measured and simulated S-parameters of a quadrature hybrid. The pipeline ingests VNA Touchstone files alongside simulator exports, aligns the data to global S-parameter labels, and produces side-by-side comparison plots suitable for documentation and verification.
Layout
Schematic
ADS Simulation
Design Criteria
Center frequency: 2.45 GHz
Return loss at all ports: S11, S22, S33, S44 < -25 dB at 2.45 GHz
Power division: S21 and S31 > -3.5 dB at 2.45 GHz
Isolation: S41 < -30 dB at 2.45 GHz
Phase balance: ∠S21 – ∠S31 = 90° at 2.45 GHz
Substrate Properties
Substrate thickness (h): 62 mil
Relative permittivity (εᵣ): 4.4
Relative permeability (μᵣ): 1
Conductor conductivity (σ): 5.85 × 10⁷ S/m
Clearance to upper reference (hᵤ): 3.93701 × 10³⁴ mil (effectively open)
Copper thickness (t): 1.5 mil
Dielectric loss tangent (tan δ): 0.02
Surface roughness: 0 mil
Repository Layout
main.m — entry point that sets up paths, loads configuration, and launches the pipeline.
run_sparam_project.m — orchestrates file discovery, measurement/simulation alignment, and plotting.
+io/ — parsers for measurement (*.s2p) and simulation (*.txt / *.tab / *.dat) data.
+plotting/ — routines that generate comparison figures and save them to output/.
+util/ — helpers for path management and filename parsing.
+data/ — sample measurement and simulation files for local runs.
output/ — generated figures (Sij.png) for each available S-parameter.
repo/ — supporting figures
gerber/ — layout description, fabrication-ready.
Running the Code
Open MATLAB and change into the repository folder.
Run the project entry point:
>> main
The script will read measurement and simulation files from the configured directories, map the local two-port VNA data to the appropriate global S-parameter labels, and write comparison plots into the output/ directory for inspection and documentation.
Measurement vs. Simulation
S11
S12
S13
S14
S21
S22
S23
S31
S32
S33
S41
S44
About
This repository contains all files relevant to my design of a quadrature hybrid coupler, which should be directly able to run in ADS, and the Matlab code used to generate plots, comparing simulated and measured results on a VNA with a frequency of operation of 2.45GHz