¿ªÔÆÌåÓý

ctrl + shift + ? for shortcuts
© 2025 Groups.io

Calibration kit modeling with nanoVNA possible? #calibration #linux #octave


 

I found a web page
explaining how to compute the *calibration kit model coefficients* from .s1p files (Load, open, short) from your home made calibration kit..
Usually you get the .s1p files from a calibrate professional VNA.
Is it possible to also use the .s1p files from nanoVNA-saver?

For those who like to calculate themselves, following I describe the software setup under Linux.
The residuals from the calculations are shown in a plot.

Installation instructions for Ubuntu 20.04 in the Terminal + file browser:
$ sudo apt install octave
# Create a data path
$ cd
$ mkdir Install
$ cd Install

# Install Octave library NLopt
$ sudo apt install octave-nlopt

# Install calkit_model.m
$ cd
$ mkdir Install/IN3OTD_CalKit
$ cd Install/IN3OTD_CalKit
# download calkit_model.m from

Here is a "script": click on script and download in folder IN3OTD_CalKit

# install sbox
# copy sbox.zip to folder IN3OTD_CalKit and "expand here"
# copy file nanoVNA1_Load.s1p to folder IN3OTD_CalKit

# now run a calculation:
$ octave
# set path to package sbox (S-parameter toolBox)
octave:1> addpath('sbox/sbox');
octave:1> calkit_model('nanoVNA1_Load.s1p','LOAD')
offs_delay = 43.648469 ps
offs_loss = 0.000000 Gohm/s
offs_Z0 = 49.986443 ohm
Residual RMS error : -44.357936 dB
Octave_CalKit-model-LOAD_nanoVNA1.png

octave:1> calkit_model('nanoVNA1_Open.s1p','OPEN')
offs_delay = 11.793264 ps
offs_loss = 0.744891 Gohm/s
offs_Z0 = 54.943388 ohm
C0 = -153.031826 * 1e-15 F
C1 = -537.445705 * 1e-27 F/Hz
C2 = -184.283709 * 1e-36 F/Hz^2
C3 = -69.580809 * 1e-45 F/Hz^3
Residual RMS error : -33.399417 dB
Octave_CalKit-model-OPEN_nanoVNA1.png

octave:1> calkit_model('nanoVNA1_Short.s1p','SHORT')
offs_delay = 20.000000 ps
offs_loss = 0.100000 Gohm/s
offs_Z0 = 10.000000 ohm
L0 = 0.000000 * 1e-12 H
L1 = 0.000000 * 1e-24 H/Hz
L2 = 0.000000 * 1e-33 H/Hz^2
L3 = 0.000000 * 1e-42 H/Hz^3
Residual RMS error : -30.112093 dB
Octave_CalKit-model-SHORT_nanoVNA1.png

The references 3 and 4 from the web page are changed to:
Reference [3] Agilent Technical Forum, "HP 85032F Cal Kit" thread


Reference [4] Agilent Technical Forum, "Type N cal kit data needed" thread


73, Rudi DL5FA


 

I've been considering using a basis pursuit to determine the parameters. Not done anything more than look closely at the math. It's an underdetermined problem, but basis pursuit can handle that very well using GLPK if one has an accurate dictionary of simulations for the ranges of values spanning the true values.

I was getting less than 1% errors inverting the heat equation for fluid flow in porous media to determine layer thicknesses above and below a horizontal crack. In that case the flow is the sum of two flows, both of which are infinite series of exponentials.

I just ordered an H4, so when that arrives I'll have a good excuse for playing with the Octave solution.

Have Fun!
Reg


 

On Sat, Jun 13, 2020 at 06:14 PM, Reginald Beardsley wrote:

I've been considering using a basis pursuit to determine the parameters. Not
done anything more than look closely at the math. It's an underdetermined
problem, but basis pursuit can handle that very well using GLPK if one has an
accurate dictionary of simulations for the ranges of values spanning the true
values.

I just ordered an H4, so when that arrives I'll have a good excuse for playing
with the Octave solution.
Hello Reg,
Thank you ver much taking care about my topic VNA calibration improvement.
I am a newcomer in that field, so it would be nice to help,
if that Octave program *calkit_model.m* could help to improve the calibration of the nanoVNA.
73, Rudi DL5FA