{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Chapter 5: Discrete Linear Power Amplifier" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.1,Page 215" ] }, { "cell_type": "code", "execution_count": 1, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Id=0 from 0 to 2 so not shown in the graph\n" ] }, { "data": { "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYYAAAEZCAYAAACTsIJzAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3Xl4U2Xax/FvW4ogi7K8uIGgiAOIIqKC4EBxFxcUURRE\nQAUGcccNx4UZfd/RUWdwRFFBEBQQFWVEQFywbiOiwyKyuLAJio6gIoso0Lx/3KfTENP2pM3Jc5L8\nPteVi+TkNLmtp7nzPPezgIiIiIiIiIiIiIiIiIiIiIiIiIiIiIgkUROgCMh1HIdIKOkPQzLVauBE\nR+99IbAqzvEqwH+ArqkNRyQxSgySqSLezYUXgb2BzjHHTwN2Aa+kPCKRBCgxSDbIA+4HvgNWAGeU\nce7NwHMxxx70bgD9vNf4CVgJ9IrzGr8AzwKXxBy/BJiEdWMB3AR8DawDLveOH+w91xVY4r3POmBo\nGTGLiIgPq4ATvPt/AJYBBwB1gDexb+7xvhgdCGwFanqP87AP72OBGsAmoJn33D5Ay1Lev4N3bjXv\n8V7ANuAI7/FpwHqgBVAdeJrdE8N6oGPUz7Yp+z9XRETKE50Y5gADo547mbKLz+8AfaLO/cK7XwP4\nAeiOfZiX5zPgIu/+AGBB1HNjgf+NetyU3RPDGi/m2j7eRySp1JUk2WA/YG3U4y/LOX8SJR/ovYCJ\n3v2tQE+sBfI18DLwuzJeZwIl3Ul9vMelxbQu5mfPw7qTVgOFQPtyYhYRkXLEthgGRT1XXovhf7Bu\nnwOwFkK8D/89sLrF22XE0AT4FTgOqzs0iHoutsVwCLu3GIrlAddSfjITSRq1GCQbPAtcTUmN4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/4rRAR\nEQlQDe/felhdoEEZ5xYPV61axjnJdArwYIreS0REPG9iH/ZLgEt8nH8F0D/QiEo8iwrPIiIiIiIi\nIiIiIiIiIiIiIiIiIiIiknn+HwC9g+9EmLPsAAAAAElFTkSuQmCC\n", "text/plain": [ "" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "#finding Id vs Vgs\n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "%matplotlib inline\n", "import numpy as np\n", "import matplotlib.pyplot as plt\n", "Vth=3.6;\n", "Vgs=4;#voltage\n", "#volt change beyond 3.6 causes a major increase in Id as it is cut off voltage\n", "\n", "#result\n", "print('Id=0 from 0 to 2 so not shown in the graph')\n", "x=np.linspace(2,3.6,300);\n", "y=(-2.5*(x-3.6))**.5;\n", "plt.plot(x,y)\n", "plt.xlabel('Vgs(volts)');\n", "plt.ylabel('Id(amps)');\n", "plt.title('Id vs Vgs');\n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.2,Page 217" ] }, { "cell_type": "code", "execution_count": 1, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "drain current is 3.8 A\n", "Vth=4V is assumed\n" ] } ], "source": [ "#finding drain current\n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "V=4.5;#voltage\n", "T=25;#degreeC\n", "Id=3.8;\n", "\n", "#result\n", "print \"drain current is\",round(Id,2), \"A\"\n", "print('Vth=4V is assumed')" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.3,Page 219" ] }, { "cell_type": "code", "execution_count": 2, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "MOSFET is IRF530N\n", "lower limit of Vth is -4.0 V\n", "upper limit of Vth is -2.0 V\n", "current is 2.3 A\n" ] } ], "source": [ "#finding drain current of IRF530N\n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "Vgs=-5;#voltage\n", "Vthl=-4;\n", "Vthu=-2;\n", "Id=2.3;#current\n", "\n", "#result\n", "print('MOSFET is IRF530N')\n", "print \"lower limit of Vth is\",round(Vthl,2), \"V\"\n", "print \"upper limit of Vth is\",round(Vthu,2), \"V\"\n", "print \"current is\",round(Id,2), \"A\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example5.5,Page 225" ] }, { "cell_type": "code", "execution_count": 3, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "resistance is 1.51 kohm\n", "load voltage is 36.68 V\n", "Pq is 40.02 watt\n", "Ps is 82.0 watt\n", "Pl is 41.97 watt\n" ] } ], "source": [ "#finding Pq,Pl,Ps,resistance,load voltage\n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "R1=22.0;#resistance\n", "Vg=3.6;#voltage\n", "Vd=56.0;\n", "G=.98;#gain\n", "Vi=40.0;\n", "Rl=8.0;#load resistance\n", "Vp=36.5;\n", "\n", "#calculation\n", "Vr=Vd-Vg;\n", "Ir=Vr/R1;\n", "R2=Vg/Ir;\n", "Va=(R1/(R1+R2))*Vi;\n", "Vl=G*Va;\n", "Il=Vp/Rl;\n", "Pl=Vp*4.6/4;\n", "Ps=Vd*4.6/pi;\n", "Pq=Ps-Pl;\n", "\n", "#result\n", "print \"resistance is\",round(R2,2), \"kohm\"\n", "print \"load voltage is\",round(Vl,2), \"V\"\n", "print \"Pq is\",round(Pq,2), \"watt\"\n", "print \"Ps is\",round(Ps,2), \"watt\"\n", "print \"Pl is\",round(Pl,2), \"watt\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.6,Page 232" ] }, { "cell_type": "code", "execution_count": 4, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "current is 2.45 mA\n", "resistance2 is 814.815 ohm\n", "pick R2=R3=820ohm R1=R4=22 kohm\n" ] } ], "source": [ "#finding resistance and current \n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "R1=22.0;#resistance\n", "V1=56.0;#voltage\n", "V2=2.0;#voltage\n", "\n", "#calculation\n", "I=(V1-V2)/R1;\n", "R2=V2/I;\n", "\n", "#result\n", "print \"current is\",round(I,2), \"mA\"\n", "print \"resistance2 is\",round(R2*1000,3), \"ohm\"\n", "print('pick R2=R3=820ohm R1=R4=22 kohm')" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.7,Page 234" ] }, { "cell_type": "code", "execution_count": 5, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "load voltage is 10.01 V\n" ] } ], "source": [ "#finding load voltage \n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "Vi=350.0;#voltage\n", "f=100.0;#frequency\n", "Rf=10000.0;#resistance\n", "Ri=520.0;\n", "\n", "#calculation\n", "Vp=(1+(Rf/Ri))*Vi*2**.5;\n", "\n", "#result\n", "print \"load voltage is\",round(Vp/1000,2), \"V\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.8,Page 238" ] }, { "cell_type": "code", "execution_count": 6, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "load rms voltage is 20.0 V\n", "resistance is 54.04 kohm\n", "current is 1.18 mA\n", "load current is 4.41 A\n", "supply power is 39.3 watt\n", "load power is 38.9 W\n", "power is 19.552 W\n", "thermal resistance is 3.01 degreC/W\n" ] } ], "source": [ "#designing amplifier\n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "P=50.0;#power\n", "Z=4.7#impedence\n", "R=4.0;#resistance\n", "Ta=40.0;#degreeC\n", "Tj=140.0;#degreeC\n", "Vd=28.0;\n", "R2=22.0;\n", "\n", "#calculation\n", "Vr=(P*R)**.5;\n", "Vp=Vr*2**.5;\n", "Av=-Vr/1.23;\n", "Rf=-Av*Z;\n", "I=(Vd-2)/R2;\n", "Vm=.63*Vd;\n", "Ip=Vm/R;\n", "Ps=Vd*Ip/pi;\n", "Pl=Ip**2/2*R;\n", "Pq=round(Ps)-Pl/2;\n", "Qs=(Tj-Ta)/Pq-2.1;\n", "\n", "#result\n", "print \"load rms voltage is\",round(Vp,2), \"V\"\n", "print \"resistance is\",round(Rf,2), \"kohm\"\n", "print \"current is\",round(I,2), \"mA\"\n", "print \"load current is\",round(Ip,2), \"A\"\n", "print \"supply power is\",round(Ps,2), \"watt\"\n", "print \"load power is\",round(Pl,2), \"W\"\n", "print \"power is\",round(Pq,3), \"W\"\n", "print \"thermal resistance is\",round(Qs,2), \"degreC/W\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.9,Page 243" ] }, { "cell_type": "code", "execution_count": 7, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "output voltage is 129.37 mV\n", "load current is 32.34 mA\n" ] } ], "source": [ "#finding load current,output voltage \n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "Vi=7.5e-3;#voltage\n", "Ib=800e-9;#current\n", "R=53.9e3;#resistance\n", "\n", "#calculation\n", "Vo=11.5*Vi+Ib*R;\n", "Id=Vo/4;\n", "\n", "#result\n", "print \"output voltage is\",round(Vo*1000,2), \"mV\"\n", "print \"load current is\",round(Id*1000,2), \"mA\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.10,Page 249" ] }, { "cell_type": "code", "execution_count": 8, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "resistance is 0.31 ohm\n", "thus pick a .33ohm rsistance\n", "voltage is 0.55 V\n", "power is 0.23 W\n", "thermal resistance is 8.1 degreeC/W\n" ] } ], "source": [ "#finding resistance,voltage,power \n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "G=6.4;#A/V\n", "I=5.0;#current\n", "Pq=9.8;#W\n", "Tj=140.0;\n", "Ta=40.0;\n", "R1=.33;\n", "\n", "#calculation\n", "R=2/G;\n", "Im=I/3;\n", "Vr=Im*R1;\n", "P=Vr*Im/4;\n", "Qs=(Tj-Ta)/Pq-2.1;\n", "\n", "#result\n", "print \"resistance is\",round(R,2), \"ohm\"\n", "print('thus pick a .33ohm rsistance')\n", "print \"voltage is\",round(Vr,2), \"V\"\n", "print \"power is\",round(P,2), \"W\"\n", "print \"thermal resistance is\",round(Qs,2), \"degreeC/W\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.11,Page 251" ] }, { "cell_type": "code", "execution_count": 9, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "limit level current is 8.49 A\n" ] } ], "source": [ "#finding limit current \n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "P=200;#power\n", "R=8;#ohm\n", "\n", "#calculation\n", "Il=(P/R)**.5*2**.5;\n", "Ilm=1.2*Il;\n", "\n", "#result\n", "print \"limit level current is\",round(Ilm,2), \"A\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.12,Page 253" ] }, { "cell_type": "code", "execution_count": 10, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "resistance is 0.1 ohm\n", "power is 1.8 W\n", "MOSFET power is 84.0 W\n", "temperature is 468.4 degreeC\n" ] } ], "source": [ "#finding resistance,power,temperature \n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "I=6;#current\n", "V=.6;#voltage\n", "D=.5;#duty cycle\n", "T=40;#temperature\n", "\n", "#calculation\n", "Rs=V/I;\n", "Pr=D*V*I;\n", "Vp=28;\n", "Pm=D*Vp*I;\n", "Tj=T+Pm*5.1;\n", "\n", "#result\n", "print \"resistance is\",round(Rs,2), \"ohm\"\n", "print \"power is\",round(Pr,2), \"W\"\n", "print \"MOSFET power is\",round(Pm,2), \"W\"\n", "print \"temperature is\",round(Tj,2), \"degreeC\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.13,Page 255" ] }, { "cell_type": "code", "execution_count": 11, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "maximum safe temperature is 89.05 degreeC\n" ] } ], "source": [ "#finding maximum safe temperature \n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "T=130;#temperature\n", "P=19.5;#power\n", "\n", "#calculation\n", "Ts=T-P*2.1;\n", "\n", "#result\n", "print \"maximum safe temperature is\",round(Ts,2), \"degreeC\"" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Example 5.14,Page 257" ] }, { "cell_type": "code", "execution_count": 12, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "reactance is 8.86 ohm\n", "voltage across resistor is 10.03 V\n", "-48 is the angle of the voltage in degrees\n", "power dissipated by load is 12.5 watts\n", "current across the resistance is 1.77 A\n", "power supply is 15.8 W\n", "power dissipated by transistor is 9.55 watts\n" ] } ], "source": [ "#finding 3 powers and current across resistance\n", "\n", "#initialisation of variable\n", "from math import pi,tan,sqrt,sin,cos,acos,atan\n", "V=15.0;#voltage\n", "f=300.0;#frequency\n", "L=4.7;#inductance\n", "Vdc=28;#V\n", "Pr=12.5;\n", "\n", "#calculation\n", "Xl=2*pi*f*L;\n", "Zload=sqrt(8**2+8.9**2);#magnitude of Zload\n", "Vload=15.0;#msgnitude of Vload\n", "Vr=Vload*8/Zload;\n", "I=Vr/8*sqrt(2);\n", "Psupply=Vdc*I/pi;\n", "Pq=Psupply-Pr/2;\n", "\n", "#result\n", "print \"reactance is\",round(Xl/1000,2), \"ohm\"\n", "print \"voltage across resistor is\",round(Vr,2), \"V\"\n", "print \"-48 is the angle of the voltage in degrees\";\n", "print \"power dissipated by load is\",round(Pr,2), \"watts\"\n", "print \"current across the resistance is\",round(I,2), \"A\"\n", "print \"power supply is\",round(Psupply,2), \"W\"\n", "print \"power dissipated by transistor is\",round(Pq,2), \"watts\"" ] } ], "metadata": { "kernelspec": { "display_name": "Python 2", "language": "python", "name": "python2" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 2 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython2", "version": "2.7.6" } }, "nbformat": 4, "nbformat_minor": 0 }