summaryrefslogtreecommitdiff
path: root/Antenna_and_Wave_Propagation_by_k.k._sharma/chapter6.ipynb
diff options
context:
space:
mode:
authorThomas Stephen Lee2015-08-28 16:53:23 +0530
committerThomas Stephen Lee2015-08-28 16:53:23 +0530
commitdb0855dbeb41ecb8a51dde8587d43e5d7e83620f (patch)
treeb95975d958cba9af36cb1680e3f77205354f6512 /Antenna_and_Wave_Propagation_by_k.k._sharma/chapter6.ipynb
parent5a86a20b9de487553d4ef88719fb0fd76a5dd6a7 (diff)
downloadPython-Textbook-Companions-db0855dbeb41ecb8a51dde8587d43e5d7e83620f.tar.gz
Python-Textbook-Companions-db0855dbeb41ecb8a51dde8587d43e5d7e83620f.tar.bz2
Python-Textbook-Companions-db0855dbeb41ecb8a51dde8587d43e5d7e83620f.zip
add books
Diffstat (limited to 'Antenna_and_Wave_Propagation_by_k.k._sharma/chapter6.ipynb')
-rwxr-xr-xAntenna_and_Wave_Propagation_by_k.k._sharma/chapter6.ipynb524
1 files changed, 524 insertions, 0 deletions
diff --git a/Antenna_and_Wave_Propagation_by_k.k._sharma/chapter6.ipynb b/Antenna_and_Wave_Propagation_by_k.k._sharma/chapter6.ipynb
new file mode 100755
index 00000000..62ee756d
--- /dev/null
+++ b/Antenna_and_Wave_Propagation_by_k.k._sharma/chapter6.ipynb
@@ -0,0 +1,524 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "chapter 06 : Practical Antennas - II"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.1 : page 6.39"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "n=20 #no. of turns\n",
+ "#Clamda=lamda\n",
+ "#Slamda=lamda/4\n",
+ "#HPBW : \n",
+ "# HPBW=52/(Clamda*sqrt(n*Slamda))\n",
+ "#Putting values below :\n",
+ "Clamda=1 #in Meter\n",
+ "Slamda=1.0/4 #in Meter\n",
+ "HPBW=52.0/(Clamda*sqrt(n*Slamda)) #in degree\n",
+ "print \"HPBW = %0.2f degree \" %HPBW \n",
+ "#Axial Ratio\n",
+ "Aratio=(2*n+1)/2 #unitless\n",
+ "print \"Axial Ratio = %0.2f \"%Aratio \n",
+ "#Gain\n",
+ "D=12*Clamda**2*n*Slamda #unitless\n",
+ "print \"Gain = %0.2f \"%D "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "HPBW = 23.26 degree \n",
+ "Axial Ratio = 20.00 \n",
+ "Gain = 60.00 \n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.2 : page 6.39"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "#Part (a): Given data :\n",
+ "n=20 #no. of turns\n",
+ "Slamda=0.472 #in meter\n",
+ "D=12*n*Slamda #in meter\n",
+ "from sympy import symbols, N, sqrt\n",
+ "lamda = symbols('lamda', real =True)\n",
+ "Ae=(lamda**2/(4*pi))*D\n",
+ "d=(sqrt(Ae))\n",
+ "print \"Part (a) : d=\",N(d,1)\n",
+ "print \"Part (b) : With a space of 3*lamda the total effective area : \" \n",
+ "Ae=9.02*lamda**2*4\n",
+ "D=4*pi*Ae/lamda**2\n",
+ "print \"\\t D = %0.2f\" %D"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Part (a) : d= 3.0*Abs(lamda)\n",
+ "Part (b) : With a space of 3*lamda the total effective area : \n",
+ "\t D = 453.39\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.3 : page 6.40"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10, ceil\n",
+ "#from 7dBi gain graph the data obtained is given below :\n",
+ "K=1.2 #Scale constant\n",
+ "alfa=1.5 #Apex angle in degree\n",
+ "Slamda=0.15 \n",
+ "print \"K**n=F or n=logF/logK\" \n",
+ "F=4 \n",
+ "n=log10(F)/log10(K) \n",
+ "n=ceil(n) \n",
+ "nplus1=n+1 \n",
+ "print \"Apex Angle = %0.2f degree \" %alfa \n",
+ "print \"Sale constant = %0.2f\" %K \n",
+ "print \"No. of elements = %d \" %n "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "K**n=F or n=logF/logK\n",
+ "Apex Angle = 1.50 degree \n",
+ "Sale constant = 1.20\n",
+ "No. of elements = 8 \n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.4 : page 6.40"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "#Given data :\n",
+ "#d=10*lamda\n",
+ "print \"d=10*lamda\" \n",
+ "print \"Power Gain : G=6*(d/lamda)**2\" \n",
+ "print \"Putting value of d, we get G=6*10**2\"\n",
+ "G=6*10**2 #unitless\n",
+ "print \"Power gain = %0.2f \" %G \n",
+ "G_dB=10*log10(G) #in dB\n",
+ "print \"Power Gain = %0.1f dB \" %G_dB "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "d=10*lamda\n",
+ "Power Gain : G=6*(d/lamda)**2\n",
+ "Putting value of d, we get G=6*10**2\n",
+ "Power gain = 600.00 \n",
+ "Power Gain = 27.8 dB \n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.5 : page 6.40"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "#Given Data:\n",
+ "f=10.0 #in GHz\n",
+ "f=f*10**9 #in Hz\n",
+ "BWFN=10 #in degree\n",
+ "c=3*10**8 #Speed of light in m/s\n",
+ "lamda=c/f #in meter\n",
+ "#Part (a):\n",
+ "d=140*lamda/BWFN #in meter\n",
+ "print \"Diameter of a parabolic Antenna = %0.2f m\" %d\n",
+ "#Part (b):\n",
+ "HPBW=58.0*lamda/d #in degree\n",
+ "print \"3-dB Beamwidth = %0.2f degree \" %HPBW \n",
+ "#Part (c):\n",
+ "Gp=6*(d/lamda)**2 #gain \n",
+ "Gp_dB=10*log10(Gp) #in dB\n",
+ "print \"Power Gain = %0.2f dB \" %Gp_dB "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Diameter of a parabolic Antenna = 0.42 m\n",
+ "3-dB Beamwidth = 4.14 degree \n",
+ "Power Gain = 30.70 dB \n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.6 : page 6.41"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "#Given Data:\n",
+ "f=1430.0 #in MHz\n",
+ "f=f*10**6 #in Hz\n",
+ "d=64 #in meter\n",
+ "c=3*10**8 #Speed of light in m/s\n",
+ "lamda=c/f #in meter\n",
+ "#Part (a):\n",
+ "HPBW=70*lamda/d #in degree\n",
+ "print \"HPBW = %0.2f degree \" %HPBW \n",
+ "#Part (b):\n",
+ "BWFN=140*lamda/d #in degree\n",
+ "print \"BWFN = %0.2f degree \" %BWFN \n",
+ "#Part (c):\n",
+ "Gp=6*(d/lamda)**2 #gain \n",
+ "Gp_dB=10*log10(Gp) #in dB\n",
+ "print \"Power Gain = %0.f dB \" %Gp_dB "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "HPBW = 0.23 degree \n",
+ "BWFN = 0.46 degree \n",
+ "Power Gain = 57 dB \n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.7 : page 6.42"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "#Given Data:\n",
+ "f=15.0 #in GHz\n",
+ "f=f*10**9 #in Hz\n",
+ "Gp_dB=75.0 #in dB\n",
+ "c=3*10**8 #Speed of light in m/s\n",
+ "lamda=c/f #in meter\n",
+ "#Formula : Gp=9.87*(d/lamda)**2\n",
+ "#Formula : Gp_dB=10log10(Gp)\n",
+ "d=sqrt((10**(Gp_dB/10))*lamda**2/9.87) #in meter\n",
+ "print \"Diameter of a parabolic reflector = %0.2f m\" %d"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Diameter of a parabolic reflector = 35.80 m\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.8 : page 6.42"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given Data:\n",
+ "f=5000.0 #in MHz\n",
+ "f=f*10**6 #in Hz\n",
+ "d=10 #in feet\n",
+ "d=d*0.3048 #in meter\n",
+ "c=3*10**8 #Speed of light in m/s\n",
+ "lamda=c/f #in meter\n",
+ "r=2*d**2.0/lamda #in meter\n",
+ "print \"Minimum distance between primary and secondary antenna = %0.f m\" %r\n",
+ "# Ans wrong in the textbook"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Minimum distance between primary and secondary antenna = 310 m\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.9 : page 6.42"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given Data:\n",
+ "K=55.0 #Aperture Efficiency in %\n",
+ "K=K/100 #Aperture Efficiency\n",
+ "f=15.0 #in GHz\n",
+ "f=f*10**9 #in Hz\n",
+ "c=3*10**8 #Speed of light in m/s\n",
+ "lamda=c/f #in meter\n",
+ "G_dB=30 #in dB\n",
+ "G=10**(G_dB/10) #Gain unitless\n",
+ "#Formula : G=4*pi*K*A/lamda**2\n",
+ "A=(G*lamda**2)/(4*pi*K) #in m**2\n",
+ "print \"Diameter of parabolic reflector = %0.3f m**2\" %A \n",
+ "#Part (b)\n",
+ "d=sqrt(4.0*A/pi) #in meter\n",
+ "HPBW=70*lamda/d #in degree\n",
+ "print \"HPBW = %0.2f degree \" %HPBW \n",
+ "#Part (c)\n",
+ "BWFN=140*lamda/d #in Degree\n",
+ "print \"BWFN = %0.2f degree \" %BWFN \n",
+ "#Note : Answer in the book is not accurate."
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Diameter of parabolic reflector = 0.058 m**2\n",
+ "HPBW = 5.16 degree \n",
+ "BWFN = 10.31 degree \n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.10 : page 6.43"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given Data:\n",
+ "Tau=0.7 #Design Factor\n",
+ "L1=0.3*2 #in meter\n",
+ "c=3*10**8 #speednof light in m/s\n",
+ "f1=(c/(2*L1))/10**6 #in MHz\n",
+ "#Design factor : L1/L2=L2/L3=L3/L4=.......=0.7\n",
+ "L2=0.7/L1 #in meter\n",
+ "f2=f1*0.7 #in MHz\n",
+ "f3=f2*0.7 #in MHz\n",
+ "f4=f3*0.7 #in MHz\n",
+ "f5=f4*0.7 #in MHz\n",
+ "f6=f5*0.7 #in MHz\n",
+ "f7=f6*0.7 #in MHz\n",
+ "f8=f7*0.7 #in MHz\n",
+ "f9=f8*0.7 #in MHz\n",
+ "f10=f9*0.7 #in MHz\n",
+ "print \"Cutoff frequencies in MHz :\"\n",
+ "print \"f1 = %0.2f MHz \" %f1 \n",
+ "print \"f2 = %0.2f MHz \" %f2\n",
+ "print \"f3 = %0.2f MHz \" %f3\n",
+ "print \"f4 = %0.2f MHz \" %f4\n",
+ "print \"f5 = %0.2f MHz \" %f5\n",
+ "print \"f6 = %0.2f MHz \" %f6\n",
+ "print \"f7 = %0.2f MHz \" %f7\n",
+ "print \"f8 = %0.2f MHz \" %f8\n",
+ "print \"f9 = %0.2f MHz \" %f9\n",
+ "print \"f10 = %0.2f MHz \" %f10\n",
+ "print \"Passband = %0.2f\"%(f1-f10 )"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Cutoff frequencies in MHz :\n",
+ "f1 = 250.00 MHz \n",
+ "f2 = 175.00 MHz \n",
+ "f3 = 122.50 MHz \n",
+ "f4 = 85.75 MHz \n",
+ "f5 = 60.02 MHz \n",
+ "f6 = 42.02 MHz \n",
+ "f7 = 29.41 MHz \n",
+ "f8 = 20.59 MHz \n",
+ "f9 = 14.41 MHz \n",
+ "f10 = 10.09 MHz \n",
+ "Passband = 239.91\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exa 6.11 : page 6.44"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi, tan, acos\n",
+ "#Given Data:\n",
+ "from sympy import symbols, simplify, atan, acos, N\n",
+ "lamda = symbols('lamda', real = True)\n",
+ "#Assuming typical values for f \n",
+ "f1=0.2*lamda #in E-plane \n",
+ "f2=0.375*lamda # in H-plane\" \n",
+ "b=10*lamda # mouth height\n",
+ "delta=0.2*lamda\n",
+ "print \"Length :\"\n",
+ "L=pow(b,2)/(8*delta)\n",
+ "print (L)\n",
+ "print \"Flare Angle (Theta):\",\n",
+ "Theta=atan(b/(2*L))*180/pi\n",
+ "print round(Theta,1),'degree'\n",
+ "print \"Flare Angle (fi):\",\n",
+ "delta=0.375*lamda\n",
+ "fi=acos(L/(L+delta))*180/pi # degree\n",
+ "print round(fi,1),'degree'\n",
+ "print \"fi=\",(acos((10**2/(8*0.2))/((10**2/(8*0.2))+0.375))),\" radian\" \n",
+ "fi=(acos((10**2/(8*0.2))/((10**2/(8*0.2))+0.375))) #in Degree\n",
+ "print \"Width :\" \n",
+ "a=2*L*tan(fi)\n",
+ "print N(a,3)"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Length :\n",
+ "62.5*lamda\n",
+ "Flare Angle (Theta): 4.6 degree\n",
+ "Flare Angle (fi): 6.3 degree\n",
+ "fi= 0.109271705413178 radian\n",
+ "Width :\n",
+ "13.7*lamda\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}