diff options
Diffstat (limited to 'sample_notebooks/NarasimhaMamidala/NarasimhaMamidala_version_backup/Chapter_4_BJT.ipynb')
-rwxr-xr-x | sample_notebooks/NarasimhaMamidala/NarasimhaMamidala_version_backup/Chapter_4_BJT.ipynb | 544 |
1 files changed, 544 insertions, 0 deletions
diff --git a/sample_notebooks/NarasimhaMamidala/NarasimhaMamidala_version_backup/Chapter_4_BJT.ipynb b/sample_notebooks/NarasimhaMamidala/NarasimhaMamidala_version_backup/Chapter_4_BJT.ipynb new file mode 100755 index 00000000..c7db6367 --- /dev/null +++ b/sample_notebooks/NarasimhaMamidala/NarasimhaMamidala_version_backup/Chapter_4_BJT.ipynb @@ -0,0 +1,544 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 4 BJT Fundamentals" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−1 in page 208" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "(a)The value of the Base Current is 3.85e-04 A\n", + "\n", + "(b)The value of the Collector Current is 3.615e-03 A \n", + "\n" + ] + } + ], + "source": [ + "#Calculate Base and Collector Currents\n", + "# Given Data\n", + "alpha=0.90; # Current Gain in CB mode\n", + "Ico=15*10**-6; # Reverse saturation Current in micro−A\n", + "Ie=4*10**-3; # Emitter Current in mA\n", + "# Calculations\n", + "Ic=Ico+(alpha*Ie);\n", + "Ib=Ie-Ic;\n", + "print \"(a)The value of the Base Current is %0.2e A\\n\" %Ib;\n", + "print \"(b)The value of the Collector Current is %0 .3e A \\n\" %Ic" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−2 in page 209" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "(a)The Current gain alpha for BJT is 0.989 \n", + "\n", + "(b)The value of the base Current is 4.44e-05 A\n", + "\n", + "(c)The value of the Emitter Current is 4.04e-03 A \n", + "\n" + ] + } + ], + "source": [ + "#Calculate alpha using beta\n", + "# Given Data\n", + "\n", + "beta_bjt=90.; # beta gain for the BJT\n", + "Ic=4*10**-3; # Collector Current in mA\n", + "# Calculations\n", + "alpha=beta_bjt/(1.+beta_bjt);\n", + "Ib=Ic/beta_bjt;\n", + "Ie=Ic+Ib;\n", + "print \"(a)The Current gain alpha for BJT is %0.3f \\n\"%alpha\n", + "print \"(b)The value of the base Current is %0.2e A\\n\"%Ib\n", + "print \"(c)The value of the Emitter Current is %0.2e A \\n\"%Ie" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−3 in page 20" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "(a)The value of Current gain beta for BJT is 9 \n", + "\n", + "(b)The value of the Collector Current is 4.65e-03 A \n", + "\n" + ] + } + ], + "source": [ + "#Collector Current in C E mode\n", + "# Given Data\n", + "alpha=0.90; # Current Gain of BJT\n", + "Ico=15*10**-6; # Reverse Saturation Current of BJT in micro−A\n", + "Ib=0.5*10**-3; # Base Current in C−E mode in mA\n", + "# Calculations\n", + "beta_bjt=alpha/(1-alpha);\n", + "Ic=(beta_bjt*Ib)+(beta_bjt+1)*Ico;\n", + "print \"(a)The value of Current gain beta for BJT is %0.0f \\n\"%beta_bjt\n", + "print \"(b)The value of the Collector Current is %0.2e A \\n\"%Ic" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−4 in page 20" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The Current gain beta for the Device is 250 \n", + "\n" + ] + } + ], + "source": [ + "#Calculate beta for the BJT\n", + "Ib=20*10**-6; # Base current in micro−A\n", + "Ic=5*10**-3; # Collector Current in mA\n", + "# Calculations\n", + "beta_bjt=Ic/Ib;\n", + "print \"The Current gain beta for the Device is %0.0f \\n\"%beta_bjt;\n", + "# The Current Gain beta for the Device is 250" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−5 in page 209" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "(a)The value of the Emitter Current is 5.05e-03A \n", + "\n", + "(b)The value of beta gain of the BJT is 100 \n", + "\n", + "(c)The value of alpha gain of the BJT is 0.990 \n", + "\n" + ] + } + ], + "source": [ + "#To Compute Alpha Beta and Emitter Current\n", + "# Given Data\n", + "Ib=50*10**-6; # Base Current in mu−A\n", + "Ic=5*10**-3; # Collector Current in mA\n", + "# Calculations\n", + "Ie=Ic+Ib;\n", + "beta_bjt=Ic/Ib;\n", + "alpha=Ic/Ie;\n", + "print \"(a)The value of the Emitter Current is %0.2eA \\n\"%Ie\n", + "print \"(b)The value of beta gain of the BJT is %0.0f \\n\"%beta_bjt\n", + "print \"(c)The value of alpha gain of the BJT is %0.3f \\n\"%alpha" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−6 in page 210" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The value of inverse beta of the BJT is 1 \n", + "\n", + "The value of inverse alpha of the BJT is 2 \n", + "\n" + ] + } + ], + "source": [ + "#Calculate alpha reverse and beta reverse\n", + "# Given Data\n", + "Ie=10.*10**-3; # Emitter Current in mA\n", + "Ib=5*10**-3; # Base Current in mu−A\n", + "# Calculations\n", + "Ic=Ie-Ib;\n", + "beta_reverse=Ib/Ic;\n", + "alpha_reverse=Ie/Ic;\n", + "print \"The value of inverse beta of the BJT is %0.0f \\n\"%beta_reverse\n", + "print \"The value of inverse alpha of the BJT is %0.0f \\n\"%alpha_reverse" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−7 in page 210" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Circuit 1:\n", + "(a)Emitter Current=9.30e-04 A\n", + "(b)Base Current=9.21e-06 A\n", + "(c)Collector Voltage=0.792 V\n", + "\n", + "\n", + "Circuit 2:\n", + "(a)Emitter Current=1.86e-03 A\n", + "(b) Collector Current=1.842e-03 A\n", + "(c)Collector Voltage=-5.700 V\n", + "\n" + ] + } + ], + "source": [ + "# Calculate Labeled Currents and Voltages\n", + "# Given Data\n", + "beta_bjt=100.; # beta gain of BJT\n", + "Vbe=0.7; # Base−Emitter voltage of BJT in V\n", + "#Calculation\n", + "Vcc1=10.;\n", + "Vee1=-10.;\n", + "Ve1=-0.7;\n", + "R1=10*10**3;\n", + "Ie1=(Vcc1-Vbe)/R1;\n", + "Ib1=Ie1/(beta_bjt+1);\n", + "Vc1=Vcc1-R1*(Ie1-Ib1);\n", + "Vcc2=10.;\n", + "Vee2=-15.;\n", + "Ve2=-0.7;\n", + "R2 =5*10**3;\n", + "Ie2=(Vcc2-Vbe)/R2;\n", + "Ic2=(beta_bjt/(beta_bjt+1.))*Ie2;\n", + "Vc2=Vee2+R2*(Ie2);\n", + "print \"Circuit 1:\\n(a)Emitter Current=%0.2e A\\n(b)Base Current=%0.2e A\\n(c)Collector Voltage=%0.3f V\\n\\n\"%(Ie1,Ib1,Vc1);\n", + "print \"Circuit 2:\\n(a)Emitter Current=%0.2e A\\n(b) Collector Current=%0.3e A\\n(c)Collector Voltage=%0.3f V\\n\"%(Ie2,Ic2,Vc2);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−8 in page 211" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Circuit 1:\n", + "(a)Base Voltage = 0.0 V\n", + "(b)Emitter Voltage = -0.7 V\n", + "\n", + "Circuit 2:\n", + "(a)Emitter Voltage = 0.7 V\n", + "(b) Collector Voltage = -5.7 V\n", + "\n" + ] + } + ], + "source": [ + "#Calculate labeled Voltages\n", + "# Given Data\n", + "Vbe=0.7; # Base−Emitter voltage of BJT in V\n", + "Vcc2=10; # DC voltage across Collector in V\n", + "Vee2=-15; # DC voltage across Emitter in V\n", + "Rc2=5*10**3; # Collector Resistance in K−ohms\n", + "# Beta Current Gain of BJT is Infinity\n", + "# Calculations\n", + "Vb1=0;\n", + "Ve1=-0.7;\n", + "Ve2=0.7;\n", + "Vc2=Vee2+Rc2*((Vcc2-Vbe)/Rc2);\n", + "print \"Circuit 1:\\n(a)Base Voltage = %0.1f V\\n(b)Emitter Voltage = %0.1f V\\n\"%(Vb1,Ve1);\n", + "print \"Circuit 2:\\n(a)Emitter Voltage = %0.1f V\\n(b) Collector Voltage = %0.1f V\\n\"%(Ve2,Vc2);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−9 in page 211" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Circuit Parameters:\n", + "(a)Base Voltage = 0.300V\n", + "(b)Base Current = 1.500e-05 A\n", + "(c)Emitter Current= 8.000e-04 A\n", + "(d)Collector Current = 7.850e-04 A\n", + "(e) Collector Voltage = -1.075 V\n", + "(f) beta gain = 52.333\n", + "(g)alpha gain = 0.981\n", + "\n" + ] + } + ], + "source": [ + "#Calculating BJT parameters assuming Vbe\n", + "# Given Data\n", + "Ve=1.; # Emitter Voltage of BJT in V\n", + "Vbe=0.7; # Base−Emitter Voltage of BJT in V\n", + "Rb=20*10**3; # Base Resistance of Circuit in K−ohms\n", + "Rc=5*10**3; # Collector Resistance of Circuit in K−ohms\n", + "Re=5*10**3; # Emitter Resistance of Circuit in K−ohms\n", + "Vcc=5.; # DC voltage across Collector in V\n", + "Vee=-5; # DC voltage across Emitter in V\n", + "# Calculations\n", + "Vb=Ve-Vbe;\n", + "Ib=Vb/Rb;\n", + "Ie=(Vcc -1)/Re;\n", + "Ic=Ie-Ib;\n", + "Vc=(Rc*Ic)-Vcc;\n", + "beta_bjt=Ic/Ib;\n", + "alpha=Ic/Ie;\n", + "print \"Circuit Parameters:\\n(a)Base Voltage = %0.3fV\\n(b)Base Current = %0.3e A\\n(c)Emitter Current= %0.3e A\\n(d)Collector Current = %0.3e A\\n(e) Collector Voltage = %0.3f V\\n(f) beta gain = %0.3f\\n(g)alpha gain = %0.3f\\n\"%(Vb,Ib,Ie,Ic,Vc, beta_bjt ,alpha);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−10 in page 211" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "(a)Change in Emitter voltage is +0.40 V\n", + "\n", + "(b)Change in Collector Voltage is 0.00 V\n", + "\n" + ] + } + ], + "source": [ + "# Measurement of Circuit Voltage changes\n", + "# Given Data\n", + "Vb=-5; # Base Voltage of BJT in V\n", + "Rc=1*10**3; # Collector Resistance in K−ohms\n", + "Ie=2*10**-3; # Emitter Current of BJT in mA\n", + "delB=+0.4; # Change in Base Voltage\n", + "# Calculations\n", + "delE =+0.4;\n", + "delC=0;\n", + "print \"(a)Change in Emitter voltage is +%0.2f V\\n\"%delE\n", + "print \"(b)Change in Collector Voltage is %0.2f V\\n\"%delC" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4−11 in page 212" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Assume active mode for circuit 1\n", + "(a)Ve = 1.30 V\n", + "(b)Ic = 0.00e+00 A\n", + "(c)Ve = 3.03 V\n", + "\n", + "Thus the circuit operates in an active mode\n", + "\n", + "\n", + "For circuit 2,assume active mode\n", + "\n", + "(a)Ve = 1.7 V\n", + "(b)Ie = 4.30e-04 A\n", + "(c)Vc = 4.30 V\n", + "\n", + "This circuit operates in a saturated mode\n", + "\n", + "\n", + "For circuit 3,assume active mode\n", + "\n", + "(a)Ve = -4.3 V\n", + "(b)Ie = 6.9000e-05 A\n", + "(c)Ic = 0.000e+00 A\n", + "(d)Vc = -40.2 V\n", + "\n", + "The circuit operates in an active mode\n", + "\n", + "\n", + "For circuit 4,assume active mode\n", + "\n", + "(a)Ie = 1.86e-03 A\n", + "(b)Vc = -10.00 V\n", + "\n", + "The circuit operates in an active mode\n" + ] + } + ], + "source": [ + "# Determine mode of operation of BJT\n", + "# Given Data\n", + "Vbe=0.7; # Base−Emitter Voltage in V\n", + "beta_bjt=100; # beta gain of BJ\n", + "# Calculation\n", + "print \"Assume active mode for circuit 1\"\n", + "Vb1=2;\n", + "Ve_1=Vb1-Vbe;\n", + "Ie1 =1*10** -3;\n", + "Ic1=Ie1*(beta_bjt/(1+beta_bjt));\n", + "Ve1=6-(3*0.99);\n", + "print \"(a)Ve = %0.2f V\\n(b)Ic = %0.2e A\\n(c)Ve = %0.2f V\\n\"%(Ve_1,Ic1,Ve1);\n", + "print \"Thus the circuit operates in an active mode\\n\\n\"\n", + "print \"For circuit 2,assume active mode\\n\"\n", + "Vcc=1;\n", + "Ve2=Vcc+Vbe;\n", + "Ie2=(6-Ve2)/(10*10**3);\n", + "Vc=0+(10*0.43);\n", + "print \"(a)Ve = %0.1f V\\n(b)Ie = %0.2e A\\n(c)Vc = %0.2f V\\n\"%(Ve2,Ie2,Vc);\n", + "print \"This circuit operates in a saturated mode\\n\\n\"\n", + "print \"For circuit 3,assume active mode\\n\"\n", + "Ve3=-5+Vbe;\n", + "Ie3=(9.5-Ve3)/(200*10**3);\n", + "Ic=Ie3*(beta_bjt/(1+beta_bjt));\n", + "Vc3=-50+(0.492*20);\n", + "print \"(a)Ve = %0.1f V\\n(b)Ie = %0.4e A\\n(c)Ic = %0.3e A\\n(d)Vc = %0.1f V\\n\"%(Ve3,Ie3,Ic,Vc3);\n", + "print \"The circuit operates in an active mode\\n\\n\"\n", + "print \"For circuit 4,assume active mode\\n\"\n", + "Ve4 = -20.7;\n", + "Ie4=(30+Ve4)/(5*10**3);\n", + "Vc4=(-Ie4*(beta_bjt/(1+beta_bjt))*(2*10**3))-10;\n", + "print \"(a)Ie = %0.2e A\\n(b)Vc = %0.2f V\\n\"%(Ie4,Vc4)\n", + "print \"The circuit operates in an active mode\"" + ] + } + ], + "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.10" + } + }, + "nbformat": 4, + "nbformat_minor": 0 +} |