# Given the microstrip width, calculate the line impedance and something else. # This procedure must be called from gnuplot with # call "w2z.gp" for example # call "w2z.gp" 58 31 4.5 where microstrip width is 58mils, heigth is 31mils, # and relative epsilon is 4.5 # AUTHORS: Paolo Subiaco http://gw.ir3ip.ampr.org/iw3grx # microstrip width w=$0*1.0 h=$1*1.0 er=$2*1.0 y=1-1/er x=log(w/h+.125) # Calculate the effective filling fraction (value between 0.5 and 1) q=(6.51309e-1 - 2.2516e-2*y - 3.32199e-3*y*y - 3.85162e-3*y*y*y) + \ (6.65212e-2*x - 1.26976e-3*x*y - 6.80530e-5*x*y*y - 1.03524e-3*x*y*y*y) + \ (1.64039e-2*x*x + 2.59784e-3*x*x*y + 2.74253e-4*x*x*y*y + 6.52501e-4*x*x*y*y*y) + \ (3.95737e-4*(x**3) + 6.69075e-4*(x**3)*y + 6.84457e-5*(x**3)*y*y + 3.34213e-4*(x**3)*y*y*y) + \ (1.84365e-3*(x**4) - 2.11987e-4*(x**4)*y + 2.1372e-5*(x**4)*y*y - 9.56514e-5*(x**4)*y*y*y) - \ (1.54945e-5*(x**5) - 9.69139e-5*(x**5)*y - 2.71033e-5*(x**5)*y*y - 3.65429e-5*(x**5)*y*y*y) - \ (6.53285e-5*(x**6) + 2.47067e-5*(x**6)*y + 4.06141e-6*(x**6)*y*y + 1.01064e-5*(x**6)*y*y*y) print "q=" , q, " (effective filling fraction)" # Given q, calculate the effective relative permittivity eeff=1+q*(er-1) print "Eeff=" , eeff , " (effective relative permittivity)" # Ok, with eeff i can calculate the phase velocity factor Vph=1.0/sqrt(eeff) print "Vph=" , Vph, " (phase velocity factor)" # Now calculate Zfs (free space) and then Zo : x=log(w/h) Zfs=exp( 4.8394 - 0.45016*x - 0.077456*x*x - 0.0065863*x*x*x + \ 0.0016510*(x**4) + 2.3165e-4*(x**5) - 3.7508e-5*(x**6) ) Zo=Vph*Zfs print "Zo=" , Zo, " (line impedance)"