📄 shldng.gnu
字号:
###################################################################### Gnuplot input file to plot shielding effectiveness# M P Robinson University of York 29/8/1997## See Electron. Lett. 15/8/96 vol.32 pp.1559-60####################################################################### To use, start gnuplot and type## load <name of this file># # Gnuplot will then plot electric (SE) and magnetic (SM) shielding# for the default dimensions, at the default position (p) over the# default frequency range (30MHz to 1GHz in 2MHz steps).# # All dimensions are in SI units.# # To change dimensions, type# a=<width of box>
# b=<height of box># d=<depth of box># L=<length of slot>
# w=<height of slot>
# t=<box wall thickness># Z0s=Zcps(<height of box>,<width of slot>,<thickness of wall>)# zeta=<loss term> # then replot or type# plot SE(x,<position>)# or# plot SM(x,<position>)# # In the Electronics Letter (Fig 1), height of box=b, width of slot=w, # thickness of wall=t. The loss term (not mentioned in the letter)# is approximately 1/Q of an enclosure resonance. Make it zero if# you are not sure.# # Type # show var# to display the values of the dimensions.# # Use the gnuplot help to find out how to change the x and y ranges.# ###################################################################### Frequency range etc.:#set samples 486, 486set function style linesset title "Shielding Effectiveness of Enclosure with Aperture" 0,0set time 0,0set xlabel "Frequency (Hz)" 0,0set xrange [3e+07 : 1e+09]set ylabel "SE or SM (dB)" 0,0set autoscale yset zero 1e-08## Functions:#dB(a)=20*log10(a)antidB(a)=10.0**(0.05*a)parallel(a,b)=a*b/(a+b)#w(x)=2*pi*xk0(x)=2.0*pi*x/c0lambda(x)=c0/x#Zslot(x)=(L/a)*0.5*j*Z0s*tan(k0(x)*0.5*L)v1(x)=Zslot(x)/(Z0 + Zslot(x))Z1(x)=parallel(Z0, Zslot(x))kg(x)=(1.0+zeta-j*zeta) * k0(x) * sqrt(1.0 - (0.5*lambda(x)/a)**2)Zg(x)=(1.0+zeta-j*zeta) * Z0 / sqrt(1.0 - (0.5*lambda(x)/a)**2)v2(x,p)=v1(x) / ( cos(kg(x)*p) + j*(Z1(x)/Zg(x))*sin(kg(x)*p) )Z2(x,p)=( Z1(x) + j*Zg(x)*tan(kg(x)*p) ) / (1 + j*(Z1(x)/Zg(x))*tan(kg(x)*p) )Z3(x,p)=j*Zg(x)*tan(kg(x)*(d-p)) v3(x,p)=v2(x,p) * Z3(x,p)/(Z2(x,p)+Z3(x,p))QE(x,p)=v3(x,p)*2.0SE(x,p)=-dB(abs(QE(x,p)))i3(x,p)=v2(x,p)/(Z2(x,p)+Z3(x,p))QM(x,p)=2.0*i3(x,p)*Z0SM(x,p)=-dB(abs(QM(x,p)))## Functions to calculate charcteristic impedance of aperture:#we(w,t)=w-0.3979*t*(3.531+log(w/t))ke(b,w,t)=we(w,t)/br4(b,w,t)=(1-ke(b,w,t)**2)**0.25Zcps(b,w,t)=120.0*pi*pi/log(2*(1+r4(b,w,t))/(1-r4(b,w,t)))## Variables (do not change):#j = {0.0, 1.0}c0 = 2.99792e+08mu0 = 1.25664e-06eps0 = 8.85419e-12Z0 = 376.73## Variables (may be changed):#L = 0.1a = 0.3d = 0.3
b=0.12
w=0.005
t=0.0015Z0s = Zcps(b,w,t)zeta = 0.0## Plot command:#plot SE(x,0.15),SM(x,0.15)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -