summaryrefslogtreecommitdiff
path: root/Microwave_and_Radar_Engineering/Chapter_8.ipynb
diff options
context:
space:
mode:
authorJovina Dsouza2014-06-18 12:43:07 +0530
committerJovina Dsouza2014-06-18 12:43:07 +0530
commit206d0358703aa05d5d7315900fe1d054c2817ddc (patch)
treef2403e29f3aded0caf7a2434ea50dd507f6545e2 /Microwave_and_Radar_Engineering/Chapter_8.ipynb
parentc6f0d6aeb95beaf41e4b679e78bb42c4ffe45a40 (diff)
downloadPython-Textbook-Companions-206d0358703aa05d5d7315900fe1d054c2817ddc.tar.gz
Python-Textbook-Companions-206d0358703aa05d5d7315900fe1d054c2817ddc.tar.bz2
Python-Textbook-Companions-206d0358703aa05d5d7315900fe1d054c2817ddc.zip
adding book
Diffstat (limited to 'Microwave_and_Radar_Engineering/Chapter_8.ipynb')
-rw-r--r--Microwave_and_Radar_Engineering/Chapter_8.ipynb1025
1 files changed, 1025 insertions, 0 deletions
diff --git a/Microwave_and_Radar_Engineering/Chapter_8.ipynb b/Microwave_and_Radar_Engineering/Chapter_8.ipynb
new file mode 100644
index 00000000..d2c5bc27
--- /dev/null
+++ b/Microwave_and_Radar_Engineering/Chapter_8.ipynb
@@ -0,0 +1,1025 @@
+{
+ "metadata": {
+ "name": "Chapter 8"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 8: Microwave Tubes and Circuits"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.1, Page number 336"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Compute -\n",
+ "a)dc electron velocity\n",
+ "b)dc phase constant\n",
+ "c)plasma frequency\n",
+ "d)reduced plasma frequency \n",
+ "e)dc beam current density\n",
+ "f)instantaeneous beam current density'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "Vo = 14.5*10**3 #beam voltage(V)\n",
+ "i = 1.4 #beam current(A)\n",
+ "f = 10*10**9 #frequency(Hz)\n",
+ "rho_o = 10**-6 #dc electron charge density(c/m^3)\n",
+ "rho = 10**-8 #RF charge density(c/m^3)\n",
+ "V = 10**5 #velocity perturbations(m/s)\n",
+ "eo = 8.854*10**-12\n",
+ "R = 0.4\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "vo = 0.593*10**6*math.sqrt(Vo) #dc electron velocity\n",
+ "\n",
+ "#Part b\n",
+ "w = 2.*math.pi*f\n",
+ "ip = w/vo #dc phase current\n",
+ "\n",
+ "#Part c\n",
+ "wp = math.sqrt((1.759*10**11*rho_o)/eo)\n",
+ "\n",
+ "#Part d\n",
+ "wq = R*wp\n",
+ "\n",
+ "#Part e\n",
+ "Jo = rho_o * vo\n",
+ "\n",
+ "#Part f\n",
+ "J = rho*vo+rho_o*V\n",
+ "\n",
+ "#Results\n",
+ "print \"dc electron velocity =\",round((vo/1E+8),3),\"*10**8 m/sec\"\n",
+ "print \"dc phase curent =\",round(ip,2),\"rad/sec (Calculation mistake in the textbook)\"\n",
+ "print \"plasma frequency =\",round((wp/1E+8),2),\"*10**8 rad/sec\"\n",
+ "print \"Reduced plasma frequency =\",round((wq/1E+8),3),\"*10**8 rad/sec\"\n",
+ "print \"dc beam current density =\",round(Jo,2), \"A/m^2\"\n",
+ "print \"instantaeneous beam current density =\",round(J,3),\"A/m^2\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "dc electron velocity = 0.714 *10**8 m/sec\n",
+ "dc phase curent = 879.92 rad/sec (Calculation mistake in the textbook)\n",
+ "plasma frequency = 1.41 *10**8 rad/sec\n",
+ "Reduced plasma frequency = 0.564 *10**8 rad/sec\n",
+ "dc beam current density = 71.41 A/m^2\n",
+ "instantaeneous beam current density = 0.814 A/m^2\n"
+ ]
+ }
+ ],
+ "prompt_number": 73
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.2, Page number 337"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Determine -\n",
+ "a)input rms voltage\n",
+ "b)output rms voltage\n",
+ "c)power delivered to the load'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "Av = 15. #voltage gain(dB)\n",
+ "Pin = 5*10**-3 #input power(W)\n",
+ "Rsh_in = 30*10**3 #Rsh of input cavity(Ohms)\n",
+ "Rsh_out = 20.*10**3 #Rsh of output cavity(Ohms)\n",
+ "Rl = 40*10**4 #load impedance(Ohms)\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "V1 = math.sqrt(Pin*Rsh_in) #input rms voltage\n",
+ "\n",
+ "#Part b\n",
+ "#Av = 20log(V2/V1) db\n",
+ "V2 = V1*10**(Av/20) #deriving V2 from above equation\n",
+ "\n",
+ "#Part c\n",
+ "Pout = (V2**2)/Rsh_out #output power\n",
+ "\n",
+ "#Results\n",
+ "print \"input rms voltage =\",round(V1,2),\"V\"\n",
+ "print \"output rms voltage =\",round(V2,2),\"V\"\n",
+ "print \"output power =\",round((Pout/1E-3),2),\"mW\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "input rms voltage = 12.25 V\n",
+ "output rms voltage = 68.87 V\n",
+ "output power = 237.17 mW\n"
+ ]
+ }
+ ],
+ "prompt_number": 50
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.3, Page number 338"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Dtermine -\n",
+ "a)input power\n",
+ "b)output power\n",
+ "c)efficiency'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "n = 2 #no. of modes\n",
+ "Vo = 300 #beam voltage(V)\n",
+ "Io = 20*10**-3 #beam current(A)\n",
+ "J1X = 1.25\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "Pdc = Vo*Io #input power\n",
+ "\n",
+ "#Part b\n",
+ "Pac = (2*Pdc*J1X)/(2*math.pi*n-(math.pi/2))\n",
+ "\n",
+ "#Part c\n",
+ "N = (Pac/Pdc)*100. #efficiency\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print \"Input power =\",round(Pdc,2),\"W\"\n",
+ "print \"Output power =\",round(Pac,2),\"W\"\n",
+ "print \"Efficiency =\",round(N,2),\"%\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input power = 6.0 W\n",
+ "Output power = 1.36 W\n",
+ "Efficiency = 22.74 %\n"
+ ]
+ }
+ ],
+ "prompt_number": 60
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.4, Page number 338"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Determine -\n",
+ "a)electron velocity \n",
+ "b)dc transit time of electrons\n",
+ "c)input voltage for maximum output voltage\n",
+ "d)voltage gain in decibles'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Varaible declaration\n",
+ "Vo = 900 #beam voltage(V)\n",
+ "Io = 30*10**-3 #beam current(A)\n",
+ "f = 8*10**9 #frequency(Hz)\n",
+ "d = 1*10**-3 #gap spacing in either cavity(m)\n",
+ "L = 4*10**-2 #spacing between centers of cavities(m)\n",
+ "Rsh = 40*10**3 #effective shunt impedance(Ohms)\n",
+ "J1X = 0.582\n",
+ "X = 1.841\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "vo = 0.593*10**6*math.sqrt(Vo)\n",
+ "\n",
+ "#Part b\n",
+ "To = L/vo\n",
+ "\n",
+ "#Part c\n",
+ "w = 2*math.pi*f\n",
+ "theta_o = w*To\n",
+ "theta_g = (w*d)/vo\n",
+ "Bo = math.sin(theta_g/2)/(theta_g/2)\n",
+ "V1_max = (Vo*3.68)/(Bo*theta_o)\n",
+ "\n",
+ "#Part d\n",
+ "Ro = Vo/Io\n",
+ "Av = ((Bo**2)*theta_o*J1X*Rsh)/(Ro*X)\n",
+ "\n",
+ "#Results\n",
+ "print \"Electron velocity =\",round((vo/1E+6),2),\"*10**6 m/sec\"\n",
+ "print \"dc transit time of electrons =\",round((To/1E-8),3),\"*10**-8 sec\"\n",
+ "print \"Maximum input voltage =\",round(V1_max,3),\"V\"\n",
+ "print \"Volatge gain =\",round(Av,3),\"V\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Electron velocity = 17.79 *10**6 m/sec\n",
+ "dc transit time of electrons = 0.225 *10**-8 sec\n",
+ "Maximum input voltage = 41.923 V\n",
+ "Volatge gain = 23.278 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 86
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.5, Page number 339"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''\n",
+ "a)Find the input microwave voltage V1 in order to generate maximum output voltage\n",
+ "b)Determine the voltage gain (reflecting beam loading in the output cavity)\n",
+ "c)Calculate the efficiency of the amplifier neglecting beam loading\n",
+ "d)Compute the beam loading conductance and show that one may neglect it in the preceeding calculations'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "Vo = 1200. #beam voltage(V)\n",
+ "Io = 28*10**-3 #beam current(A)\n",
+ "f = 8*10**9 #frequency(Hz)\n",
+ "d = 1*10**-3 #gap spacing in either cavity(m)\n",
+ "L = 4.*10**-2 #spacing between centers of cavities(m)\n",
+ "Rsh = 40*10**3 #effective shunt impedance(Ohms)\n",
+ "J1X = 0.582\n",
+ "X = 1.841\n",
+ "Go = 23.3*10**-6\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "vo = 0.593*10**6*math.sqrt(Vo)\n",
+ "w = 2*math.pi*f\n",
+ "theta_o = (w*L)/vo\n",
+ "theta_g = (w*d)/vo\n",
+ "Bo = math.sin(theta_g/2)/(theta_g/2)\n",
+ "V1_max = (Vo*3.68)/(Bo*theta_o)\n",
+ "\n",
+ "#Part b\n",
+ "Ro = Vo/Io\n",
+ "Av = ((Bo**2)*theta_o*J1X*Rsh)/(Ro*X)\n",
+ "\n",
+ "#Part c\n",
+ "V2 = 2*Io*J1X*Bo*Rsh\n",
+ "N = ((0.58*V2)/Vo)*100\n",
+ "\n",
+ "#Part d\n",
+ "Gb = (Go*((Bo**2)-(Bo*math.cos(theta_g))))/2\n",
+ "Rb = 1/Gb\n",
+ "\n",
+ "#Results\n",
+ "print \"The input microwave voltage V1 in order to generate maximum output voltage is\",round(V1_max,2),\"V\"\n",
+ "print \"The voltage gain (reflecting beam loading in the output cavity) is\",round(Av,3)\n",
+ "print \"The efficiency of the amplifier neglecting beam loading is\",round(N,3),\"%\" \n",
+ "print \"The beam loading conductance is\",round((Rb/1E+3),2),\"K Ohms (Calculation mistake in the textbook)\"\n",
+ "print \"The value of\",round((Rb/1E+3),2),\"K Ohms is very much comparable to Rsh and cannot be neglected because theta_g is quite high\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The input microwave voltage V1 in order to generate maximum output voltage is 58.71 V\n",
+ "The voltage gain (reflecting beam loading in the output cavity) is 17.058\n",
+ "The efficiency of the amplifier neglecting beam loading is 48.427 %\n",
+ "The beam loading conductance is 72.68 K Ohms (Calculation mistake in the textbook)\n",
+ "The value of 72.68 K Ohms is very much comparable to Rsh and cannot be neglected because theta_g is quite high\n"
+ ]
+ }
+ ],
+ "prompt_number": 111
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.6, Page number 341"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''\n",
+ "a)Find the value of repeller voltage Vr\n",
+ "b)Find the dc necesaary to give the microwave gap of voltage of 200V\n",
+ "c)Calculate the elctron efficiency'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "Vo = 500. #beam voltage(V)\n",
+ "Rsh = 20*10**3 #effective shunt impedance(Ohms)\n",
+ "f = 8*10**9 #frequency(Hz)\n",
+ "L = 1.*10**-3 #spacing between centers of cavities(m)\n",
+ "n = 2\n",
+ "e_m = 1.759*10**11\n",
+ "V1 = 200\n",
+ "J1X = 0.582\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "w = 2*math.pi*f\n",
+ "x = (e_m*((2*math.pi*n)-(math.pi/2))**2)/(8*(w**2)*(L**2))\n",
+ "y = math.sqrt(Vo/x)\n",
+ "Vr = y+Vo\n",
+ "\n",
+ "#Part b\n",
+ "Bo = 1 #Assumption\n",
+ "Io = V1/(2*J1X*Rsh)\n",
+ "\n",
+ "#Part c\n",
+ "vo = 0.593*10**6*math.sqrt(Vo)\n",
+ "theta_o = (w*2*L*vo)/(e_m*(Vr+Vo))\n",
+ "Bi = 1 #Assumption\n",
+ "X_dash = (V1*theta_o)/(2*Vo)\n",
+ "X = 1.51 #from graph\n",
+ "J1X = 0.84\n",
+ "N = ((2*J1X)/((2*math.pi*n)-(math.pi/2)))*100\n",
+ "\n",
+ "#Results\n",
+ "print \"The value of repeller voltage is\",round(Vr,2),\"V (Calculation mistake in the textbook)\"\n",
+ "print \"The dc necesaary to give the microwave gap of voltage of 200V is\",round((Io/1E-3),2),\"mA\"\n",
+ "print \"The elctron efficiency is\", round(N,2),\"%\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of repeller voltage is 1189.36 V (Calculation mistake in the textbook)\n",
+ "The dc necesaary to give the microwave gap of voltage of 200V is 8.59 mA\n",
+ "The elctron efficiency is 15.28 %\n"
+ ]
+ }
+ ],
+ "prompt_number": 41
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.7, Page number 342"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''\n",
+ "a)Determine the efficiency of the reflex klystron\n",
+ "b)Find the total power output in mW\n",
+ "c)If 20% of the power delivered by the elctron beam is dissipated in the cavity walls find the power delivered to the load'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "n = 1 #no. of modes\n",
+ "Pdc = 40*10**-3 #input power(W)\n",
+ "V1_Vo = 0.278 #ratio\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "N = (V1_Vo*3*math.pi)/4\n",
+ "\n",
+ "#Part b \n",
+ "Pout = (8.91*Pdc)/100\n",
+ "\n",
+ "#Part c\n",
+ "Pl = (Pout*80)/100\n",
+ "\n",
+ "#Results\n",
+ "print \"The efficiency of the reflex klystron is\",round(N,3)\n",
+ "print \"The total power output is\",round((Pout/1E-3),2),\"W\"\n",
+ "print \"The power delivered to the load is\",round((Pl/1E-3),2),\"W\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " The efficiency of the reflex klystron is 0.655\n",
+ "The total power output is 3.56 W\n",
+ "The power delivered to the load is 2.85 W\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.8, Page number 343"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Determine -\n",
+ "a)Hull cut-off voltage\n",
+ "b)Cut-off magnetic flux density\n",
+ "c)Cyclotron frequency'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "a = 0.15 #inner raddius(m)\n",
+ "b = 0.45 #outer radius(m)\n",
+ "Bo = 1.2*10**-3 #magnetic flux density(Wb/m^2)\n",
+ "Vo = 6000. #beam voltage(V)\n",
+ "e = 1.759*10**11\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "V = (e*Bo*(b**2)*(1-(a**2/b**2))**2)/8\n",
+ "\n",
+ "#Part b\n",
+ "Bc = math.sqrt(8*Vo)/(e**2)*b*(1-(a**2/b**2))**2\n",
+ "\n",
+ "#Part c\n",
+ "wc = (e*Bo)/(math.pi*2)\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print \"Please note that here are calculation errors in this problem. Hence, the difference in answers\\n\"\n",
+ "print \"Hull cut-off voltage =\",round((V/1E+3),2),\"kV\"\n",
+ "print \"Cut-off magnetic flux density =\",((Bc/1E-3)),\"mwb/m^2\"\n",
+ "print \"Cyclotron frequency =\",round(wc,2),\"Hz\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Please note that here are calculation errors in this problem. Hence, the difference in answers\n",
+ "\n",
+ "Hull cut-off voltage = 4221.6 kV\n",
+ "Cut-off magnetic flux density = 2.51765610822e-18 mwb/m^2\n",
+ "Cyclotron frequency = 33594425.39 Hz\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.9, Page number 343"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Calculate axial phase velocity and the anode voltage'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "d = 2*10**-3 #diameter of helical TWT(m)\n",
+ "n = 50. #no. of turns per cm\n",
+ "v = 3*10**8 #velocity of light(m/s)\n",
+ "m = 9.1*10**-31 #mass of electron\n",
+ "e = 1.6*10**-19 #charge on electron\n",
+ "\n",
+ "#Calculations\n",
+ "p = 1/n*10**-2 #pitch(m)\n",
+ "c = math.pi*d #circumference(m)\n",
+ "Vp = (v*p)/c \n",
+ "\n",
+ "Vo = (m*(Vp**2))/(2*e)\n",
+ "\n",
+ "#Results\n",
+ "print \"Axial phase velociity =\",round(Vp,2),\"m/sec\"\n",
+ "print \"Anode voltage =\",round(Vo,2),\"V(Calculation mistake in the textbook)\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Axial phase velociity = 9549296.59 m/sec\n",
+ "Anode voltage = 259.32 V(Calculation mistake in the textbook)\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.10, Page number 344"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Determine -\n",
+ "a)electron velocity\n",
+ "b)dc electronic transit time\n",
+ "c)input voltage for maximum output voltage\n",
+ "d)voltage gain in decibles'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "Vo = 900 #beam voltage(V)\n",
+ "Io = 30.*10**-3 #beam current(A)\n",
+ "f = 8.*10**9 #frequency(Hz)\n",
+ "d = 1.*10**-3 #gap spacing in either cavity(m)\n",
+ "L = 4.*10**-2 #spacing between centres of cavity(m)\n",
+ "Rsh = 40.*10**3 #effective shunt impedance(Ohms)\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "vo = 0.593*10**6*math.sqrt(Vo)\n",
+ "\n",
+ "#Part b\n",
+ "Tt = d/vo\n",
+ "\n",
+ "#Part c\n",
+ "w = 2*math.pi*f\n",
+ "theta_g = (w*d)/vo\n",
+ "Bo = math.sin(theta_g/2)/(theta_g/2) #Beam coupling coefficient\n",
+ "theta_o = (w*L)/vo #dc transit angle\n",
+ "#For maximum o/p volltage,\n",
+ "J1X = 0.582\n",
+ "X = 1.841\n",
+ "V1max = (2*Vo*X)/(Bo*theta_o)\n",
+ "\n",
+ "#Part d\n",
+ "Av = (Bo**2*theta_o*J1X*Rsh)/(Io*X)\n",
+ "\n",
+ "#Results\n",
+ "print \"dc electron velocity =\",round((vo/1E+7),1),\"*10**7 m/sec\"\n",
+ "print \"Transit time =\",round((Tt/1E-10),2),\"*10^-10 s\"\n",
+ "print \"Input voltage for maximum output voltage =\",round(V1max,2),\"V\"\n",
+ "print \"Voltage gain =\",round((Av/1E+6),2),\"dB\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "dc electron velocity = 1.8 *10**7 m/sec\n",
+ "Transit time = 0.56 *10^-10 s\n",
+ "Input voltage for maximum output voltage = 41.95 V\n",
+ "Voltage gain = 23.28 dB\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.11, Page number 345"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Determine -\n",
+ "a)dc electron velocity\n",
+ "b)dc phase constant\n",
+ "c)plasma frequency\n",
+ "d)reduced plasma frequency\n",
+ "e)beam current density\n",
+ "f)instantaneous bean current density'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "Vo = 20*10**3 #beam voltage(V)\n",
+ "Io = 2 #beam current(A)\n",
+ "f = 9*10**9 #frequency(Hz)\n",
+ "rho_o = 10**-6 #dc electron charge density(c/m^3)\n",
+ "rho = 10**-8 #RF charge density(c/m^3)\n",
+ "V = 10**5 #velocity perturbations(m/s)\n",
+ "eo = 8.854*10**-12\n",
+ "R = 0.5\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "vo = 0.59*10**6*math.sqrt(Vo)\n",
+ "\n",
+ "#Part b\n",
+ "w = 2.*math.pi*f\n",
+ "ip = w/vo #dc phase current\n",
+ "\n",
+ "#Part c\n",
+ "wp = math.sqrt((1.759*10**11*rho_o)/eo)\n",
+ "\n",
+ "#Part d\n",
+ "wq = R*wp\n",
+ "\n",
+ "#Part e\n",
+ "Jo = rho_o * vo\n",
+ "\n",
+ "#Part f\n",
+ "J = rho*vo-rho_o*V\n",
+ "\n",
+ "#Results\n",
+ "print \"dc electron velocity =\",round((vo/1E+7),3),\"*10**7 m/sec\"\n",
+ "print \"dc phase constant =\",round(ip,2),\"rad/sec (Calculation mistake in the textbook)\"\n",
+ "print \"plasma frequency =\",round((wp/1E+8),2),\"*10**8 rad/sec\"\n",
+ "print \"Reduced plasma frequency =\",round((wq/1E+8),3),\"*10**8 rad/sec\"\n",
+ "print \"dc beam current density =\",round(Jo,2), \"A/m^2\"\n",
+ "print \"instantaeneous beam current density =\",round(J,2),\"A/m^2\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "dc electron velocity = 8.344 *10**7 m/sec\n",
+ "dc phase constant = 677.73 rad/sec (Calculation mistake in the textbook)\n",
+ "plasma frequency = 1.41 *10**8 rad/sec\n",
+ "Reduced plasma frequency = 0.705 *10**8 rad/sec\n",
+ "dc beam current density = 83.44 A/m^2\n",
+ "instantaeneous beam current density = 0.73 A/m^2\n"
+ ]
+ }
+ ],
+ "prompt_number": 71
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.12, Page number 345"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Calclate the gap transit angle and optimum length of drift region'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "f = 5*10**9 #frequency(Hz)\n",
+ "Vo = 1000 #operating voltage(V)\n",
+ "n = 1.75 #no. of turns\n",
+ "Vr = -500 #repeller voltage(V)\n",
+ "d = 2*10**-3 #cavity gap(m)\n",
+ "\n",
+ "#Calculations\n",
+ "w = 2*math.pi*f\n",
+ "uo = 5.93*10**5*math.sqrt(Vo)\n",
+ "theta_g = (w*d)/uo\n",
+ "\n",
+ "#Results\n",
+ "print \"Transit angle =\",round(theta_g,2),\"radians\"\n",
+ "print \"\\nThe length of drift region cannot be computed as the value of F is not given\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Transit angle = 3.35 radians\n",
+ "\n",
+ "The length of drift region cannot be computed as the value of F is not given\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.13, Page number 346"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Calculate -\n",
+ "a)input RF voltage\n",
+ "b)voltage gain\n",
+ "c)efficiency'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "f = 10*10**9 #frequency(Hz)\n",
+ "Vo = 1200 #beam voltage(V)\n",
+ "Io = 30*10**-3 #beam current(A)\n",
+ "d = 1*10**-3 #diameter(m)\n",
+ "Rsh = 40*10**3 #shunt resistance(Ohms)\n",
+ "L = 4*10**-2 #length(m)\n",
+ "X = 1.84\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "vo = 0.59*10**6*math.sqrt(Vo)\n",
+ "w = 2*math.pi*f\n",
+ "theta_o = (w*L)/vo\n",
+ "V1 = (2*X*Vo)/theta_o\n",
+ "theta_g = (theta_o*d)/L\n",
+ "Bi = (math.sin(theta_g/2))/(theta_g/2)\n",
+ "V1max = V1/Bi\n",
+ "\n",
+ "#Part b\n",
+ "J1X = 0.58 #from table\n",
+ "I2 = 2*Io*J1X\n",
+ "V2 = Bi*I2*Rsh\n",
+ "A = V2/V1\n",
+ "Av = 20*math.log10(A)\n",
+ "\n",
+ "#Part c\n",
+ "N = ((0.58*V2)/Vo)*100\n",
+ "\n",
+ "#Results\n",
+ "print \"Input RF voltage is\",round(V1max,2),\"V\" \n",
+ "print \"Voltage gain is\",round(Av,2),\"dB\"\n",
+ "print \"efficiency is\",round(N,2),\"%\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input RF voltage is 55.23 V\n",
+ "Voltage gain is 28.03 dB\n",
+ "efficiency is 43.75 %\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.14, Page number 347"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Calculate -\n",
+ "a)cyclotron angular frequency\n",
+ "b)Hull cut-off voltage\n",
+ "c)cut-off magnetic flux density'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "Vo = 30*10**3 #beam voltage(V)\n",
+ "Io = 80 #beam current(A)\n",
+ "Bo = 0.01 #Wb/m**2\n",
+ "a = 4*10**-2 #length of magnetron(m)\n",
+ "b = 8*10**-2 #breadth of magnetron(m)\n",
+ "e = 1.6*10**-19 #charge on electron(C)\n",
+ "m = 9.1*10**-31 #mass of electron\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "w = (e*Bo)/m\n",
+ "\n",
+ "#Part b\n",
+ "Vhc = (e*(Bo**2)*(b**2)*((1-((a/b)**2))**2))/(8*m)\n",
+ "\n",
+ "#PArt c\n",
+ "Bc = ((8*Vo*(m/e))**0.5)/(b*(1-((a/b)**2)))\n",
+ "\n",
+ "#Results\n",
+ "print \"Cyclotron angular frequency =\",round((w/1E+9),3),\"*10**9 rad/s\"\n",
+ "print \"Hull cut-off voltage =\",round((Vhc/1E+3),3),\"kV\"\n",
+ "print \"Cut-off magnetic flux density =\",round((Bc/1E-3),3),\"mWb/m**2\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Cyclotron angular frequency = 1.758 *10**9 rad/s\n",
+ "Hull cut-off voltage = 7.912 kV\n",
+ "Cut-off magnetic flux density = 19.472 mWb/m**2\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.15, Page number 348"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Determine - \n",
+ "a)input power\n",
+ "b)output power\n",
+ "c)efficiency'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "n = 2 #mode\n",
+ "Vo = 280 #beam volatge(V)\n",
+ "Io = 22*10**-3 #beam current(A)\n",
+ "V1 = 30 #signal voltage(V)\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "Pdc = Vo*Io\n",
+ "\n",
+ "#Part b\n",
+ "J1X = 1.25 #from table\n",
+ "Pac = (2*Pdc*J1X)/((2*n*math.pi)-(math.pi/2))\n",
+ "\n",
+ "#Part c\n",
+ "N = (Pac/Pdc)*100\n",
+ "\n",
+ "#Results\n",
+ "print \"Input power =\",round(Pdc,2),\"W\"\n",
+ "print \"Output power =\",round(Pac,2),\"W\"\n",
+ "print \"Efficiency =\",round(N,2),\"%\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input power = 6.16 W\n",
+ "Output power = 1.4 W\n",
+ "Efficiency = 22.74 %\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.16, Page number 348"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "'''Find -\n",
+ "a)repeller voltage\n",
+ "b)beam current'''\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "f = 8*10**9 #frequency(Hz)\n",
+ "Vo = 300 #beam voltage(V)\n",
+ "Rsh = 20*10**3 #shunt resistance(Ohms)\n",
+ "L = 1*10**-3 #length(m)\n",
+ "V1 = 200 #gap voltage(V)\n",
+ "e_m = 1.759*10**11\n",
+ "n = 2 #mode\n",
+ "\n",
+ "#Calculations\n",
+ "#Part a\n",
+ "w = 2*math.pi*f\n",
+ "x = (e_m*((2*math.pi*n)-(math.pi/2))**2)/(8*(w**2)*(L**2))\n",
+ "y = math.sqrt(Vo/x)\n",
+ "Vr = y+Vo\n",
+ "\n",
+ "#Part b\n",
+ "Bo = 1 #assumption\n",
+ "J1X = 0.582 #from table\n",
+ "Io = V1/(2*J1X*Rsh)\n",
+ "\n",
+ "#Results\n",
+ "print \"Repeller voltage =\",round(Vr,3),\"V\"\n",
+ "print \"Beam current =\",round((Io/1E-3),2),\"mA\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Repeller voltage = 833.98 V\n",
+ "Beam current = 8.59 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 37
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file