summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter10_1.ipynb1297
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter11_1.ipynb1025
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter12_1.ipynb968
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter13_1.ipynb1147
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter14_1.ipynb502
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter15_1.ipynb482
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter16_1.ipynb936
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter17_1.ipynb877
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter18_1.ipynb815
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter19_1.ipynb1666
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter1_1.ipynb646
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter20_1.ipynb677
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter21_1.ipynb467
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter22_1.ipynb668
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter23_1.ipynb133
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter24_1.ipynb604
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter25_1.ipynb2552
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter26_1.ipynb472
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter2_1.ipynb125
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter6_1.ipynb1624
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter7_1.ipynb212
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter8_1.ipynb1851
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter9_1.ipynb1907
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter10_ac_load_line_1.pngbin0 -> 17473 bytes
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter18_clipping_ckt_output_1.pngbin0 -> 21213 bytes
-rw-r--r--Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter8_dc_load_line_1.pngbin0 -> 25388 bytes
-rw-r--r--Problems_in_Electrical_Engineering_by_Parker_Smith/Chapter1.ipynb3260
-rw-r--r--Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/VgnES.pngbin0 -> 77953 bytes
-rw-r--r--Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/f4att.pngbin0 -> 37338 bytes
-rw-r--r--Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/starNdelta.pngbin0 -> 57025 bytes
30 files changed, 24913 insertions, 0 deletions
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter10_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter10_1.ipynb
new file mode 100644
index 00000000..c0b0e702
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter10_1.ipynb
@@ -0,0 +1,1297 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:4bf16723750572755d7939b2e42621cb1f52fcda512b32f42476447ce96a6e93"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 10 : SINGLE STAGE TRANSISTOR AMPLIFIERS\n"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.2 : page number 243-244\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "#Variable declaration\n",
+ "f_min=2.0; #Minimum frequency of operation of amplifier, kHz\n",
+ "f_max=10.0; #Maximum frequency of operation of amplifier, kHz\n",
+ "RE=560.0; #Emitter resistor, \u2126\n",
+ "\n",
+ "#Calculations\n",
+ "#X_CE(Emitter capacitor's capacitive reactance)\n",
+ "#X_CE=1/(2*pi*f_min*CE)=RE/10\n",
+ "#From the above equation.\n",
+ "CE=1/(2*pi*f_min*1000*(RE/10)); #Emitter capacitor, F,\n",
+ "\n",
+ "CE=CE*10**6; #Emitter capacitor, \ud835\udf07F\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print('The value of the emitter capacitor = %.2f \ud835\udf07F'%(CE));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of the emitter capacitor = 1.42 \ud835\udf07F\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.5: Page number 252-253\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage in V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "R1=10.0; #Resistor R1, k\u2126\n",
+ "R2=5.0; #Resistor R2, k\u2126\n",
+ "RC=1.0; #Collector resistor, k\u2126\n",
+ "RE=2.0; #Emitter resistor, k\u2126\n",
+ "RL=1.0; #Load resistor, k\u2126\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#For d.c load line, from the equation: VCE=VCC-IC*(RC+RE),\n",
+ "#VCE is maximum when IC=0 and IC is maximum when VCE=0.\n",
+ "VCE_max=VCC; #Maximum collector-emitter voltage, V\n",
+ "IC_max=VCC/(RC+RE); #Maximum collector current, mA\n",
+ "\n",
+ "\n",
+ "#plot\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,20])\n",
+ "limit.set_ylim([0,6])\n",
+ "VCE_plot=[i for i in range(0,(int)(VCC+1))]; #Plot variable for V_CE\n",
+ "IC_plot=[((VCC-i)/(RC+RE)) for i in (VCE_plot[:])]; #Plot variable for I_C\n",
+ "\n",
+ "p=plot(VCE_plot,IC_plot);\n",
+ "xlabel(\"VCE(V)\");\n",
+ "ylabel(\"IC(mA)\");\n",
+ "title(\"d.c load line\");\n",
+ "show(p);\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "#For operating point:\n",
+ "#Assuming VCC drops almost completely across R1 and R2,\n",
+ "V2=VCC*R2/(R1+R2); #Voltage across resistor R2, V\n",
+ "IE=(V2-VBE)/RE; #Emitter current, mA\n",
+ "IC=IE; #Collector current, mA\n",
+ "VCE=VCC-IC*(RC+RE); #Collector-emitter voltage , V\n",
+ "\n",
+ "print(\"The operating point: VCE=%.2fV and IC=%.2fmA.\"%(VCE,IC));\n",
+ "\n",
+ "\n",
+ "#(iii)\n",
+ "#For a.c load line\n",
+ "RAC=(RC*RL)/(RC+RL); #a.c load, k\u2126\n",
+ "VCE_ac_max=VCE+IC*RAC; #Maximum collector-emitter voltage, V\n",
+ "IC_ac_max=IC+VCE/RAC; #Maximum collector current, mA\n",
+ "print(\"Maximum v_CE=%.2fV and maximum i_C=%.2fmA\"%(VCE_ac_max,IC_ac_max));\n",
+ "\n",
+ "#plot\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,10])\n",
+ "limit.set_ylim([0,20])\n",
+ "vCE_plot=[0,VCE_ac_max]; #Plot variable for V_CE\n",
+ "iC_plot=[IC_ac_max,0]; #Plot variable for I_C\n",
+ "\n",
+ "p=plot(vCE_plot,iC_plot);\n",
+ "xlabel(\"vCE(V)\");\n",
+ "ylabel(\"iC(mA)\");\n",
+ "title(\"a.c load line\");\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXsAAAEZCAYAAAB2AoVaAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XtUVPXaB/DvIHhBQVEBQUQUNZVBGEBTChk0KD14SVJB\nQ0KpXvW4JFtvpeekvLXyZOEpseyc1/DSUYEuWqZgFq9jLi/RQTwqdg6SYgiYdwUNuc37x45RUJAZ\nZs/eM/v7WYuVzsD8HmZNz/x8Zu/9Ven1ej2IiMim2UldABERiY/NnohIAdjsiYgUgM2eiEgB2OyJ\niBSAzZ6ISAHY7EnWnnvuObz++uvteoySkhLY2dmhoaHBTFXdpdVqkZ6e/sD7UlJSEB8fDwD45Zdf\n4OTkBB7pTFKxl7oAotaoVCqoVCqpy2hRa/Xde7u3tzcqKystVRbRfbizJ9mz1t2wtdZNtonNnmSl\noKAAQUFBcHZ2RmxsLKqrq1v83oaGBqxcuRKDBg2Cs7MzQkJCcP78+YeuUV5ejsmTJ6NXr14YPHgw\nPv74Y8N9eXl5GDNmDFxcXODp6YlFixahtrbWcP+3336LoUOHokePHli0aBH0en2bmnrzUZJWq8Xy\n5cvx+OOPw9nZGU8++SSuXLli+P4jR44gNDQULi4uCAwMxP79+x+6BlFr2OxJNmpqajB16lQkJCTg\n2rVrmD59Or744osWxySrV69GZmYmcnJycPPmTWzcuBG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text": [
+ "<matplotlib.figure.Figure at 0x7fc7c93536d0>"
+ ]
+ },
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The operating point: VCE=8.55V and IC=2.15mA.\n",
+ "Maximum v_CE=9.62V and maximum i_C=19.25mA\n"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYAAAAEZCAYAAACervI0AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAGylJREFUeJzt3XtwVPX9//HXpoCISBIg2QABgkKEXDARqEUJhGoopQQp\nUEmoQoEorWPVAtPitHIpMxC0lqEUqo1ogyiX2lauol9tFylImWJoALGRMaEBEm4JlwDhkuzvD34s\nCYTNhd095+x5PmZ2JHt9ZyfuJ89zzmYdbrfbLQCA7YQYPQAAwBgsAABgUywAAGBTLAAAYFMsAABg\nUywAAGBTLACwLZfLpc6dO/vlvmNiYvTJJ5/UedmPfvQjvfTSS5KkrVu3qmfPnn6ZAagPCwDgBw6H\nQw6Ho97LUlJS9OWXXwZyNMCDBQAwAO+/hBmwAMASsrOz1b17d7Vp00bx8fF6//33b3ndCxcuaNq0\naYqJiVFYWJhSUlJUWVlZ72Ps379fqampCg8PV0JCgtavX++5bOPGjUpOTlZoaKi6dOmiOXPm1Lrt\n22+/ra5du6p9+/aaN29eg7+vGzdDxcTE6NVXX9X999+vsLAwZWRk6OLFi57LN2zYoKSkJIWHh+vh\nhx/Wnj17GvxYwI1YAGAJ3bt31z//+U+dOXNGs2bN0hNPPKHS0tI6rzt9+nTl5eXps88+U1lZmV55\n5RWFhHj/Ub98+bLS09M1dOhQHT9+XIsXL9YPf/hDFRQUSJJat26tFStW6PTp09q4caP+8Ic/aO3a\ntZKkL774Qs8884zeeecdHTlyRCdPntShQ4ea9H06HA79+c9/1ocffqjCwkLl5+frT3/6kyQpLy9P\nkydPVk5OjsrKyjRlyhSNGDFCly5datJjASwAsIQxY8YoKipKkvT444+rR48e2rlz503Xq66u1ltv\nvaVFixapQ4cOCgkJ0be+9S21aNHC6/3v2LFD586d04wZM9SsWTMNHjxYw4cP18qVKyVJgwYNUnx8\nvCQpMTFRGRkZ2rJliyTpvffeU3p6ugYMGKAWLVpo7ty59S443jz33HOKiopSeHi40tPTtXv3bknS\nH//4R02ZMkX9+vWTw+HQ+PHjdccdd2jHjh1NfizYGwsALGH58uVKTk5WeHi4wsPDtXfvXp08efKm\n6504cUKVlZW69957G3X/R44cuemIoK5du+rw4cOSpH/9618aPHiwIiMjFRYWptdff93z+EeOHFF0\ndLTndq1atVK7du0a+y16XFvoJOnOO+9URUWFJOngwYN69dVXPc9BeHi4Dh06pJKSkiY/FuyNBQCm\nd/DgQT399NNasmSJysrKVF5eroSEhDp3pLZv314tW7bUgQMHGvUYHTt2VHFxca37PHjwoOeFfdy4\ncRo5cqQOHTqkU6dO6cc//rHnutdue8358+frXJxqutURQt6u26VLF/3yl79UeXm551RRUaGxY8c2\n+L6AmlgAYHrnzp2Tw+FQ+/btPZt49u7dW+d1Q0JCNGnSJE2dOlUlJSWqqqrSZ599Vu928gcffFCt\nWrXSyy+/rMuXL8vlcmnDhg3KyMiQJFVUVCg8PFwtWrTQzp079e6773puO3r0aG3YsEHbtm3TpUuX\nNHPmTFVXV9/ysdxud6OOArp23aeeekqvvfaadu7cKbfbrXPnzmnjxo2eQgAaiwUAphcXF6dp06ap\nf//+ioqK0t69ezVgwADP5Vu3btXdd9/t+fo3v/mNEhMT1a9fP7Vr104vvvjiLV+Qr/123aJFC61f\nv14ffPCBIiIi9Oyzz+rtt99WbGysJGnp0qWaOXOm2rRpo7lz59b6rTs+Pl5LlizRuHHj1LFjR7Vt\n29brG8xufI+Atxqoed0+ffooJydHzz77rNq2basePXpo+fLl3p46wCuHvz4Qpri4WOPHj9exY8fk\ncDj09NNP67nnnlNZWZnGjh2rgwcPKiYmRmvWrFFYWJg/RgAAeOG3BaC0tFSlpaVKSkpSRUWF+vTp\no/fff19v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+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.6: Page number 253-254\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variable declaration\n",
+ "RC=10; #Collector resistor, k\u2126\n",
+ "RL=30; #Load resistor, k\u2126\n",
+ "VCC=20; #Collector supply voltage, V\n",
+ "IC=1; #Collector current, mA\n",
+ "VCE=10; #Collector-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#For d.c load line:\n",
+ "#From the equation: VCE=VCC-IC*(RC+RE),\n",
+ "#When VCE=0, IC is maximum.\n",
+ "#Emitter resistor is neglected, assuming it as negligible\n",
+ "IC_max=VCC/RC; #Maximum collector current, mA\n",
+ "\n",
+ "#And, when IC=0, VCE is maximum\n",
+ "VCE_max=VCC; #Maximum collector-emitter voltage, V\n",
+ "\n",
+ "#plot\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,20])\n",
+ "limit.set_ylim([0,5])\n",
+ "VCE_plot=[0,VCE_max]; #Plot variable for V_CE\n",
+ "IC_plot=[IC_max,0]; #Plot variable for I_C\n",
+ "\n",
+ "p=plot(VCE_plot,IC_plot);\n",
+ "xlabel(\"VCE(V)\");\n",
+ "ylabel(\"IC(mA)\");\n",
+ "title(\"d.c load line\");\n",
+ "show(p);\n",
+ "\n",
+ "#For a.c load line:\n",
+ "RAC=(RC*RL)/(RC+RL); #a.c Load resistor, k\u2126\n",
+ "\n",
+ "VCE_ac_max=VCE+IC*RAC; #Maximum collector-emitter voltage, V\n",
+ "IC_ac_max=IC+ VCE/RAC; #Maximum collector current, mA\n",
+ "\n",
+ "#plot\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,25])\n",
+ "limit.set_ylim([0,5])\n",
+ "vCE_plot=[0,VCE_ac_max]; #Plot variable for V_CE\n",
+ "iC_plot=[IC_ac_max,0]; #Plot variable for I_C\n",
+ "\n",
+ "p=plot(vCE_plot,iC_plot);\n",
+ "xlabel(\"vCE(V)\");\n",
+ "ylabel(\"iC(mA)\");\n",
+ "title(\"a.c load line\");\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXsAAAEZCAYAAAB2AoVaAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAGMxJREFUeJzt3XtQVPfBxvFnEUww3hUURZR4F1Tw+uqr6RKvtd6pCqnE\nqtQZbW2s7bQ2nViTTqi2WqNp0nZSbWIc0diYmChaEydrrNbYMjgampbQSIpcVNBE0SCw7PsHr6uI\nILvsYS/n+5nZGTm7nN+PM5tnf3n27FmLw+FwCAAQ0IK8PQEAgPEIewAwAcIeAEyAsAcAEyDsAcAE\nCHsAMAHCHj7t29/+tp555pkm7SMvL09BQUGqrq720KzusFqt2rZt233vW7dunVJSUiRJ//3vf9Wm\nTRtxpjO8JdjbEwAaYrFYZLFYvD2NejU0v7u3R0VF6fr16801LaAOVvbwef66GvbXeSMwEfbwKVlZ\nWRo2bJjatm2rpKQklZeX1/vY6upqpaWlqU+fPmrbtq1GjBihCxcuPHCMwsJCzZw5U506dVLfvn31\nxz/+0Xnf6dOnNWbMGHXo0EHdunXTypUrVVlZ6bz/vffe04ABA9S+fXutXLlSDoejUaF+b5VktVq1\ndu1ajRs3Tm3bttWUKVNUWlrqfPypU6c0duxYdejQQXFxcTp27NgDxwAaQtjDZ1RUVGj27NlatGiR\nrl69qnnz5unNN9+stybZtGmTdu/erUOHDunatWv605/+pFatWj1wnKSkJEVFRamoqEh//vOf9fTT\nT+uDDz6QJAUHB2vLli0qLS3V3/72Nx09elQvv/yyJKmkpESJiYlKS0tTaWmpevfurRMnTrhdM6Wn\np+vVV1/VpUuXVFFRoY0bN0qSCgoKNH36dK1du1ZXr17Vxo0blZiYqJKSErfGASTCHj7k1KlTqqqq\n0lNPPaUWLVooMTFRI0eOrPfx27Zt0/PPP6++fftKkgYPHqyOHTs2OEZ+fr5OnjypDRs2qGXLlho6\ndKhSU1O1Y8cOSdKwYcM0atQoBQUFqWfPnlq2bJlzVZ2RkaHY2FjNnTtXLVq00KpVq9S1a1e3/laL\nxaLFixerT58+evjhhzV//nydOXNGkrRz505NmzZNU6dOlSRNnDhRI0aMUEZGhltjARJhDx9SWFio\n7t2719rWs2fPemuS/Px89e7d2+UxOnbsqEceecS5LSoqSgUFBZKknJwcTZ8+XREREWrXrp1+9rOf\nOeuVwsJCRUZG1tpfjx49XBr/bne/UISGhqqsrEyS9Pnnn2vv3r3q0KGD83bixAkVFxe7PRZA2MNn\nREREOEP3ts8//7zemqRHjx7Kzc11aYxu3brpypUrzmCVak6LvB3iy5cv16BBg5Sbm6svv/xSzz//\nvLNn79atm/Lz852/53A4av18L3frnaioKKWkpOjq1avO2/Xr1/XjH//Yrf0BEmEPHzJ27FgFBwdr\n69atqqys1L59+/T3v/+93senpqbqmWeeUW5urhwOh86ePasrV640OEaPHj00duxY/fSnP9WtW7d0\n9uxZbd++XQsXLpQklZWVqU2bNmrVqpX+9a9/6Xe/+53zd6dNm6bs7Gy99dZbqqqq0tatWxtcbT/o\njdv67l+4cKHeffddHTlyRHa7XeXl5bLZbHVeCAFXEPbwGSEhIdq3b59effVVderUSW+88YYSExOd\n99/+YNLtM25Wr16t+fPna/LkyWrXrp2+853v1Hv2zt2r7PT0dOXl5albt26aO3eunnvuOT3++OOS\npI0bN2rXrl1q27atli1bpqSkJOfvdu7cWXv37tWaNWvUuXNn5ebmaty4cfX+Pfeeg3/vSv/e+27/\nHBkZqf379ystLU3h4eGKiorSpk2bDPlQGMzDYvSXl/Tq1Utt27ZVixYtFBISotOnTxs5HADgPgz/\nBK3FYpHNZnvgWRIAAOM0S43DJwkBwLsMD3uLxeI8T/iVV14xejgAwH0YXuOcOHFCERERunz5siZN\nmqQBAwZo/PjxRg8LALi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Kx1Ons9+3bJ0maPHlynR4+OTlZ//73vzV37txa2z/44ANNnz69ef5A\noJG4nj3QCFlZWdq8ebN27NjR4ONu3bolq9WqEydOKCiItRR8B89GoBHi4+OVkJCg6urqBh+Xn5+v\nDRs2EPTwOazsAcAEWH4AgAkQ9gBgAoQ9AJgAYQ8AJkDYA4AJ/B97RjZ/9S1ZzQAAAABJRU5ErkJg\ngg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7fc7c8c8ec90>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXsAAAEZCAYAAAB2AoVaAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAG55JREFUeJzt3XtQ1XX+x/HXIS9hXkAFpNAwL6WAQmqkacKu0U2yJAUv\naSrV2rTVZjvZ7qyx64zddBvX7baklpZoV++Zv3E7pnZhN2nytsta0HBNQy1AEYTv749vHkMBOcD3\nnAPf52OGGTi3z+d85zsvPvP5fr6ft8MwDEMAgDbNz9sdAABYj7AHABsg7AHABgh7ALABwh4AbICw\nBwAbIOzR5jmdTvXu3duSzw4PD9eOHTvqfO7ee+/Vn/70J0nSrl27dM0111jSB6AxCHugGRwOhxwO\nx0WfGzNmjP7zn/94smtALYQ9YCHuWYSvIOzhU5555hn1799fXbt2VUREhNavX1/va0+dOqV58+Yp\nPDxcAQEBGjNmjCoqKi7axqFDhxQXF6fAwEBFRkZq06ZNrue2bNmimJgYdevWTX369NGf//znWu9d\nvXq1rrzySvXs2VOLFi1q9Pc6fyopPDxcS5Ys0dChQxUQEKCUlBSdPn3a9fzmzZsVHR2twMBA3XDD\nDdq3b1+j2wLqQtjDp/Tv31+7d+/WTz/9pKeeekrTp09XcXFxna99/PHHlZWVpc8++0zHjh3T888/\nLz+/hk/pqqoqJSYm6pZbbtHRo0e1bNkyTZs2TdnZ2ZKkzp07680339SPP/6oLVu26OWXX9aGDRsk\nSQcPHtSDD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hp0yZov/+97+aOHFircc//vhjjR8/3mPfEWgM9rMHGiErK0svvPCCVq1a1eDr\nTp8+rbi4OO3Zs0d+foyl4Ds4G4FGiImJUXx8vGpqahp8XV5enp599lmCHj6HkT0A2ADDDwCwAcIe\nAGyAsAcAGyDsAcAGCHsAsIH/B/OXRHOm5kPCAAAAAElFTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7fc7c8a07890>"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.7 : Page number 254-255"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variabe declaration\n",
+ "VCE_Q=8.0; #Q-point collector emitter voltage, V\n",
+ "IC_Q=1; #Q-point collector current, mA\n",
+ "ic_positive_peak=1.5; #Collector current at positive peak of signal, mA\n",
+ "ic_negative_peak=0.5; #Collector current at negative peak of signal, mA\n",
+ "vce_positive_peak=7; #Collector emitter voltage at positive peak of signal, V\n",
+ "vce_negative_peak=9; #Collector emitter voltage at negative peak of signal, V\n",
+ "\n",
+ "#Plot\n",
+ "vce_plot=[vce_positive_peak,vce_negative_peak]; #Plot variable of vce\n",
+ "ic_plot=[ic_positive_peak,ic_negative_peak]; #Plot variable of ic\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,10])\n",
+ "limit.set_ylim([0,2])\n",
+ "p=plot(vce_plot,ic_plot);\n",
+ "xlabel(\"vCE(V)\");\n",
+ "ylabel(\"iC(mA)\");\n",
+ "title(\"a.c load line\");\n",
+ "plt.grid();\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYQAAAEZCAYAAACXRVJOAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAAC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8QAACX0RAAAJJoCACAy2gIAABJNAQAwGX/D/7pwLYLsAND\nAAAAAElFTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7fc7c877c550>"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.8 : Page number 256\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "RC=2.0; #Collector resistor, k\u2126\n",
+ "Rin=1.0; #Input resistance, k\u2126\n",
+ "beta=60.0; #Base current amplification factor\n",
+ "RL=0.5; #Load resistor, k\u2126\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "RAC=(RC*RL)/(RC+RL); #a.c load resistor, k\u2126\n",
+ "Av=beta*(RAC/Rin); #Voltage gain\n",
+ "\n",
+ "#Results\n",
+ "print(\"Voltage gain= %d.\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage gain= 24.\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.9 : Page number 256\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "V_in=1.0; #Input voltage , mV\n",
+ "RC=10.0; #Collector resistor, k\u2126\n",
+ "Rin=2.5; #Input resistance, k\u2126\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "RL=10.0; #Load resistor, k\u2126\n",
+ "\n",
+ "#Calculations\n",
+ "RAC=(RC*RL)/(RC+RL); #Effective load, k\u2126\n",
+ "Av=beta*(RAC/Rin); #Voltage gain\n",
+ "\n",
+ "V_out=V_in*Av; #Output voltage, V\n",
+ "\n",
+ "#Results\n",
+ "print(\"Output voltage= %dmV.\"%V_out);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage= 200mV.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.10 : Page number 256-257\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "change_in_IB=10.0; #Change in base current, \ud835\udf07A\n",
+ "change_in_IC=1.0; #Change in collector current, mA\n",
+ "change_in_VBE=0.02; #Change in Base-emitter voltage, V\n",
+ "RC=5.0; #Collector resistor, k\u2126\n",
+ "RL=10.0; #Emitter resistor, k\u2126\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "beta=(change_in_IC*1000)/change_in_IB; #Base current amplification factor\n",
+ "\n",
+ "#(ii)\n",
+ "Rin=(change_in_VBE/change_in_IB)*1000; #Input impedance, k\u2126\n",
+ "\n",
+ "#(iii)\n",
+ "RAC=round((RC*RL)/(RC+RL),1); #a.c load, k\u2126\n",
+ "\n",
+ "#(iv)\n",
+ "Av=beta*RAC/Rin; #Voltage gain\n",
+ "\n",
+ "#(v)\n",
+ "Ap=beta*Av; #Power gain\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Beta= %d.\"%beta);\n",
+ "print(\"Input impedance=%d k\u2126.\"%Rin);\n",
+ "print(\"a.c load=%.1f k\u2126.\"%RAC);\n",
+ "print(\"Voltage gain= %d.\"%Av);\n",
+ "print(\"Power gain=%d.\"%Ap);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Beta= 100.\n",
+ "Input impedance=2 k\u2126.\n",
+ "a.c load=3.3 k\u2126.\n",
+ "Voltage gain= 165.\n",
+ "Power gain=16500.\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.11 : Page number 257\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "RC=3.0; #Collector resistor,k\u2126\n",
+ "RL=6.0; #Load resistor, k\u2126\n",
+ "Rin=0.5; #Input impedance, k\u2126\n",
+ "Vin=1; #Input voltage, mV\n",
+ "\n",
+ "#Calculation\n",
+ "RAC=(RC*RL)/(RC+RL); #a.c load, k\u2126\n",
+ "Av=beta*RAC/Rin; #Voltage gain\n",
+ "Vout=Vin*Av; #Output voltage, V\n",
+ "\n",
+ "#Results\n",
+ "print(\"Output voltage=%dmV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=200mV\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.12 : Page number 257-258\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VT=6.0; #Collector potential, V\n",
+ "R1=1.0; #Resistor R1, k\u2126\n",
+ "R2=2.0; #Resistor R2, k\u2126\n",
+ "VB_found=4.0; #Measured base voltage, V\n",
+ "\n",
+ "#Calculations\n",
+ "VB=(VT*R1)/(R1+R2); #Theoretical base voltage, V\n",
+ "\n",
+ "if(VB_found==VB):\n",
+ " print(\"The circuit is operating properly.\");\n",
+ "else:\n",
+ " print(\"The circuit is not operating properly.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The circuit is not operating properly.\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.13 : Page number 258-259\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "R1=40.0; #Resistor R1, k\u2126\n",
+ "R2=10.0; #Resistor R2, k\u2126\n",
+ "RC=6.0; #Collector resistor, k\u2126\n",
+ "RE=2.0; #Emitter resistor, k\u2126\n",
+ "beta=80; #Base current amplification factor\n",
+ "VBE=0.7; #Base emitter voltage, V\n",
+ "\n",
+ "#Calculations\n",
+ "V2=(VCC*R2)/(R1+R2); #Voltage across resistor R2, V\n",
+ "VE=V2-VBE; #Emitter voltage, V\n",
+ "IE=VE/RE; #Emitter current, mA\n",
+ "re=25/IE; #a.c emitter resistance, \u2126\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"a.c emitter resistance= %.2f \u2126.\"%re);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "a.c emitter resistance= 38.46 \u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.14 : Page number 262-263\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "R1=150.0; #Resistor R1, k\u2126\n",
+ "R2=20.0 #Resistor R2, k\u2126\n",
+ "RC=12.0; #Collector resistor, k\u2126\n",
+ "RE=2.2; #Emitter resistor, k\u2126\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "V2=round(VCC*R2/(R1+R2),2); #Voltage across R2, V\n",
+ "VE=round(V2-VBE,2); #Voltage across emitter resistor, V\n",
+ "IE=round(VE/RE,2); #Emitter current, mA\n",
+ "re=round(25/IE,1); #a.c emitter resistance, \u2126\n",
+ "\n",
+ "\n",
+ "#(i)\n",
+ "#CE(emitter capacitor) connected in the circuit:\n",
+ "Av=(RC*1000)/re; #Voltage gain for emitter capacitor connected.\n",
+ "\n",
+ "print(\"(i)Voltage gain= %d.\"%Av);\n",
+ "\n",
+ "#(ii)\n",
+ "#CE(emitter capacitor) removed from the circuit:\n",
+ "Av=(RC*1000)/(re+RE*1000); #Voltage gain for emitter capacitor removed.\n",
+ "\n",
+ "print(\"(ii)Voltage gain= %.2f.\"%Av);\n",
+ "\n",
+ "#Note: The answer in the text book has been approximated to 5.38 but it's actually coming 5.37.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)Voltage gain= 360.\n",
+ "(ii)Voltage gain= 5.37.\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.15 : Page number 263\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RC=6.0; #Collector resistor, k\u2126\n",
+ "RL=12.0; #Load resistor, k\u2126\n",
+ "re=33.3; #a.c emitter resistance, \u2126\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "RAC=RC*RL/(RC+RL); #a.c effective load, k\u2126\n",
+ "Av=RAC*1000/re; #Voltage gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"Voltage gain= %d.\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage gain= 120.\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.16 : Page number 263-264\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=9.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "R1=240.0; #Resistor R1, k\u2126\n",
+ "R2=30.0 #Resistor R2, k\u2126\n",
+ "RC=20.0; #Collector resistor, k\u2126\n",
+ "RE=3.0; #Emitter resistor, k\u2126\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "V2=round(VCC*R2/(R1+R2),1); #Voltage across R2, V\n",
+ "VE=round(V2-VBE,1); #Voltage across emitter resistor, V\n",
+ "IE=round(VE/RE,1); #Emitter current, mA\n",
+ "re=25/IE; #a.c emitter resistance, \u2126\n",
+ "\n",
+ "#(ii)\n",
+ "Av=RC*1000/re; #Voltage gain\n",
+ "\n",
+ "#(iii)\n",
+ "V_C_in=V2; #d.c voltage across input capacitor, V\n",
+ "V_C_E=VE; #d.c vooltage across emitter capacitor, V\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"(i) a.c emitter resistance=%d \u2126.\"%re);\n",
+ "print(\"(ii) Voltage gain =%d.\"%Av);\n",
+ "print(\"(iii) d.c voltage across input capacitor= %dV and emitter capacitor=%.1fV.\"%(V_C_in,V_C_E));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) a.c emitter resistance=250 \u2126.\n",
+ "(ii) Voltage gain =80.\n",
+ "(iii) d.c voltage across input capacitor= 1V and emitter capacitor=0.3V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.17 : Page number 264-265"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "R1=40.0; #Resistor R1, k\u2126\n",
+ "R2=10.0 #Resistor R2, k\u2126\n",
+ "RC=2.0; #Collector resistor, k\u2126\n",
+ "RE=1.0; #Emitter resistor, k\u2126\n",
+ "RL=1.0; #Load resistor, k\u2126\n",
+ "beta=100; #Base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) D.C bias levels\n",
+ "V2=VCC*R2/(R1+R2); #Voltage across R2, V\n",
+ "VE=round(V2-VBE,1); #Voltage across emitter resistor, V\n",
+ "IE=round(VE/RE,1); #Emitter current, mA\n",
+ "IC=IE; #Collector current, mA\n",
+ "IB=IC/beta; #Base current, mA\n",
+ "VC=VCC-IC*RC; #Collector voltage, V\n",
+ "print(\"(i) D.C bias levels: V2=%dV, VE=%.1fV, IE=%.1fmA, IC=%.1fmA, IB=%.3fmA and VC=%.1fV.\"%(V2,VE,IE,IC,IB,VC));\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "Cin_V=V2; #Voltage across Cin capacitor, V\n",
+ "CE_V=VE; #Voltage across CE capacitor, V \n",
+ "CC_V=VC; #Voltage across CC capacitor, V\n",
+ "print(\"(ii) D.c voltage across: Cin=%dV and CE=%.1fV and CC=%.1fV.\"%(Cin_V,CE_V,CC_V));\n",
+ "\n",
+ "#(iii)\n",
+ "re=round(25/IE,1); #a.c emitter resistance, \u2126\n",
+ "print(\"(iii) a.c emitter resistance=%.1f\u2126.\"%re);\n",
+ "\n",
+ "\n",
+ "#(iv)\n",
+ "RAC=round(RC*RL/(RC+RL),3); #Total a.c collector resistance, k\u2126\n",
+ "Av=RAC/(re/1000); #Voltage gain\n",
+ "print(\"(iv) Voltage gain=%.1f.\"%Av);\n",
+ "\n",
+ "#(v)\n",
+ "print(\"(v) VC>VE. Therefore, the transistor is in active state.\" );\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) D.C bias levels: V2=3V, VE=2.3V, IE=2.3mA, IC=2.3mA, IB=0.023mA and VC=10.4V.\n",
+ "(ii) D.c voltage across: Cin=3V and CE=2.3V and CC=10.4V.\n",
+ "(iii) a.c emitter resistance=10.9\u2126.\n",
+ "(iv) Voltage gain=61.2.\n",
+ "(v) VC>VE. Therefore, the transistor is in active state.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.18 : page number 265\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=132.0; #Voltage gain\n",
+ "beta=200.0; #Base current amplification factor\n",
+ "P_in=60.0; #Input power, \ud835\udf07W\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "Ap=beta*Av; #Power gain\n",
+ "P_out=Ap*(P_in/10**6); #Output power, W\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The power gain = %d and output power = %.3fW.\"%(Ap,P_out));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The power gain = 26400 and output power = 1.584W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 32
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.19 : page number 265-266\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "IB=200.0; #Base current, microampere\n",
+ "IE=10.0; #Emitter current, mA\n",
+ "R1=27.0; #Resistor R1, kilo ohm\n",
+ "R2=13.0 #Resistor R2, kilo ohm\n",
+ "RC=4.7; #Collector resistor, kilo ohm\n",
+ "RE=2.2; #Emitter resistor, kilo ohm\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "IC=IE-(IB/1000); #Collector current, mA\n",
+ "beta=IC/(IB/1000); #Current gain\n",
+ "\n",
+ "print(\"(i) Current gain=%d\"%beta);\n",
+ "\n",
+ "#(ii)\n",
+ "#a.c emitter resistance is neglected, voltage gain=(collector resistor)/(emitter resistor)\n",
+ "Av=RC/RE; #Voltage gain\n",
+ "\n",
+ "print(\"(ii) Voltage gain=%.2f\"%Av);\n",
+ "\n",
+ "#(iii)\n",
+ "Ap=round(beta*Av,0); #Power gain\n",
+ "\n",
+ "#Results\n",
+ "print(\"(iii) Power gain=%d.\"%Ap);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Current gain=49\n",
+ "(ii) Voltage gain=2.14\n",
+ "(iii) Power gain=105.\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.20 : Page number 266-267\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=30.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base emitter voltage, V\n",
+ "R1=45.0; #Resistor R1, k\u2126\n",
+ "R2=15.0 #Resistor R2, k\u2126\n",
+ "RC=10.0; #Collector resistor,k\u2126\n",
+ "RE=7.5; #Emitter resistor, k\u2126\n",
+ "beta=200.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "V2=round(VCC*R2/(R1+R2),1); #Voltage across R2, V (Voltage divider rule)\n",
+ "VE=V2; #Voltage across emitter resistor(base-emitter voltage is neglected), V\n",
+ "IE=VE/RE; #Emitter current, mA (OHM's LAW)\n",
+ "re=25/IE; #a.c emitter resistance, ohm\n",
+ "Zin_base=(beta*re)/1000; #input impedance of transistor base,k\u2126\n",
+ "R1_R2=(R1*R2)/(R1+R2); #Parallel resistance between R1 and R2, k\u2126\n",
+ "Zin=((R1_R2)*Zin_base)/(R1_R2+Zin_base); #Input impedance of the amplifier circuit, k\u2126\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The input impedance of the amplifier circuit= %.2f k\u2126.\"%Zin); \n",
+ "\n",
+ "#Note: The input impedance of the amplifier circuit is approximated as 3.45 k\u2126 in the text book, but actually it's 3.46 k\u2126.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The input impedance of the amplifier circuit= 3.46 k\u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.21 : Page Number 268-269\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V.\n",
+ "RC=1.5; #Collector resistor, k\u2126.\n",
+ "R1=18.0; #Resistor R1, k\u2126.\n",
+ "R2=4.7; #Resistor R2, k\u2126.\n",
+ "RE1=300.0; #Emitter resistor 1, \u2126.\n",
+ "RE2=900.0; #Emitter resistor 2, \u2126.\n",
+ "VBE=0.7; #Base-emitter voltage, V.\n",
+ "beta=150.0; #Base current amplification factor.\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "V2=round(VCC*R2/(R1+R2),1); #d.c voltage across R2, V. (Voltage divider rule)\n",
+ "VE=round(V2-VBE,1); #d.c voltage across RE, V.\n",
+ "IE=round((VE/(RE1+RE2))*1000,2); #d.c emitter current, mA.(OHM'S LAW)\n",
+ "re=round(25/IE,1); #a.c emitter resistance, \u2126.\n",
+ "Av=RC*1000/(re+RE1); #Voltage gain\n",
+ "Zin_base=(beta*(re+RE1))/1000; #Input impedance of transistor base, k\u2126.\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The voltage gain of the swamped amplifier= %.2f.\"%Av);\n",
+ "print(\"Input impedance of transistor base of the swamped amplifier= %.2f k\u2126.\"%Zin_base);\n",
+ "\n",
+ "#Note:In the textbook Av is approximated to 4.66and Zin_base to 48.22 kilo ohm, but the actual answers come as 4.67 and 48.21 kilo ohm.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain of the swamped amplifier= 4.67.\n",
+ "Input impedance of transistor base of the swamped amplifier= 48.21 k\u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.22 : Page number 269\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RC=1.5; #Collector resistor, k\u2126.\n",
+ "RE1=300.0; #Emitter resistor 1, \u2126.\n",
+ "re=21.5; #a.c emitter resistance, \u2126.\n",
+ "\n",
+ "#Calculations\n",
+ "Av=round(RC*1000/(re+RE1),2); #Voltage gain.\n",
+ "Av_1=round(RC*1000/(2*re+RE1),2); #Voltage gain when re doubles.\n",
+ "change_in_gain=round(Av-Av_1,2); #Change in voltage gain.\n",
+ "change_percentage=change_in_gain*100/Av; #Change percentage\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "if(change_in_gain>0):\n",
+ " print(\"The percentage change from the original value= %.2f%%(decrease)\"%change_percentage);\n",
+ "else:\n",
+ " print(\"The percentage change from the original value= %.2f%%(increase)\"%change_percentage);\n",
+ "\n",
+ "\n",
+ "#Note: The percentage has been approximated in the text book as 6.22%, but the answer comes as 6.42%.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The percentage change from the original value= 6.42%(decrease)\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.23 : Page number 269-270\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base emitter voltage, V\n",
+ "R1=10.0; #Resistor R1, kilo ohm\n",
+ "R2=2.2; #Resistor R2, kilo ohm\n",
+ "RC=4.0; #Collector resistor, kilo ohm\n",
+ "RE=1.1; #Emitter resistor, kilo ohm\n",
+ "beta=200.0; #Base current amplification factor\n",
+ "RE1=210.0; #Emitter resistor 1 of swamped amplifier, ohm.\n",
+ "RE2=900.0; #Emitter resistor 2 of swamped amplifier, ohm.\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "V2=round(VCC*R2/(R1+R2),1); #d.c voltage across R2, V. (Voltage divider rule)\n",
+ "VE=round(V2-VBE,1); #d.c voltage across RE, V.\n",
+ "IE=(VE/RE); #d.c emitter current, mA.(OHM'S LAW)\n",
+ "re=25/IE; #a.c emitter resistance, ohm.\n",
+ "\n",
+ "\n",
+ "#(i) Zin_base:\n",
+ "Zin_base_standard=(beta*re)/1000; #input impedance of transistor base for standard amplifier , kilo ohm.\n",
+ "Zin_base_swamped=(beta*(re+RE1))/1000; #input impedance of transistor base for swamped amplifier, kilo ohm.\n",
+ "\n",
+ "\n",
+ "#(ii) Zin:\n",
+ "#input impedance for standard amplifier circuit\n",
+ "Zin_standard=(((R1*R2)/(R1+R2))*Zin_base_standard)/(Zin_base_standard +((R1*R2)/(R1+R2))); #kilo ohm\n",
+ "\n",
+ "#input impedance for standard amplifier circuit\n",
+ "Zin_swamped=(((R1*R2)/(R1+R2))*Zin_base_swamped)/(Zin_base_swamped +((R1*R2)/(R1+R2))); #kilo ohm\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"(i) input impedance of transistor base for standard amplifier= %d kilo ohm\"%Zin_base_standard);\n",
+ "print(\" input impedance of transistor base for swamped amplifier= %d kilo ohm\"%Zin_base_swamped);\n",
+ "print(\"(ii) input impedance for standard amplifier= %.2f kilo ohm\"%Zin_standard);\n",
+ "print(\" input impedance for swamped amplifier= %.2f kilo ohm\"%Zin_swamped);\n",
+ "\n",
+ "\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) input impedance of transistor base for standard amplifier= 5 kilo ohm\n",
+ " input impedance of transistor base for swamped amplifier= 47 kilo ohm\n",
+ "(ii) input impedance for standard amplifier= 1.33 kilo ohm\n",
+ " input impedance for swamped amplifier= 1.74 kilo ohm\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.24 : Page number 270-271\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RC=4.0; #Collector resistor, kilo ohm\n",
+ "re=25.0; #a.c emitter resistance, ohm (calculated in example 10.23)\n",
+ "RE_1=210.0; #Emitter resistor 1 of swamped amplifier,ohm\n",
+ "\n",
+ "#Calculation\n",
+ "Av_standard=(RC*1000)/re; #Voltage gain of standard common emitter amplifier\n",
+ "Av_swamped=(RC*1000)/(re+RE_1); #Voltage gain of swamped amplifier\n",
+ "\n",
+ "#Results\n",
+ "print(\"The voltage gain of standard amplifier=%d.\"%Av_standard);\n",
+ "print(\"The voltage gain of swamped amplifier=%d.\"%Av_swamped);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain of standard amplifier=160.\n",
+ "The voltage gain of swamped amplifier=17.\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.26 : Page number 273-274\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_0=1000.0; #Open circuit voltage gain\n",
+ "R_in=2.0; #Input resistance, kilo ohm\n",
+ "R_out=1.0; #Output resistance, ohm\n",
+ "RL=4; #Load resistor across the output, ohm\n",
+ "I_2=0.5; #Output signal current, A.\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#Since A_0*(I_1*R_in) = I_2*(R_out+RL)\n",
+ "I_1=I_2*(R_out+RL)/(A_0*(R_in*1000)); #Input current, A\n",
+ "V_1=I_1*(R_in*1000); #Input signal voltage, V\n",
+ "V_1=V_1*1000; #Input signal voltage, mV\n",
+ "\n",
+ "print(\"The required input signal voltage =%.1fmV\"%V_1);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required input signal voltage =2.5mV\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.27 : Page number 274\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_0=1000.0; #Open circuit voltage gain\n",
+ "R_in=7.0; #Input resistance, kilo ohm\n",
+ "R_out=15.0; #Output resistance, ohm\n",
+ "RL=35.0; #Load resistor across the output, ohm\n",
+ "R_s=3.0; #Internal resistance, kilo ohm\n",
+ "E_s=10.0; #Input signal voltage, mV.\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "I_1=E_s*(10**-3)/(R_s*1000+R_in*1000); #Input current, A\n",
+ "V_1=I_1*(R_in*1000); #Voltage across input resistance, V\n",
+ "\n",
+ "#Since, A_v=V_2/V_1 = A_0*RL/(R_out+RL)\n",
+ "A_v=A_0*RL/(R_out+RL); #Voltage gain\n",
+ "V_2=A_v*V_1; #Outout voltage, V\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "P_2=V_2**2/RL; #Output power, W\n",
+ "P_1=V_1**2/(R_in*1000); #Input power, W\n",
+ "A_p=round(P_2/P_1,-6); #Power gain\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The magnitude of output voltage = %.1fV\"%V_2);\n",
+ "print(\"The power gain =%de-06.\"%(A_p/10**6));\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The magnitude of output voltage = 4.9V\n",
+ "The power gain =98e-06.\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 10.28 : Page number 274-275\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_v=80.0; #Voltage gain\n",
+ "V_2=1.0; #Output voltage, V\n",
+ "A_i=120.0; #Current gain\n",
+ "RL=2; #Load resistor, kilo ohm\n",
+ "\n",
+ "#Calculation\n",
+ "V_1=(V_2/A_v)*1000; #Input signal voltage, mV\n",
+ "\n",
+ "#Since, A_i=A0*R_in/(R_out+RL) and A_v=A0*RL/(R_out+RL)\n",
+ "#So, A_v/A_i=RL/R_in\n",
+ "R_in=RL*A_i/A_v; #Input resistance, kilo ohm\n",
+ "I_1=V_1/R_in; #Input current, \u03bcA\n",
+ "A_p=A_i*A_v; #Power gain\n",
+ "\n",
+ "#Results\n",
+ "print(\"Necessary input signal voltage= %.1fmV\"%V_1);\n",
+ "print(\"Input signal current =%.2f \u03bcA\"%I_1);\n",
+ "print(\"Power gain = %d.\"%A_p);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Necessary input signal voltage= 12.5mV\n",
+ "Input signal current =4.17 \u03bcA\n",
+ "Power gain = 9600.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter11_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter11_1.ipynb
new file mode 100644
index 00000000..6e0fb200
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter11_1.ipynb
@@ -0,0 +1,1025 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:8e425c9c2dfbfee43b3a89e44b0fd7936ba869da73ac3c372e9b23848f1cded1"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "#CHAPTER 11 : MULTISTAGE TRANSISTOR AMPLIFIERS"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 11.1 : Page number 285"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from math import log10\n",
+ "#Variable declaration\n",
+ "#(i)\n",
+ "A_v=30; #Voltage gain\n",
+ "\n",
+ "#(ii)\n",
+ "A_p=100; #Power gain\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "A_v_dB=20*log10(A_v); #Voltage gain, dB\n",
+ "A_p_dB=10*log10(A_p); #Power gain, dB\n",
+ "\n",
+ "#Results\n",
+ "print(\"(i) Voltage gain in dB=%.2fdB\"%A_v_dB);\n",
+ "print(\"(ii) Power gain in dB=%ddB\"%A_p_dB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Voltage gain in dB=29.54dB\n",
+ "(ii) Power gain in dB=20dB\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.2 : Page number 285-286\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#(i)\n",
+ "A_p_dB=40.0; #Power gain in dB\n",
+ "A_p_b=A_p_dB/10; #Power gain in bel\n",
+ "A_p=10**A_p_b; #Power gain in number\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Power gain in number=%d\"%A_p);\n",
+ "\n",
+ "#(ii)\n",
+ "A_p_dB=43.0; #Power gain in dB\n",
+ "A_p_b=A_p_dB/10; #Power gain in bel\n",
+ "A_p=round(10**A_p_b,-4); #Power gain in number\n",
+ "\n",
+ "#Result\n",
+ "print(\"(ii) Power gain in number=%d\"%A_p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Power gain in number=10000\n",
+ "(ii) Power gain in number=20000\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.3 : Page number 286\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "Av_1=100.0; #Voltage gain of stage 1\n",
+ "Av_2=200.0; #Voltage gain of stage 2\n",
+ "Av_3=400.0; #Voltage gain of stage 3\n",
+ "\n",
+ "#Calculations\n",
+ "Av_1_dB=20*log10(Av_1); #Voltage gain of stage 1, dB\n",
+ "Av_2_dB=20*log10(Av_2); #Voltage gain of stage 2, dB\n",
+ "Av_3_dB=20*log10(Av_3); #Voltage gain of stage 3, dB\n",
+ "\n",
+ "Av_T=Av_1_dB+Av_2_dB+Av_3_dB; #Total voltage gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"The total voltage gain=%ddB\"%Av_T);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total voltage gain=138dB\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.4 : Page number 286\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "A_p_absolute=30.0; #Absolute gain of each stage\n",
+ "number_of_stages=5.0; #number of stages\n",
+ "negative_feedback=10.0; #negative feedback, dB\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "A_p_dB=round(10*log10(A_p_absolute),2); #Power gain of one stage. dB\n",
+ "A_p_T=number_of_stages * A_p_dB; #Total power gain, dB\n",
+ "\n",
+ "#(ii)\n",
+ "A_p_resultant=A_p_T-negative_feedback; #Resultant power gain with negative feedback, dB\n",
+ "\n",
+ "#Results\n",
+ "print(\"The total power gain = %.2fdB.\"%A_p_T);\n",
+ "print(\"The resultant power gain with negative feedback = %.2fdB.\"%A_p_resultant);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total power gain = 73.85dB.\n",
+ "The resultant power gain with negative feedback = 63.85dB.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.5 : Page number 286\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "P_out_2kHz=1.5; #Output power at 2 kHz, W\n",
+ "P_out_20kHz=0.3; #Output power at 20 kHz, W\n",
+ "P_in=10.0; #Input power, mW\n",
+ "\n",
+ "#Calculations\n",
+ "A_p_dB_2kHz=10*log10(P_out_2kHz*1000/P_in); #dB power gain at 2 kHz\n",
+ "A_p_dB_20kHz=10*log10(P_out_20kHz*1000/P_in); #dB power gain at 20 kHz\n",
+ "Fall_in_gain=A_p_dB_2kHz-A_p_dB_20kHz; #Fall in gain from 2kHz to 20kHz\n",
+ "\n",
+ "#Results\n",
+ "print(\"The fall in gain from 2kHz to 20kHz=%.2fdB\"%Fall_in_gain);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The fall in gain from 2kHz to 20kHz=6.99dB\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.6 : Page number 287\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "A_v=15.0; #Voltage gain, dB\n",
+ "V_1=0.8; #Input signal voltage, V\n",
+ "\n",
+ "#Calculations\n",
+ "#Since, Av(in decibel)=20*log10(V_2/V_1),\n",
+ "V_2=V_1*(10**(A_v/20)); #Output voltage, V\n",
+ "\n",
+ "#Results\n",
+ "print(\"The output voltage= %.1fV.\"%V_2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output voltage= 4.5V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.7 : Page number 287\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_0_dB=70.0; #Open circuit voltage gain, dB\n",
+ "A_v_dB=67.0; #Voltage gain, dB\n",
+ "R_out=1.5; #Output resistance, kilo ohm\n",
+ "\n",
+ "#Calculations\n",
+ "#Since, A_0_dB-A_v_dB=20*log10(A_0/A_v)\n",
+ "ratio_A0_Av=round(10**((A_0_dB-A_v_dB)/20),2); #Ratio of open-circuit voltage gain to normal voltage gain\n",
+ "\n",
+ "#Since, A_v/A_0 = RL/(R_out+RL)\n",
+ "RL=R_out/(ratio_A0_Av-1); #Load resistor, kilo ohm\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The load resistance=%.2f kilo ohm.\"%RL);\n",
+ "\n",
+ "#Note: The value of load resistor is calculated to be 3.6585 kilo ohm and approximated to 3.66. But, in the text it has been approximated to 3.65.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The load resistance=3.66 kilo ohm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.8 : Page number 287\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RL=1.0; #Load resistance, kilo ohm\n",
+ "A_v=40.0; #Voltage gain, dB\n",
+ "V_in=10.0; #Input signal voltage, mV\n",
+ "\n",
+ "#Calcultaions\n",
+ "#(i)\n",
+ "#Since, A_v=20*log10(V_out/V_in)\n",
+ "V_out=V_in*(10**(A_v/20))/1000; #Output voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "P_L=(V_out**2/RL); #The load power, mW\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"(i)The output voltage is %dV.\"%V_out);\n",
+ "print(\"(ii)The load poweris %dmW.\"%P_L);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)The output voltage is 1V.\n",
+ "(ii)The load poweris 1mW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.9 : Page number 287-288\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "P_2=40.0; #Output power, W\n",
+ "R=10.0; #Resistance of speaker, ohm\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "A_p_dB=25.0; #Power gain, dB\n",
+ "#Since, A_p_dB=10*log10(P_2/P_1)\n",
+ "P_1=(P_2/10**(A_p_dB/10))*1000; #Input power, mW\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "A_v_dB=40.0; #Voltage gain, dB\n",
+ "\n",
+ "#Since, P=(V**2)/R,\n",
+ "V_2=(P_2*R)**0.5; #Output voltage, V\n",
+ "\n",
+ "#Since, A_v_dB=20*log10(V_2/V_1)\n",
+ "V_1=(V_2/10**(A_v_dB/20))*1000; #Input voltage, mV\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "\n",
+ "print(\"(i)The input power=%.1fmW.\"%P_1);\n",
+ "print(\"(ii)The input voltage=%dmV.\"%V_1);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)The input power=126.5mW.\n",
+ "(ii)The input voltage=200mV.\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.10 : Page number 288\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_v_max=2000.0; #Maximum voltage gain\n",
+ "f_max=2.0; #Frequency at which maximum voltage gain occurs,kHz\n",
+ "A_v=1414.0; #Voltage gain at 50 Hz and 10kHz\n",
+ "f1=50; #Lower frequency at which gain is 1414, Hz\n",
+ "f2=10; #Upper frequency at which gain is 1414, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, bandwidth is the range of frequency over which gain is greater than or equal to 70.7% of maximum gain\n",
+ "if((A_v/A_v_max)*100 ==70.7): \n",
+ " print(\"(i)The bandwidth is from %dHz to %dkHz.\"%(f1,f2));\n",
+ " print(\"(ii)The lower cut-off frequency=%dHz.\"%f1);\n",
+ " print(\"(iii)The upper cut-off frequency=%dkHz.\"%f2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)The bandwidth is from 50Hz to 10kHz.\n",
+ "(ii)The lower cut-off frequency=50Hz.\n",
+ "(iii)The upper cut-off frequency=10kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.11 : Page number 291\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_v=60.0; #Voltage gain of single stage amplifier\n",
+ "R_C=500.0; #Collector load, ohm\n",
+ "R_in=1.0; #Input impedance, kilo ohm\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, there is no loading , second stage gain remains at A_v\n",
+ "#But, due to loading effect of input impedance of second stage, gain of first stage decreases\n",
+ "A_v_2=A_v; #Voltage gain of second stage\n",
+ "R_AC=round((R_C*R_in*1000)/(R_C+R_in*1000),0); #Effective load of first stage, ohm\n",
+ "A_v_1=A_v*R_AC/R_C; #Gain of first stage\n",
+ "A_v_T=A_v_1*A_v_2; #Total gain\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The total gain=%d.\"%A_v_T);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total gain=2397.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.12 : Page number 291-292\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rin=1.0; #Input resistance, kilo ohm\n",
+ "beta=100.0; #base current amplification factor\n",
+ "RC=2.0; #Collector load, kilo ohm\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "R_AC=(RC*Rin)/(RC+Rin); #Effective load on first stage, kilo ohm\n",
+ "A_v_1=round(beta*(R_AC/Rin),0); #Voltage gain of first stage\n",
+ "\n",
+ "#(ii)\n",
+ "A_v_2=round(beta*RC/Rin,0); #Voltage gain of second stage\n",
+ "\n",
+ "#(iii)\n",
+ "A_v_T=A_v_1*A_v_2; #Total voltage gain\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"(i)The voltage gain of first stage =%d.\"%A_v_1);\n",
+ "print(\"(ii)The voltage gain of second stage =%d.\"%A_v_2);\n",
+ "print(\"(iii)The total voltage gain =%d.\"%A_v_T);\n",
+ "\n",
+ "#Note: The approximation inthe text for A_v_1=66.66 is taken as 66 but here it has been taken 67 and therefore the total voltage is 13400 instead of 13200.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)The voltage gain of first stage =67.\n",
+ "(ii)The voltage gain of second stage =200.\n",
+ "(iii)The total voltage gain =13400.\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.13 : Page number 292\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RC=10.0; #Collector load of single stage amplifier, kilo ohm\n",
+ "Rin=1.0; #Input resistance, kilo ohm\n",
+ "beta=100.0; #base current amplification factor\n",
+ "RL=100.0; #Load resistor, ohm\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "R_AC=round((RC*1000)*RL/(RC*1000+RL),-1); #Effective collector load,\n",
+ "A_v=beta*R_AC/(Rin*1000); #Voltage gain\n",
+ "\n",
+ "#Results\n",
+ "print(\"The voltage gain=%d.\"%A_v);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain=10.\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.14 : Page number 292-293\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector suppply voltage, V\n",
+ "R1=10.0; #resistor R1, kilo ohm\n",
+ "R2=2.2; #resistor R2, kilo ohm\n",
+ "R3=10.0; #resistor R3, kilo ohm\n",
+ "R4=2.2; #resistor R4, kilo ohm\n",
+ "RC_1=3.6; #Collector resistor of first stage, kilo ohm\n",
+ "RC_2=4.0; #Collector resistor of second stage, kilo ohm\n",
+ "RE_1=900.0; #Emitter resistor of first stage, ohm\n",
+ "RE_2=1.0; #Emitter resistor of second stage, kilo ohm\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#Biasing potential for the second stage is the voltage across R4 resistor,\n",
+ "#so, by voltage divider rule:\n",
+ "VB=VCC*R4/(R3+R4); #Biasing potential for second stage,(Voltage across R4), V\n",
+ "\n",
+ "print(\"The biasing voltage for the second stage=%.1fV.\"%VB);\n",
+ "\n",
+ "#If coupling capacitor C_c is replaced by a wire, RC_1 and R3 become parallel\n",
+ "Req=round((RC_1*R3)/(RC_1+R3),2); #Equivalent resistance of R3 parallel with RC_1, kilo ohm\n",
+ "VB=VCC*R4/(Req+R4); #Biasing voltage if coupling capacitor is replaced by a wire, V\n",
+ "\n",
+ "print(\"The biasing voltage after replacing coupling capacitor by wire=%.2fV.\"%VB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The biasing voltage for the second stage=3.6V.\n",
+ "The biasing voltage after replacing coupling capacitor by wire=9.07V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.15 : Page number 293-294\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Function for calculating parallel resistance\n",
+ "def pr(r1,r2):\n",
+ " return (r1*r2)/(r1+r2);\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage, V\n",
+ "R1=22.0; #Resistor R1, kilo ohm\n",
+ "R2=3.3; #Resistor R2, kilo ohm\n",
+ "R3=5.0; #Resistor R3, kilo ohm\n",
+ "R4=1.0; #Resistor R4, kilo ohm\n",
+ "R5=15.0; #Resistor R5, kilo ohm\n",
+ "R6=2.5; #Resistor R6, kilo ohm\n",
+ "R7=5.0; #Resistor R7, kilo ohm\n",
+ "R8=1.0; #Resistor R8, kilo ohm\n",
+ "beta=200; #Base current amplification factor\n",
+ "RL=10.0; #Load resistor, kilo ohm\n",
+ "V_BE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#for 2nd stage\n",
+ "V_R6=round(VCC*R6/(R5+R6),2); #Voltage across R6, V (voltage divider rule)\n",
+ "V_R8=round(V_R6-V_BE,2); #Voltage across R8, V\n",
+ "IE_2=round(V_R8/R8,2); #Emitter current through R8, mA (OHM's LAW)\n",
+ "re_2nd_stage=round(25/IE_2,1); #a.c emitter resistance for 2nd stage, ohm\n",
+ "\n",
+ "#For 1st stage\n",
+ "V_R2=round(VCC*R2/(R1+R2),2); #Voltage across R2, V (voltage divider rule)\n",
+ "V_R4=round(V_R2-V_BE,2); #Voltage across R4, V\n",
+ "IE_1=round(V_R4/R4,2); #Emitter current through R4, mA (OHM's LAW)\n",
+ "re_1st_stage=round(25/IE_1,1); #a.c emitter resistance for 1st stage, ohm\n",
+ "\n",
+ "#(i)\n",
+ "Zin_base_2nd_stage=round((beta*re_2nd_stage)/1000,2); #input resistance of transistor base of 2nd stage, kilo ohm\n",
+ "Zin=round(pr(pr(R5,R6),Zin_base_2nd_stage),2); #Input impedance of the 2nd stage, kilo ohm\n",
+ "R_AC_1st_stage=round(pr(R3,Zin),2); #Effective collector load for 1st stage, kilo ohm\n",
+ "A_v_1=round(R_AC_1st_stage*1000/re_1st_stage,0); #voltage gain of 1st stage\n",
+ "\n",
+ "#(ii)\n",
+ "R_AC_2nd_stage=round(pr(R7,RL),2); #Effective collector load for 2nd stage, kilo ohm\n",
+ "A_v_2=round(R_AC_2nd_stage*1000/re_2nd_stage,1); #voltage gain of 2nd stage\n",
+ "\n",
+ "#(iii)\n",
+ "A_v_overall=A_v_1*A_v_2; #overall voltage gain\n",
+ "\n",
+ "\n",
+ "#results\n",
+ "print(\"(i)The voltage gain of 1st stage=%.0f.\"%A_v_1);\n",
+ "print(\"(i)The voltage gain of 2nd stage=%.1f.\"%A_v_2);\n",
+ "print(\"(i)The overall voltage gain =%d.\"%A_v_overall);\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)The voltage gain of 1st stage=53.\n",
+ "(i)The voltage gain of 2nd stage=191.4.\n",
+ "(i)The overall voltage gain =10144.\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.16 : Page number 297\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Primary_impedance=1000.0; #Primary impedance, ohm\n",
+ "Load_impedance=10.0; #Load impedance, ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#since,for maximum power transfer primary impedance should be equal to output impedance\n",
+ "#and, impedance of secondary should be equal to load impedance\n",
+ "#therfore, primary_impedance/load_impedance=square of(primary to secondary turn ratio)\n",
+ "n=(Primary_impedance/Load_impedance)**0.5; #Primary to secondary turn ratio\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print('The primary to secondary turn ratio for maximum power transfer=%d.'%n);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The primary to secondary turn ratio for maximum power transfer=10.\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.17 : Page number 297\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RL=16.0; #Load resistor, ohm\n",
+ "R_p=10.0; #Output impedance of primary, kilo ohm\n",
+ "Vp=10.0; #Terminal voltage of the source, V\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, for maximum power transfer, the impedance of the primary should be equal to output impedance of the source\n",
+ "n=(R_p*1000/RL)**0.5; #Primary to secondary turns ratio\n",
+ "\n",
+ "#Since, power in a transformer remains constant,\n",
+ "#ratio of primary to secondary voltageis equal to primary to secondary turns ratio\n",
+ "Vs=Vp/n; #Voltage across the external load, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The primary to secondary turns ratio=%d.\"%n);\n",
+ "print(\"The voltage across the external load=%.1fV.\"%Vs);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The primary to secondary turns ratio=25.\n",
+ "The voltage across the external load=0.4V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.18 : Page number 297-298\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rp=300.0; #D.C resistance of primary, ohm\n",
+ "RL=3.0; #Load resistance, ohm\n",
+ "R_out=3.0; #Ouput resistance of the transistor, kilo ohm \n",
+ "\n",
+ "#Calculation\n",
+ "#when no signal is applied, only Rp is seen to be the load.\n",
+ "#But, when a.c signal is applied, RL in secondary reflects as RL*(squre of turns ratio).\n",
+ "#Therefore, load is seen to be Rp in series with the reflected RL in primary.\n",
+ "#i.e, R_out=Rp+(n**2 * RL), where n is the turns ratio\n",
+ "n=((R_out*1000-Rp)/RL)**0.5; #turns ratio\n",
+ "\n",
+ "#Result\n",
+ "print(\"Turns ratio for maximum power transfer=%d.\"%n);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Turns ratio for maximum power transfer=30.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.19 : Page number 298"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "f=200.0; #Frequency, Hz\n",
+ "Z_out=10.0; #Output impedance of the transistor, kilo ohm\n",
+ "Z_in=2.5; #Input impedance of the next stage, kilo ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#For perfect impedance matching,\n",
+ "#Z_out should be equal to primary impedance\n",
+ "#Z_out=2*pi*f*(primary inductance)\n",
+ "Lp=(Z_out*1000)/(2*pi*f); #Primary inductance, H\n",
+ "\n",
+ "#for the secondary side,\n",
+ "#Z_in should be equal to impedance of secondary\n",
+ "Ls=(Z_in*1000)/(2*pi*f); #Secondary inductance, H\n",
+ "\n",
+ "\n",
+ "#result\n",
+ "print(\"The primary inductance=%.0fH.\"%Lp);\n",
+ "print(\"The secondary inductance=%.0fH.\"%Ls);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The primary inductance=8H.\n",
+ "The secondary inductance=2H.\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.20 : Page number 299\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Lp=8.0; #Primary inductance, H\n",
+ "Ls=2.0; #Secondary inductance, H\n",
+ "K=10**-5; #Inductance to turns ratio, constant\n",
+ "\n",
+ "#Calculations\n",
+ "Np=(Lp/K)**0.5; #Primary turns\n",
+ "Ns=(Ls/K)**0.5; #Secondary turns\n",
+ "\n",
+ "#Result\n",
+ "print(\"The primary turns=%.0f.\"%Np);\n",
+ "print(\"The secondary turns=%.0f.\"%Ns);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The primary turns=894.\n",
+ "The secondary turns=447.\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 11.21 : Page number 300-301\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage, V\n",
+ "R1=100.0; #Resistor R1, kilo ohm\n",
+ "R2=22.0; #Resistor R2, kilo ohm\n",
+ "R3=22.0; #Resistor R3, kilo ohm\n",
+ "R4=4.7; #Resistor R4, kilo ohm\n",
+ "R5=10.0; #Resistor R5, kilo ohm\n",
+ "R6=10.0; #Resistor R6, kilo ohm\n",
+ "beta=125; #Base current amplification factor\n",
+ "V_BE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) D.C voltages\n",
+ "#For 1st stage:\n",
+ "V_B1=VCC*R2/(R1+R2); #Voltage at the base of 1st transistor, V (Voltage across R2, using voltage divider rule)\n",
+ "V_E1=V_B1-V_BE; #Emitter voltage of the 1st transistor, V\n",
+ "I_E1=round(V_E1/R4,2); #Emitter current of 1st transistor, mA (OHM's LAW)\n",
+ "I_C1=I_E1; #Collector current of 1st transistor, mA(approximately equals to emitter current)\n",
+ "V_C1=VCC-I_C1*R3; #Collector voltage of 1st transistor, V\n",
+ "\n",
+ "#For 2nd stage:\n",
+ "V_B2=V_C1; #Voltage at the base of 2nd transistor, V (equals to collector voltage of 1st transistor)\n",
+ "V_E2=V_C1-V_BE; #Emitter voltage of the 2nd transistor, V\n",
+ "I_E2=V_E2/R6; #Emitter current of 2nd transistor, mA (OHM's LAW)\n",
+ "I_C2=I_E2; #Collector current 2nd transistor, mA(approximately equals to emitter current)\n",
+ "V_C2=VCC-I_C2*R5; #Collector voltage of 2nd transistor, V\n",
+ "\n",
+ "print(\"(i) D.C voltages\");\n",
+ "print(\"First stage: VB1=%.2fV , VE1=%.2fV and VC1=%.2fV\"%(V_B1,V_E1,V_C1));\n",
+ "print(\"First stage: VB2=%.2fV , VE2=%.2fV and VC2=%.2fV\"%(V_B2,V_E2,V_C2));\n",
+ "\n",
+ "#(ii)Voltage gain\n",
+ "#First stage\n",
+ "re_1=25/I_E1; #a.c emitter resistance of 1st transistor, ohm\n",
+ "re_2=25/I_E2; #a.c emitter resistance of 2nd transistor, ohm\n",
+ "Zin_2nd_stage=beta*re_2/1000; #Input impedance of 2nd stage, kilo ohm\n",
+ "R_AC=R3*Zin_2nd_stage/(R3+Zin_2nd_stage); #Total a.c collector load, kilo ohm\n",
+ "A_v1=round(R_AC*1000/re_1,0); #Voltage gain of first stage\n",
+ "\n",
+ "print(\"The voltage gain of first stage=%d.\"%A_v1);\n",
+ "\n",
+ "#Second stage\n",
+ "R_AC=R5; #Total a.c collector load for 2nd stage, kilo ohm(Due to no loading effect, equal to R5)\n",
+ "A_v2=round(R5*1000/re_2,0); #Voltage gain of 2nd stage\n",
+ "\n",
+ "print(\"The voltage gain of second stage=%d.\"%A_v2);\n",
+ "\n",
+ "A_vT=A_v1*A_v2; #Overall voltage gain\n",
+ "\n",
+ "print(\"Overall voltage gain=%d.\"%A_vT);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) D.C voltages\n",
+ "First stage: VB1=2.16V , VE1=1.46V and VC1=5.18V\n",
+ "First stage: VB2=5.18V , VE2=4.48V and VC2=7.52V\n",
+ "The voltage gain of first stage=66.\n",
+ "The voltage gain of second stage=179.\n",
+ "Overall voltage gain=11814.\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter12_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter12_1.ipynb
new file mode 100644
index 00000000..05e3d9d8
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter12_1.ipynb
@@ -0,0 +1,968 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:1e9209171152811793fc18d1ee8c80ddcef574d69421ec87eeaa8fb87a304f6d"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 12: TRANSISTOR AUDIO POWER AMPLIFIERS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.1 : Page number 308\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "R1=10.0; #Resistor R1, kilo ohm\n",
+ "R2=2.2; #Resistor R2, kilo ohm\n",
+ "RC=3.6; #Collector resistor, kilo ohm\n",
+ "RE=1.1; #Emitter resistor, kilo ohm\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "I1=VCC/(R1+R2); #Current through R1 and R2, mA (OHM's LAW)\n",
+ "V2=I1*R2; #Voltage across R2 resistor, V (OHM's LAW)\n",
+ "VE=V2-VBE; #Emitter voltage, V\n",
+ "IE=VE/RE; #Emitter current, mA (OHM's LAW)\n",
+ "IC=IE; #Collector current, mA (approximately equal to emitter current)\n",
+ "I_T=I1+IC; #Total current drawn from the supply, mA\n",
+ "P_dc=VCC*I_T; #Total power drawn from the supply, mW\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The total power drawn from the supply=%.1fmW.\"%P_dc);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total power drawn from the supply=18.2mW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.2 : Page number 309\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_L=10.6; #Voltage across load, V.(from a.c voltmeter, therfore r.m.s value)\n",
+ "R_L=200.0; #Load resistance, ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, power =V**2/R,\n",
+ "P_O=(V_L**2/R_L)*1000; #A.C output power, mW\n",
+ "\n",
+ "#Result\n",
+ "print(\"The a.c output power = %.1fmW.\"%P_O);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The a.c output power = 561.8mW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.3 : Page number 309\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RL=100.0; #Load resistance, ohm\n",
+ "V_PP=18.0; #Peak-to-peak a.c voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, V(r.m.s)=(V(peak-to-peak)/2)/sqrt(2)\n",
+ "VL=V_PP/(2*(2**0.5)); #r.m.s value, V\n",
+ "\n",
+ "#Since, power=(square of voltage)/resistance\n",
+ "P_O_max=(VL**2/RL)*1000; #Maximum possible a.c load power, mW\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum possible a.c load power=%dmW.\"%P_O_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum possible a.c load power=405mW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.4 : Page number 310\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_battery=12.0; #Battery voltage, V\n",
+ "P_out=2.0; #Output power, W\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Power=Current*Voltage\n",
+ "IC=(P_out/V_battery)*1000; #Maximum collector current , mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum collector current=%.1fmA.\"%IC);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum collector current=166.7mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.5 : Page number 310\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_battery=12.0; #Battery voltage, V\n",
+ "RL=4.0; #Collector load, kilo ohm\n",
+ "\n",
+ "#Calculation\n",
+ "IC_max=V_battery/RL; #Maximum collector current, mA\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum collector current=%dmA.\"%IC_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum collector current=3mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.6 : Page number 310-311\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "P=50.0; #Power supplied by power amplifier, W\n",
+ "R=8.0; #Resistance of speaker, ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#Since, Power=Voltage _square/Resistance,\n",
+ "V=(P*R)**0.5; #a.c output voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "I=V/R; #a.c output current, A (OHM's LAW)\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The a.c output voltage=%dV.\"%V);\n",
+ "print(\"(ii) The a.c output current=%.1fA.\"%I);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The a.c output voltage=20V.\n",
+ "(ii) The a.c output current=2.5A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.7 : Page number 315\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector supply voltage, V\n",
+ "ib_peak=10.0; #Base current(peak), mA\n",
+ "RB=1.0; #Base resistance, kilo ohm\n",
+ "RC=20.0; #Collector resistance, ohm\n",
+ "beta=25.0; #Base current amplification factor\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "IB=round(VCC-VBE/RB,1); #Base current, mA (OHM's LAW)\n",
+ "IC=int(beta*IB); #Collector current, mA\n",
+ "VCE=VCC-(IC/1000)*RC; #Collector emitter voltage, V (KVL)\n",
+ "\n",
+ "#(i)\n",
+ "ic_peak=beta*ib_peak; #Collector current(peak), mA\n",
+ "P_o_ac=(ic_peak/1000)**2*RC/2; #Output power, W\n",
+ "\n",
+ "#(ii)\n",
+ "P_dc=VCC*IC/1000; #Input power, W\n",
+ "\n",
+ "#(iii)\n",
+ "collector_efficiency=(P_o_ac/P_dc)*100; #Collector efficiency of the amplifier circuit,\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The output power=%.3fW.\"%P_o_ac);\n",
+ "print(\"(ii) The input power=%.1fW.\"%P_dc);\n",
+ "print(\"(iii) The collector efficiency=%.1f%%.\"%collector_efficiency);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The output power=0.625W.\n",
+ "(ii) The input power=9.6W.\n",
+ "(iii) The collector efficiency=6.5%.\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.8 : Page number 317\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "P_dc=10.0; #zero signal power dissipation, W\n",
+ "P_o=4.0; #a.c output power, W\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Collector_eff=(P_o/P_dc)*100; #collector efficiency\n",
+ "\n",
+ "#(ii)\n",
+ "#Zero signal power is the maximum power dissipation in a transistor, therefore,\n",
+ "Power_rating=P_dc; #Power rating of the transistor, W\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The collector efficiency=%d%%.\"%Collector_eff);\n",
+ "print(\"(i) The power rating of the transistor=%dW.\"%Power_rating);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The collector efficiency=40%.\n",
+ "(i) The power rating of the transistor=10W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.9 : Page number 317-318\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RL=100.0; #Secondary load, ohm\n",
+ "n=10.0; #Transformer turn ratio\n",
+ "IC=100.0; #Zero signal collector current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "RL_reflected=n**2*RL; #Reflected load as seen by the primary of the transformer, ohm\n",
+ "P_o_ac_max=(IC/1000)**2*RL_reflected/2; #Maximum a.c power output, W \n",
+ "\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum a.c power output=%dW.\"%P_o_ac_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum a.c power output=50W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.10 : Page number 318\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=5.0; #Collector supply voltage, V\n",
+ "IC=50.0; #Zero signal collector current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "P_o_max=VCC*IC/2; #Maximum a.c output power, mW\n",
+ "\n",
+ "#(ii)\n",
+ "P_dc=VCC*IC; #D.C input power, mW\n",
+ "#Since, maximum power is dissipated in the zero signal conditions\n",
+ "Power_rating=P_dc; #Power rating of transistor, mW\n",
+ "\n",
+ "#(iii)\n",
+ "Max_collector_eff=(P_o_max/P_dc)*100; #Maximum collector efficiency\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The maximum a.c output power=%dmW\"%P_o_max);\n",
+ "print(\"(ii) The power rating of the transistor=%dmW.\"%Power_rating);\n",
+ "print(\"(iii) The maximum collector efficiency =%d%%.\"%Max_collector_eff);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The maximum a.c output power=125mW\n",
+ "(ii) The power rating of the transistor=250mW.\n",
+ "(iii) The maximum collector efficiency =50%.\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.11 : Page number 318\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "ic_max=160.0; #Maximum a.c collector current, mA\n",
+ "ic_min=10.0; #Minimum a.c collector current, mA\n",
+ "vce_max=12.0; #Maximum collector-emitter voltage, V\n",
+ "vce_min=2.0; #Minimum collector-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "vce_pp=vce_max-vce_min; #peak to peak collector emitter voltage, V\n",
+ "ic_pp=ic_max-ic_min; #peak to peak collector current, V\n",
+ "P_o=(vce_pp/(2*sqrt(2)))*(ic_pp/(2*sqrt(2))); #a.c output power, mW\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The a.c output power=%.1fmW.\"%P_o);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The a.c output power=187.5mW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.12 : Page number 319-320\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt \n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=12.0; #Battey voltage, V\n",
+ "IC_max_change=100.0; #maximum collector current change, mA\n",
+ "RL=5.0; #Loudspeaker resistance, ohm\n",
+ "\n",
+ "#Calculation\n",
+ "VCE_max_change=VCC; #Maximum collector-emitter voltage change\n",
+ "#(i) Loud speaker directly connected in the collector\n",
+ "Vmax_speaker=(IC_max_change/1000)*RL; #Maximum voltage across the loudspeaker, V\n",
+ "P_speaker_directly_coupled=Vmax_speaker*IC_max_change; #Power developed in the loudspeaker,mW\n",
+ "\n",
+ "#(ii) Loudspeaker transformer coupled\n",
+ "Z_out=(VCE_max_change/IC_max_change)*1000; #Output impedance of transistor, ohm\n",
+ "\n",
+ "#For max power transfer, primary impedance should be Z_out\n",
+ "RL_reflected=Z_out; #Load resistance as seen by primary, ohm\n",
+ "n=sqrt(RL_reflected/RL); #Turns ratio of transformer\n",
+ "Vp=VCC; #Transformer primary voltage, V\n",
+ "Vs=Vp/n; #Transformer secondary voltage, V\n",
+ "IL=Vs/RL; #Load current, A\n",
+ "P_speaker_transformer_coupled=IL**2*RL*1000; #Power delivered to the speaker, mW\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The power transferred to the speaker when directly coupled=%dmW.\"%P_speaker_directly_coupled);\n",
+ "print(\"(ii) The power trasnferred to the speaker when transformer-coupled=%dmW.\"%P_speaker_transformer_coupled);\n",
+ "print(\" The turns ratio=%.1f.\"%n);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The power transferred to the speaker when directly coupled=50mW.\n",
+ "(ii) The power trasnferred to the speaker when transformer-coupled=1200mW.\n",
+ " The turns ratio=4.9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.13 : Page number 320-321\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "RL=81.6; #Load resistance, ohm\n",
+ "VCE_peak=30.0; #Peak value of collector voltage, V\n",
+ "IC_peak=35.0; #Peak value of collector current, mA\n",
+ "VCE_min=5.0; #Minimum value of collector voltage, V\n",
+ "IC_min=1.0; #Minimum value of collector current, mA\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "IC_zero_signal=(IC_peak-IC_min)/2 +1; #Zero signal collector current, mA\n",
+ "\n",
+ "#(ii)\n",
+ "IB_zero_signal=IC_zero_signal/beta; #Zero signal base current, mA\n",
+ "\n",
+ "#(iii)\n",
+ "VCE_zero_signal=(VCE_peak-VCE_min)/2 +5; #Zero signal collector-emitter voltage, V\n",
+ "VCC=VCE_zero_signal; #Collector supply voltage,V (due to transformer coupling, aproximately equal to zero signal VCE)\n",
+ "P_dc=VCC*IC_zero_signal; #d.c input power, mW\n",
+ "VCE_ac=(VCE_peak-VCE_min)/(2*sqrt(2)); #a.c output voltage, V\n",
+ "IC_ac=(IC_peak-IC_min)/(2*sqrt(2)); #a.c output current, mA\n",
+ "P_ac=VCE_ac*IC_ac; #a.c output power, mW\n",
+ "\n",
+ "#(iv)\n",
+ "collector_eff=(P_ac/P_dc)*100; #Collector efficiency\n",
+ "\n",
+ "#(v)\n",
+ "#a.c resistance RL'=negative inverse of slope of the d.c load line\n",
+ "slope=(IC_peak-IC_min)/(VCE_min-VCE_peak); #Slope of he d.c load line, kilo mho\n",
+ "RL_ac=-(1/slope)*1000; #a.c resistance, ohm\n",
+ "n=sqrt(RL_ac/RL); #Transformer turn ratio\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The approximate value of zero signal collector current=%dmA.\"%IC_zero_signal);\n",
+ "print(\"(ii) The zero signal base current=%.2fmA.\"%IB_zero_signal);\n",
+ "print(\"(iii) The d.c input power= %dmW and a.c output power =%dmW.\"%(P_dc,P_ac));\n",
+ "print(\"(iv) The collector efficiency=%.1f%%.\"%collector_eff);\n",
+ "print(\"(v) The turn ratio of the transformer=%d.\"%n);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The approximate value of zero signal collector current=18mA.\n",
+ "(ii) The zero signal base current=0.18mA.\n",
+ "(iii) The d.c input power= 315mW and a.c output power =106mW.\n",
+ "(iv) The collector efficiency=33.7%.\n",
+ "(v) The turn ratio of the transformer=3.\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.14 : Page number 321-322\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "RL=13.0; #Load resistance, ohm\n",
+ "RL_reflected=325.0; #Load resistance, when referred to primary, ohm\n",
+ "VCC=20.0; #Supply voltage, V\n",
+ "IC=58.0; #Quiscent value of collector current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "n=sqrt(RL_reflected/RL); #Transformer turn ratio\n",
+ "\n",
+ "#(ii)\n",
+ "P_ac=(((IC/1000)**2)*RL_reflected/2)*1000; #A.C output power, mW\n",
+ "\n",
+ "#(iii)\n",
+ "P_dc=VCC*IC; #d.c input power, mW\n",
+ "collector_eff=(P_ac/P_dc)*100; #Collector efficiency\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Transformer turn ratio=%d.\"%n);\n",
+ "print(\"(ii) The a.c output power=%dmW.\"%P_ac);\n",
+ "print(\"(iii) The collector efficiency=%d%%.\"%collector_eff);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Transformer turn ratio=5.\n",
+ "(ii) The a.c output power=546mW.\n",
+ "(iii) The collector efficiency=47%.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.15 : Page number 323\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "P_total=4.0; #Total power dissipated by the power transistor, W\n",
+ "T_j_max=90.0; #Maximum junction temperature, degree celsius\n",
+ "theta=10.0; #Thermal resistance, degree celsius per watt\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Total power dissipation=half of(max. junc. temp. - ambient temp.)\n",
+ "T_amb=T_j_max-(P_total*theta); #Ambient temperature, degree celsius\n",
+ "\n",
+ "#Result\n",
+ "print(\"The ambient temperature=%d degree celsius.\"%T_amb);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The ambient temperature=50 degree celsius.\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.16 : Page number 323-324\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "theta=300.0; #Thermal resistance, degree celsius per watt\n",
+ "T_j_max=90.0; #Maximum junction temperature, degree celsius\n",
+ "T_amb=30.0; #Ambient temperature, degree celsius\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) Without heat sink\n",
+ "P_total=((T_j_max-T_amb)/theta)*1000; #Maximum permissible power dissipation without sink, mW\n",
+ "\n",
+ "print(\"(i)The maximum permissible power dissipation without heat sink=%dmW.\"%P_total);\n",
+ "\n",
+ "#(ii) With heat sink\n",
+ "theta=60.0; #reduced thermal resistance, degree celsius per watt\n",
+ "P_total=((T_j_max-T_amb)/theta)*1000; #Maximum permissible power dissipation with heat sink, mW\n",
+ "\n",
+ "print(\"(ii)The maximum permissible power dissipation with heat sink=%dmW.\"%P_total);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)The maximum permissible power dissipation without heat sink=200mW.\n",
+ "(ii)The maximum permissible power dissipation with heat sink=1000mW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.17 : Page number 324\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "theta=20.0; #Thermal resistance, degree celsius per watt\n",
+ "T_j_max=200.0; #Maximum junction temperature, degree celsius\n",
+ "T_amb=25.0; #Ambient temperature, degree celsius\n",
+ "VCE=4.0; #Collector-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "P_total=(T_j_max-T_amb)/theta; #Maximum permissible power dissipation, W\n",
+ "\n",
+ "#since, the max. power dissipation=VCE_max*IC_max,therefore\n",
+ "IC_max=P_total/VCE; #Maximum collector current, A\n",
+ "\n",
+ "print(\"The maximum collector current that the transistor can carry without destruction=%.2fA.\"%IC_max);\n",
+ "\n",
+ "#The ambient temperature rises\n",
+ "T_amb=75.0; #The risen ambibent temperature, degree celsius\n",
+ "P_total=(T_j_max-T_amb)/theta; #Maximum permissible power dissipation, W\n",
+ "IC_max=P_total/VCE; #Maximum collector current, A\n",
+ "\n",
+ "print(\"The maximum collector current for the risen ambient temperature=%.2fA.\"%IC_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum collector current that the transistor can carry without destruction=2.19A.\n",
+ "The maximum collector current for the risen ambient temperature=1.56A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.18 : Page number 328-329\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=12.0; #Supply voltage, V\n",
+ "RL=8.0; #Driving load, ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "IC_sat=VCC/(2*RL); #Collector saturation current, A\n",
+ "P_o_max=round(VCC*IC_sat*0.25,2); #Maximum load power, W\n",
+ "\n",
+ "#(ii)\n",
+ "P_dc=round(VCC*IC_sat/round(pi,2),2); #d.c input power, W\n",
+ "\n",
+ "#(iii)\n",
+ "Collector_eff=(P_o_max/P_dc)*100; #Collector efficiency\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The maximum load power =%.2fW.\"%P_o_max);\n",
+ "print(\"(ii) The d.c input power=%.2fW.\"%P_dc);\n",
+ "print(\"(iii) The collector efficiency=%.1f%%.\"%Collector_eff);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The maximum load power =2.25W.\n",
+ "(ii) The d.c input power=2.87W.\n",
+ "(iii) The collector efficiency=78.4%.\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.19 : Page number 329\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "P_T=10.0; #Power rating of each transistor, W\n",
+ "max_eff=0.785; #Maximum collector effciency\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, input power=max. a.c power + Power rating of transistor\n",
+ "#And, max. efficiency=max. a.c power/input d.c power\n",
+ "P_2T=2*P_T; #Total power dissipation by two transistors\n",
+ "P_o_max=(max_eff*P_2T)/(1-max_eff); #Maximum output a.c power, W\n",
+ "\n",
+ "#result\n",
+ "print(\"The maximum output power that can be obtained=%.2fW.\"%P_o_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum output power that can be obtained=73.02W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.20 : Page number 329\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "eff=60.0/100; #Efficiency of the amplifier\n",
+ "P_T=2.5; #Power dissipated by each transistor, W\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, input power=max. a.c power + Power rating of transistor\n",
+ "#And, max. efficiency=max. a.c power/input d.c power\n",
+ "P_2T=2*P_T; #Total power dissipated by both transistors, W\n",
+ "P_ac=(eff*P_2T)/(1-eff); #Output a.c power, W\n",
+ "P_dc=P_ac+P_2T; #Input d.c power, W\n",
+ "\n",
+ "#Result\n",
+ "print(\"The a.c output power= %.1fW.\"%P_ac);\n",
+ "print(\"The d.c input power= %.1fW.\"%P_dc);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The a.c output power= 7.5W.\n",
+ "The d.c input power= 12.5W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 32
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.21 : Page number 329-330\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Supply voltage, V\n",
+ "RL=10.0; #Load resistance, ohm\n",
+ "\n",
+ "#Calculation\n",
+ "IC_sat=(VCC/(2*RL))*1000; #Saturated collector current, mA\n",
+ "VCE_off=VCC/2; #Collector-emitter voltage in off state, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"1st end point of a.c load line, IC(sat)=%dmA.\"%IC_sat);\n",
+ "print(\"2nd end point of a.c load line, VCE(off)=%dV.\"%VCE_off);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "1st end point of a.c load line, IC(sat)=500mA.\n",
+ "2nd end point of a.c load line, VCE(off)=5V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 33
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter13_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter13_1.ipynb
new file mode 100644
index 00000000..8c036515
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter13_1.ipynb
@@ -0,0 +1,1147 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:950272de386b8a006089886b37042be2cbcff413c494ad9f74eae7a1268e49ba"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 13: AMPLIFIERS WITH NEGATIVE FEEDBACK"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.1 : Page number 338\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=3000.0; #Voltage gain without feedback\n",
+ "m_v=0.01; #Feedback fraction\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "Avf=Av/(1+Av*m_v); #Voltage gain of the amplifier with negative feedback\n",
+ "\n",
+ "#Result\n",
+ "print(\"The voltage gain of the amplifier with negative feedback=%.0f.\"%Avf);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain of the amplifier with negative feedback=97.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.2 : Page number 339\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=140.0; #Voltage gain\n",
+ "Avf=17.5; #Voltage gain with negative feedback\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Avf=Av/(1+Av*mv), so,\n",
+ "mv=(Av-Avf)/(Av*Avf); #Fraction of output fedback to the input\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The fraction of output fedback to the input=1/%.0f.\"%(1.0/mv));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The fraction of output fedback to the input=1/20.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.3 : Page number 339\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=100.0; #Voltage gain\n",
+ "Avf=50.0; #Voltage gain with negative feedback\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "mv=(Av-Avf)/(Av*Avf); #The fraction of output fedback to input\n",
+ "\n",
+ "#(ii) Overall gain is to be 75:\n",
+ "Avf=75.0; #The required overall gain\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "Av=Avf/(1-Avf*mv); #The required value of amplifier gain\n",
+ "\n",
+ "#result\n",
+ "print(\"(i) The fraction of output fedback to input=%.2f.\"%mv);\n",
+ "print(\"(ii) The required amplifier gain for overall gain to be 75=%d.\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The fraction of output fedback to input=0.01.\n",
+ "(ii) The required amplifier gain for overall gain to be 75=300.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.4 : Page number 339-340\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vout=10.0; #output voltage , V\n",
+ "Vin_f=0.5; #Input votage for amplifier with feedback, V\n",
+ "Vin=0.25; #Input votage for amplifier without feedback, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Av=Vout/Vin; #Voltage gain without negative feedback\n",
+ "\n",
+ "#(ii)\n",
+ "Avf=Vout/Vin_f; #Voltage gain with negative feedback\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "mv=(Av-Avf)/(Av*Avf); #Feedback fraction\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The voltage gain without feedback=%d.\"%Av);\n",
+ "print(\"(ii) The feedback fraction = 1/%d.\"%(1/mv));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The voltage gain without feedback=40.\n",
+ "(ii) The feedback fraction = 1/40.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.5 : Page number 340\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=50.0; #Gain without feedback\n",
+ "Avf=25.0; #Gain with negative feedback\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "mv=(Av-Avf)/(Av*Avf); #Feedback fraction\n",
+ "\n",
+ "#(i)\n",
+ "#percentage of reduction without feedback\n",
+ "Av_reduced=40.0; #Reduced amplifier gain due to ageing\n",
+ "percentage_of_reduction=((Av-Av_reduced)/Av)*100; #Percentage of reduction in stage gain\n",
+ "\n",
+ "print(\"(i) The percentage of reduction in stage gain without feedback=%d%%.\"%percentage_of_reduction);\n",
+ "\n",
+ "#(ii)\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "Avf_reduced=round(Av_reduced/(1+mv*Av_reduced),1); #Reduced net gain with negative feedback \n",
+ "percentage_of_reduction_f=((Avf-Avf_reduced)/Avf)*100; #Percentage of reduction in net gain with feedback\n",
+ "\n",
+ "print(\"(ii) The percentage of reduction in net gain with feedback=%.1f%%\"%percentage_of_reduction_f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The percentage of reduction in stage gain without feedback=20%.\n",
+ "(ii) The percentage of reduction in net gain with feedback=11.2%\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.6 : Page number 340\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=100.0; #Gain\n",
+ "mv=0.1; #feedback fraction\n",
+ "Av_fall=6.0; #fall in gain, dB\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "Avf=round(Av/(1+Av*mv),2); #Total system gain with feedback\n",
+ "\n",
+ "#Since, fall in gain=20*log10(Av/Av_1)\n",
+ "Av1=round(Av/10**(Av_fall/20),0); #New absolute voltage gain without feedback\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "Avf_new=round(Av1/(1+Av1*mv),2); #New net system gain with feedback\n",
+ "\n",
+ "percentage_change=((Avf-Avf_new)/Avf)*100; #Percentage change in system gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"The percentage change in system gain=%.2f%%\"%percentage_change);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The percentage change in system gain=8.36%\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.7 : Page number 341\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=500.0; #Voltage gain without feedback\n",
+ "Avf=100.0; #Voltage gain with negative feedback\n",
+ "Av_fall_percentage=20.0; #Gain fall percentage due to ageing\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "mv=(Av-Avf)/(Av*Avf); #Feedback fraction\n",
+ "Av_reduced=((100-Av_fall_percentage)/100)*Av; #Reduced voltage gain\n",
+ "Avf_reduced=round(Av_reduced/(1+Av_reduced*mv),1); #Reduced total gain of the system\n",
+ "percentage_fall=((Avf-Avf_reduced)/Avf)*100; #Percentage of fall in total system gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"The feedback fraction=%.3f.\"%mv);\n",
+ "print(\"The percentage fall in system gain=%.1f%%.\"%percentage_fall);\n",
+ "\n",
+ "#Note: The percentage gain is calculated in the text as 4.7% due to approximation of Avf to 95.3 whose actual approximation will be (95.238)~95.2. So, the percentage fall calculated here is 4.8%\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The feedback fraction=0.008.\n",
+ "The percentage fall in system gain=4.8%.\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.8 : Page number 341\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "Av=100000.0; #Open loop voltage gain\n",
+ "f_dB=10.0; #Negative feedback, dB\n",
+ "\n",
+ "#Calculation\n",
+ "Av_dB=20*log10(Av); #dB voltage gain without feedback, dB\n",
+ "Avf_dB=Av_dB-f_dB; #dB voltage gain with feedback, dB\n",
+ "Avf=10**(Avf_dB/20); #Voltage gain with feedback\n",
+ "\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "mv=(Av-Avf)/(Av*Avf); #feedback fraction\n",
+ "\n",
+ "#Result\n",
+ "print(\"The voltage gain with feedback=%d.\"%Avf);\n",
+ "print(\"The feedback fraction=%.2e.\"%mv);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain with feedback=31622.\n",
+ "The feedback fraction=2.16e-05.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.9 : Page number 341-342\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ao=1000.0; #Open circuit voltage gain\n",
+ "Rout=100.0; #Output resistance, ohm\n",
+ "RL=900.0; #Resistive load, ohm\n",
+ "mv=1/50; #feedback fraction\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Av=Ao*RL/(Rout+RL)\n",
+ "Av=Ao*RL/(Rout+RL); #Voltage gain without feedback\n",
+ "Avf=Av/(1+Av*mv); #Voltage gain with feedback\n",
+ "\n",
+ "#Result\n",
+ "print(\"The voltage gain with feedback=%.1f.\"%Avf);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain with feedback=900.0.\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.10 : Page number 342\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Avf=100.0; #Voltage gain with feedback\n",
+ "vary_f=1; #Vary percentage in voltage gain with feedback\n",
+ "vary_wf=20; #Vary percentage in voltage gain without feedback\n",
+ "\n",
+ "#Calculation\n",
+ "#Avf=Av/(1+Av*mv)\n",
+ "print(\"%d=Av/(1+Av*mv) ------Eq. 1\"%Avf); #Equation 1\n",
+ "\n",
+ "#considering variation in gains\n",
+ "Avf_vary=Avf*(1- vary_f/100.0); #Gain with feedback, considering variation\n",
+ "print(\"%d=%.1f*Av/(1+%.1f*Av*mv) ------Eq. 2\"%(Avf_vary,(1-vary_wf/100.0),(1-vary_wf/100.0))); #Equation 2\n",
+ "\n",
+ "#Solving the above two equations\n",
+ "print(\"%d + %.1f*Av*mv=%.1fAv ------Eq. 3 from Eq. 2\"%(Avf_vary,Avf_vary*(1-vary_wf/100.0),(1-vary_wf/100.0))); #Equation 3\n",
+ "\n",
+ "#multiplying Eq. 1 with (Avf_vary*(1-vary_wf/100.0))/100=0.792\n",
+ "print(\"%.1f + %.1f*Av*mv=%.3fAv ------Eq. 4 from Eq. 1\"%(Avf*Avf_vary*(1-vary_wf/100.0)/100.0,Avf*Avf_vary*(1-vary_wf/100.0)/100.0,Avf_vary*(1-vary_wf/100.0)/100.0)); #Equation 4\n",
+ "\n",
+ "print(\"Subtracting Eq.4 from Eq.3\" );\n",
+ "print(\"%.1f = %.3f*Av\"%(Avf_vary-Avf*Avf_vary*(1-vary_wf/100.0)/100.0,(1-vary_wf/100.0)-Avf_vary*(1-vary_wf/100.0)/100.0));\n",
+ "Av=(Avf_vary-Avf*Avf_vary*(1-vary_wf/100.0)/100.0)/((1-vary_wf/100.0)-Avf_vary*(1-vary_wf/100.0)/100.0);\n",
+ "print(\"Av=%.0f.\"%Av);\n",
+ "mv=(Av-Avf)/(Av*Avf);\n",
+ "print(\"mv=%.4f.\"%mv);\n",
+ " "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "100=Av/(1+Av*mv) ------Eq. 1\n",
+ "99=0.8*Av/(1+0.8*Av*mv) ------Eq. 2\n",
+ "99 + 79.2*Av*mv=0.8Av ------Eq. 3 from Eq. 2\n",
+ "79.2 + 79.2*Av*mv=0.792Av ------Eq. 4 from Eq. 1\n",
+ "Subtracting Eq.4 from Eq.3\n",
+ "19.8 = 0.008*Av\n",
+ "Av=2475.\n",
+ "mv=0.0096.\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.11 : Page number 345\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=10000.0; #Volage gain without feedback\n",
+ "R1=2.0; #Resistor R1, kilo ohm\n",
+ "R2=18.0; #Resistor R2, kilo ohm\n",
+ "Vin=1.0; #input voltage, mV\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "mv=R1/(R1+R2); #feedback fraction\n",
+ "\n",
+ "#(ii)\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "Avf=round(Av/(1+Av*mv),0); #Voltage gain with feedback\n",
+ "\n",
+ "#(iii)\n",
+ "Vout=Avf*Vin; #Output voltage, mV\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Feedback fraction=%.1f.\"%mv);\n",
+ "print(\"(ii) Voltage gain with feedback=%d.\"%Avf);\n",
+ "print(\"(iii) Output voltage=%dmV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Feedback fraction=0.1.\n",
+ "(ii) Voltage gain with feedback=10.\n",
+ "(iii) Output voltage=10mV.\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.12 : Page number 345-346\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=10000.0; #Volateg gain without feedback\n",
+ "Zin=10.0; #Input impedance, kilo ohm\n",
+ "Zout=100.0; #Output impedance, ohm\n",
+ "R1=10.0; #Resistor R1, kilo ohm\n",
+ "R2=90.0; #Resistor R2, kilo ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "mv=R1/(R1+R2); #Feedback fraction\n",
+ "\n",
+ "#(ii)\n",
+ "#Since, Gain_with_feedback= Gain_without_feedback/(1+Gain_without_feedback*feedback_fraction),\n",
+ "Avf=round(Av/(1+Av*mv),0); #Voltage gain with feedback\n",
+ "\n",
+ "#(iii)\n",
+ "Zin_feedback=((1+Av*mv)*Zin)/1000; #Increased input impedance due to negative feedback, mega ohm\n",
+ "\n",
+ "#(iv)\n",
+ "Zout_feedback=Zout/(1+Av*mv); #Decreased output impedance due to negative feedback, ohm\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Feedback fraction=%.1f.\"%mv);\n",
+ "print(\"(ii) The voltage gain with feedback=%d.\"%Avf);\n",
+ "print(\"(iii) Increased input impedance due to negative feedback=%.0f mega ohm\"%Zin_feedback);\n",
+ "print(\"(iv) Decreased output impedance due to negative feedback=%.1f ohm.\"%Zout_feedback);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Feedback fraction=0.1.\n",
+ "(ii) The voltage gain with feedback=10.\n",
+ "(iii) Increased input impedance due to negative feedback=10 mega ohm\n",
+ "(iv) Decreased output impedance due to negative feedback=0.1 ohm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.13 : Page number 346\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=150.0; #Voltage gain\n",
+ "D=5/100.0; #Distortion\n",
+ "mv=10/100.0; #Feedback fraction\n",
+ "\n",
+ "#Calculation\n",
+ "Dvf=round((D/(1+Av*mv))*100,3); #Distortion with negative feedback\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Distortion with negative feedback=%.3f%%\"%Dvf);\n",
+ "\n",
+ "#Note: In the text, value of Dvf=0.3125% has been approximated to 0.313%. But, here the approximation is done to 0.312%\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Distortion with negative feedback=0.313%\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.14 : Page number 346\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Av=1000.0; #Voltage gain\n",
+ "f1=1.5; #Lower cut-off frequency, kHz\n",
+ "f2=501.5; #Upper cut-off frequency, kHz\n",
+ "mv=1/100.0; #Feedbcack fraction\n",
+ "\n",
+ "#Calculation\n",
+ "f1_f=(f1/(1+mv*Av))*1000; #New lower cut-off frequency, Hz\n",
+ "f2_f=(f2*(1+mv*Av))/1000; #New upper cut-off frequency, MHz\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The new lower cut-off frequency=%.1fHz\"%f1_f);\n",
+ "print(\"The new upper cut-off frequency=%.2fMHz\"%f2_f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The new lower cut-off frequency=136.4Hz\n",
+ "The new upper cut-off frequency=5.52MHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.15 : Page number 348\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ai=200.0; #Current gain without feedback\n",
+ "mi=0.012; #Current attenuation\n",
+ "\n",
+ "#Calculation\n",
+ "Aif=Ai/(1+Ai*mi);\n",
+ "\n",
+ "#Result\n",
+ "print(\"The effective current gain=%.2f.\"%Aif);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The effective current gain=58.82.\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.16 : Page number 349\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ai=240.0; #Current gain\n",
+ "Zin=15.0; #Input impedance without feedback, kilo ohm\n",
+ "mi=0.015; #Current feedback fraction\n",
+ "\n",
+ "#Calculations\n",
+ "Zin_f=Zin/(1+mi*Ai); #Input impedance with feedback, kilo ohm\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The input impedance when negative feedback is applied=%.2f kilo ohm\"%Zin_f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The input impedance when negative feedback is applied=3.26 kilo ohm\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.17 : Page number 349\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ai=200.0; #Current gain without feedback\n",
+ "Zout=3.0; #Output impedance without feedback, kilo ohm\n",
+ "mi=0.01; #current feedback fraction\n",
+ "\n",
+ "#Calculation\n",
+ "Zout_f=Zout*(1+mi*Ai); #Output impedance with negative feedback, kilo ohm\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output impedance with negative feedback=%dkilo ohm.\"%Zout_f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output impedance with negative feedback=9kilo ohm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.18 : Page number 349\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ai=250.0; #Current gain without feedback\n",
+ "BW=400.0; #Bandwidth, kHz\n",
+ "mi=0.01; #current feedback fraction\n",
+ "\n",
+ "#Calculation\n",
+ "BW_f=BW*(1+mi*Ai); #Bandwidth when negative feedback is applied, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"Bandwidth when negative feedback is applied=%dkHz.\"%BW_f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Bandwidth when negative feedback is applied=1400kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 32
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.19 : Page number 350-351\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=18.0; #Supply voltage, V\n",
+ "R1=16.0; #Resistor R1, kilo ohm\n",
+ "R2=22.0; #Resistor R2, kilo ohm\n",
+ "RE=910.0; #Emitter resistor, ohm\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculations\n",
+ "V2=VCC*R2/(R1+R2); #Voltage across R2, V (Voltage divider rule)\n",
+ "VE=V2-VBE; #Emitter voltage, V\n",
+ "IE=(VE/RE)*1000; #Emitter current, mA (OHM's LAW)\n",
+ "\n",
+ "#D.C load line\n",
+ "IC_sat=(VCC/RE)*1000; #Collector saturation current, mA\n",
+ "VCE_off=VCC; #Collector-emitter voltage in off state, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Value of VE=%.2fV and IE=%.2fmA\"%(VE,IE));\n",
+ "\n",
+ "#Plotting\n",
+ "VCE_plot=[0,VCE_off]; #Plotting variable for VCE\n",
+ "IC_plot=[IC_sat,0]; #Plotting variable for IC\n",
+ "p=plot(VCE_plot,IC_plot);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,20])\n",
+ "limit.set_ylim([0,25])\n",
+ "xlabel('VCE(V)');\n",
+ "ylabel('IC(mA)');\n",
+ "title('d.c load line');\n",
+ "plt.grid();\n",
+ "show(p);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Value of VE=9.72V and IE=10.68mA\n"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYEAAAEZCAYAAABxbJkKAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\n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+ "text": [
+ "<matplotlib.figure.Figure at 0x7f109441f290>"
+ ]
+ }
+ ],
+ "prompt_number": 39
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.20 : Page number 352\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Supply voltage, V\n",
+ "R1=10.0; #Resistor R1, kilo ohm\n",
+ "R2=10.0; #Resistor R2, kilo ohm\n",
+ "RE=5.0; #Emitter resistance, kilo ohm\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V2=VCC*R2/(R1+R2); #Voltage across R2, V (Voltage divider rule)\n",
+ "VE=V2-VBE; #Emitter voltage, V\n",
+ "IE=(VE/RE); #Emitter current, mA (OHM's LAW)\n",
+ "re=25/IE; #a.c emitter resistance, ohm\n",
+ "Av=RE*1000/(re+RE*1000); #Voltage gain\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The voltage gain of the emitter follower circuit=%.3f.\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain of the emitter follower circuit=0.994.\n"
+ ]
+ }
+ ],
+ "prompt_number": 33
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.21 : Page number 352-353\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RE=5.0; #Emitter resistance, kilo ohm\n",
+ "re=29.1; #a.c emitter resistance, ohm\n",
+ "RL=5.0; #Load resistance, kilo ohm\n",
+ "\n",
+ "#Calculation\n",
+ "RE_ac=(RE*RL)/(RE+RL); #New effective value of emitter resistance, kilo ohm\n",
+ "Av=RE_ac*1000/(re+RE_ac*1000); #Voltage gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"The voltage gain=%.3f\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain=0.988\n"
+ ]
+ }
+ ],
+ "prompt_number": 34
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.22 : Page number 354\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "def pr(r1,r2): #Function for calculating parallel resistance\n",
+ " return (r1*r2)/(r1+r2);\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=10.0; #Supply voltage, V\n",
+ "R1=10.0; #Resistor R1, kilo ohm\n",
+ "R2=10.0; #Resistor R2, kilo ohm\n",
+ "RE=4.3; #Emitter resistor, kilo ohm\n",
+ "RL=10.0; #Load resistance, kilo ohm\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=200.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "V2=VCC*R2/(R1+R2); #Voltage across R2, V (Voltage divider rule)\n",
+ "VE=V2-VBE; #Emitter voltage, V\n",
+ "IE=(VE/RE); #Emitter current, mA (OHM's LAW)\n",
+ "re=25/IE; #a.c emitter resistance, ohm\n",
+ "RE_eff=pr(RE,RL); #Effective external emitter resistance, kilo ohm\n",
+ "Zin_base=beta*(re/1000+RE_eff); #Input impedance of the base of the transistor, kilo ohm\n",
+ "Zin=pr(pr(R1,R2),Zin_base); #Input impedance of emitter follower, kilo ohm\n",
+ "#Approximate value of input impedance taken as parallel resistance of R1 and R2 and ignoring Zin_base due to its relatively large value\n",
+ "Zin_approx=pr(R1,R2); #Approximate input impedance, kilo ohm\n",
+ "\n",
+ "#Result\n",
+ "print(\"The input impedance of the emitter follower =%.2f kilo ohm\"%Zin);\n",
+ "print(\"The approximate value of the input impedance=%d kilo ohm\"%Zin_approx);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The input impedance of the emitter follower =4.96 kilo ohm\n",
+ "The approximate value of the input impedance=5 kilo ohm\n"
+ ]
+ }
+ ],
+ "prompt_number": 35
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.23 : Page number 355\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "def pr(r1,r2): #Function for calculating parallel resistance\n",
+ " return (r1*r2)/(r1+r2);\n",
+ "\n",
+ "\n",
+ "#Variable declaration\n",
+ "re=20.0; #a.c emitter resistance, ohm\n",
+ "R1=3.0; #Resistor R1, kilo ohm\n",
+ "R2=4.7; #Resistor R2, kilo ohm\n",
+ "RS=600.0; #Source resistance, kilo ohm\n",
+ "beta=200.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "Rin_ac=pr(pr(R1,R2)*1000,RS); #Input a.c resistance, ohm\n",
+ "Zout=re + Rin_ac/beta; #Output impedance, ohm\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output impedance=%.1f ohm\"%Zout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output impedance=22.3 ohm\n"
+ ]
+ }
+ ],
+ "prompt_number": 36
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.24 : Page number 358\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Supply voltage, V\n",
+ "R1=120.0; #Resistor R1, kilo ohm\n",
+ "R2=120.0; #Resistor R2, kilo ohm\n",
+ "RE=3.3; #Emitter resistor, kilo ohm\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta_1=70.0; #Base current amplification factor of 1st transistor\n",
+ "beta_2=70.0; #Base current amplification factor of 2nd transistor\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "V2=VCC*R2/(R1+R2); #Voltage across R2, V (Voltage divider rule)\n",
+ "IE_2=(V2-2*VBE)/RE; #Emitter current, mA (OHM's LAW)\n",
+ "\n",
+ "#(ii)\n",
+ "Zin=(beta_1*beta_2*RE)/1000; #Input impedance, mega ohm\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) d.c value of current in RE=%.2fmA\"%IE_2);\n",
+ "print(\"(ii) Input impedance=%.2f mega ohm.\"%Zin);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) d.c value of current in RE=1.09mA\n",
+ "(ii) Input impedance=16.17 mega ohm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 37
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 13.25 : Page number 358-359\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Supply voltage, V\n",
+ "R1=20.0; #Resistor R1, kilo ohm\n",
+ "R2=10.0; #Resistor R2, kilo ohm\n",
+ "RC=4.0; #Collector resistor, kilo ohm\n",
+ "RE=2.0; #Emitter resistor, kilo ohm\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=100.0; #Base current amplification factor of 1st transistor\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) D.C Bias levels\n",
+ "VB1=VCC*R2/(R1+R2); #Base voltage of 1st transistor, V (Voltage divider rule)\n",
+ "VE1=VB1-VBE; #Emitter voltage of 1st transistor, V\n",
+ "VB2=VE1; #Base voltage of 2nd transistor, V\n",
+ "VE2=VB2-VBE; #Emitter voltage of 2nd transistor, V\n",
+ "IE2=VE2/RE; #Emitter current of 2nd transistor, mA (OHM' LAW)\n",
+ "IE1=IE2/beta; #Emitter current of 1st transistor, mA (IE~IC=beta*IB, here IB2=IE1)\n",
+ "\n",
+ "#(ii) A.C analysis\n",
+ "re1=25/IE1; #a.c emitter resistance of 1st transistor\n",
+ "re2=25/IE2; #a.c emitter resistance of 2nd transistor\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) D.C Bias levels: \\n VB1= %dV, VE1=%.1fV, VB2=%.1fV, VE2=%.1fV, IE2=%.1fmA and IE1=%.3fmA.\"%(VB1,VE1,VB2,VE2,IE2,IE1));\n",
+ "print(\"(ii) A.C Analysis: \\n re1=%d ohm and re2=%.2f ohm \"%(re1,re2));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) D.C Bias levels: \n",
+ " VB1= 4V, VE1=3.3V, VB2=3.3V, VE2=2.6V, IE2=1.3mA and IE1=0.013mA.\n",
+ "(ii) A.C Analysis: \n",
+ " re1=1923 ohm and re2=19.23 ohm \n"
+ ]
+ }
+ ],
+ "prompt_number": 38
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter14_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter14_1.ipynb
new file mode 100644
index 00000000..5e35882c
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter14_1.ipynb
@@ -0,0 +1,502 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:ec0d27209d08b0b95750f66ce9ee21af5ef586e23d0bf0ea218aa20a4ce63e43"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "#CHAPTER 14: SINUSOIDAL OSCILLATORS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.1 : Page number 371-372\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "L1=58.6; #Inductance, micro henry\n",
+ "C1=300.0; #Capacitance, pF\n",
+ "\n",
+ "#Calculation\n",
+ "f=(1/(2*round(pi,2)*sqrt(L1*10**-6*C1*10**-12)))/1000; #Frequency of oscillation, kHz\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"frequency of oscillation=%dkHz\"%f);\n",
+ "\n",
+ "\n",
+ "#Note : The frequency has been calculated in the text as 1199kHz but here the answer gets approximated to 1200kHz.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "frequency of oscillation=1200kHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.2 : Page number 372\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "L1=1.0; #Inductance , mH\n",
+ "f=1.0; #frequency of oscillation, GHz\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, f=1/(2*pi*sqrt(L1*C1)),\n",
+ "C1=(1/(L1*10**-3*(f*10**12*2*pi)**2))*10**12; #Capacitance, pF\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The Capacitance of the capacitor of the LC oscillator=%.2epF\"%C1);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Capacitance of the capacitor of the LC oscillator=2.53e-11pF\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.3 : Page number 373-374\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "C1=0.001; #Capacitor C1, microfarad\n",
+ "C2=0.01; #Capacitor C2, microfarad\n",
+ "L=15.0; #Inductance, microhenry\n",
+ "\n",
+ "#Calculation\n",
+ "CT=C1*C2/(C1+C2); #Total capacitance\n",
+ "\n",
+ "#(i) Operating frequency\n",
+ "f=(1/(2*pi*sqrt(CT*10**-6*L*10**-6)))/1000; #Operating frequency, kHz\n",
+ "\n",
+ "#(ii) Feedback fraction\n",
+ "mv=C1/C2; #Feedback fraction\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The operating frequency=%dkHz\"%f);\n",
+ "print(\"(ii) The feedback fraction=%.1f\"%mv);\n",
+ "\n",
+ "#Note : The operating frequency is calculated in the text as 1361kHz but here it has been approximated to 1362kHz\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The operating frequency=1362kHz\n",
+ "(ii) The feedback fraction=0.1\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.4 : Page number 374: Page number\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "mv=0.25; #Feedback fraction\n",
+ "L=1.0; #Inductance, mH\n",
+ "f=1.0; #Operating frequeny, MHz\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, f=1/(2*pi*sqrt(L*C))\n",
+ "CT=round((1/(L*10**-3*(2*pi*f*10**6)**2))*10**12,1); #Total capacitance, pF\n",
+ "\n",
+ "#Since, mv=C1/C2 and CT=C1*C2/(C1+C2) or CT=C2/(1+ (C2/C1)),\n",
+ "#From the above equations, substituting value of mv and calculaing value of C2,\n",
+ "C2=CT*(1+(1/mv)); #Capacitance of C2 capactior, pF\n",
+ "C1=mv*C2; #Capacitance of C1 capacitor, pF\n",
+ "\n",
+ "#Result\n",
+ "print(\"C1=%.1fpF and C2=%.1fpF\"%(C1,C2));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C1=31.6pF and C2=126.5pF\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.5 : Page number 375-376\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable decalaration\n",
+ "L1=1000.0; #Inductance of L1 inductor, microhenry\n",
+ "L2=100.0; #Inductance of L2 inductor, microhenry\n",
+ "M=20.0; #Mutual inductance, microhenry\n",
+ "C=20.0; #Capacitance, pF\n",
+ "\n",
+ "#Calculation\n",
+ "LT=L1+L2+2*M; #Total inductance, microhenry\n",
+ "\n",
+ "#(i) Operating frequency\n",
+ "f=(1/(2*pi*sqrt(LT*10**-6*C*10**-12)))/1000; #Operating frequency, kHz\n",
+ "\n",
+ "#(ii)\n",
+ "mv=L2/L1; #feedback fraction\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The operating frequency=%dkHz.\"%f);\n",
+ "print(\"(ii) The feedback fraction=%.1f.\"%mv);\n",
+ "\n",
+ "#Note : The operating frequecy has been calculated in the text as 1052kHz but here it gets approximated to 1054kHz\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The operating frequency=1054kHz.\n",
+ "(ii) The feedback fraction=0.1.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.6 : Page number 376\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "C=1.0; #Capacitance, pF\n",
+ "f=1.0; #Frequency, MHz\n",
+ "mv=0.2; #Feedback frequency\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "LT=(1/(C*10**-12*(2*pi*f*10**6)**2))*1000; #Total inductance, mH\n",
+ "\n",
+ "#Since, mv=L2/L1 or L2=mv*L1 and L1+L2=LT or L1(1+mv)=LT,\n",
+ "L1=LT/(1+mv); #Inductance of L1 inductor, mH\n",
+ "L2=L1*mv; #inductance of L2 inductor, mH\n",
+ "\n",
+ "#Result\n",
+ "print(\"L1=%.1fmH and L2=%.2fmH.\"%(L1,L2));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "L1=21.1mH and L2=4.22mH.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.7 : Page number 378\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "R1=1.0; #Resistor R1, mega ohm\n",
+ "R2=R1; #Resistor R2, mega ohm\n",
+ "R3=R1; #Resistor R3, mega ohm\n",
+ "C1=68.0; #Capacitor C1, pF\n",
+ "C2=C1; #Capacitor C2, pF\n",
+ "C3=C1; #Capacitor C3, pF\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "R=R1*10**6; #Resistance of the resistors of phase shift circuit, ohm\n",
+ "C=C1*10**-12; #Capacitance of the capacitors of phase shift circuit, F\n",
+ "fo=1/(2*pi*R*C*sqrt(6)); #Frequency of oscillation, Hz\n",
+ "\n",
+ "#Result\n",
+ "print(\"The frequency of oscillation=%dHz\"%fo);\n",
+ "\n",
+ "#Note: The frequency of oscillation had been calculated in the text as 954Hz, but here it gets approximated to 955 HZ.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The frequency of oscillation=955Hz\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.8 : Page number 378\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "C=5.0; #Capacitance of the capacitors of phase shift circuit, pF\n",
+ "fo=800.0; #Required frequency of oscillation, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, fo=1/(2*pi*R*C*sqrt(6))\n",
+ "R=(1/(2*pi*C*10**-12*fo*10**3*sqrt(6)))/1000; #Resistance of the resistors of phase shift circuit, kilo ohm\n",
+ "\n",
+ "#Result\n",
+ "print(\"R=%.1f kilo ohm.\"%R);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "R=16.2 kilo ohm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.9 : Page number 380\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "#Resistance of R1 and R2 resistors of the R-C bridge circuit\n",
+ "R1=220.0; #kilo ohm \n",
+ "R2=220.0; #kilo ohm\n",
+ "\n",
+ "#Capacitance of C1 and C2 the capacitors of the R-C bridge circuit\n",
+ "C1=250.0; #pF\n",
+ "C2=250.0; #pF\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, R1=R2 and C1=C2, R1=R2 is taken as R and C1=C2 is taken as C\n",
+ "#And, f=1/(2*pi*sqrt(R1*R2*C1*C2))is transformed to f=1/(2*pi*R*C).\n",
+ "R=R1*10**3; #kilo ohm\n",
+ "C=C1*10**-12; #pF\n",
+ "f=1/(2*pi*R*C); #Frequency of oscillation, Hz\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The frequency of oscillation=%dHz.\"%f);\n",
+ "\n",
+ "\n",
+ "#Note : The frequency of oscillation is calculated in the text as 2892Hz but here it gets approximated to 2893 Hz.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The frequency of oscillation=2893Hz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 14.11 : Page number 384\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "#a.c equivalent values of the crystal:\n",
+ "L=1.0; #Inductance , H\n",
+ "C=0.01; #Capacitance , pF\n",
+ "R=1000.0; #Resistance , ohm\n",
+ "Cm=20.0; #Mounting capacitance, pF\n",
+ "\n",
+ "#Calculation\n",
+ "fs=(1/(2*round(pi,2)*sqrt(L*C*10**-12)))/1000; #Series resonant frrequency, kHz\n",
+ "CT=(C*Cm/(C+Cm)); #Total capacitance, pF\n",
+ "fp=(1/(2*round(pi,2)*sqrt(L*CT*10**-12)))/1000; #Prallel resonant frequency, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"fs=%.0fkHz and fp=%.0fkHz.\"%(fs,fp));\n",
+ "\n",
+ "#Note: fs and fp are calculated in the text as 1589kHz and 1590kHz, but here it gets approximated to 1592kHz and 1593kHz\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "fs=1592kHz and fp=1593kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter15_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter15_1.ipynb
new file mode 100644
index 00000000..e649cc91
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter15_1.ipynb
@@ -0,0 +1,482 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:034eec32676d4e7abdedfb3bf68426d81a2d1483fc668bcbfdb5be18cec2e406"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 15: TRANSISTOR TUNED AMPLIFIERS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.1 : Page number 394"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "C=250.0*10**-12; #Capacitor of parallel resonant circuit, F\n",
+ "L=1.25*10**-3; #Inductor of the parallel resonant circuit, H\n",
+ "R=10.0; #Resistor of the parallel resonant circuit, ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) Resonant frequency\n",
+ "fr=((1/(2*pi))*sqrt((1/(L*C))-(R/L)**2))/1000; #Resonant frequecy, kHz\n",
+ "\n",
+ "#(ii) Impedance of the circuit at resonance\n",
+ "Zr=(L/(C*R))/1000; #Impedance of the circuit at resonance, kilo ohm\n",
+ "\n",
+ "#(iii) Quality factor of the circuit\n",
+ "Q=2*pi*(fr*10**3)*L/R; #Quality factor of the circuit\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The resonant frequency=%.1fkHz.\"%fr);\n",
+ "print(\"(ii) The impedance of the circuit at resonance=%d kilo ohm.\"%Zr);\n",
+ "print(\"(iii) The quality factor of the circuit=%.1f.\"%Q);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The resonant frequency=284.7kHz.\n",
+ "(ii) The impedance of the circuit at resonance=500 kilo ohm.\n",
+ "(iii) The quality factor of the circuit=223.6.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.2 : Page number 394-395\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "C=100.0*10**-12; #Capacitor of parallel resonant circuit, F\n",
+ "L=100.0*10**-6; #Inductor of the parallel resonant circuit, H\n",
+ "R=10.0; #Resistor of the parallel resonant circuit, ohm\n",
+ "V=10.0; #Supply voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) Resonant frequency\n",
+ "fr=((1/(2*pi))*sqrt((1/(L*C))-(R/L)**2))/1000; #Resonant frequecy, kHz\n",
+ "\n",
+ "#(ii) Impedance of the circuit at resonance\n",
+ "Zr=(L/(C*R))/10**6; #Impedance of the circuit at resonance, mega ohm\n",
+ "\n",
+ "I=V/Zr; #Line current at resonance, microampere\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The resonant frequency=%.2fkHz.\"%fr);\n",
+ "print(\"(ii) The impedance of the circuit at resonance=%.1f mega ohm.\"%Zr);\n",
+ "print(\"The line current at resonance=%d micro ampere.\"%I);\n",
+ "\n",
+ "#Note : The resonant frequency in the text has been calculated as 1592.28 kHz, but here it gets approximated to 1591.47 kHz.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The resonant frequency=1591.47kHz.\n",
+ "(ii) The impedance of the circuit at resonance=0.1 mega ohm.\n",
+ "The line current at resonance=100 micro ampere.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.3 : Page number 395\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "C=250.0*10**-12; #Capacitor of parallel resonant circuit, F\n",
+ "Zr=500.0*10**3; #Dynamic impedance, ohm\n",
+ "R=10.0; #Resistance of the coil, ohm\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#Since,Zr=L/CR,\n",
+ "L=(Zr*C*R)*10**3; #Inductance of the coil, mH\n",
+ "\n",
+ "#(ii) Resonant frequency\n",
+ "fr=((1/(2*pi))*sqrt((1/(L*10**-3*C))-(R/(L*10**-3))**2))/1000; #Resonant frequecy, kHz\n",
+ "\n",
+ "#(iii) Quality factor of the circuit\n",
+ "Q=2*pi*(fr*10**3)*(L*10**-3)/R; #Quality factor of the circuit\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The inductance of the coil=%.2fmH.\"%L);\n",
+ "print(\"(ii) The resonant frequency=%.1fkHz.\"%fr);\n",
+ "print(\"(iii) The quality factor of the circuit=%.1f.\"%Q);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The inductance of the coil=1.25mH.\n",
+ "(ii) The resonant frequency=284.7kHz.\n",
+ "(iii) The quality factor of the circuit=223.6.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.4 : Page number 397\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Q=60.0; #Quality factor of the tuned amplifier\n",
+ "fr=1200.0; #Resonant frequency, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "BW=fr/Q; #Bandwidth, kHz\n",
+ "\n",
+ "#(ii)\n",
+ "f1=fr-(BW/2); #Lower cut-off frequency, kHz\n",
+ "f2=fr+(BW/2); #Upper cut-off frequency, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The bandwidth=%dkHz\"%BW);\n",
+ "print(\"(ii) The lower and upper cut-off frequencies are=%dkHz and %dkHz.\"%(f1,f2));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The bandwidth=20kHz\n",
+ "(ii) The lower and upper cut-off frequencies are=1190kHz and 1210kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.5 : Page number 397\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "fr=2.0; #Resonant frequency, MHz\n",
+ "BW=50.0; #Bandwidth, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, bandwidth=resonant_frequency/quality_factor\n",
+ "Q=(fr*10**6)/(BW*10**3); #Quality factor\n",
+ "\n",
+ "#Result\n",
+ "print(\"The quality factor=%d\"%Q);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The quality factor=40\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.7 : Page number 400\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "C=0.1*10**-6; #Capacitor of parallel resonant circuit, F\n",
+ "L=33.0*10**-3; #Inductor of the parallel resonant circuit, H\n",
+ "R=25.0; #Resistor of the parallel resonant circuit, ohm\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "fr=(1/(2*pi*sqrt(L*C)))/1000; #Resonant frequency, kHz\n",
+ "\n",
+ "#(ii)\n",
+ "XL=2*pi*(fr*10**3)*L; #Inductive reactance, ohm\n",
+ "Q=round(XL/R,0); #Quality factor\n",
+ "\n",
+ "#(iii)\n",
+ "BW=(fr*10**3)/Q; #Bandwidth\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The resonant frequency=%.2fkHz\"%fr);\n",
+ "print(\"(ii) The quality factor= %d.\"%Q);\n",
+ "print(\"(iii) The bandwidth=%dHz.\"%BW);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The resonant frequency=2.77kHz\n",
+ "(ii) The quality factor= 23.\n",
+ "(iii) The bandwidth=120Hz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.8 : Page number 401-402\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "BW_dt=200.0; #Bandwidth, kHz\n",
+ "fr=10.0; #Operating frequency, MHz\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, BW_dt=k*fr (i.e.,co-efficient_of_coupling * operating_frequency)\n",
+ "k=BW_dt/(fr*10**3); #co-efficient of coupling\n",
+ "\n",
+ "#Result\n",
+ "print(\"The co-efficient of coupling=%.2f.\"%k);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The co-efficient of coupling=0.02.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.9 : Page number 405\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "C=500.0*10**-12; #Capacitor of parallel resonant circuit, F\n",
+ "L=50.7*10**-6; #Inductor of the parallel resonant circuit, H\n",
+ "R=10.0; #Resistor of the parallel resonant circuit, ohm\n",
+ "RL=1.0; #Load resistance, mega ohm\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "fr=round((1/(2*pi*sqrt(L*C)))/1000); #Resonant frequency, Hz\n",
+ "\n",
+ "#(ii)\n",
+ "R_dc=R; #d.c load, ohm\n",
+ "XL=2*pi*(fr*1000)*L; #Inductive reactance, ohm\n",
+ "Q_coil=round(XL/R,1); #Quality factor\n",
+ "R_P=(Q_coil*XL)/1000 ; #Equivalent parallel resistance, kilo ohm\n",
+ "R_AC=(R_P*RL*10**3)/(R_P+RL*10**3); #A.C load,kilo ohm\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The resonant frequency=%dkHz\"%fr);\n",
+ "print(\"(ii) d.c load=%d ohm and a.c load=%d kilo ohm.\"%(R_dc,R_AC));\n",
+ "\n",
+ "#Note: In the text resonant frequency has been wrongly calculated to 106kHz but its actual value is approximately 1000kHz\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The resonant frequency=1000kHz\n",
+ "(ii) d.c load=10 ohm and a.c load=10 kilo ohm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.10 : Page number 406-407\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RL=50.0; #Load resistance, ohm\n",
+ "n=5; #Turns ratio of the transformer\n",
+ "VCC=50.0; #Supply voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "R_ac=n**2*RL; #A.C load, ohm\n",
+ "\n",
+ "#(ii)\n",
+ "P_o_max=VCC**2/(2*R_ac); #Maximum load power, W\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The a.c load=%d ohm\"%R_ac);\n",
+ "print(\"(ii) Maximum load power=%dW\"%P_o_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The a.c load=1250 ohm\n",
+ "(ii) Maximum load power=1W\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 15.11 : Page number 407\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "P_D=4.0; #Maximum power dissipation, mW\n",
+ "P_o_max=1.0; #Maximum load power, W\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "max_collector_eff=(P_o_max/(P_o_max+(P_D/1000)))*100; #Maximum collector efficiency\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum collector efficiency=%.1f%%\"%max_collector_eff);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum collector efficiency=99.6%\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter16_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter16_1.ipynb
new file mode 100644
index 00000000..b2262b8f
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter16_1.ipynb
@@ -0,0 +1,936 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:d4ffda068787fb0974622fa8de40f7d54b5df2a00735e870e01cb9df45be78f9"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 16 : MODULATION AND DEMODULATION"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.2 : Page number 416-417\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variabledeclaration\n",
+ "V_pp_max=16.0; #Maximum peak-to-peak voltage of an AM wave, mV\n",
+ "V_pp_min=4.0; #Minimum peak-to-peak voltage of an AM wave, mV\n",
+ "\n",
+ "#Calculation\n",
+ "Vmax=V_pp_max/2; #Maximum voltage of AM wave, mV\n",
+ "Vmin=V_pp_min/2; #Minimum voltage of AM wave, mV\n",
+ "m=(Vmax-Vmin)/(Vmax+Vmin); #Modulation factor.\n",
+ "\n",
+ "#Result\n",
+ "print(\"The modulation factor=%.1f.\"%m);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The modulation factor=0.6.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.3 : Page number 417\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Es=50.0; #signalvoltage amplitude, V\n",
+ "Ec=100.0; #Carrier voltage amplitude, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "m=Es/Ec; #Modulation factor\n",
+ "\n",
+ "#Result\n",
+ "print(\"Modulation factor=%.1f.\"%m);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Modulation factor=0.5.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.4 : Page number 419\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "fc=2500.0; #Carrier frequency, kHz\n",
+ "f1=50.0; #Lower frequency of the audio signal, Hz\n",
+ "f2=15000.0; #Upper frequency of the audio signal, Hz\n",
+ "\n",
+ "#Calculation\n",
+ "fl_usb=fc+(f1/1000); #Lower frequency of upper sideband, kHz\n",
+ "fu_usb=fc+(f2/1000); #Upper frequency of upper sideband, kHz\n",
+ "\n",
+ "fu_lsb=fc-(f1/1000); #Lower frequency of upper sideband, kHz\n",
+ "fl_lsb=fc-(f2/1000); #Upper frequency of upper sideband, kHz\n",
+ "\n",
+ "#Since, f1=50Hz is negligible with respect to f2=15000Hz,\n",
+ "BW=(fc+(f2/1000))-(fc-(f2/1000)); #Bandwidth, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"The upper sideband=%.2fkHz to %dkHz.\"%(fl_usb,fu_usb));\n",
+ "print(\"The lower sideband=%dkHz to %.2fkHz.\"%(fl_lsb,fu_lsb));\n",
+ "print(\"The bandwidth=%dkHz\"%BW);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The upper sideband=2500.05kHz to 2515kHz.\n",
+ "The lower sideband=2485kHz to 2499.95kHz.\n",
+ "The bandwidth=30kHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.5 : Page number 420\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "EC=5.0; #Carrier amplitude, V\n",
+ "m=0.6; #modulation factor\n",
+ "ws=6280.0; #angular frequency of signal, radians/s\n",
+ "wc=211*10**4; #angular frequency of carrier, radians/s\n",
+ "\n",
+ "#Calculation\n",
+ "fs=(ws/(2*pi))/1000; #Signal frequency, kHz\n",
+ "fc=(wc/(2*pi))/1000; #Carrier frequency, kHz\n",
+ "\n",
+ "#(i)\n",
+ "Max_amp=EC+m*EC; #Maximum amplitude of AM wave, V\n",
+ "Min_amp=EC-m*EC; #Minimum amplitude of AM wave, V\n",
+ "\n",
+ "#(ii)\n",
+ "frequency_components=[fc-fs,fc,fc+fs]; #frequency components, kHz\n",
+ "amplitudes=[m*EC/2,EC,m*EC/2]; #Corresponding amplitudes, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The maximum and minimum amplitudes of AM wave=%dV and %dV.\"%(Max_amp,Min_amp));\n",
+ "print(\"(ii) The frequency components of the AM wave=%.0f,%.0f,%.0f.\"%(frequency_components[0],frequency_components[1],frequency_components[2]));\n",
+ "print(\" The corresponding amplitudes are =%.1fV, %dV, %.1fV.\"%(amplitudes[0],amplitudes[1],amplitudes[2]));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The maximum and minimum amplitudes of AM wave=8V and 2V.\n",
+ "(ii) The frequency components of the AM wave=335,336,337.\n",
+ " The corresponding amplitudes are =1.5V, 5V, 1.5V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.6 : Page number 420-421\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "fc=1000.0; #Carrier frequency, kHz\n",
+ "fs=5.0; #Signal frequency, kHz\n",
+ "m=0.5; #Modulation factor\n",
+ "EC=100.0; #Amplitude of the carrier, V\n",
+ "\n",
+ "#Calculation\n",
+ "f_lsb=fc-fs; #Lower sideband frequency,kHz\n",
+ "f_usb=fc+fs; #Upper sideband frequency, kHz\n",
+ "Amplitude=m*EC/2; #Amplitude of each sideband, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The lower and upper sideband frequencies are=%dkHz and %dkHz.\"%(f_lsb,f_usb));\n",
+ "print(\"The amplitude of each sideband =%dV\"%Amplitude);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The lower and upper sideband frequencies are=995kHz and 1005kHz.\n",
+ "The amplitude of each sideband =25V\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.7 : Page number 421\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "EC=10.0; #Carrier amplitude, V\n",
+ "ES=6.0; #Signal amplitude, V\n",
+ "fc=10.0; #Carrier frequency, MHz\n",
+ "fs=5/1000.0; #Signal frequency. MHz\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "m=ES/EC; #Modulation factor\n",
+ "\n",
+ "#(ii)\n",
+ "f_lsb=fc-fs; #Lower sideband frequency,MHz\n",
+ "f_usb=fc+fs; #Upper sideband frequency, MHz\n",
+ "\n",
+ "#(iii)\n",
+ "Amplitude=m*EC/2; #Amplitude of each sideband, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The modulation factor=%.1f.\"%m);\n",
+ "print(\"(ii) The lower and upper sideband frequencies are=%.3fMHz and %.3fMHz.\"%(f_lsb,f_usb));\n",
+ "print(\"(iii) The amplitude of each sideband =%dV\"%Amplitude);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The modulation factor=0.6.\n",
+ "(ii) The lower and upper sideband frequencies are=9.995MHz and 10.005MHz.\n",
+ "(iii) The amplitude of each sideband =3V\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.8 : Page number 423\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Pc=500.0; #Carrier power, W\n",
+ "m=1.0; #Modulation factor\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Ps=(1/2.0)*m**2*Pc; #Sideband power, W\n",
+ "\n",
+ "#(ii)\n",
+ "PT=Pc+Ps; #Power of AM wave, W\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The power in sidebands=%dW\"%Ps);\n",
+ "print(\"(ii) The power of AM wave=%dW\"%PT);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The power in sidebands=250W\n",
+ "(ii) The power of AM wave=750W\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Exmaple 16.9 : Page number 423\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Pc=50.0; #Power of carrier, kW\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "m=80/100.0; #Modulation factor\n",
+ "Ps=(1/2.0)*m**2*Pc; #Sideband Power, kW\n",
+ "print(\"(i) The sideband power for 80%% modulation=%dkW.\"%Ps);\n",
+ "\n",
+ "#(ii)\n",
+ "m=10/100.0; #Modulation factor\n",
+ "Ps=(1/2.0)*m**2*Pc; #Sideband Power, kW\n",
+ "print(\"(ii) The sideband power for 10%% modulation=%.2fkW.\"%Ps);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The sideband power for 80% modulation=16kW.\n",
+ "(ii) The sideband power for 10% modulation=0.25kW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.10 : Page number 423-424\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Pc=40.0; #Carrier power, kW\n",
+ "m=100/100.0; #Modulation index\n",
+ "amplifier_eff=72/100.0; #Efficiency of modulated RF amplifier\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)Carrier power remains same after modulation\n",
+ "\n",
+ "#(ii)\n",
+ "Ps=(1/2.0)*(m**2)*Pc; #Sideband power\n",
+ "P_audio=Ps/amplifier_eff; #Required audio power, kW\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The carrier power=%dkW.\"%Pc);\n",
+ "print(\"(ii) The required audio power=%.1fkW.\"%P_audio);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The carrier power=40kW.\n",
+ "(ii) The required audio power=27.8kW.\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.11 : Page number 424\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "fs=1.0; #Signal frequency, kHz\n",
+ "fc=500.0; #Carrier frequency, kHz\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "sideband_f=[fc-fs,fc+fs]; #Sideband frequencies, kHz\n",
+ "\n",
+ "#(ii)\n",
+ "BW=(fc+fs)-(fc-fs); #Bandwidth required, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The sideband frequencies=%dkHz and %dkHz.\"%(sideband_f[0],sideband_f[1]));\n",
+ "print(\"(ii) The bandwidth required=%dkHz\"%BW);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The sideband frequencies=499kHz and 501kHz.\n",
+ "(ii) The bandwidth required=2kHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.12 : Page number 424\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "IC=8.0; #Antenna current due to carrier,A\n",
+ "m=40/100.0; #Modulation index\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Ps=(1/2)*m\u00b2*Pc and PT=Pc+Ps (Total_power=carrier_power+signal_power)\n",
+ "#that implies, (PT/Pc)=1+(m\u00b2/2),\n",
+ "#So, square_of(Total_current/Carrier_current)=(IT/IC)\u00b2=1+(m\u00b2/2).\n",
+ "IT=IC*sqrt(1+(m**2/2.0)); #Total current, A\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The total antenna current=%.2fA.\"%IT);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total antenna current=8.31A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.13 : Page number 424\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "IC=8.0; #Antenna current when only carrier is sent, A\n",
+ "IT=8.93; #Total antenna current, A\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Ps=(1/2)*m\u00b2*Pc and PT=Pc+Ps (Total_power=carrier_power+signal_power)\n",
+ "#that implies, (PT/Pc)=1+(m\u00b2/2),\n",
+ "#So, square_of(Total_current/Carrier_current)=(IT/IC)\u00b2=1+(m\u00b2/2).\n",
+ "m=sqrt((((IT/IC)**2)-1)*2)*100; #The %age of modulation\n",
+ "\n",
+ "#Result\n",
+ "print(\"The %%age of modulation=%.1f%%.\"%m);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The %age of modulation=70.1%.\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.14 : Page number 425\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "Vc=100.0; #Carrier voltage, V\n",
+ "V_T=110.0; #The total voltage after modulation, V\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Ps=(1/2)*m\u00b2*Pc and PT=Pc+Ps (Total_power=carrier_power+signal_power)\n",
+ "#that implies, (PT/Pc)=1+(m\u00b2/2),\n",
+ "#So, square_of(Total_voltage/Carrier_voltage)=(V_T/Vc)\u00b2=1+(m\u00b2/2).\n",
+ "m=sqrt((((V_T/Vc)**2)-1)*2); #The %age of modulation\n",
+ "\n",
+ "#Result\n",
+ "print(\"The modulation index =%.3f.\"%m);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The modulation index =0.648.\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.15 : Page number 425-426\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vc=5.0; #Carrier voltage, V\n",
+ "V_lsb=2.5; #Lower sideband component, V\n",
+ "V_usb=2.5; #Upper sideband component, V\n",
+ "R=2.0; #Resistor driven by AM wave, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, power=(r.m.s_voltage)\u00b2/resistance\n",
+ "#(i)\n",
+ "Pc=round((0.707*Vc)**2/R,2); #Carrier power mW\n",
+ "\n",
+ "#(ii)\n",
+ "P_lower=round((0.707*V_lsb)**2/R,3); #Power delivered by lower sideband, mW\n",
+ "\n",
+ "#(iii)\n",
+ "P_upper=round((0.707*V_usb)**2/R,3); #Power delivered by upper sideband, mW\n",
+ "\n",
+ "P_T=round(Pc+P_lower+P_upper,3); #Total power delivered by the AM wave, mW\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The carrier power=%.2fmW\"%Pc);\n",
+ "print(\"(ii) The power delivered by lower sideband=%.3fmW\"%P_lower);\n",
+ "print(\"(iii) The power delivered by upper sideband=%.3fmW\"%P_upper);\n",
+ "print(\"The total power delivered by the AM wave=%.3fmW\"%P_T);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The carrier power=6.25mW\n",
+ "(ii) The power delivered by lower sideband=1.562mW\n",
+ "(iii) The power delivered by upper sideband=1.562mW\n",
+ "The total power delivered by the AM wave=9.374mW\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.16 : Page number 428\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "wc=6e08; #Carrier angular frequency, rad/s\n",
+ "ws=1250.0; #Signal angular frequency, rad/s\n",
+ "mf=5; #Modulation index\n",
+ "Ec=12.0; #Carrier amplitude, V\n",
+ "R=10.0; #Resistor, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "fc=wc/(2*pi); #Carrier frequency, Hz\n",
+ "\n",
+ "#(ii)\n",
+ "fs=ws/(2*pi); #Signal frequency, Hz\n",
+ "\n",
+ "#(iv)\n",
+ "delta_f=mf*fs; #Maximum frequency deviation, Hz\n",
+ "\n",
+ "#(v)\n",
+ "P=(Ec/sqrt(2))**2/R; #Power dissipated, W\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The carrier frequency=%.1fe06 Hz.\"%(fc/10**6));\n",
+ "print(\"(ii) The signal frequency=%.0f Hz.\"%fs);\n",
+ "print(\"(iii) The modulation index=%d.\"%mf);\n",
+ "print(\"(iv) The maximum frequency deviation=%.0fHz.\"%delta_f);\n",
+ "print(\"(v) The power dissipated=%.1fW.\"%P);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The carrier frequency=95.5e06 Hz.\n",
+ "(ii) The signal frequency=199 Hz.\n",
+ "(iii) The modulation index=5.\n",
+ "(iv) The maximum frequency deviation=995Hz.\n",
+ "(v) The power dissipated=7.2W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.17 : Page number 428-429\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "fc=25.0; #Carrier frequency, MHz\n",
+ "fs=400.0; #Signal frequency, Hz\n",
+ "Ec=4.0; #Carrier amplitude, V\n",
+ "delta_f=10.0; #Maximum frequency deviation, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "wc=2*pi*fc*10**6; #Carrier angular frequency, rad/s\n",
+ "ws=2*pi*fs; #Signal angular frequency, rad/s\n",
+ "mf=delta_f*1000/fs; #Modulation index\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"e=%dcos(%.2et + %dsin%dt)\"%(Ec,wc,mf,ws));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "e=4cos(1.57e+08t + 25sin2513t)\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.18 : Page number 429\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "delta_f=50.0; #Maximum frequency deviation, kHz\n",
+ "fs=5.0; #Modulating frequency, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "mf=delta_f/fs; #Modulation index\n",
+ "\n",
+ "#Result\n",
+ "print(\"The modulation index=%d\"%mf);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The modulation index=10\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.19 : Page number 429\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "fc=1000.0; #Carrier frequency, kHz\n",
+ "fs=15.0; #Modulating frequency, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "first_3_usb_f=[fc+fs,fc+2*fs,fc+3*fs]; #First three upper sideband frequncies, kHz\n",
+ "first_3_lsb_f=[fc-fs,fc-2*fs,fc-3*fs]; #First three lowerr sideband frequncies, kHz\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The first three upper sideband frequencies=%dkHz ,%dkHz and %dkHz.\"%(first_3_usb_f[0],first_3_usb_f[1],first_3_usb_f[2]));\n",
+ "print(\"The first three lower sideband frequencies=%dkHz ,%dkHz and %dkHz.\"%(first_3_lsb_f[0],first_3_lsb_f[1],first_3_lsb_f[2]));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The first three upper sideband frequencies=1015kHz ,1030kHz and 1045kHz.\n",
+ "The first three lower sideband frequencies=985kHz ,970kHz and 955kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.20 : Page number 429\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "fs=15.0; #Modulating frequency, kHz\n",
+ "delta_f=75.0; #Maximum frequency deviation, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "BW=2*(delta_f+fs); #Bandwidth, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"The bandwidth of the FM signal=%dkHz.\"%BW);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The bandwidth of the FM signal=180kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 25
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.21 : Page number 429\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "k=75.0; #Frequency deviation constant, kHz/V\n",
+ "Es=2.0; #Amplitude of signal, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "delta_f=k*Es; #Maximum frequency deviation, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum frequency deviation=%dkHz.\"%delta_f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum frequency deviation=150kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 16.22 : Page number 429-430\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "fs1=500.0; #First audio frequency, Hz\n",
+ "fs2=200.0; #Second audio frequency (decreased), Hz\n",
+ "Es=2.4; #AF voltage, V\n",
+ "delta_f1=4.8; #Frequency deviation,kHz\n",
+ "\n",
+ "#Calculation\n",
+ "k=delta_f1/Es; #Frequency deviation constant, kHz/V\n",
+ "Es=7.2; #AF voltage, V (increased)\n",
+ "delta_f2=k*Es; #2nd frequency deviation, kHz\n",
+ "Es=10.0; #AF voltage, V (increased)\n",
+ "delta_f3=k*Es; #3rd frequency deviation, kHz\n",
+ "\n",
+ "mf1=delta_f1/(fs1/1000); #Modulation index in 1st case\n",
+ "mf2=delta_f2/(fs1/1000); #Modulation index in 2nd case\n",
+ "mf3=delta_f3/(fs2/1000); #Modulation index in 3rd case\n",
+ "\n",
+ "#Result\n",
+ "print(\"The frequency deviation in second case=%.1fkHz.\"%delta_f2);\n",
+ "print(\"The frequency deviation in third case=%dkHz.\"%delta_f3);\n",
+ "print(\"The modulation index in 1st case=%.1f\"%mf1);\n",
+ "print(\"The modulation index in 2nd case=%.1f\"%mf2);\n",
+ "print(\"The modulation index in 3rd case=%d\"%mf3);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The frequency deviation in second case=14.4kHz.\n",
+ "The frequency deviation in third case=20kHz.\n",
+ "The modulation index in 1st case=9.6\n",
+ "The modulation index in 2nd case=28.8\n",
+ "The modulation index in 3rd case=100\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter17_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter17_1.ipynb
new file mode 100644
index 00000000..2c9a49a5
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter17_1.ipynb
@@ -0,0 +1,877 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:33d9a7285654630dd24f2d6229210244e78961e0605c11041ed1b2f130cb19a1"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 17 : REGULATED D.C POWER SUPPLY"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.1 : Page number 444\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_NL=400.0; #Output voltage with no-load, V\n",
+ "V_FL=300.0; #Output voltage with full-load, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "percentage_voltage_regulation=((V_NL-V_FL)/V_FL)*100; #Percentage of voltage regulation\n",
+ "\n",
+ "#Result\n",
+ "print(\"The percentage of voltage regulation=%.2f%%.\"%percentage_voltage_regulation);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The percentage of voltage regulation=33.33%.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.2 : Page number 444\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_regulation=1.0; #%age voltage regulation\n",
+ "V_NL=30.0; #Output voltage with no-load,V\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, %age_of_voltage_regulation=((V_NL-V_FL)/V_FL)*100\n",
+ "V_FL=V_NL/(1+(V_regulation/100)); #Output voltage with full-load, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The full-load voltage=%.1fV.\"%V_FL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The full-load voltage=29.7V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.3 : Page number 445\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_NL_A=30.0; #Output voltage of supply A with no-load, V\n",
+ "V_FL_A=25.0; #Output voltage of supply A with full-load, V\n",
+ "V_NL_B=30.0; #Output voltage of supply B with no-load, V\n",
+ "V_FL_B=29.0; #Output voltage of supply B with full-load, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_regulation_A=((V_NL_A-V_FL_A)/V_FL_A)*100; #%age of voltage regulation in power supply A\n",
+ "V_regulation_B=((V_NL_B-V_FL_B)/V_FL_B)*100; #%age of voltage regulation in power supply B\n",
+ "\n",
+ "#Result\n",
+ "if(V_regulation_A<V_regulation_B):\n",
+ " print(\"Power supply A is better than B.\");\n",
+ "else :\n",
+ " print(\"Power supply B is better than A.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Power supply B is better than A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.4 : Page number 445\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_NL=500.0; #Output voltage with no-load, V\n",
+ "V_FL=300.0; #Output voltage with full-load, V\n",
+ "I_FL=120.0; #Output current with full-load, mA\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Regulation=((V_NL-V_FL)/V_FL)*100; #Voltage regulation percentage\n",
+ "\n",
+ "#(ii)\n",
+ "RL_min=V_FL/I_FL; #Minimum load resistance, k\u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The voltage regulation=%.1f%%.\"%Regulation);\n",
+ "print(\"(ii)The minimum load resistance=%.1fk\u03a9.\"%RL_min);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The voltage regulation=66.7%.\n",
+ "(ii)The minimum load resistance=2.5k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.5 : Page number 445\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VL_1=10.5; #Initial output voltage with load, V\n",
+ "VL_2=10.0; #Decreased output voltage with additional load, V\n",
+ "IL_1=1.0; #Initial load current, A\n",
+ "IL_added=1.0; #Added load current, A\n",
+ "\n",
+ "#Calculation\n",
+ "delta_VL=VL_1-VL_2; #Change in output voltage, V\n",
+ "delta_IL=IL_added; #Change in load current, A\n",
+ "\n",
+ "#(i)\n",
+ "Zo=delta_VL/delta_IL; #Output impedance of power supply, \u03a9 (OHM's LAW)\n",
+ "\n",
+ "#(ii)\n",
+ "#Since, Output_impedance=change_in_output_voltage/change_in_output_current\n",
+ "#Zo=(V_NL-VL_1)/delta_IL,\n",
+ "delta_IL=IL_1; #Change in load current, A\n",
+ "V_NL=VL_1+(delta_IL*Zo); #Output voltage with no load, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The output impedance=%.1f\u03a9.\"%Zo);\n",
+ "print(\"(ii) The output voltage with no-load=%dV.\"%V_NL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The output impedance=0.5\u03a9.\n",
+ "(ii) The output voltage with no-load=11V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.6 : Page number 446\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Zo=0.01; #Output impedance, \u03a9\n",
+ "IL_max=1.0; #Maximum output current, A\n",
+ "IL_min=0.5 #Minimum output current, A\n",
+ "f=10.0; #Frequency, kHz\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Zo=delta_VL/delta_IL\n",
+ "delta_IL=IL_max-IL_min; #Maximum change in output current, A\n",
+ "delta_VL=(Zo*delta_IL)*1000; #Fluctuations in output voltage, mV\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output voltage will have %dmV peak-to-peak fluctuation at a rate of %dkHz.\"%(delta_VL,f));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output voltage will have 5mV peak-to-peak fluctuation at a rate of 10kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.7 : Page number 446\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "delta_Vout=10.0; #Change in output voltage, \u03bcV\n",
+ "delta_Vin=5.0; #Change in input voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "Line_regulation=delta_Vout/delta_Vin; #Line regulation, \u03bcV/V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The line regulation of the voltage regulator=%d\u03bcV/V.\"%Line_regulation);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The line regulation of the voltage regulator=2\u03bcV/V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.8 : Page number 449-450\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vin=24.0; #Input voltage, V\n",
+ "Vz=12.0; #Zener voltage, V\n",
+ "Rs=160.0; #Series resistance, \u03a9\n",
+ "RL_max=float('inf'); #Maximum load resistance, \u03a9\n",
+ "RL_min=200.0; #Minimum load resistance, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Vout=Vz; #Output voltage,(equal to zener regulated voltage), V\n",
+ "Is=((Vin-Vout)/Rs)*1000; #Current through series resistance, mA\n",
+ "\n",
+ "#(ii)\n",
+ "IL_min=Vout/RL_max; #Minimum load current, A\n",
+ "IL_max=(Vout/RL_min)*1000; #Maximum load current, mA\n",
+ "\n",
+ "#(iii)\n",
+ "IZ_min=Is-IL_max; #Minimum zener current, mA\n",
+ "IZ_max=Is-IL_min; #Maximum zener current, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The current through the series resistance=%dmA\"%Is);\n",
+ "print(\"(ii) The minimum and maximum load currents are=%dA and %dmA\"%(IL_min,IL_max));\n",
+ "print(\"(iii) The minimum and maximum zener currents are=%dmA and %dmA\"%(IZ_min,IZ_max));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The current through the series resistance=75mA\n",
+ "(ii) The minimum and maximum load currents are=0A and 60mA\n",
+ "(iii) The minimum and maximum zener currents are=15mA and 75mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.9 : Page number 450\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VZ=15.0; #Zener voltage, V\n",
+ "Vin_min=22.0 #Minimum input voltage, V\n",
+ "Vin_max=40.0 #Maximum input voltage, V\n",
+ "Vout=VZ; #Regulated output voltage, V\n",
+ "IL_max=100.0; #Maximum load current, mA\n",
+ "IL_min=20.0; #Minimum load current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "RS_max=(Vin_min-Vout)/(IL_max/1000); #Maximum value of series resistance, \u03a9 (OHM'S lAW)\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum load resistance to hold the voltage constant=%d\u03a9.\"%RS_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum load resistance to hold the voltage constant=70\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.10 : Page number 450-451\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=3.3; #Zener voltage, V\n",
+ "Iz_min=3.0; #Minimum zener current, mA\n",
+ "Iz_max=100.0; #Maximum zener current, mA\n",
+ "RL_max=2.0; #Maximum load resistance, k\u03a9\n",
+ "RL_min=500.0; #Minimum load resistance, \u03a9\n",
+ "Vin=20.0; #Input voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "Rs_min=(Vin-Vz)/(Iz_max/1000); #Minimum series resistance required, \u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"The minimum series resistance required to limit the zener current=%.0f\u03a9.\"%Rs_min);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The minimum series resistance required to limit the zener current=167\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.11 : Page number 451\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=3.3; #Zener voltage, V\n",
+ "Iz_min=3.0; #Minimum zener current, mA\n",
+ "Iz_max=100.0; #Maximum zener current, mA\n",
+ "RL_max=2.0; #Maximum load resistance, k\u03a9\n",
+ "RL_min=500.0; #Minimum load resistance, \u03a9\n",
+ "Vin=20.0; #Input voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "IL_max=(Vz/RL_min)*1000; #Maximum load current, mA\n",
+ "Rs_max=((Vin-Vz)/(IL_max+Iz_min))*1000; #Maximum series resistance, \u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum allowable value of series resistance=%d\u03a9.\"%Rs_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum allowable value of series resistance=1739\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.12 : Page number 452\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=10.0; #Zener voltage, V\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "RL=1000.0; #Load resistance, \u03a9\n",
+ "VBE=0.5; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "Vout=Vz-VBE; #Output voltage, V\n",
+ "IL=(Vout/RL)*1000; #Load current, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output voltage=%.1fV.\"%Vout);\n",
+ "print(\"The load current=%.1fmA\"%IL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output voltage=9.5V.\n",
+ "The load current=9.5mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.3 : Page number 452\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "IC=1.0; #Required current(collector current), A\n",
+ "Vout=6.0; #Constant output voltage, V\n",
+ "Vin=10.0; #Supply voltage, V\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "VBE=0.5; #Base-emitter voltage, V\n",
+ "Iz=10.0; #Minimum zener current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "IB=(IC/beta)*1000; #Base current, mA\n",
+ "\n",
+ "#Since, Vout=Vz-VBE;\n",
+ "Vz=Vout+VBE; #Zener breakdown voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "V_Rs=Vin-Vz; #Voltage across series resistance Rs, V\n",
+ "Rs=(V_Rs/(IB+Iz))*1000; #Series resistance, \u03a9\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The zener breakdown voltage=%.1fV\"%Vz);\n",
+ "print(\"(ii)The series resistance=%.0f\u03a9.\"%Rs);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The zener breakdown voltage=6.5V\n",
+ "(ii)The series resistance=117\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.14: Page number 452-453\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=12.0; #Zener voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "Vin=20.0; #Input voltage, V\n",
+ "RS=220.0; #Series resistance, \u03a9\n",
+ "RL=1.0; #Load resistance, k\u03a9\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Vout=Vz-VBE; #Output voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "V_RS=Vin-Vz; #Voltage across series resistance, RS, V\n",
+ "IR=(V_RS/RS)*1000; #Current through series resistance, mA\n",
+ "IL=Vout/RL; #Load current, mA\n",
+ "\n",
+ "#Since, IL is emitter current and emitter current is approx. equal to collector current,\n",
+ "IC=IL; #Collector current, mA\n",
+ "IB=IC/beta; #Base current, mA\n",
+ "Iz=IR-IB; #Zener current, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The output voltage=%.1fV.\"%Vout);\n",
+ "print(\"(ii) The zener current=%dmA\"%Iz);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The output voltage=11.3V.\n",
+ "(ii) The zener current=36mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.15 : Page number 453-454\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import ceil\n",
+ "from math import floor\n",
+ "\n",
+ "#Variable declaration\n",
+ "IL_min=0; #Minimum load current, A\n",
+ "IL_max=1.0; #Maximum load current, A\n",
+ "Vin_min=12.0; #Minimum input voltage, V\n",
+ "Vin_max=18.0; #Maximum input voltage, V\n",
+ "Iz_min=1.0; #Minimum zener current, mA\n",
+ "Vz=8.5; #Zener voltage, V\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "IB_max=(IL_max/beta)*1000; #Maximum base current, mA\n",
+ "I_RS=Iz_min+IB_max; #Current through the series resistance, mA\n",
+ "RS=((Vin_min-Vz)/I_RS)*1000; #Series resistance, \u03a9\n",
+ "\n",
+ "#(ii)\n",
+ "V_RS_max=Vin_max-Vz; #Maximum voltage across series resistance, V\n",
+ "P_max_RS=ceil((V_RS_max**2/RS)*1000)/1000; #Maximum power dissipation in series resistance RS, W\n",
+ "\n",
+ "#(iii)\n",
+ "I_RS_max=V_RS_max/floor(RS); #Maximum current through series resistance,mA\n",
+ "Iz_max=I_RS_max; #Maximum zener current, mA\n",
+ "P_z_max=Vz*Iz_max; #Maximum power dissipated in zener diode, W\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The series resistance=%d\u03a9.\"%RS);\n",
+ "print(\"(ii) The maximum power dissipated in series resistance=%.3fW.\"%P_max_RS);\n",
+ "print(\"(iii)The maximum power dissipated in zener diode=%.3fW.\"%P_z_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The series resistance=166\u03a9.\n",
+ "(ii) The maximum power dissipated in series resistance=0.542W.\n",
+ "(iii)The maximum power dissipated in zener diode=0.486W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.16 : Page number 456\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=2.0; #Resistor R1, k\u03a9\n",
+ "R2=1.0; #Resistor R2, k\u03a9\n",
+ "Vz=6.0; #Zener voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "m=R2/(R1+R2); #Feedback fraction\n",
+ "A_CL=1/m; #Closed-loop voltage gain\n",
+ "Vout=A_CL*(Vz+VBE); #Regulated output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The regulated output voltage=%.1fV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The regulated output voltage=20.1V\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.17 : Page number 456\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=30.0; #Resistor R1, k\u03a9\n",
+ "R2=10.0; #Resistor R2, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "m=R2/(R1+R2); #Feedback fraction\n",
+ "A_CL=1/m; #Closed-loop voltage gain\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The closed-loop voltage gain=%d.\"%A_CL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The closed-loop voltage gain=4.\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.18 : Page number 457\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vin=22.0; #Input voltage, V\n",
+ "Rs=130.0; #Series resistance, \u03a9\n",
+ "Vz=8.3; #Zener voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "RL=100.0; #Load resistance, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Vout=Vz+VBE; #Output voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "IL=(Vout/RL)*1000; #Load current, mA (OHM's LAW)\n",
+ "IS=((Vin-Vout)/Rs)*1000; #Current through series resistance, mA (OHM's LAW)\n",
+ "IC=IS-IL; #Collector current, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The regulated output voltage=%dV\"%Vout);\n",
+ "print(\"(ii) Various currents for the shunt regulator are: IL=%dmA , IS=%dmA and IC=%dmA\"%(IL,IS,IC));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The regulated output voltage=9V\n",
+ "(ii) Various currents for the shunt regulator are: IL=90mA , IS=100mA and IC=10mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.20 : Page number 463\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=240.0; #Resistor R1 of the regulator, \u03a9\n",
+ "R2=2.4; #Variable resistance R2 of the regulator, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Vout=1.25*(R2*1000/R1 + 1); #Regulated output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The regulated output voltage=%.2fV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The regulated output voltage=13.75V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 17.21 : Page number 463\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vout_adj=8.0; #Output voltage (adjusted), V\n",
+ "Vd=40.0; #Input/output differential rating, V\n",
+ "\n",
+ "#Calculation\n",
+ "Vin_max=Vout_adj+Vd; #Maximum allowable input voltage, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum allowable input voltage=%dV.\"%Vin_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum allowable input voltage=48V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter18_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter18_1.ipynb
new file mode 100644
index 00000000..34ff63b3
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter18_1.ipynb
@@ -0,0 +1,815 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:5aefee63b41b58f0caeac1aa6be18e130e4530aaaa6bc5e9bbc45b3687d3f8e9"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 18 : SOLID-STATE SWITCHING CIRCUITS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.1 : Page number 472"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10; #Supply voltage, V\n",
+ "RC=1.0; #Collector resistor, k\u03a9\n",
+ "RB=47.0; #Base resistor, k\u03a9\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "IC_sat=VCC/RC; #Collector saturation current, mA\n",
+ "IB=IC_sat/beta; #Base current, mA\n",
+ "V=IB*RB+VBE; #Input voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Input voltage required to saturate the transistor switch=%.1fV.\"%V);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input voltage required to saturate the transistor switch=5.4V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.2 : Page number 475"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10; #Supply voltage, V\n",
+ "RC=1.0; #Collector resistor, k\u03a9\n",
+ "ICBO=10.0; #Collector leakage current, \u03bcA\n",
+ "V_knee=0.7; #Knee voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "IC=ICBO; #Collector current, \u03bcA\n",
+ "VCE=VCC-(ICBO/1000)*RC; #Collector-emitter voltage, V\n",
+ "\n",
+ "print(\"(i) The collector emitter voltage at cut-off=%.2fV.\"%VCE);\n",
+ "\n",
+ "#(ii)\n",
+ "#Since, saturation current=IC_sat=(VCC-V_knee)/RC; \n",
+ "VCE=V_knee; #Collector-emitter voltage, V\n",
+ "\n",
+ "print(\"(ii) The collector emitter voltage at saturation=%.1fV.\"%VCE);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The collector emitter voltage at cut-off=9.99V.\n",
+ "(ii) The collector emitter voltage at saturation=0.7V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.3 : Page number 475-476"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10; #Supply voltage, V\n",
+ "RC=1; #Collector resistor, k\u03a9\n",
+ "VBB=2; #Supply voltage to base, V\n",
+ "RB=2.7; #Base resistor, k\u03a9\n",
+ "V_knee=0.7; #Knee voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "IB=round((VBB-VBE)/RB,2); #Base current, mA\n",
+ "Ic_sat=(VCC-V_knee)/RC; #Collector saturation current, mA\n",
+ "beta_min=Ic_sat/IB; #Minimum value of base current amplification factor\n",
+ "print(\"(i) Minimum \u03b2=%.1f.\"%beta_min);\n",
+ "\n",
+ "#(ii)\n",
+ "VBB=1; #Supply voltage to base(changed), V\n",
+ "beta=50; #Base current amplification factor\n",
+ "IB=(VBB-VBE)/RB; #Base current, mA\n",
+ "IC=beta*IB; #Collector current,mA\n",
+ "\n",
+ "if(IC<Ic_sat):\n",
+ " print(\"(ii) The transistor will not be saturated.\");\n",
+ "else:\n",
+ " print(\"(ii) The transistor will be saturated.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Minimum \u03b2=19.4.\n",
+ "(ii) The transistor will not be saturated.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.4 : Page number 480"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R2=10; #Resistor R2, k\u03a9\n",
+ "R3=10; #Resistor R3, k\u03a9\n",
+ "C1=0.01; #Capacitor of 1st transistor, \u03bcF\n",
+ "C2=0.01; #Capacitor of 2nd transistor, \u03bcF\n",
+ "\n",
+ "#Calculation\n",
+ "R=R2*1000; #Resistance, \u03a9\n",
+ "C=C1*10**-6; #Capacitance, F\n",
+ "T=round((1.4*R*C)*1000,2); #Time period,m sec\n",
+ "f=1/(T*10**-3); #Frequency, Hz\n",
+ "f=f/1000; #Frequency, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"Time period of the square wave=%.2f m sec.\"%T);\n",
+ "print(\"Time frequency of the square wave=%d kHz.\"%f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Time period of the square wave=0.14 m sec.\n",
+ "Time frequency of the square wave=7 kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.6 : Page number 485"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R=10; #Resistance in differentiating circuit, k\u03a9\n",
+ "C=2.2; #Capacitance in differentiating circuit, \u03bcF\n",
+ "d_ei=10; #Change in input voltage, V\n",
+ "dt=0.4; #Time in which change occurs, s\n",
+ "\n",
+ "#Calculation\n",
+ "eo=R*1000*C*10**-6*d_ei/dt\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output voltage=%.2fV.\"%eo);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output voltage=0.55V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.7 : Page number 489"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vin_peak=12; #Peak value of input voltage, V\n",
+ "V_D=0.7; #Forward bias voltage of diode, V\n",
+ "\n",
+ "#Calculation\n",
+ "Vout_peak=Vin_peak-V_D; #Peak value of output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The peak output voltage=%.1fV.\"%Vout_peak);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The peak output voltage=11.3V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.8 : Page number 489"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vin_peak=10; #Peak value of input voltage, V\n",
+ "R=1; #Input resistor, k\u03a9\n",
+ "RL=4; #Load resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Vout_peak=(Vin_peak*RL)/(R+RL); #Peak output voltage, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The peak output voltage=%dV.\"%Vout_peak);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The peak output voltage=8V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.9 : Page number 490"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vin=-10; #Input voltage, V\n",
+ "V_D=0.7; #Forward bias voltage of the diode, V\n",
+ "R=1; #Resistance, k\u03a9\n",
+ "\n",
+ "\n",
+ "print(\"The diode will be forward biased for the negative half-cycle of input signal.\");\n",
+ "Vout=-V_D; #Output voltage, V\n",
+ "V_R=Vin-(-V_D); #Voltage across resistor R, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output voltage=%.1fV.\"%Vout);\n",
+ "print(\"The voltage across R=%.1fV.\"%V_R);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The diode will be forward biased for the negative half-cycle of input signal.\n",
+ "The output voltage=-0.7V.\n",
+ "The voltage across R=-9.3V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.10 : Page number 490-491"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_F=0.7; #Forward bias voltage of diode, V\n",
+ "R=200.0; #Input resistor of the circuit, \u03a9\n",
+ "RL=1.0; #Load resistor, k\u03a9\n",
+ "Vin_peak=10.0; #Peak input voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#Positive half-cycle:\n",
+ "print(\"During the positive half cycle, the diode is foward biased and can be replaced by battery of %.1fV.\"%V_F);\n",
+ "print(\"Therefore, Vout=%.1fV.\"%V_F);\n",
+ "\n",
+ "#Negative half-cycle:\n",
+ "print(\"During the negative half cycle, the diode is reverse biased and hence behaves as an open circuit.\");\n",
+ "Vout_peak=RL*(-Vin_peak)/(R/1000+RL);\n",
+ "print(\"Therefore, Vout_peak=%.2fV.\"%Vout_peak);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "During the positive half cycle, the diode is foward biased and can be replaced by battery of 0.7V.\n",
+ "Therefore, Vout=0.7V.\n",
+ "During the negative half cycle, the diode is reverse biased and hence behaves as an open circuit.\n",
+ "Therefore, Vout_peak=-8.33V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.12 : Page number 491"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sin\n",
+ "from math import pi\n",
+ "V_biasing=10.0; #Biasing voltage, V\n",
+ "vin=[30*sin(t/10.0) for t in range(0,(int)(2*pi*10))] #input voltage waveform, V\n",
+ "p=plot(vin);\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vin(V)');\n",
+ "title('Input waveform');\n",
+ "show(p);\n",
+ "vout=[]; #Output voltage waveform, V\n",
+ "for v in vin[:]:\n",
+ " if(v-V_biasing)>0 : #Diode is forward biased.\n",
+ " vout.append(v-V_biasing);\n",
+ " else: #Diode is reverse biased.\n",
+ " vout.append(0);\n",
+ " \n",
+ "p=plot(vout);\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vout(V)');\n",
+ "title('Output waveform');\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYkAAAEZCAYAAABiu9n+AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3X18zfX/x/HHcRVp5iLmYjQXmxnDECUXQ0NiJoaRhPrW\n11dRii/f1FKZUmRCJUr6YUouYwgbJVPMVRNyObYpl2HY1ef3xzsnYtrFOed9Pue87rfbbm3nnH3O\nc8c6r72vLYZhGAghhBC3UUR3ACGEEM5LioQQQohcSZEQQgiRKykSQgghciVFQgghRK6kSAghhMiV\nFAkhTOD777/H19cXDw8Pli9frjuOcCNSJITT8vHxYf369XZ/nsjISAYMGGD35ymMV199leeff56L\nFy8SGhqqO45wI1IkhNOyWCxYLBbdMZzC8ePHCQgIKND3Zmdn2ziNcCdSJIQpfPbZZ7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4wc+ZM\n3TGEcBgpEkLkw7lz55gxY0aeHyuE2UmRECIf/vvf/3Lo0CGCgoIYNWrUHR/bo0cPunfvzooVK8jK\nynJQQiFsS1ZcC5EPx44do2vXruzZsydPj4+Pj2fOnDn88MMPhIeHM3jwYGrXrm3nlELYjrQkhMiH\n/P5N1bZtW+bOncv27dsB8Pf3Z8mSJfaIJoRdSJEQooBeeeUVgoKCaNKkifVwo6CgIOtZ2qB2n50/\nfz6PPfYY69atIzo6mocfflhfaCHySbqbhMiHM2fO0LRpU44ePfqPjx01ahRfffUVXbt2ZciQITRq\n1Mj+AYWwMSkSQuRT//792b17N4888gjvvPNOro9bvXo1HTp0oESJEg5MJ4RtSZEQQgiRKxmTEEII\nkSspEkIIIXIlRUIIIUSupEgIIYTIlRQJIYQQuZIiIYQQIldSJIQQQuRKioQQQohc/T8h6SoX+d+n\nUQAAAABJRU5ErkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a24cd1d0>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYEAAAEZCAYAAABxbJkKAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlYVWXiB/DvVVERTFGQRVDc2BQBNXcFQqxmXMclwUFD\np57ySceaycyfpjZNaWWWZTPVLyemfmnlkjkquYKmiaUgiKClgoiAG6C4sry/P07ccUHlwj33Peee\n7+d5fPTeC+d+QT1f3vc9i0kIIUBERIbUQHYAIiKShyVARGRgLAEiIgNjCRARGRhLgIjIwFgCREQG\nxhIg0rC5c+fCzc0NXl5esqOQnWIJkM189tlnCA4OhpOTEzw9PTFt2jSUlpbW+vN9fX2xY8cOq+Wx\n9vas7dSpU3jnnXeQnZ2NM2fOyI5DdoolQDaxZMkSzJ49G0uWLMGlS5ewb98+5ObmIjo6GuXl5bXa\nhslkgjXPbbT29qzt1KlTaN26NVq3bm3x51ZUVKiQi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yUlJYnhw4cLIfST/8SJEyIkJESEhISIrl27mv+/6iW/EEKkpaWJ\nXr16ie7du4vRo0eLkpISXeUvKysTrVu3FpcuXTI/Z2l+nixGRGRgmpoOIiIi22IJEBEZGEuAiMjA\nWAJERAbGEiAiMjCWABGRgbEEiG5RWlqKf/zjH7JjENkMS4DoFsXFxfjwww9r/bFEescSILrF7Nmz\ncfz4cYSFhWHWrFn3/djRo0dj5MiR2LBhAyoqKmyUkMi6eMYw0S1yc3MxbNgwZGRk1Orjk5OTsWLF\nCvz4448YN24cpkyZgk6dOqmcksh6OBIguoWlPxOFh4cjISEBBw4cAAAEBARg3bp1akQjUgVLgOge\n5s6di7CwMPTo0cN885qwsDDzvYwB5eqlX375Jf7whz9g69atWLZsGYYMGSIvNJGFOB1EdIsLFy6g\nZ8+eyMnJeeDHzpo1C6tXr8awYcMwdepUhISEqB+QyMpYAkR3mDhxItLT0/H444/jzTffvOfHbd68\nGVFRUWjcuLEN0xFZF0uAiMjAuCZARGRgLAEiIgNjCRARGRhLgIjIwFgCREQGxhIgIjIwlgARkYGx\nBIiIDOz/AUzB4hO0oBxxAAAAAElFTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a23a9e90>"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.13 : Page number 492"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "Vin=[]; #Input voltage waveform, V\n",
+ "t1=50; #Assumed time interval, s\n",
+ "t2=100; #Assumed time interval, s\n",
+ "V_biasing=10; #Biasing voltage, V\n",
+ "for t in range(0,151): #time interval from 0s to 151s\n",
+ " if(t<=t1): \n",
+ " Vin.append(15); #Value of input voltage for time 0 to t1 seconds \n",
+ " elif(t<=t2 and t>t1):\n",
+ " Vin.append(-30); #Value of input voltage for time t1 to t2 seconds\n",
+ " else :\n",
+ " Vin.append(15); #Value of input voltage after t2 seconds\n",
+ "\n",
+ "p=plot(Vin);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,160])\n",
+ "limit.set_ylim([-35,20])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vin(V)');\n",
+ "title('Input waveform');\n",
+ "show(p);\n",
+ "\n",
+ "vout=[]; #Output voltage waveform, V\n",
+ "for v in Vin[:]: #Loop iterating input voltage \n",
+ " if(v<=0):\n",
+ " vout.append(0); #Diode reverse biased\n",
+ " else:\n",
+ " vout.append(v-V_biasing); #Diode forward biased\n",
+ "\n",
+ "p=plot(vout);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,160])\n",
+ "limit.set_ylim([-35,20])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vout(V)');\n",
+ "title('Output waveform');\n",
+ "show(p);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYwAAAEZCAYAAACEkhK6AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3X1UlHX+//HXIHg0Q0RLEAaCRRBGESkjM1smFW9KkVBI\nMLSk3W09Ze52vN1usE3A6OZku9bprCabq2CZoa6xmIaypXkKshs6QgbKfZvcpKYO4uf3h1/nJ3Hj\nXBdzcX0uez3O4QQzw8w7GOfJ55rhg0kIIUBERHQNLnoPQERExsBgEBGRQxgMIiJyCINBREQOYTCI\niMghDAYRETmEwSAygI8//hjBwcFwd3fHzp079R6HfqUYDJJWQEAA9u3bp/ntpKWlISUlRfPb6Yln\nnnkGixcvxunTpxEbG6v3OPQrxWCQtEwmE0wmk95jSOHkyZOwWCyqPretrc3J09CvFYNBhrBp0yZM\nmDABS5cuxeDBg/Gb3/wG+fn59vOtVitWrlyJO+64Ax4eHoiLi0NTUxMAoLCwEH5+fu2u78rqJT8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gMD7U96yzanzWYTDz74oBg1apS4\n9dZbxUcffaR6TkPuJUVERL3PUIekiIhIPwwGERE5hMEgIiKHMBhEROQQBoOIiBzCYBARkUMYDCIF\nWlpa8Prrr+s9BpEuGAwiBZqamrB+/XqHL0t0PWEwiBRYsWIFjh8/jsjISCxbtqzby95///2YNWsW\ndu3ahYsXL/bShETa4W96Eylw4sQJzJgxA1999ZVDlz9w4AA2btyIQ4cOISEhAQsXLkRQUJDGUxJp\ngysMIgWU/nwVHR2N7OxsfP755wCA0NBQ7NixQ4vRiDTHYBCp9NRTTyEyMhK33norLl26hDFjxiAy\nMhJpaWn2y5w7dw5btmxBfHw89u7di3Xr1mHy5Mn6DU3UAzwkRaTAqVOncNttt6GysvKal122bBne\nffddzJgxA6mpqYiIiNB+QCINMRhECs2bNw9ffvklpk+fjhdeeKHLy33wwQeYNGkS+vbt24vTEWmH\nwSAiIofwOQwiInIIg0FERA5hMIiIyCEMBhEROYTBICIihzAYRETkEAaDiIgcwmAQEZFD/h//Vhlz\nQ+VgQAAAAABJRU5ErkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a25d35d0>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYwAAAEZCAYAAACEkhK6AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAH6xJREFUeJzt3XtcVHXi//H3IHhJXa+IAiqmKJKEaKG2bWKIWl4yLySY\nmrrblt/0a7uZ1upq+0jBXLKrtds3Vzc3sVJD12S9hbarZpvWmlioC4ogeAOS1Lj4+f3Bw/lJXjrD\n7Qz2ej4ePB4zZ86c82Zw5j3n8znOOIwxRgAA/AgPuwMAAGoHCgMAYAmFAQCwhMIAAFhCYQAALKEw\nAACWUBhALTZ79mx5e3vL19fX7ij4CaAw4DaWLVumkJAQNWzYUG3atNGUKVNUUFBg+f4BAQHatm1b\nleWp6u1VtWPHjunFF1/U119/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Hp3Lmz6dixo1mwYIHdcZw++eQT43A4TGhoqOnevbvp3r272bhxozlz5oyJ\njIw0gYGBJioqyuTl5dkd1RhjTEpKivMsKXfM+MUXX5g77rjD3H777ebBBx80+fn5bplz7ty5Jigo\nyHTr1s2MHz/eFBUVuUXOMWPGmDZt2hgvLy/j7+9vli5desNc8+fPNx07djRdunQxycnJtuV8++23\nTadOnUy7du2cz6PHH3/cbXLWrVvX+XheqUOHDs5Jb3fLWVRUZB5++GHTrVs306NHD/Pxxx9XOGet\n/CwpAEDNq1VDUgAA+1AYAABLKAwAgCUUBgDAEgoDAGAJhQEAsITCAFxQUFCgN954w+4YgC0oDMAF\neXl5WrJkieV1gZsJhQG4YNasWTpy5IjCwsL09NNP33DdBx98UA888IDWr1+vkpKSGkoIVB/+pzfg\ngqNHj2rIkCHav3+/pfW3b9+upUuXateuXRo9erQmTZqkjh07VnNKoHpwhAG4wNX3V3379tXy5cv1\n+eefS5KCgoK0du3a6ogGVDsKA6ig2bNnKywsTD169NClS5fUvXt3hYWFad68ec51Lly4oHfffVcj\nRozQ5s2b9corr6h///72hQYqgSEpwAVnzpxRz549lZGR8aPrPv300/rggw80ZMgQTZ48WaGhodUf\nEKhGFAbgorFjx+o///mP7rvvPr3wwgvXXW/jxo2KjIxU3bp1azAdUH0oDACAJcxhAAAsoTAAAJZQ\nGAAASygMAIAlFAYAwBIKAwBgCYUBALCEwgAAWPL/AAJNjJBx3DtUAAAAAElFTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a2496cd0>"
+ ]
+ }
+ ],
+ "prompt_number": 37
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.14 : Page number 492-493"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "Vin=[]; #Input voltage waveform, V\n",
+ "t1=50; #Assumed time interval, s\n",
+ "t2=100; #Assumed time interval, s\n",
+ "V_biasing=5; #Biasing voltage, V\n",
+ "for t in range(0,151): #time interval from 0s to 151s\n",
+ " if(t<=t1): \n",
+ " Vin.append(10); #Value of input voltage for time 0 to t1 seconds \n",
+ " elif(t<=t2 and t>t1):\n",
+ " Vin.append(-10); #Value of input voltage for time t1 to t2 seconds\n",
+ " else :\n",
+ " Vin.append(0);\n",
+ " \n",
+ "p=plot(Vin);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,101])\n",
+ "limit.set_ylim([-20,20])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vin(V)');\n",
+ "title('Input waveform');\n",
+ "show(p);\n",
+ "\n",
+ "vout=[]; #Output voltage waveform, V\n",
+ "for v in Vin[:]: #Loop iterating input voltage \n",
+ " if(v<=0):\n",
+ " vout.append(v); #Diode reverse biased\n",
+ " else:\n",
+ " vout.append(v-V_biasing); #Diode forward biased\n",
+ "\n",
+ "p=plot(vout);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,101])\n",
+ "limit.set_ylim([-20,20])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vout(V)');\n",
+ "title('Output waveform');\n",
+ "show(p);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEZCAYAAACNebLAAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAH/pJREFUeJzt3X1UVHX+B/D3RUBJAUET5ClYBMdRxDGyMo0pHAQTIgwV\nXGqVdi1/Za6eTDupY7sCPZw86eaWmw+YRyUz0sxm1bVBK1nPJqaJG2qMIU+lPKSmgnh/f7BOEhdk\nxoF7Z+b9OmcOM/dh7me+Hu+b7/d7LyOIoiiCiIjoN1zkLoCIiJSJAUFERJIYEEREJIkBQUREkhgQ\nREQkiQFBRESSGBBEduDLL79EREQEPD09sWPHDrnLISfBgCDFCg0Nxb/+9a8uP45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FTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f4f12db9190>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEZCAYAAACNebLAAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XtYVHX+B/D3EVBRTFGQu2JcRJRgrEzbkiEYzAQveUlw\nydTt5qZrmmU9mtiTiKVZWm66jxblk1gZqZmskjt0UWJ/oRuJLWaAyM0bg6EoF7+/P1gnkQMx48A5\nzLxfzzMPc87MOfOZbznv+V5mRhJCCBAREd2ki9IFEBGROjEgiIhIFgOCiIhkMSCIiEgWA4KIiGQx\nIIiISBYDgqgTW7p0KVxdXeHp6al0KWSFGBCkGu+//z5CQkLQs2dPeHh4YO7cuaiqqmrz8b6+vjh4\n8KDF6rH0+Szt1KlTeOONN/Dzzz+jtLRU6XLICjEgSBXWrl2LJUuWYO3atbh48SKysrJQVFQEnU6H\nurq6Np1DkiRY8nOflj6fpZ06dQr9+vVDv379TD62vr6+HSoiqyOIFFZVVSWcnJzEJ5980mR/dXW1\ncHV1FVu3bhVCCDFz5kyxdOlS4+3/+te/hLe3txBCiD//+c+iS5cuwtHRUTg5OYnXX39dFBQUCEmS\nxObNm4Wnp6fw8PAQa9asMR5v6vluNnr0aLFz504hhBDffvutkCRJ7N27VwghREZGhggLCxNCCPHL\nL7+IiIgI0a9fP+Hi4iJmzJghDAaDEEKI5ORkMWXKlCbnnT9/vpg/f74QQgiDwSBmz54tPDw8hJeX\nl1i6dKloaGgQBw4cEI6OjqJLly7CyclJzJo1SwghxK5du0RwcLDo06eP0Gq14vjx48bzDhw4UKxe\nvVqEhISI7t27i19++UVIkiTee+894ePjI5ydncW7774rsrOzRUhIiOjTp4945pln2vYfkawSA4IU\nt2/fPmFvby8aGhqa3TZz5kwRFxcnhBDiscceE8uWLTPeduMLuhBC+Pr6iq+++sq4fT0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wILKyslBT\nUwMhBDIyMhAcHGxz7XBdS/8Wxo8fj9TUVNTW1qKgoAAnTpzAiBEjWj+ZpSdM2tuXX34pAgMDhZ+f\nn0hKSlK6nA7zzTffCEmSRGhoqAgLCxNhYWFi37594vz58yIyMlIEBAQInU4nKisrlS61w+j1ehEb\nGyuEEDbbDkePHhV33XWXuOOOO8SkSZOEwWCwybZYvny5CAoKEsOGDROPPvqoqK2ttYl2mD59uvDw\n8BAODg7C29tbbN26tdXnvXLlSuHn5ycGDx4s0tPT//D8/KAcERHJ6lRDTERE1HEYEEREJIsBQURE\nshgQREQkiwFBRESyGBBERCSLAUFkgqqqKvz9739XugyiDsGAIDJBZWUlNm7c2Ob7EnVmDAgiEyxZ\nsgQnT56ERqPB888/3+p9J02ahAkTJmDPnj2or6/voAqJLIefpCYyQVFREWJiYpCbm9um+2dmZmLr\n1q04fPjuqg5MAAAA8klEQVQwpk6ditmzZ8PPz6+dqySyDPYgiExg6vup8PBwpKSk4IcffgAABAUF\nIS0trT1KI7I4BgSRmZYuXQqNRoPhw4fj2rVrCAsLg0ajQWJiovE+NTU1+Oijj/Dwww/jwIEDWL9+\nPaKiopQrmsgEHGIiMsH58+dx5513orCw8A/v+/zzz+PTTz9FTEwM5syZg9DQ0PYvkMiCGBBEJpox\nYwZ+/PFHjB07Fq+99lqL99u3bx8iIyPRtWvXDqyOyHIYEEREJItzEEREJIsBQUREshgQREQkiwFB\nRESyGBBERCSLAUFERLIYEEREJIsBQUREsv4f6Fm2xaDZ14IAAAAASUVORK5CYII=\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f4f12c80dd0>"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.15 : Page number 493"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "Vin=[]; #Input voltage waveform, V\n",
+ "t1=50; #Assumed time interval, s\n",
+ "t2=100; #Assumed time interval, s\n",
+ "V_D1=0.6; #Forward Biasing voltage of the 1st diode, V\n",
+ "V_D2=0.6; #Forward Biasing voltage of the 2nd diode, V\n",
+ "for t in range(0,151): #time interval from 0s to 151s\n",
+ " if(t<=t1): \n",
+ " Vin.append(10); #Value of input voltage for time 0 to t1 seconds \n",
+ " elif(t<=t2 and t>t1):\n",
+ " Vin.append(-10); #Value of input voltage for time t1 to t2 seconds\n",
+ " else :\n",
+ " Vin.append(0);\n",
+ " \n",
+ "p=plot(Vin);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,110])\n",
+ "limit.set_ylim([-20,20])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vin(V)');\n",
+ "title('Input waveform');\n",
+ "show(p);\n",
+ "\n",
+ "vout=[]; #Output voltage waveform, V\n",
+ "for v in Vin[:]: #Loop iterating input voltage \n",
+ " if(v<=0):\n",
+ " vout.append(-V_D1); #Diode D1 forward biased, \n",
+ " else:\n",
+ " vout.append(V_D2); #Diode D2 forward biased\n",
+ "\n",
+ "p=plot(vout);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,110])\n",
+ "limit.set_ylim([-1,1])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vout(V)');\n",
+ "title('Output waveform');\n",
+ "show(p);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYMAAAEZCAYAAAB1mUk3AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAH2lJREFUeJzt3X1UVHXiBvDnKqCmiGAK8iYsguMo4hhZmcYYjqIJEYYK\nLpXS9uIpdfWXaSd1aFeg7OSmm1vtplKuSlakWc2ia0OWkmcT8wU3zBgbebGUF5FMEO/vD5abvIrG\nnTsz9/mcM8eZO3dmni9y7sP93rkzgiiKIoiISNW6KR2Ai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T5GMDlUGkZGROHnyJCwWC+rq6pCdnY24uDilY3U5URSRmpoKrVaLhQsXSsvj\n4uKQlZUFAMjKypJKwtGlp6fDarWiuLgY27Ztw7333ot33nnHaccLAD4+PggICEBRURGAxg3l8OHD\nERsb67RjHjx4MPLz83Hp0iWIoog9e/ZAq9U69ZibtPe7HBcXh23btqGurg7FxcU4efIkxowZo0xI\nRY5U/AaffPKJGBYWJoaEhIjp6elKx5HFvn37REEQxIiICHHUqFHiqFGjxE8//VQ8f/68GB0dLYaG\nhooGg0GsrKxUOmqXM5vNYmxsrCiKotOP9/Dhw2JkZKQ4cuRI8YEHHhCrqqqcfswrV64UNRqNOGLE\nCPGhhx4S6+rqnG7Ms2bNEgcNGiS6urqK/v7+4oYNGzoc46pVq8SQkBBx6NChoslkUiw3TzojIiLH\nmiYiIiJ5sAyIiIhlQERELAMiIgLLgIiIwDIgIiKwDIhuSHV1Nf72t78pHYOoy7EMiG5AZWUl1q9f\n3+l1iRwFy4DoBixduhSnTp2CTqfDkiVLOlz3gQcewP3334+PPvoIV65csVFCopvDM5CJbsDp06cx\nbdo0HD16tFPr5+XlYcOGDThw4AASExMxd+5chISEyJyS6MZxz4DoBtzo305RUVHIysrC119/DQDQ\naDTIycmRIxrRb8IyILpJzz//PHQ6HUaPHo2rV69i1KhR0Ol0MBqN0jqXLl3Cli1bkJCQgN27d2Pt\n2rWYOHGicqGJ2sFpIqIbcP78edx2222wWCzXXXfJkiV47733MG3aNKSmpiIiIkL+gEQ3iWVAdINm\nz56NI0eOYMqUKXjppZfaXe/TTz9FdHQ03NzcbJiO6OawDIiIiMcMiIiIZUBERGAZEBERWAZERASW\nARERgWVARERgGRAREVgGREQE4P8B9NpS75ZEenwAAAAASUVORK5CYII=\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a2417c90>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYYAAAEZCAYAAACTsIJzAAAAB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Rkdf3ed68eSY8PNz06tXL3H//\n/ebSpUte1eeJEyeagIAA4+vra4KDg83KlSur7N+zzz5runbtanr06GFSU1PdVjcnuAEALBrsUBIA\noG4QDAAAC4IBAGBBMAAALAgGAIAFwQAAsCAYgBo6d+6c3njjDXeXAdQ6ggGoocLCQr3++usutwUa\nCoIBqKE5c+bo6NGjiomJ0ZNPPlll2zvvvFN33HGHNm/erNLS0nqqEKgZznwGauj48eMaPXq0Dhw4\n4FL7Xbt2aeXKldqzZ48mTJigqVOnqmvXrnVcJfDTccQA1NBP/UwVGxurVatWae/evZKk8PBwbdiw\noS5KA64LwQDUgrlz5yomJkZ9+vTR5cuXFR0drZiYGM2fP9/Z5sKFC1q9erXuuusu7dixQ8uWLdOw\nYcPcVzRQCYaSgBo6c+aMbrnlFmVnZ1fb9sknn9S6des0evRoTZs2Tb179677AoEaIhiA63Dffffp\n888/1+23367nn3++0nbbtm1TfHy8mjRpUo/VATVDMAAALJhjAABYEAwAAAuCAQBgQTAAACwIBgCA\nBcEAALAgGAAAFgQDAMDi/wAfN3vR+U6XwgAAAABJRU5ErkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a23368d0>"
+ ]
+ }
+ ],
+ "prompt_number": 42
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.16 : Page number 493-494"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "from math import sin\n",
+ "from math import pi\n",
+ "\n",
+ "VZ=20; #Assumed zener voltage, V\n",
+ "VF=0.7; #Assumed forward biasing voltage of the zener diode, V\n",
+ "Vin=[]; #Input voltage waveform, V\n",
+ "for t in range(0,(int)(2*pi*10)): #time interval from 0s to 151s\n",
+ " Vin.append(30*sin(t/10.0));\n",
+ " \n",
+ "p=plot(Vin);\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vin(V)');\n",
+ "title('Input waveform');\n",
+ "show(p);\n",
+ "\n",
+ "vout=[]; #Output voltage waveform, V\n",
+ "for v in Vin[:]: #Loop iterating input voltage \n",
+ " if(v<=-VF):\n",
+ " vout.append(-VF); #Zener diode forward biased, \n",
+ " elif(v>=VZ):\n",
+ " vout.append(VZ); #Input voltage exceeds zener voltage\n",
+ " else:\n",
+ " vout.append(v); #Zener diode reverse biased\n",
+ "\n",
+ "p=plot(vout);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,80])\n",
+ "limit.set_ylim([-1,40])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vout(V)');\n",
+ "title('Output waveform');\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYkAAAEZCAYAAABiu9n+AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3X18zfX/x/HHcRVp5iLmYjQXmxnDECUXQ0NiJoaRhPrW\n11dRii/f1FKZUmRCJUr6YUouYwgbJVPMVRNyObYpl2HY1ef3xzsnYtrFOed9Pue87rfbbm3nnH3O\nc8c6r72vLYZhGAghhBC3UUR3ACGEEM5LioQQQohcSZEQQgiRKykSQgghciVFQgghRK6kSAghhMiV\nFAkhTOD777/H19cXDw8Pli9frjuOcCNSJITT8vHxYf369XZ/nsjISAYMGGD35ymMV199leeff56L\nFy8SGhqqO45wI1IkhNOyWCxYLBbdMZzC8ePHCQgIKND3Zmdn2ziNcCdSJIQpfPbZZ7Rq1YqXX36Z\n8uXLU6tWLWJjY633BwcHM2bMGFq0aIGnpydhYWGcO3cOgLi4OKpXr37T9a63UmJjY4mKiiImJgYP\nDw+CgoJuee5PP/30pr/efX196d27t/Xr6tWrs3v3bgCGDx9OjRo18PT0pFmzZnz33XcApKSkcPfd\nd1szASQmJlKxYkXrm/icOXMICAigfPnydO7cmePHjwNQu3ZtDh8+TLdu3ShT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NKkifVwo6CgIOtZ2qB2n50/\nfz6PPfYY69atIzo6mocfflhfaCHySbqbhMiHM2fO0LRpU44ePfqPjx01ahRfffUVXbt2ZciQITRq\n1Mj+AYWwMSkSQuRT//792b17N4888gjvvPNOro9bvXo1HTp0oESJEg5MJ4RtSZEQQgiRKxmTEEII\nkSspEkIIIXIlRUIIIUSupEgIIYTIlRQJIYQQuZIiIYQQIldSJIQQQuRKioQQQohc/T8h6SoX+d+n\nUQAAAABJRU5ErkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a2639290>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYEAAAEZCAYAAABxbJkKAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XtYVGXiB/DvUcxEzBswoKDgBQVBGK/pqgxxMQu85BVc\nJaXa1t/WY7oZ9ehKu63hlnmpbbft6cLao2h5CVdFQBo1zXQTfmFmbiqKCCgKKApye39/zDI/SUEG\nOHPOzPl+nqdnmRnmzFdY5jvnfc95jySEECAiIk1qp3QAIiJSDkuAiEjDWAJERBrGEiAi0jCWABGR\nhrEEiIg0jCVApGLLly+Hi4sLevXqpXQUslMsAbKaTz/9FAEBAejcuTPc3d2xaNEilJWVNfv5Xl5e\nyMzMbLM8bb29tnbx4kW88847OH36NC5fvqx0HLJTLAGyijVr1iA+Ph5r1qzBjRs3cPToUVy4cAHh\n4eGorq5u1jYkSUJbntvY1ttraxcvXkTPnj3Rs2dPi59bU1MjQyKyS4JIZmVlZcLJyUl8/vnnDe4v\nLy8XLi4u4uOPPxZCCBEbGyuWL19ufvyrr74SHh4eQgghfv3rX4t27dqJTp06CScnJ/HWW2+J8+fP\nC0mSxD/+8Q/Rq1cv4e7uLt5++23z8y3d3i9NmDBBbNu2TQghxNdffy0kSRK7d+8WQgiRkZEhgoKC\nhBBC/PzzzyIkJET07NlTODs7i7lz54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mTCxcuBD9+/eXOSVR2+GeANFdLP1MFBwcjKSkJHz33XcAgMGDB2PHjh1yRCOSBUuA\nqBHLly+HXq/HsGHDzBfA0ev15ushA6YVUDdt2oSnnnoK6enp2LBhA8LCwpQLTWQhDgcR3eXatWsY\nPnw4cnNzH/i9y5YtwxdffIHIyEjExcUhMDBQ/oBEbYwlQPQLc+fOxffff49JkybhL3/5S6Pft3fv\nXoSGhuKhhx6yYjqitsUSICLSMM4JEBFpGEuAiEjDWAJERBrGEiAi0jCWABGRhrEEiIg0jCVARKRh\nLAEiIg37P3SDpk3uSVOuAAAAAElFTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a232f110>"
+ ]
+ }
+ ],
+ "prompt_number": 54
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 18.17 : Page number 494"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "from math import sin\n",
+ "from math import pi\n",
+ "\n",
+ "VZ1=20; #Assumed zener voltage, V\n",
+ "VF1=0.7; #Assumed forward biasing voltage of the zener diode, V\n",
+ "VZ2=20; #Assumed zener voltage, V\n",
+ "VF2=0.7; #Assumed forward biasing voltage of the zener diode, V\n",
+ "Vin=[]; #Input voltage waveform, V\n",
+ "for t in range(0,(int)(2*pi*10)): #time interval from 0s to 151s\n",
+ " Vin.append(30*sin(t/10.0));\n",
+ " \n",
+ "p=plot(Vin);\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vin(V)');\n",
+ "title('Input waveform');\n",
+ "show(p);\n",
+ "\n",
+ "vout=[]; #Output voltage waveform, V\n",
+ "for v in Vin[:]: #Loop iterating input voltage \n",
+ " if(v<=-(VZ1+VF2)):\n",
+ " vout.append(-(VZ1+VF2)); #Zener diode forward biased, \n",
+ " elif(v>=VZ2+VF1):\n",
+ " vout.append(VZ2+VF1); #Input voltage exceeds zener voltage\n",
+ " else:\n",
+ " vout.append(v); #Zener diode reverse biased\n",
+ "\n",
+ "p=plot(vout);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,80])\n",
+ "limit.set_ylim([-40,40])\n",
+ "xlabel('t-->');\n",
+ "ylabel('Vout(V)');\n",
+ "title('Output waveform');\n",
+ "show(p);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYkAAAEZCAYAAABiu9n+AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3X18zfX/x/HHcRVp5iLmYjQXmxnDECUXQ0NiJoaRhPrW\n11dRii/f1FKZUmRCJUr6YUouYwgbJVPMVRNyObYpl2HY1ef3xzsnYtrFOed9Pue87rfbbm3nnH3O\nc8c6r72vLYZhGAghhBC3UUR3ACGEEM5LioQQQohcSZEQQgiRKykSQgghciVFQgghRK6kSAghhMiV\nFAkhTOD777/H19cXDw8Pli9frjuOcCNSJITT8vHxYf369XZ/nsjISAYMGGD35ymMV199leeff56L\nFy8SGhqqO45wI1IkhNOyWCxYLBbdMZzC8ePHCQgIKND3Zmdn2ziNcCdSJIQpfPbZZ7Rq1YqXX36Z\n8uXLU6tWLWJjY633BwcHM2bMGFq0aIGnpydhYWGcO3cOgLi4OKpXr37T9a63UmJjY4mKiiImJgYP\nDw+CgoJuee5PP/30pr/efX196d27t/Xr6tWrs3v3bgCGDx9OjRo18PT0pFmzZnz33XcApKSkcPfd\nd1szASQmJlKxYkXrm/icOXMICAigfPnydO7cmePHjwNQu3ZtDh8+TLdu3ShTpgyZmZmkpKQQGhpK\nhQoV8PX15ZNPPrFeNzIykl69ejFgwAA8PT357LPPCA4O5pVXXuGhhx7Cw8OD0NBQzpw5Q//+/fH0\n9KR58+YcO3asYP84wqVJkRCmsW3bNvz9/Tlz5gyjRo1iyJAhN90/b948Pv30U1JTUylWrBjPP/98\nrte63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EkIIIXIlRUIIIUSupEgIIYTIlRQJIYQQuZIiIYQQIldSJIQQQuRKioQQQohc/T8h6SoX+d+n\nUQAAAABJRU5ErkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a2723990>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYkAAAEZCAYAAABiu9n+AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XtYVNXCBvB3EPKeN3BQIMcURASFNMwuOoiQlpKmoWBI\naqfPTEstDUsTSwUtK+1kdUyL9CTaMW+pJGhD9nmhk1oYKVqi3PMCKN64re+PnfOJso2BGdYMvL/n\n8Ym57XnBnJe99tp7aYQQAkRERFWwkx2AiIisF0uCiIhUsSSIiEgVS4KIiFSxJIiISBVLgoiIVLEk\niGzYnDlz4OTkhI4dO8qOQvUUS4Ksxueffw4fHx80b94cHTp0wOTJk1FUVFTt1+t0OuzZs8dsecy9\nPXM7c+YM3n33XRw7dgw5OTmy41A9xZIgq7B06VJERUVh6dKluHjxIg4cOIDTp08jKCgIpaWl1dqG\nRqOBOc8NNff2zO3MmTNo164d2rVrZ/Jry8rKLJCI6iVBJFlRUZFo0aKF+OqrryrdX1xcLJycnMTq\n1auFEEJERkaKOXPmGB//7rvvhKurqxBCiKefflrY2dmJpk2bihYtWoi3335bnDp1Smg0GvGvf/1L\ndOzYUXTo0EG88847xtebur1b9e/fX2zcuFEIIcQPP/wgNBqN2L59uxBCiKSkJOHr6yuEEOLkyZMi\nICBAtGvXTjg6OoqxY8eKwsJCIYQQsbGxYtSoUZW2++KLL4oXX3xRCCFEYWGhmDBhgujQoYNwcXER\nc+bMEeXl5SIxMVE0bdpU2NnZiRYtWojx48cLIYTYsmWL8PLyEq1btxZ6vV789ttvxu126tRJLF68\nWPj4+IgmTZqIkydPCo1GIz777DPh5uYm2rRpIz7++GORkpIifHx8ROvWrcWUKVO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kZ1+QGlKvYfvnll3jyySeRmJiI5cuXY9CgQfJCE5mIw01EJjh//jx69+6NjIyMv33urFmz8J//\n/AdDhw7FxIkT0atXL8sHJDIzlgSRicaOHYtffvkFQ4YMwZIlS1Sft3PnTgQGBuKuu+6qw3RE5sWS\nICIiVTwmQUREqlgSRESkiiVBRESqWBJERKSKJUFERKpYEkREpIolQUREqlgSRESk6v8AbU8ybWOZ\nXb8AAAAASUVORK5CYII=\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f15a2583910>"
+ ]
+ }
+ ],
+ "prompt_number": 55
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter19_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter19_1.ipynb
new file mode 100644
index 00000000..5c74053c
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter19_1.ipynb
@@ -0,0 +1,1666 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:e80dba2d461291c68fb06b32e702542441b6f13e4e124da0b4826c1be4471e9c"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 19 : FIELD EFFECT TRANSISTORS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.1 : Page number 515\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_DSS=12.0; #Shorted gate drain current, mA\n",
+ "V_GS_off=-5.0; #Gate-source cut-off voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"ID=%d[1 + VGS/%d]\u00b2mA.\"%(I_DSS,abs(V_GS_off)));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "ID=12[1 + VGS/5]\u00b2mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 40
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.2 : Page number 515\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_DSS=32.0; #Shorted gate drain current, mA\n",
+ "V_GS_off=-8.0; #Gate-source cut-off voltage, V\n",
+ "V_GS=-4.5; #Gate-source voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "I_D=I_DSS*(1-(V_GS/V_GS_off))**2; #Drain current mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The drain current=%.2fmA.\"%I_D);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The drain current=6.12mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 41
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.3 : Page number 515\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "I_DSS=10.0; #Shorted gate drain current, mA\n",
+ "V_GS_off=-6.0; #Gate-source cut-off voltage, V\n",
+ "I_D=5.0; #Drain current mA\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#Since, I_D=I_DSS*[1 - (V_GS/V_GS_off)]\u00b2\n",
+ "V_GS=V_GS_off*(1-sqrt(I_D/I_DSS)); #Gate-source voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "V_P=-V_GS_off; #Pinch-off voltage, V \n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) VGS=%.2fV.\"%V_GS);\n",
+ "print(\"(ii) VP=%dV\"%V_P);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) VGS=-1.76V.\n",
+ "(ii) VP=6V\n"
+ ]
+ }
+ ],
+ "prompt_number": 42
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.4 : Page number 515-516\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_GS_off=-4.0; #Gate-source cut-off voltage, V\n",
+ "I_DSS=12.0; #Shorted gate drain current, mA\n",
+ "R_D=560.0; #Drain resistor, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "V_P=-V_GS_off; #Pinch-off voltage, V\n",
+ "V_DS=V_P; #Minimum drain-source voltage for JFET to be in constant current region, V\n",
+ "I_D=I_DSS; #Maximum drain current, mA (V_GS=0)\n",
+ "V_RD=(I_D/1000)*R_D; #Voltage across drain resistor, V (OHM's LAW)\n",
+ "V_DD=V_DS+V_RD; #Minimum value of supply voltage to drain, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The minimum value of VDD required =%.2fV.\"%V_DD);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The minimum value of VDD required =10.72V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 43
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.5 : Page number 516\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_DSS=3.0; #Shorted gate drain current, mA\n",
+ "V_GS_off=-6.0; #Gate-source cut-off voltage, V\n",
+ "V_GS=-2.0; #Gate-source voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "I_D=I_DSS*(1-(V_GS/V_GS_off))**2; #Drain current mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The drain current=%.2fmA.\"%I_D);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The drain current=1.33mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 44
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.6 : Page number 516"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VGS_off=4; #Gate-source cut-off voltage, V\n",
+ "VGS=6; #Gate source voltage, V\n",
+ "\n",
+ "print(\"p-channel JFET requires a positive gate-to-source voltage to pass drain current.\");\n",
+ "print(\"More positive voltage, the less the drain current. \");\n",
+ "print(\"Any further increase in VGS keeps the JFET cut-off. Therefore, ID=0A.\");"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "p-channel JFET requires a positive gate-to-source voltage to pass drain current.\n",
+ "More positive voltage, the less the drain current. \n",
+ "Any further increase in VGS keeps the JFET cut-off. Therefore, ID=0A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 45
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.7 : Page number 517-518\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_GS=15.0; #Gate-source voltage, V\n",
+ "I_G=1e-03; #Gate current, \u03bcA\n",
+ "\n",
+ "#Calculation\n",
+ "R_GS=(V_GS/(I_G*10**-6))/10**6; #Gate to source resistance, M\u03a9 (OHM's LAW)\n",
+ "\n",
+ "#Result\n",
+ "print(\"The gate to source resistance=%dM\u03a9.\"%R_GS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The gate to source resistance=15000M\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 47
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.8 : Page number 518\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "V_GS_max=-3.1; #Maximum gate to source voltage, V\n",
+ "V_GS_min=-3.0; #Minimum gate to source voltage, V\n",
+ "I_D_max=1.3; #Maximum drain current, mA\n",
+ "I_D_min=1.0; #Minimum drain current, mA\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "delta_V_GS=abs(V_GS_max-V_GS_min); #Change in gate to source voltage, V\n",
+ "delta_I_D=I_D_max-I_D_min; #Change in drain current, mA\n",
+ "g_fs=(delta_I_D/delta_V_GS)*1000; #Transconductance, \u03bc mho\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Transconductance=%.0f \u03bc mho\"%g_fs);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Transconductance=3000 \u03bc mho\n"
+ ]
+ }
+ ],
+ "prompt_number": 50
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.9 : Page number 518\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_GS=[0,0,-0.2]; #Readings of Gate-source voltage, V\n",
+ "V_DS=[7,15,15]; #Readings of Drain-source voltage, V\n",
+ "ID=[10,10.25,9.65]; #Readings of drain current, mA\n",
+ "\n",
+ "\n",
+ "#Displaying the readings:\n",
+ "print(\"VGS= %dV %dV %.1fV\"%(V_GS[0],V_GS[1],V_GS[2]));\n",
+ "print(\"VDS= %dV %dV %dV\"%(V_DS[0],V_DS[1],V_DS[2]));\n",
+ "print(\"ID = %dV %.2fV %.2fV\"%(ID[0],ID[1],ID[2]));\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "#V_GS constant at 0V,\n",
+ "delta_VDS=V_DS[1]-V_DS[0]; #Change in drain-source voltage, V\n",
+ "delta_ID=ID[1]-ID[0]; #Change in drain current, mA\n",
+ "rd=delta_VDS/delta_ID; #a.c drain resistance, k\u03a9\n",
+ "\n",
+ "#(ii)\n",
+ "#V_DS constant at 15V,\n",
+ "delta_VGS=V_GS[2]-V_GS[1]; #Change in gate-source voltage, V\n",
+ "delta_ID=ID[2]-ID[1]; #Change in drain current, mA\n",
+ "g_fs=round((delta_ID/delta_VGS)*1000,); #Transconductance, \u03bc mho\n",
+ "\n",
+ "#(iii)\n",
+ "amplification_factor=rd*1000*g_fs*10**-6; #Amplification factor\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The a.c drain resistance=%dk\u03a9.\"%rd);\n",
+ "print(\"(ii) The transconductance=%d \u03bc mho.\"%g_fs);\n",
+ "print(\"(iii) The amplification factor=%d.\"%amplification_factor );\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "VGS= 0V 0V -0.2V\n",
+ "VDS= 7V 15V 15V\n",
+ "ID = 10V 10.25V 9.65V\n",
+ "(i) The a.c drain resistance=32k\u03a9.\n",
+ "(ii) The transconductance=3000 \u03bc mho.\n",
+ "(iii) The amplification factor=96.\n"
+ ]
+ }
+ ],
+ "prompt_number": 53
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.10 : Page number 519\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "g_mo=4000.0; #Maximum transconductance, \u03bcS\n",
+ "V_GS=-3.0; #Gate to source voltage, V\n",
+ "V_GS_off=-8.0; #Gate-source cut-off voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "g_m=g_mo*(1-(V_GS/V_GS_off)); #Transconductance, \u03bcS\n",
+ "\n",
+ "#Result\n",
+ "print(\"The transconductance=%d \u03bcS.\"%g_m);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The transconductance=2500 \u03bcS.\n"
+ ]
+ }
+ ],
+ "prompt_number": 54
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.11 : Page number 519\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "g_mo=5000.0; #Maximum transconductance, \u03bcS\n",
+ "V_GS=-4.0; #Gate to source voltage, V\n",
+ "V_GS_off=-6.0; #Gate-source cut-off voltage, V\n",
+ "I_DSS=3.0; #Shorted-gate drain current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "g_m=g_mo*(1-(V_GS/V_GS_off)); #Transconductance, \u03bcS\n",
+ "I_D=(I_DSS*(1-(V_GS/V_GS_off))**2)*1000; #Drain current \u03bcA\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The transconductance=%.0f \u03bcS.\"%g_m);\n",
+ "print(\"The drain current=%d \u03bcA.\"%I_D);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The transconductance=1667 \u03bcS.\n",
+ "The drain current=333 \u03bcA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 55
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.12 : Page number 520\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_GS_off=-8.0; #Gate-source cut-off voltage, V\n",
+ "I_DSS=16.0; #Shorted-gate drain current, mA\n",
+ "R_D=2.2; #Drain resistor, k\u03a9\n",
+ "R_G=1.0; #Gate resistor, M\u03a9\n",
+ "V_DD=10.0; #Drain supply voltage, V\n",
+ "V_GG=-5.0; #Gate supply voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_GS=V_GG; #Gate-source voltage, V\n",
+ "I_D=I_DSS*(1-(V_GS/V_GS_off))**2; #Drain current \u03bcA\n",
+ "V_DS=V_DD-I_D*R_D; #Drain-source voltage, V (Kirchhoff's voltage law)\n",
+ "\n",
+ "#Result\n",
+ "print(\"The gate-source voltage=%dV.\"%V_GS);\n",
+ "print(\"The drain current=%.2fmA.\"%I_D);\n",
+ "print(\"The drain-source voltage=%.2fV.\"%V_DS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The gate-source voltage=-5V.\n",
+ "The drain current=2.25mA.\n",
+ "The drain-source voltage=5.05V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 56
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.13 : Page number 521\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_D=5.0; #Drain current mA\n",
+ "V_DD=15.0; #Drain supply voltage, V\n",
+ "V_G=0; #Gate voltage, V\n",
+ "R_D=1.0; #Drain resistor, k\u03a9\n",
+ "R_S=470.0; #Source resistor, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_S=(I_D/1000)*R_S; #Source voltage, V (OHM's LAW)\n",
+ "V_D=V_DD-I_D*R_D; #Drain voltage, V (Kirchhoff's voltage law)\n",
+ "V_DS=V_D-V_S; #Drain-source voltage, V\n",
+ "V_GS=V_G-V_S; #Gate-source voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The drain-source voltage=%.2fV.\"%V_DS);\n",
+ "print(\"The gate-source voltage=%.2fV.\"%V_GS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The drain-source voltage=7.65V.\n",
+ "The gate-source voltage=-2.35V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 57
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.14 : Page number 521\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_GS=-5.0; #Gate-source voltage, V\n",
+ "I_D=6.25; #Drain current mA\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "R_S=abs(V_GS/(I_D/1000)); #Required source resistor, \u03a9 (OHM's LAW)\n",
+ "\n",
+ "#Result\n",
+ "print(\"The required source resistor=%d \u03a9.\"%R_S);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required source resistor=800 \u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 58
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.15 : Page number : 521\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_DSS=25.0; #Shorted gate drain current, mA\n",
+ "V_GS_off=15.0; #Gate-source cut-off voltage, V\n",
+ "V_GS=5.0; #Gate-source voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "I_D=I_DSS*(1-(V_GS/V_GS_off))**2; #Drain current mA\n",
+ "R_S=V_GS/(I_D/1000); #Required source resistor, \u03a9 (OHM's LAW)\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The source resistance=%.0f\u03a9.\"%R_S);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The source resistance=450\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 59
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.16 : Page number 522\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_DSS=15.0; #Shorted gate drain current, mA\n",
+ "V_GS_off=-8.0; #Gate-source cut-off voltage, V\n",
+ "V_DD=12.0; #Drain supply voltage,V\n",
+ "V_D=V_DD/2; #Drain voltage(half of V_DD), V\n",
+ "\n",
+ "#Calculation\n",
+ "I_D=I_DSS/2; #Drain current(approximately half of I_DSS), mA\n",
+ "V_GS=V_GS_off/3.4; #Gate-source voltage, V\n",
+ "R_S=abs(V_GS/(I_D/1000)); #Source resistor, \u03a9 (OHM's LAW)\n",
+ "#Since,V_D=V_DD-I_D*R_D; \n",
+ "R_D=(V_DD-V_D)/(I_D/1000); #Drain resistor, \u03a9 (OHM's LAW)\n",
+ "\n",
+ "#Result\n",
+ "print(\" RS=%d \u03a9 and RD=%d \u03a9.\"%(R_S,R_D));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " RS=313 \u03a9 and RD=800 \u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 60
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.17 : Page number 522\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "I_DSS=5.0; #Shorted gate drain current, mA\n",
+ "V_GS_off=-2.0; #Gate-source cut-off voltage, V\n",
+ "V_DS=10.0; #Drain-source voltage,V\n",
+ "I_D=1.5; #Drain current, mA\n",
+ "V_DD=20.0; #Drain supply voltage,V\n",
+ "V_G=0; #Gate voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Drain current, I_D=I_DSS*(1-(V_GS/V_GS_off))**2; \n",
+ "V_GS=V_GS_off*(1-sqrt(I_D/I_DSS)); #Gate-source voltage, V\n",
+ "\n",
+ "#Since, V_GS=V_G-V_S,\n",
+ "V_S=V_G-V_GS; #Source voltage, V\n",
+ "\n",
+ "R_S=V_S/I_D; #Source resistor, k\u03a9\n",
+ "\n",
+ "#Since, V_DD=I_D*R_D +V_DS+ I_D*R_S,\n",
+ "R_D=(V_DD-I_D*R_S-V_DS)/I_D; #Drain resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "print(\"The source resistance=%.1f k\u03a9\"%R_S);\n",
+ "print(\"The drain resistance=%d k\u03a9.\"%R_D);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The source resistance=0.6 k\u03a9\n",
+ "The drain resistance=6 k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 61
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.18 : Page number 522-523\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_DD=30.0; #Drain supply voltage, V\n",
+ "R_D=5.0; #Drain resistor, k\u03a9\n",
+ "I_D=2.5; #Drain current, mA\n",
+ "R_S=200.0; #Source resistor, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "V_DS=V_DD-I_D*(R_D+(R_S/1000)); #Drain-source voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "V_GS=-(I_D/1000)*R_S; #Gate-source voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The drain-source voltage=%dV.\"%V_DS);\n",
+ "print(\"The gate-source voltage=%.1fV.\"%V_GS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The drain-source voltage=17V.\n",
+ "The gate-source voltage=-0.5V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 62
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.19 : Page number 523"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "ID_1=2.15; #First stage drain current, mA\n",
+ "ID_2=9.15; #Second stage drain current, mA\n",
+ "VDD=30; #Drain supply voltage, V\n",
+ "RS_1=0.68; #Source resistance of 1st stage, k\u03a9\n",
+ "RS_2=0.22; #Source resistance of 2nd stage, k\u03a9\n",
+ "RD_1=8.2; #Drain resistor of 1st stage, k\u03a9\n",
+ "RD_2=2; #Drain resistor of 2nd stage, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "V_RD1=ID_1*RD_1; #Voltage drop across 8.2k\u03a9\n",
+ "VD_1=VDD-V_RD1; #Drain voltage of 1st stage, V\n",
+ "VS_1=ID_1*RS_1; #D.C potential of source of first stage, V\n",
+ "V_RD2=ID_2*RD_2; #Voltage drop across 2k\u03a9\n",
+ "VD_2=VDD-V_RD2; #Drain voltage of 2nd stage, V\n",
+ "VS_2=ID_2*RS_2; #D.C potential of source of 2nd stage, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"drain voltage of 1st stage=%.2fV.\"%VD_1);\n",
+ "print(\"Source voltage of 1st stage=%.2fV.\"%VS_1);\n",
+ "print(\"drain voltage of 2nd stage=%.1fV.\"%VD_2);\n",
+ "print(\"Source voltage of 2nd stage=%.2fV.\"%VS_2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "drain voltage of 1st stage=12.37V.\n",
+ "Source voltage of 1st stage=1.46V.\n",
+ "drain voltage of 2nd stage=11.7V.\n",
+ "Source voltage of 2nd stage=2.01V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 63
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.20 : Page number 524"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=12; #Drain supply voltage, V\n",
+ "VD=7; #Drain voltage, V\n",
+ "R1=6.8; #Resistor R1, M\u03a9\n",
+ "R2=1; #Resistor R2, M\u03a9\n",
+ "RS=1.8; #Source resistance, k\u03a9\n",
+ "RD=3.3; #Drain resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "ID=(VDD-VD)/RD; #Second stage drain current, mA\n",
+ "VS=ID*RS; #Source voltage, V\n",
+ "VG=VDD*R2/(R1+R2); #Drain voltage, V\n",
+ "VGS=VG-VS; #Drain-source voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "print(\"Drain current=%.2fmA.\"%ID);\n",
+ "print(\"Gate-source voltage=%.1fV.\"%VGS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Drain current=1.52mA.\n",
+ "Gate-source voltage=-1.2V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 65
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.21 : Page number 524-525"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "VDD=30; #Drain supply voltage, V\n",
+ "ID=2.5; #Drain current, mA\n",
+ "VDS=8; #Drain-source voltage, V\n",
+ "VGS_off=-5; #Gate-source cutoff voltage, V\n",
+ "R1=1; #Resistor R1, M\u03a9\n",
+ "R2=500; #Resistor R2, k\u03a9\n",
+ "IDSS=10; #Shorted gate drain current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "#ID=IDSS*square_of(1-(VGS/VGS_off))\n",
+ "VGS=VGS_off*(1-sqrt(ID/IDSS)); #Gate-source voltage, V\n",
+ "V2=VDD*R2/(R1*1000+R2); #Voltage across R2, V\n",
+ "\n",
+ "\n",
+ "#V2=VGS+ID*RS\n",
+ "RS=(V2-VGS)/ID; #Source resistor, k\u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"Source resistor, RS=%dk\u03a9.\"%RS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Source resistor, RS=5k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 66
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "\n",
+ "Example 19.22 : Page number 528-529\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=20.0; #Drain supply voltage, V\n",
+ "RS=50.0; #Source resistor, \u03a9\n",
+ "RD=150.0; #Drain resistor, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "VDS_max=VDD; #Maximum drain source voltage, V\n",
+ "ID_max=(VDD/(RD+RS))*1000; #Maximum drain current, mA\n",
+ "\n",
+ "\n",
+ "#plot\n",
+ "x=[i for i in range(0,(int)(VDS_max+1))]; #Plot variable for V_DS\n",
+ "y=[(i/(RD+RS))*1000 for i in reversed(x[:])]; #Plot variable for ID\n",
+ "p=plot(x,y);\n",
+ "xlabel(\"VDS(V)\");\n",
+ "ylabel(\"ID(mA)\");\n",
+ "title(\"d.c load line\");\n",
+ "show(p);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYcAAAEZCAYAAAB8culNAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAHtRJREFUeJzt3Xl0VOXBx/HfAEEBQcKSCSFAFEghBEMo+ys4gBMVIU2J\nbNa8MbK0Wn2l2CrSo6b1CGOLUmLRnhaBqDUsghAVcUETFEU8EoHD0sgSCJCkhRANIFuc9480Y0IW\nsszMnTvz/ZyTY5j1yZwxT773ufeOxel0OgUAQCXNjB4AAMD3MDkAAKphcgAAVMPkAACohskBAFAN\nkwMAoBomB/iVe++9V0888USTHiMvL0/NmjXTDz/84KZR/chms+nll1+u8brU1FQlJSVJko4ePaq2\nbduKPc1hlBZGDwBwJ4vFIovFYvQwalXX+Cpf3r17d5WWlnprWEA1lAP8jln/2jbruOGfmBxgajk5\nORo4cKDatWunqVOn6vz587Xe9ocfftD8+fPVq1cvtWvXToMGDdKxY8eu+hwnTpxQfHy8OnbsqN69\ne2vp0qWu67Zv367hw4crODhYYWFheuihh3Tp0iXX9R988IH69Omj9u3b66GHHpLT6azXJHDlpi2b\nzaYnn3xSN998s9q1a6fbbrtNp06dct1+27ZtGjFihIKDgzVgwABlZ2df9TmAujA5wLQuXryohIQE\nJScn6/Tp05o0aZLWrl1b62ab5557TitXrtS7776r7777TsuXL1fr1q2v+jxTp05V9+7dVVBQoDfe\neEPz5s3Txx9/LElq0aKFFi9erFOnTunzzz/X5s2b9eKLL0qSTp48qcTERM2fP1+nTp1Sz549tXXr\n1kZv9srIyNCKFSv073//WxcvXtTChQslScePH9f48eP15JNP6vTp01q4cKESExN18uTJRj0PIDE5\nwMS2bdumy5cv6+GHH1bz5s2VmJiowYMH13r7l19+Wc8884x69+4tSerfv786dOhQ53Pk5+frs88+\n07PPPquWLVsqJiZGM2bM0CuvvCJJGjhwoIYMGaJmzZqpR48emjVrluuv9o0bNyo6OloTJ05U8+bN\nNXv2bIWGhjbqZ7VYLEpJSVGvXr107bXXavLkyfr6668lSa+99prGjRun22+/XZJ06623atCgQdq4\ncWOjnguQmBxgYidOnFDXrl2rXNajR49aN9vk5+erZ8+eDX6ODh06qE2bNq7LunfvruPHj0uScnNz\nNX78eHXp0kXXX3+9fv/737s295w4cULh4eFVHq9bt24Nev7KKk8srVq10pkzZyRJR44c0Zo1axQc\nHOz62rp1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QEMxOQCSOnTooCFDhmjjxo2SpJUrV2rKlCk1ntY4NjZW+/fvlyT9+te/1vTp0zVmzBjN\nnz/fdcK4w4cPKzg4WEFBQZKkuLg47dixQ6dPn3Y9/rRp01yPOWjQIE6bDp/C5AD8V+W/7letWqVp\n06bV+GlklS+Li4vToUOHNHPmTO3fv1+xsbE6efKkCgoK1LlzZ9ftWrZsqfj4eK1Zs0YnT57U119/\nrdtuu811fefOnXXixAkP/nRAwzA5AP8VHx+vzZs3KycnR+fOnVNsbGyNt8vJyVFUVJTr38HBwZo2\nbZpeeeUVDR48WFu2bFHr1q11/vz5KvermHzWrl2rhIQENW/e3HXd+fPn1apVK8/8YEAjMDkA/3Xd\ndddp9OjRSklJ0d13313jbfLy8vS73/1ODz30kCTp448/1rlz5yRJpaWlOnjwoHr06KHevXsrLy+v\nyn1tNptyc3O1ZMmSKpuUJCk3N5fPLIBPYXIAKpk2bZp2795d5Zf3wYMHXbuyTpkyRQ8//LDrg9q/\n+uorDR48WDExMRoxYoRmzpypn/70p2rTpo169uypgwcPuh7HYrFo0qRJKi4u1i233FLlebOysqrs\nBgsYjc9zADxk/fr1+uqrr/T000/XebuioiL94he/0IcffuilkQFX18LoAQD+KiEhQadOnbrq7fLz\n8/X88897YURA/VEOAIBqWHMAAFTD5AAAqIbJAQBQDZMDAKAaJgcAQDX/D6nl1pVwH0dBAAAAAElF\nTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7fafb8158f50>"
+ ]
+ }
+ ],
+ "prompt_number": 68
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.23 : Page number 529"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=20; #Drain supply voltage, V\n",
+ "RD=500.0; #Drain resistor, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "VDS_max=VDD; #Maximum drain source voltage, v \n",
+ "ID_max=(VDD/RD)*1000; #Maximum drain current, mA\n",
+ "\n",
+ "#Plot\n",
+ "x=[i for i in range(0,(int)(VDS_max+1))]; #Plot variable for V_DS\n",
+ "y=[(i/RD)*1000 for i in reversed(x[:])]; #Plot variable for ID\n",
+ "p=plot(x,y);\n",
+ "xlabel(\"VDS(V)\");\n",
+ "ylabel(\"ID(mA)\");\n",
+ "title(\"d.c load line\");\n",
+ "show(p);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYEAAAEZCAYAAABxbJkKAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3X1UVHX+B/D3RdEkMVFxgNBgfUgQZAYJzaM5PoAPCaGc\nREoixKx2t3JxJbeVxDyxeLaHRbfd05YpqWG0KlkZm7mNlT3YUUiyPKzmKOGAi0BJSDzd3x/8mAUF\nZIa5c++d+36d4znMDMN8mDPOm/f93jtXEEVRBBERaZKb3AMQEZF8GAJERBrGECAi0jCGABGRhjEE\niIg0jCFARKRhDAFSpQcffBAZGRl9+hlmsxlubm5obW110FT/YzQasW3bti5vy8zMRFJSEgDgwoUL\n8PT0BPfUJrn0l3sAInsIggBBEOQeo1s9zdfx+tGjR+PKlSvOGovoOmwCpFpq/etZrXOTa2IIkCoU\nFRUhPDwcQ4YMwbJly9DQ0NDt97a2tiIrKwtjx47FkCFDEBERgR9++OGGj3Hx4kXExsZi+PDhGDdu\nHF599VXrbceOHcOdd94JLy8v+Pn54bHHHkNTU5P19kOHDmHChAkYOnQoHnvsMYii2Ks3+2s3SRmN\nRjz99NOYPn06hgwZgnnz5uHy5cvW7//iiy8wbdo0eHl5Qa/X48iRIzd8DKKeMARI8RobGxEXF4fk\n5GTU1NTg3nvvxd69e7vd3PL8889jz549eP/99/HTTz9h+/bt8PDwuOHjLFu2DKNHj4bFYsE///lP\nPPXUU/joo48AAP3790dOTg4uX76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<matplotlib.figure.Figure at 0x7fafb804f310>"
+ ]
+ }
+ ],
+ "prompt_number": 71
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.24 : Page number 530-531"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=20; #Drain supply voltage, V\n",
+ "RD=12.0; #Drain resistor, k\u03a9\n",
+ "RL=8.0; #Load resistor, k\u03a9\n",
+ "RG=1.0; #Gate resistor, M\u03a9\n",
+ "gm=1.0; #transconductance, mA/V\n",
+ "\n",
+ "#Calculation\n",
+ "gm=gm*10**-3; #transconductance, mho\n",
+ "RAC=(RD*RL)/(RD+RL); #Total a.c load, k\u03a9\n",
+ "Av=gm*RAC*1000; #Voltage gain\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Voltage gain=%.1f.\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage gain=4.8.\n"
+ ]
+ }
+ ],
+ "prompt_number": 73
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.25 : Page number 531"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "gm=3000; #transconductance, \u03bcmho\n",
+ "RD=10; #Drain resistance, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Av=gm*10**-6*RD*1000; #Voltage gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"Voltage gain=%d.\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage gain=30.\n"
+ ]
+ }
+ ],
+ "prompt_number": 74
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.26 : Page number 531"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "IDSS=8; #Shorted gate drain current, mA\n",
+ "VGS_off=-10; #Gate-source cut-off voltage, V\n",
+ "ID=1.9; #Drain current, mA\n",
+ "RD=3.3; #Drain resistance, k\u03a9\n",
+ "RS=2.7; #Source resistor, k\u03a9\n",
+ "vin=100; #Input voltage, mV\n",
+ "\n",
+ "#Calculation\n",
+ "VGS=-ID*RS; #Gate-source voltage, V\n",
+ "gmo=2*IDSS*10**-3/abs(VGS_off); #Maximum transconductance, S\n",
+ "gm=gmo*(1-(VGS/VGS_off)); #Transconductance, S\n",
+ "Av=gm*RD*1000; #Voltage gain\n",
+ "vout=Av*vin; #Output voltage, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%dmV(r.m.s).\"%vout);\n",
+ " \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=257mV(r.m.s).\n"
+ ]
+ }
+ ],
+ "prompt_number": 76
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.27 : Page number 531-532"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RL=4.7; #Load resistor, \u03a9\n",
+ "RD=3.3; #Drain resistance, k\u03a9\n",
+ "gm=779*10**-6; #Transconductance, S\n",
+ "vin=100; #Input voltage, mV\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "RAC=RD*RL/(RD+RL); #Total a.c drain resistance, k\u03a9\n",
+ "Av=gm*RAC*1000; #Voltage gain\n",
+ "vout=Av*vin; #Output voltage, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%dmV(r.m.s).\"%vout);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=151mV(r.m.s).\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.28 : Page number 532-533"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RD=1.5; #Drain resistance, k\u03a9\n",
+ "gm=4; #Transconductance, mS\n",
+ "RS=560; #Source resistance, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Av=gm*10**-3*RD*1000/(1+gm*10**-3*RS);\n",
+ "print(\"Voltage gain=%.2f.\"%Av);\n",
+ "\n",
+ "#If RS is bypassed by a capacitor\n",
+ "Av=gm*10**-3*RD*1000;\n",
+ "print(\"Voltage gain, if RS resistor is bypassed=%d.\"%Av);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage gain=1.85.\n",
+ "Voltage gain, if RS resistor is bypassed=6.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.29 : Page number 533"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "from math import sqrt\n",
+ "\n",
+ "IDSS=10; #Shorted gate drain current, mA\n",
+ "VGS_off=-3.5; #Gate-source cut-off voltage, V\n",
+ "RD=1.5; #Drain resistance, k\u03a9\n",
+ "RS=750; #Source resistance, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#From d.c biasing\n",
+ "ID=2.3; #Drain current, mA\n",
+ "VGS=round(VGS_off*(1-sqrt(ID/IDSS)),1); #Gate-source voltage, V\n",
+ "gm=round(round((2*IDSS/abs(VGS_off)),1)*round((1-(VGS/VGS_off)),3),2); #Transconductance, mS\n",
+ "\n",
+ "\n",
+ "#(i)\n",
+ "Av=gm*RD; #Voltage gain with RS resistor bypassed\n",
+ "print(\"(i) Voltage gain with RS bypassed=%.3f.\"%Av);\n",
+ "\n",
+ "#(ii)\n",
+ "Av=Av/(1+gm*(RS/1000.0));\n",
+ "print(\"(ii) Voltage gain with RS unbypassed=%.2f.\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Voltage gain with RS bypassed=4.155.\n",
+ "(ii) Voltage gain with RS unbypassed=1.35.\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.30 : Page number 539-540"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "IDSS=10.0; #Shorted gate drain current, mA\n",
+ "VGS_off=-8.0; #Gate-source cut-off voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "if(VGS_off<0):\n",
+ " print(\"(i) n-channel D-MOSFET\");\n",
+ "else:\n",
+ " print(\"(i) p-channel D-MOSFET\");\n",
+ " \n",
+ "\n",
+ "#(ii)\n",
+ "VGS=-3.0; #Gate-source voltage, V\n",
+ "ID=IDSS*(1-(VGS/VGS_off))**2; #Drain current mA\n",
+ "print(\"(ii) Drain current=%.2fmA\"%ID);\n",
+ "\n",
+ "#(iii)\n",
+ "VGS=3.0; #Gate-source voltage, V\n",
+ "ID=IDSS*(1-(VGS/VGS_off))**2; #Drain current mA\n",
+ "print(\"(iii) Drain current=%.1fmA\"%ID);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) n-channel D-MOSFET\n",
+ "(ii) Drain current=3.91mA\n",
+ "(iii) Drain current=18.9mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.31 : Page number 540\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "IDSS=1.0; #Shorted gate drain current, mA\n",
+ "VGS_off=-6.0; #Gate-source cut-off voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Point 1\n",
+ "VGS=0; #Gate source voltage, V \n",
+ "ID=IDSS; #Drain current, mA\n",
+ "print(\"Point 1: VGS=%dV and ID=%dmA.\"%(VGS,ID));\n",
+ "\n",
+ "#Point 2\n",
+ "VGS=VGS_off; #Gate source voltage, V \n",
+ "ID=0; #Drain current, mA\n",
+ "print(\"Point 2: VGS=%dV and ID=%dmA.\"%(VGS,ID));\n",
+ "\n",
+ "#locating more points by changing VG values\n",
+ "VGS=-3; #Gate source voltage, V \n",
+ "ID=IDSS*(1-(VGS/VGS_off))**2; #Drain current mA\n",
+ "print(\"Point 3: VGS=%dV and ID=%.2fmA.\"%(VGS,ID));\n",
+ "\n",
+ "VGS=-1; #Gate source voltage, V \n",
+ "ID=IDSS*(1-(VGS/VGS_off))**2; #Drain current mA\n",
+ "print(\"Point 4: VGS=%dV and ID=%.3fmA.\"%(VGS,ID));\n",
+ "\n",
+ "VGS=1; #Gate source voltage, V \n",
+ "ID=IDSS*(1-(VGS/VGS_off))**2; #Drain current mA\n",
+ "print(\"Point 5: VGS=%dV and ID=%.2fmA.\"%(VGS,ID));\n",
+ "\n",
+ "VGS=3; #Gate source voltage, V \n",
+ "ID=IDSS*(1-(VGS/VGS_off))**2; #Drain current mA\n",
+ "print(\"Point 6: VGS=%dV and ID=%.2fmA.\"%(VGS,ID));"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Point 1: VGS=0V and ID=1mA.\n",
+ "Point 2: VGS=-6V and ID=0mA.\n",
+ "Point 3: VGS=-3V and ID=0.25mA.\n",
+ "Point 4: VGS=-1V and ID=0.694mA.\n",
+ "Point 5: VGS=1V and ID=1.36mA.\n",
+ "Point 6: VGS=3V and ID=2.25mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.32 : Page number 541"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=18; #Drain supply voltage, V\n",
+ "RD=620.0; #Drain resistor, \u03a9\n",
+ "IDSS=12.0; #Shorted gate drain current, mA\n",
+ "VGS_off=-8.0; #Gate-source cut-off voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "ID=IDSS; #Drain current, mA\n",
+ "VDS=VDD-IDSS*(RD/1000); #Drain source voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Drain source voltage=%.1fV.\"%VDS);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Drain source voltage=10.6V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.33 : Page number 542"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=15; #Drain supply voltage\n",
+ "RD=620.0; #Drain resistor, \u03a9\n",
+ "RL=8.2; #Load resistor, k\u03a9\n",
+ "vin=500.0; #Input voltage, V\n",
+ "IDSS=12.0; #Shorted gate drain current, mA\n",
+ "gm=3.2; #Transconductance, mS\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "VDS=VDD-IDSS*(RD/1000.0); #Drain source voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "RAC=RD*RL*1000/(RD+RL*1000); #Total a.c drain resistace, \u03a9\n",
+ "vout=(gm/1000.0)*RAC*vin; #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Drain source voltage=%.2fV.\"%VDS);\n",
+ "print(\"(ii) Output voltage=%dmV\"%vout);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Drain source voltage=7.56V.\n",
+ "(ii) Output voltage=922mV\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.34 : Page number 545"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "ID_on=500.0; #Drain current for MOSFET ON, mA\n",
+ "VGS_on=10.0; #Gate-source voltage for MOSFET ON, V\n",
+ "VGS_th=1.0; #Threshold value of gate-source voltage, V\n",
+ "VGS=5; #Gate-source voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "K=round(ID_on/(VGS_on-VGS_th)**2,2); #Constant for a E-MOSFET, mA/V\u00b2\n",
+ "ID=K*(VGS-VGS_th)**2; #Drain current, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Drain current=%.1fmA\"%ID);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Drain current=98.7mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.35 : Page number 545"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "ID_on=3.0; #Drain current for MOSFET ON, mA\n",
+ "VGS_on=10.0; #Gate-source voltage for MOSFET ON, V\n",
+ "VGS_th=3.0; #Threshold value of gate-source voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "K=round((ID_on/(VGS_on-VGS_th)**2),3); #Constant for a E-MOSFET, mA/V\u00b2\n",
+ "print(\"K=%.3fe-03A/V\u00b2.\"%K);\n",
+ "\n",
+ "#Determining different points for plotting\n",
+ "VGS=5; #Gate-source voltage, V\n",
+ "ID=K*(VGS-VGS_th)**2; #Drain current, mA\n",
+ "print(\"For VGS=5V, Drain current=%.3fmA\"%ID);\n",
+ "VGS=8; #Gate-source voltage, V\n",
+ "ID=K*(VGS-VGS_th)**2; #Drain current, mA\n",
+ "print(\"For VGS=8V, Drain current=%.3fmA\"%ID);\n",
+ "VGS=10; #Gate-source voltage, V\n",
+ "ID=K*(VGS-VGS_th)**2; #Drain current, mA\n",
+ "print(\"For VGS=10V, Drain current=%.dmA\"%ID);\n",
+ "VGS=12; #Gate-source voltage, V\n",
+ "ID=K*(VGS-VGS_th)**2; #Drain current, mA\n",
+ "print(\"For VGS=12V, Drain current=%.2fmA\"%ID);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "K=0.061e-03A/V\u00b2.\n",
+ "For VGS=5V, Drain current=0.244mA\n",
+ "For VGS=8V, Drain current=1.525mA\n",
+ "For VGS=10V, Drain current=2mA\n",
+ "For VGS=12V, Drain current=4.94mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.36 : Page number 546-547"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=24.0; #Drain supply voltage, V\n",
+ "RD=470.0; #Drain resistor, \u03a9\n",
+ "R1=100.0; #Resistor R1, k\u03a9\n",
+ "R2=15.0; #Resistor R2, k\u03a9\n",
+ "ID_on=500.0; #Drain current for MOSFET ON, mA\n",
+ "VGS_on=10.0; #Gate-source voltage for MOSFET ON, V\n",
+ "VGS_th=1.0; #Threshold value of gate-source voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "VGS=VDD*R2/(R1+R2); #Gate-source voltage, V (Voltage divider rule)\n",
+ "K=round((ID_on/(VGS_on-VGS_th)**2),2); #Constant for a E-MOSFET, mA/V\u00b2\n",
+ "ID=K*(VGS-VGS_th)**2; #Drain current, mA\n",
+ "VDS=VDD-(ID/1000)*RD; #Drain-source voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Drain-source voltage=%.1fV.\"%VDS);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Drain-source voltage=10.8V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.37 : Page number 547"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=20.0; #Drain supply voltage, V\n",
+ "RD=1.0; #Drain resistor, k\u03a9\n",
+ "RG=5.0; #Gate resistor , M\u03a9\n",
+ "ID_on=10.0; #Drain current for MOSFET ON, mA\n",
+ "\n",
+ "#Calculation\n",
+ "#since, VGS=VDS\n",
+ "ID=ID_on; #Drain current, mA\n",
+ "VDS=VDD-ID*RD; #Drain-source voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Drain current=%dmA.\"%ID);\n",
+ "print(\"Drain-source voltage=%dV.\"%VDS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Drain current=10mA.\n",
+ "Drain-source voltage=10V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 19.38 : Page number 547-548"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VDD=10.0; #Drain supply voltage, V\n",
+ "RD=3.0; #Drain resistor, k\u03a9\n",
+ "R1=1.0; #Resistor R1, M\u03a9\n",
+ "R2=1.0; #Resistor R2, M\u03a9\n",
+ "ID_on=10.0; #Drain current for MOSFET ON, mA\n",
+ "VGS_on=10.0; #Gate-source voltage for MOSFET ON, V\n",
+ "VGS_th=1.5; #Threshold value of gate-source voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "K=round((ID_on/(VGS_on-VGS_th)**2),3); #Constant for a E-MOSFET, mA/V\u00b2\n",
+ "VGS=VDD*R2/(R1+R2); #Gate-source voltage, V (Voltage divider rule)\n",
+ "ID=K*(VGS-VGS_th)**2; #Drain current, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Drain current=%.2fmA.\"%ID);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Drain current=1.69mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter1_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter1_1.ipynb
new file mode 100644
index 00000000..49519941
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter1_1.ipynb
@@ -0,0 +1,646 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:0ac98582dd0b2497034e459e869a2a3bd28001d0d4c4b37a61a8ed5d05f228e3"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 1: INTRODUCTION"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "EXAMPLE 1.1: Page Number 8"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "Eg=24.0; #Generated voltage in V\n",
+ "Ri=0.01; #Internal Resistance in \u03a9\n",
+ "P=100; #Power supplied in watts\n",
+ "\n",
+ "#Calculations\n",
+ "# (i)\n",
+ "I=P/Eg; #Load current in A\n",
+ "V_Ri=I*Ri; #Voltage drop in internal resistance\n",
+ "\n",
+ "# (ii)\n",
+ "V=Eg-(I*Ri); #Terminal Voltage\n",
+ "\n",
+ "#Results\n",
+ "print (\"The voltage drop in internal resistance is %.4f V\"%V_Ri);\n",
+ "print (\"The terminal voltage is %.2f V\"%V);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage drop in internal resistance is 0.0417 V\n",
+ "The terminal voltage is 23.96 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "EXAMPLE 1.2: Page number 10"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Eg=500.0; #Generated voltage in V\n",
+ "Ri=1000.0; #Internal Resistance in \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "# (i)\n",
+ "RL=10; #Load resistance of case 1 in \u03a9 \n",
+ "I= Eg/(RL+Ri); #Load current in A\n",
+ "\n",
+ "print(\"The load current for RL=10\u03a9 is %.3f A\"%I);\n",
+ "\n",
+ "# (ii)\n",
+ "RL=50; #Load resistance of case 2 in \u03a9 \n",
+ "I= Eg/(RL+Ri); #Load current in A\n",
+ "\n",
+ "print(\"The load current for RL=50\u03a9 is %.3f A\"%I);\n",
+ "\n",
+ "# (iii)\n",
+ "RL=100; #Load resistance of case 3 in \u03a9 \n",
+ "I= Eg/(RL+Ri); #Load current in A\n",
+ "I=round(I,3);\n",
+ "\n",
+ "print(\"The load current for RL=100\u03a9 is %.3f A\"%I);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The load current for RL=10\u03a9 is 0.495 A\n",
+ "The load current for RL=50\u03a9 is 0.476 A\n",
+ "The load current for RL=100\u03a9 is 0.455 A\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.3: Page Number 11"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "E=10.0; #voltage of voltage source in V\n",
+ "Ri=10.0; #Internal Resistance of the voltage source in \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Isc=E/Ri; #short circuit current in A\n",
+ "I=Isc; #Current value of current source in A\n",
+ "R=Ri; #Internal Resistence of the current source in \u03a9\n",
+ "\n",
+ "#Results\n",
+ "print(\"The current value of the current source= %d A\"%Isc);\n",
+ "print(\"The internal resistance of the current source =%d \u03a9 \"%R);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The current value of the current source= 1 A\n",
+ "The internal resistance of the current source =10 \u03a9 \n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "EXAMPLE 1.4: Page number 11-12"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I=6.0; # current value of current source in mA\n",
+ "Ri=2000.0; #Internal Resistance of the current source in \u03a9\n",
+ "\n",
+ "#Calcultion\n",
+ "V=(I/1000)*Ri; #Voltage of voltage source in V\n",
+ "R=Ri; #Internal resistance of voltage source in \u03a9\n",
+ "\n",
+ "#Results\n",
+ "print(\"The voltage of voltage source is %d V\"%V);\n",
+ "print(\"The internal resistance of the voltage source is %d \u03a9\"%R);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage of voltage source is 12 V\n",
+ "The internal resistance of the voltage source is 2000 \u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.5: Page number 13\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#variable declaration\n",
+ "E=200.0; #Generated voltage in V\n",
+ "Ri=100.0; #Internal Resistance of generator in \u03a9\n",
+ "\n",
+ "#Calculations\n",
+ "#(i)\n",
+ "RL=100; #Load resistance for 1st case in \u03a9\n",
+ "I=E/(RL+Ri); #Load current in 1st case A\n",
+ "P=(I*I)*RL; #Power delivered to load of 2nd case in watts\n",
+ "Pt=(I*I)*(Ri+RL); #Total power generated in watts\n",
+ "\n",
+ "print(\"Power delivered for RL=100\u03a9 is %d watts\"%P);\n",
+ "print(\"Total power generated for RL=100\u03a9 is %d watts\"%Pt);\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "RL=300; #Load resistance for 2nd case in \u03a9\n",
+ "I=E/(RL+Ri); #Load current in 2nd case in A\n",
+ "P=(I*I)*RL; #Power delivered to load of 2nd case in watts\n",
+ "Pt=(I*I)*(Ri+RL); #Total power generated in watts\n",
+ "\n",
+ "print(\"Power delivered for RL=300\u03a9 is %d watts\"%P);\n",
+ "print(\"Total power generated for RL=300\u03a9 is %d watts\"%Pt);\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Power delivered for RL=100\u03a9 is 100 watts\n",
+ "Total power generated for RL=100\u03a9 is 200 watts\n",
+ "Power delivered for RL=300\u03a9 is 75 watts\n",
+ "Total power generated for RL=300\u03a9 is 100 watts\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.6: Page number 14"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V=12.0; #Output from amplifier in V\n",
+ "R_out_eq=15; #Equivalent resistance in \u03a9\n",
+ "\n",
+ "#Calculations\n",
+ "RL=R_out_eq; #Load resistance in \u03a9\n",
+ "Rt=RL+R_out_eq; #Total resistance in \u03a9\n",
+ "I=V/Rt; #Circuit current in A\n",
+ "PL=pow(I,2)*RL; #Power delivered to load in W\n",
+ "\n",
+ "#Results\n",
+ "print(\"Load resistance required is = %d \u03a9\"%RL);\n",
+ "print(\"Power delivered to load = %.1f W\"%PL);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Load resistance required is = 15 \u03a9\n",
+ "Power delivered to load = 2.4 W\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.7, Page number 14"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V=50.0; #voltage from ac generator in V\n",
+ "R=100.0; #Resistance of internal impedance in \u03a9\n",
+ "XL=50.0; #inductive reactance of internal impedance in \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Zi=100+(50j); #Internal impedance in complex form (\u03a9)\n",
+ "ZL=conjugate(Zi); #Load impedance (conjugate of internal impedance ) in \u03a9\n",
+ "Zt=Zi+ZL; #Total impedance in \u03a9\n",
+ "I=real(V/Zt); #Circuit current in A\n",
+ "\n",
+ "Max_Power=pow(I,2)*R; #Maximum power transferred to the load in watts\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print (\"Load impedance %d %dj \u03a9\"%(real(ZL),imag(ZL)));\n",
+ "print(\"Maximum power transferred to the load =%.2f W\"%Max_Power);\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Load impedance 100 -50j \u03a9\n",
+ "Maximum power transferred to the load =6.25 W\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.8: Page number 16"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Function for calculating parallel resistance\n",
+ "def pR(R1,R2):\n",
+ " return((R1*R2)/(R1+R2));\n",
+ "\n",
+ "\n",
+ "#Variable declaration\n",
+ "E=100.0; #Source voltage in V\n",
+ "R1=10.0; #Resistance of resistor 1 in \u03a9\n",
+ "R2=20.0; #Resistance of resistor 2 in \u03a9\n",
+ "R3=12.0; #Resistance of resistor 3 in \u03a9\n",
+ "R4=8.0; #Resistance of resistor 4 in \u03a9\n",
+ "RL=100.0; #Resistance of load in \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Req=R1+pR(R3+R4,R2); #Equivalent resistance after removing RL ,in \u03a9\n",
+ "I=E/Req; #Total circuit current in A\n",
+ "I8=I*R2/(R2+R3+R4);\n",
+ "\n",
+ "#Thevenin's equivalent circuit's parameters\n",
+ "E0=I8*R4; #Thevenin voltage V\n",
+ "R0=pR(pR(R1,R2)+R3,R4); #Thevenin resistance \n",
+ "I_RL=E0/(R0+RL); #Load current in A \n",
+ "\n",
+ "#Result \n",
+ "print (\"Current through load = %.2f A.\"%I_RL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Current through load = 0.19 A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.9: Page number 17"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Function for calculating parallel resistance\n",
+ "def pR(R1,R2):\n",
+ " return((R1*R2)/(R1+R2));\n",
+ "\n",
+ "\n",
+ "#Variable declaration\n",
+ "V=20.0; #Voltage source in V\n",
+ "R1=1000.0; #resistance of resistor 1 in \u03a9\n",
+ "R2=1000.0; #resistance of resistor 2 in \u03a9\n",
+ "R3=1000.0; #resistance of resistor 3 in \u03a9\n",
+ "\n",
+ "#calculation\n",
+ "#parameter for Thevenin's equivalent circuit\n",
+ "E0=(V*R3)/(R1+R3); #thevenin voltage in V\n",
+ "R0=pR(R1,R3)+R2; #Thevenins resistance in \u03a9\n",
+ "\n",
+ "#result\n",
+ "print(\"The thevenin voltage = %d V\"%E0);\n",
+ "print(\"The thevenin resistance = %d \u03a9\"%R0);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The thevenin voltage = 10 V\n",
+ "The thevenin resistance = 1500 \u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.10: Page number 18"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V=120.0; #Supply voltage in V\n",
+ "R1=40.0; #Resistor 1's resistance in \u03a9\n",
+ "R2=20.0; #Resistor 2's resistance in \u03a9\n",
+ "R3=60.0; #Resistor 3's resistance in \u03a9\n",
+ "\n",
+ "#Calculations\n",
+ "#Using Thevenin's theorem, Thevenin's voltage and resistance are calculated\n",
+ "E0=(V*R2)/(R1+R2); #Thevenin voltage (voltage across the load resistance RL, after removing RL)in V\n",
+ "R0=(R1*R2)/(R1+R2) + R3; #Thevenin's resistance (Resistance between the terminals of load RL, with RL removed and source voltage shorted)in \u03a9 \n",
+ "RL=R0; #Value of load resistance to be connected for maximum power transfer in \u03a9\n",
+ "Pmax=pow(E0,2)/(4*RL); #Maximum power transferred to load in watts\n",
+ "\n",
+ "#Results\n",
+ "print(\"The value of load resistance RL to which maximum power will be transferred = %.2f \u03a9.\"%RL);\n",
+ "print(\"The maximum power transferred to load =%.2f W.\"%Pmax);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of load resistance RL to which maximum power will be transferred = 73.33 \u03a9.\n",
+ "The maximum power transferred to load =5.45 W.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.11: Page number 18-19-20"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V=80.0; #Supply voltage in V\n",
+ "R1=100.0; #Resistor 1's resistance in \u03a9\n",
+ "R2=100.0; #Resistor 2's resistance in \u03a9\n",
+ "R3=30.0; #Resistor 3's resistance in \u03a9\n",
+ "R4=80.0; #Resistor 4's resistance in \u03a9\n",
+ "R5=20.0; #Resistor 5's resistance in \u03a9\n",
+ "R6=60.0; #Resistor 6's resistance in \u03a9\n",
+ "R7=20.0; #Resistor 7's resistance in \u03a9\n",
+ "R8=50.0; #Resistor 8's resistance in \u03a9\n",
+ "\n",
+ "#Calculations\n",
+ "#Using Thevenin's theorem,\n",
+ "E0=(V*R2)/(R1+R2); #Thevenin's voltage for the circuit containing V, R1, R2 in V.\n",
+ "R0=(R1*R2)/(R1+R2); #Thevenin's resistance for R1, R2 in \u03a9.\n",
+ "\n",
+ "#Using Thevenin's theorem again on E0, R0 and rest of the circuit resistors.\n",
+ "E0_1=(E0*R4)/(R0+R3+R4); #Thevenin's voltage for the cicruit containing E0, R0, R3, R4 in V\n",
+ "R0_1=((R0+R3)*R4)/(R0+R3+R4); #Thevenin's resistance of R0,R3,R4 (R0 and R3 in series and both in parallel with R4), in \u03a9 \n",
+ "\n",
+ "#Using Thevenin's theorem again on E0_1, R0_1, and rest of the circuit resistors.\n",
+ "E0_2=(E0_1*R6)/(R0_1+R5+R6); #Thevenin's voltage for the circuit containing E0_1, R0_1, R5, R6 in V\n",
+ "R0_2=((R0_1+R5)*R6)/(R0_1+R5+R6); #Thevenin's resistance of R0_1,R5,R6 (R0 and R3 in series and both in parallel with R4), in \u03a9\n",
+ "\n",
+ "\n",
+ "I_50=E0_2/(R0_2+R7+R8); #Current through the 50 \u03a9 resistor in A\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The current through the 50 \u03a9 resistor =%.1f A.\"%I_50);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The current through the 50 \u03a9 resistor =0.1 A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.12: Page number 22\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from math import floor\n",
+ "#Variable declaration\n",
+ "V=40.0; #Voltage supply in V\n",
+ "R1=4.0; #Resistor 1's resistance in \u03a9\n",
+ "R2=6.0; #Resistor 2's resistance in \u03a9\n",
+ "R3=5.0; #Resistor 3's resistance in \u03a9\n",
+ "R4=8.0; #Resistor 4's resistance in \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Using Norton's theorem,\n",
+ "#calculating Norton current by removing the load resistance R4 and short circuiting those two terminals of the circuit\n",
+ "R=R1 + (R2*R3)/(R2+R3); #Load on source after removing R4 resistor, in \u03a9\n",
+ "I=V/R; #Source current in A\n",
+ "\n",
+ "#Using current dividing rule ,calculating the short circuit current.\n",
+ "I_N=(I*R2)/(R2+R3); #Norton's equivalent current or the short circuit current in A\n",
+ "\n",
+ "R_N=R3 + (R1*R2)/(R1+R2); #Norton's equivalent resistance in \u03a9\n",
+ "\n",
+ "I_8=(I_N*R_N)/(R_N+R4); #Current through the 8 \u03a9 resistance in A\n",
+ "\n",
+ " \n",
+ "\n",
+ "#Results\n",
+ "print(\"The current through the 8\u03a9 resistance =%.2f A.\"%I_8);\n",
+ "\n",
+ "#Note: The answer in the book is 1.55 A, but in the above code the approximate value is obtained, i.e not 1.55A but 1.56A\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The current through the 8\u03a9 resistance =1.56 A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.13 :Page number 23\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V1=30.0; #Voltage source 1, V\n",
+ "V2=18.0; #Voltage source 2, V\n",
+ "R1=20.0; #1st resistor, \u03a9\n",
+ "R2=10.0; #2nd resistor, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#Finding Thevenin's Equivalent circuit\n",
+ "I=(V1-V2)/(R1+R2); #Current in the circuit, A\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law to 1st loop of the circuit,\n",
+ "#V1-I*R1-E0=0, where E0 is the voltage across the points X-Y.\n",
+ "E0=V1-I*R1; #Thevenin's voltage source, V\n",
+ "\n",
+ "R0=R1*R2/(R1+R2); #Thevenin's resistance, \u03a9\n",
+ "\n",
+ "#Finding Norton's equivalent circuit\n",
+ "IN=E0/R0; #Norton's equivalent current source, A\n",
+ "RN=R0; #Norton's equivanlent resistance, \u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"IN=%.1fA and RN=%.2f \u03a9\"%(IN,RN));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "IN=3.3A and RN=6.67 \u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter20_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter20_1.ipynb
new file mode 100644
index 00000000..cad31534
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter20_1.ipynb
@@ -0,0 +1,677 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:369e36634d005b832372dcae6796c76b979f32b499d8baadce951517f2201533"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 20 : SILICON CONTROLLED RECTIFIERS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.2 : Page number 559\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I=50.0; #Surge current, A\n",
+ "t=12.0; #Time for which surge current lasts, ms\n",
+ "circuit_fusing_rating_max=90; #Maximum circuit fusing rating, A\u00b2s\n",
+ "\n",
+ "#Calculation\n",
+ "circuit_fusing_rating=I**2*(t*10**-3); #Circuit fusing rating, A\u00b2s\n",
+ "\n",
+ "#Result\n",
+ "if(circuit_fusing_rating<circuit_fusing_rating_max):\n",
+ " print(\"The device will not be destroyed.\");\n",
+ "else:\n",
+ " print(\"The device will be destroyed.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The device will not be destroyed.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.3 : Page number 559\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I2_t_rating=50.0; #circuit fuse rating, A\u00b2s\n",
+ "Is=100.0; #Surge current, A\n",
+ "\n",
+ "#Calculation\n",
+ "t_max=(I2_t_rating/Is**2)*1000; #Maximum allowable duration, ms\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum allowable duration =%dms\"%t_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum allowable duration =5ms\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.4 : Page number 559\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "R=220.0; #Gate resistor, \u03a9\n",
+ "I_G=7.0; #Gate current, mA\n",
+ "V_GK=0.7; #Junction voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "V_in=V_GK+(I_G/1000)*R; #Input voltage, V (Kirchhoff's voltage law)\n",
+ "\n",
+ "#Result\n",
+ "print(\"The required input voltage=%.2fV.\"%V_in);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required input voltage=2.24V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.5 : Page number 564\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import asin\n",
+ "from math import cos\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "I_G=1.0; #Gate current, mA\n",
+ "V_m=200.0; #Peak value of input sinusoidal voltage, V\n",
+ "v=100.0; #Forward breakdown voltage of SCR, V\n",
+ "R_L=100.0; #Load resistance, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#v=Vm*sin(theta)\n",
+ "#Finding angle theta, for input voltage (v)= (V_f)forward_breakdown_voltage\n",
+ "theta=asin(v/V_m); #angle for input voltage = forward breakdown voltage, rad\n",
+ "theta=theta*180/pi; #angle for input voltage = forward breakdown voltage, degrees\n",
+ "\n",
+ "alpha=round(theta,0); #Firing angle, degrees\n",
+ "\n",
+ "#(ii)\n",
+ "phi=180-alpha; #Conduction angle, degrees\n",
+ "\n",
+ "#(iii)\n",
+ "V_avg=(V_m/(2*pi))*(1+cos(alpha*pi/180)); #Average voltage, V\n",
+ "I_avg=V_avg/R_L; #Average current, A\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The firing agle=%d\u00b0\"%alpha);\n",
+ "print(\"(ii) The conduction angle=%.0f\u00b0\"%phi);\n",
+ "print(\"(iii) The average current=%.4fA \"%I_avg);\n",
+ "\n",
+ "#Note: In the text book has approximated the average current to 0.5925A but in the code it gets approximated to 0.5940A.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The firing agle=30\u00b0\n",
+ "(ii) The conduction angle=150\u00b0\n",
+ "(iii) The average current=0.5940A \n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.6 : Page number 564\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import asin\n",
+ "from math import cos\n",
+ "from math import pi\n",
+ "from math import floor\n",
+ "\n",
+ "\n",
+ "#Variable declaration\n",
+ "I_G=1.0; #Gate current, mA\n",
+ "V_m=400.0; #Peak value of input sinusoidal voltage, V\n",
+ "v=150.0; #Forward breakdown voltage of SCR, V\n",
+ "R_L=200.0; #Load resistance, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#v=Vm*sin(theta)\n",
+ "#Finding angle theta, for input voltage (v)= (V_f)forward_breakdown_voltage\n",
+ "theta=asin(v/V_m); #angle for input voltage = forward breakdown voltage, rad\n",
+ "theta=theta*180/pi; #angle for input voltage = forward breakdown voltage, degrees\n",
+ "\n",
+ "alpha=theta; #Firing angle, degrees\n",
+ "\n",
+ "#(ii)\n",
+ "V_av=floor((V_m/(2*pi))*(1+cos(alpha*pi/180))*10)/10; #Average voltage, V\n",
+ "\n",
+ "#(iii)\n",
+ "I_av=V_av/R_L; #Average current, A\n",
+ "\n",
+ "#(iv)\n",
+ "P_out=V_av*I_av; #Output power, W\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The firing agle=%d\u00b0\"%alpha);\n",
+ "print(\"(ii) The average output voltage=%.1f V\"%V_av);\n",
+ "print(\"(iii) The average current=%.3fA \"%I_av);\n",
+ "print(\"(iv) The output power=%.2f W\"%P_out);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The firing agle=22\u00b0\n",
+ "(ii) The average output voltage=122.6 V\n",
+ "(iii) The average current=0.613A \n",
+ "(iv) The output power=75.15 W\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.7 : Page number 564-565\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import asin\n",
+ "\n",
+ "#Variable declaration\n",
+ "v=180.0; #Forward breakdown voltage, V\n",
+ "V_m=240.0; #Peak value of input voltage, V\n",
+ "w=314.0; #Angular frequency of input ,rad/s\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#v=Vm*sin(w*t)\n",
+ "#So, t=asin(v/Vm)/w\n",
+ "t=(asin(v/V_m)/w)*1000; #Time for which SCR remains off, ms\n",
+ "\n",
+ "#Result\n",
+ "print(\"The SCR remains off for %.1f ms.\"%t);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The SCR remains off for 2.7 ms.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.8 : Page number 565\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "from math import cos\n",
+ "from math import floor\n",
+ "\n",
+ "#Variable declaration\n",
+ "I_dc=1.0; #d.c load current, A\n",
+ "alpha=30.0; #Firing angle, \u00b0\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "I_av=I_dc; #Average current(= d.c current), A\n",
+ "\n",
+ "#Since, Iav=(Vm/(2*pi*RL))*(1+cos(alpha)) and Im=Vm/RL\n",
+ "I_m=floor((2*pi*I_av/(1+cos(alpha*pi/180)))*100)/100; #Peak-load current, A\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Peak-load current=%.2f A.\"%I_m);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Peak-load current=3.36 A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.9: Page number 565\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "from math import sin\n",
+ "\n",
+ "#Variable declaration\n",
+ "alpha=60.0; #Firing angle, \u00b0\n",
+ "P=100.0; #Power rating of tungsten lamp, W\n",
+ "V=110.0; #Voltage rating of tungsten lamp, V\n",
+ "V_ac=110.0; #a.c supply voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_m=V_ac*sqrt(2); #Peak value of input voltage, V\n",
+ "\n",
+ "alpha=alpha*pi/180; #firing angle, rad\n",
+ "\n",
+ "#Since, E_rms\u00b2=(1/2*pi) \u222b V_m\u00b2sin\u00b2(theta) d(theta), limits: alpha to pi\n",
+ "# E_rms\u00b2=Vm\u00b2*((2*(pi-alpha) + sin(2*alpha))/(8*pi)),\n",
+ "# E_rms=Vm*sqrt((2*(pi-alpha) + sin(2*alpha))/(8*pi)),\n",
+ "E_rms=round(V_m*sqrt((2*(pi-alpha) + sin(2*alpha))/(8*pi))); #r.m.s voltage developed in the lamp, V\n",
+ "\n",
+ "\n",
+ "RL=V**2/P; #Load resistance, \u03a9\n",
+ "\n",
+ "I_rms=E_rms/RL; #r.m.s current developed in the lamp, A\n",
+ "\n",
+ "#Result\n",
+ "print(\"The r.m.s voltage developed in the lamp=%d V.\"%E_rms);\n",
+ "print(\"The r.m.s current developed in the lamp=%.2f A.\"%I_rms);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The r.m.s voltage developed in the lamp=70 V.\n",
+ "The r.m.s current developed in the lamp=0.58 A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.10 : Page number 567\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import cos\n",
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "RL=100.0; #Load resistance, \u03a9\n",
+ "V_m=200.0; #Peak a.c voltage, V\n",
+ "alpha=60; #firing angle, \u00b0\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "V_av=(V_m/pi)*(1+cos(alpha*pi/180)); #D.C output voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "I_av=V_av/RL; #Load current, A\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) d.c output voltage=%.1f V.\"%V_av);\n",
+ "print(\"(ii) Load current=%.3f A\"%I_av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) d.c output voltage=95.5 V.\n",
+ "(ii) Load current=0.955 A\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.11: Page number 567\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import pi\n",
+ "from math import sin\n",
+ "\n",
+ "#Variable declaration\n",
+ "alpha=60.0; #Firing angle, \u00b0\n",
+ "P=100.0; #Power rating of tungsten lamp, W\n",
+ "V=110.0; #Voltage rating of tungsten lamp, V\n",
+ "V_ac=110.0; #a.c supply voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_m=round(V_ac*sqrt(2)); #Peak value of input voltage, V\n",
+ "\n",
+ "alpha=alpha*pi/180; #firing angle, rad\n",
+ "\n",
+ "#Since, E_rms\u00b2=(1/2*pi) \u222b V_m\u00b2sin\u00b2(theta) d(theta), limits: alpha to pi\n",
+ "# E_rms\u00b2=Vm\u00b2*((2*(pi-alpha) + sin(2*alpha))/(8*pi)),\n",
+ "# E_rms=Vm*sqrt((2*(pi-alpha) + sin(2*alpha))/(8*pi)),\n",
+ "E_rms=V_m*sqrt((2*(pi-alpha) + sin(2*alpha))/(4*pi)); #r.m.s voltage developed in the lamp, V\n",
+ "\n",
+ "RL=V**2/P; #Load resistance, \u03a9\n",
+ "\n",
+ "I_rms=E_rms/RL; #r.m.s current developed in the lamp, A\n",
+ "\n",
+ "#Result\n",
+ "print(\"The r.m.s voltage developed in the lamp=%.1f V.\"%E_rms);\n",
+ "print(\"The r.m.s current developed in the lamp=%.2f A.\"%I_rms);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The r.m.s voltage developed in the lamp=98.9 V.\n",
+ "The r.m.s current developed in the lamp=0.82 A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.12 : Page number 572\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15; #Suuply voltage, V\n",
+ "V_T=0.7; #Gate trigger voltage, V\n",
+ "I_T=7.0; #Gate trigger current, mA\n",
+ "I_H=6.0; #Holding current. mA\n",
+ "R_Vin=1; #Resistance at Vin, k\u03a9\n",
+ "R_VCC=100; #Resistance at Vcc, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) when SCR is off, there is no current, therefore no voltage drop across the resistor\n",
+ "V_out=VCC; #Output voltage, when SCR is off, V\n",
+ "\n",
+ "#(ii)\n",
+ "V_in=V_T+I_T*R_Vin; #Input voltage required to trigger the SCR, V\n",
+ "\n",
+ "#(iii)\n",
+ "#Since, I_H=(Vcc-VT)/R_Vin;\n",
+ "VCC_SCR_open=(I_H/1000)*R_VCC+V_T; #Decreased value of supply voltage at which SCR opens, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The output voltage when SCR is off=%dV.\"%V_out);\n",
+ "print(\"(ii) The input voltage required to trigger the SCR=%.1f V.\"%V_in);\n",
+ "print(\"(iii) The decreased supply voltage at which SCR opens=%.1f V.\"%VCC_SCR_open);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The output voltage when SCR is off=15V.\n",
+ "(ii) The input voltage required to trigger the SCR=7.7 V.\n",
+ "(iii) The decreased supply voltage at which SCR opens=1.3 V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.13 : Page number 572-573\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=5.6; #zener voltage, V\n",
+ "V_T=0.7; #Trigger voltage of SCR, V\n",
+ "\n",
+ "#Calculation\n",
+ "VCC=Vz+V_T; #Required supply voltage to turn on the crowbar, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The required supply voltage to turn on the crowbar=%.1fV.\"%VCC);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required supply voltage to turn on the crowbar=6.3V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.14 : Page number 573\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=12; #Zener breakdown voltage, V\n",
+ "V_T=1.5; #Trigger voltage, V\n",
+ "tolerance_z=10.0; #Tolerance of zener diode, %\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "Vz_max=Vz*(1+tolerance_z/100); #Maximum value of zener breakdown, V\n",
+ "Vz_min=Vz*(1-tolerance_z/100); #Minimum value of zener breakdown, V\n",
+ "V_crowbar=Vz_max+V_T; #Maximum value of supply voltage for crowbarring, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum value of supply voltage for crowbarring=%.1fV\"%V_crowbar);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum value of supply voltage for crowbarring=14.7V\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 20.15 : Page number 573\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=25.0; #Supply voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#When brights light is on, LASCR conducts and thus gets short circuited to ground, hence,\n",
+ "V_out=0; #Output voltage, V\n",
+ "\n",
+ "print(\"Output voltage when bright light is on=%dV\"%V_out);\n",
+ "\n",
+ "\n",
+ "#When brights light is off, LASCR stops conducting and thus no current through resistor, hence,\n",
+ "V_out=VCC; #Output voltage, V\n",
+ "print(\"Output voltage when bright light is off=%dV\"%V_out);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage when bright light is on=0V\n",
+ "Output voltage when bright light is off=25V\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter21_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter21_1.ipynb
new file mode 100644
index 00000000..acca0cfa
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter21_1.ipynb
@@ -0,0 +1,467 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:412bf04e25192c77f9fa9664d995cc0ae6446a81f631fb5e0e755ebfa36436bf"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 21 : POWER ELECTRONICS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.3: Page number 585\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_GT=2; #Gate triggering voltage, V\n",
+ "V_F=0.7; #Forward voltage for diode D1\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)Triggering only by a positive gate voltage,\n",
+ "#A diode is connected at the gatewith the n-side connected to thegate of the device,\n",
+ "V_A=V_F+V_GT; #Required voltage to trigger the device, V\n",
+ "\n",
+ "print(\"The required voltage to trigger the device only by positive voltage=%.1fV.\"%V_A);\n",
+ "\n",
+ "#(ii)\n",
+ "print(\"In order to trigger the triac only by negative voltage, the direction of diode D1 is reversed.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required voltage to trigger the device only by positive voltage=2.7V.\n",
+ "In order to trigger the triac only by negative voltage, the direction of diode D1 is reversed.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.4 : Page number 585-586\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R=50.0; #Resitor, \u03a9\n",
+ "V=50.0; #Supply voltage, V\n",
+ "V_drop=1.0; #Drop across the triac in conduction, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) Ideal triac\n",
+ "#Since the triac is ideal, voltage drop across it is zero,\n",
+ "I=V/R; #Current through the 50 \u03a9 resistor, A\n",
+ "\n",
+ "print(\"(i) The cuurent through the 50 \u03a9 resistor when the triac is ideal=%dA.\"%I);\n",
+ "\n",
+ "#(ii) Triac has a drop of 1V\n",
+ "I=(V-V_drop)/R; #Current through the 50 \u03a9 resistor, A\n",
+ "\n",
+ "print(\"(ii) The current through the 50 \u03a9 resistor when the triac has a drop of 1V=%.2fA.\"%I);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The cuurent through the 50 \u03a9 resistor when the triac is ideal=1A.\n",
+ "(ii) The current through the 50 \u03a9 resistor when the triac has a drop of 1V=0.98A.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.5 : Page number 588-589\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_GT=2; #Gate triggering voltage, V\n",
+ "V_BO=20; #Breakover voltage,V\n",
+ "\n",
+ "#Calculation\n",
+ "print(\"The triggering level is raised by using a diac.\");\n",
+ "V_A=V_BO+V_GT; #Gate trigger signal, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"In order to turn on the triac, the gate trigger signal=%dV.\"%V_A);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The triggering level is raised by using a diac.\n",
+ "In order to turn on the triac, the gate trigger signal=22V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.6 : Page number 589\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_BO=30; #Breakover voltage of diac, V\n",
+ "V_GT=1; #Trigger voltage of the triac, V\n",
+ "I_T=10; #Trigger current, mA\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_A=V_BO+V_GT; #Voltage required for triggering the triac, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The minimum capacitor voltage that will trigger the triac=%d V.\"%V_A);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The minimum capacitor voltage that will trigger the triac=31 V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.7 : Page number 593\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "eta=0.6; #Intrinsic stand-off ratio for UJT\n",
+ "R_BB=10; #Inter-base resistance, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, RBB=RB1+RB2 and eta=RB1/(RB1+RB2),\n",
+ "#eta=RB1/RBB.\n",
+ "R_B1=eta*R_BB; #Resistance of the bar between B1 and emitter junction, k\u03a9\n",
+ "R_B2=R_BB-R_B1; #Resistance of the bar between B2 and emitter junction, k\u03a9 \n",
+ "\n",
+ "#Result\n",
+ "print(\"Resistance of the bar between B1 and emitter junction=%d k\u03a9.\"%R_B1);\n",
+ "print(\"Resistance of the bar between B2 and emitter junction=%d k\u03a9.\"%R_B2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Resistance of the bar between B1 and emitter junction=6 k\u03a9.\n",
+ "Resistance of the bar between B2 and emitter junction=4 k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.8 : Page number 593\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_BB=10; #Interbase voltage, V\n",
+ "eta=0.65; #Intrinsic stand-off ratio for UJT\n",
+ "V_D=0.7; #Voltage drop in the pn junction, V\n",
+ "\n",
+ "#Calculation\n",
+ "V_stand_off=eta*V_BB; #Stand off voltage, V\n",
+ "V_P=V_stand_off+V_D; #Peak-point voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Stand off voltage=%.1f V.\"%V_stand_off);\n",
+ "print(\"Peak-point voltage=%.1f V.\"%V_P);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Stand off voltage=6.5 V.\n",
+ "Peak-point voltage=7.2 V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.9 : Page number 593\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_BB=25; #Interbase voltage, V\n",
+ "eta_max=0.86; #Maximum intrinsic stand-off ratio for UJT\n",
+ "eta_min=0.74; #Minimum intrinsic stand-off ratio for UJT\n",
+ "V_D=0.7; #Voltage drop in the pn junction, V\n",
+ "\n",
+ "#Calculation\n",
+ "V_P_max=eta_max*V_BB+V_D; #Maximum peak-point, V\n",
+ "V_P_min=eta_min*V_BB+V_D; #Minimum peak-point, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Maximum peak-point voltage=%.1fV\"%V_P_max);\n",
+ "print(\"Minimum peak-point voltage=%.1fV\"%V_P_min);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Maximum peak-point voltage=22.2V\n",
+ "Minimum peak-point voltage=19.2V\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.10 : Page number 593-594\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "eta=0.65; #Intrinsic stand-off ratio for UJT\n",
+ "R_BB=7.0; #Inter-base resistance, k\u03a9\n",
+ "R1=100.0; #Resistor R1, \u03a9\n",
+ "R2=400.0; #Resistor R2, \u03a9\n",
+ "V_S=12.0; #Source voltage, V\n",
+ "V_D=0.7; #Voltage drop in the pn junction, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#Since, eta=RB1/RBB,\n",
+ "R_B1=eta*R_BB; #Resistance of the bar between B1 and emitter junction, k\u03a9\n",
+ "R_B2=R_BB-R_B1; #Resistance of the bar between B2 and emitter junction, k\u03a9 \n",
+ "\n",
+ "print(\"(i) Resistance of the bar between B1 and emitter junction=%.2f k\u03a9.\"%R_B1);\n",
+ "print(\" Resistance of the bar between B2 and emitter junction=%.2f k\u03a9.\"%R_B2);\n",
+ "\n",
+ "#(ii)\n",
+ "V_B2_B1=V_S*R_BB/(R_BB + (R1/1000) + (R2/1000)); #Voltage across B2-B1, V (voltage divider rule)\n",
+ "V_P=eta*V_B2_B1+V_D; #Peak-point voltage, V\n",
+ "\n",
+ "print(\"(ii) The voltage across the base B2-B1=%.1fV.\"%V_B2_B1);\n",
+ "print(\" Peak-point voltage=%.2fV\"%V_P);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Resistance of the bar between B1 and emitter junction=4.55 k\u03a9.\n",
+ " Resistance of the bar between B2 and emitter junction=2.45 k\u03a9.\n",
+ "(ii) The voltage across the base B2-B1=11.2V.\n",
+ " Peak-point voltage=7.98V\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.11 : Page number 596\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log\n",
+ "\n",
+ "#Variable declaration\n",
+ "RE_initial=5; #Initial value of emitter resistor, k\u03a9\n",
+ "RE_adjusted=10; #Adjusted value of emitter resistor, k\u03a9\n",
+ "C=0.2; #Capacitance, \u03bcF\n",
+ "eta=0.54; #intrinsic stand-off ratio\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "t=round((RE_initial*1000*C*10**-6*log(1/(1-eta)))*1000,2); #Time period, ms\n",
+ "f=(1/t)*1000; #frequency, Hz\n",
+ "\n",
+ "print(\"Frequency for 5k\u03a9 setting=%dHz.\"%f);\n",
+ "\n",
+ "#(i)\n",
+ "t=round((RE_adjusted*1000*C*10**-6*log(1/(1-eta)))*1000,2); #Time period, ms\n",
+ "f=(1/t)*1000; #frequency, Hz\n",
+ "\n",
+ "print(\"Frequency for 10k\u03a9 setting=%dHz.\"%f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Frequency for 5k\u03a9 setting=1282Hz.\n",
+ "Frequency for 10k\u03a9 setting=645Hz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 21.12 : Page number 596-597\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log\n",
+ "\n",
+ "#Variable declaration\n",
+ "V_S=12; #Supply voltage, V\n",
+ "R_BB=5; #Interbase resistance, k\u03a9\n",
+ "R_1=50; #Resistor R1, k\u03a9\n",
+ "R_2=0.1; #Resistor R2, k\u03a9\n",
+ "C=0.1; #Capacitance, \u03bcF\n",
+ "eta=0.6; #intrinsic stand-off ratio\n",
+ "V_D=0.7; #Voltage drop across pn junction, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "#Since, \u03b7=R_B1/R_BB,\n",
+ "R_B1=eta*R_BB; #Resitance between base B1 and emitter junction, k\u03a9\n",
+ "\n",
+ "#Since, R_BB=R_B1+R_B2\n",
+ "R_B2=R_BB-R_B1; #Resitance between base B2 and emitter junction, k\u03a9\n",
+ "\n",
+ "#(ii)\n",
+ "V_RB1_R2=V_S*(R_B1+R_2)/(R_BB+R_2); #Voltage drop across R_B1 and R_2 resistors, V\n",
+ "V_P=V_D+V_RB1_R2; #Peak-point voltage, V\n",
+ "\n",
+ "#(iii)\n",
+ "t=round((R_1*1000*C*10**-6*log(1/(1-eta)))*1000,2); #Time period, ms\n",
+ "f=(1/t)*1000; #frequency, Hz\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) R_B1=%dk\u03a9 and R_B2=%dk\u03a9\"%(R_B1,R_B2));\n",
+ "print(\"(ii) The peak-point voltage to turn on the UJT=%.0fV.\"%V_P);\n",
+ "print(\"(iii) Frequency of oscillations=%dHz.\"%f);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) R_B1=3k\u03a9 and R_B2=2k\u03a9\n",
+ "(ii) The peak-point voltage to turn on the UJT=8V.\n",
+ "(iii) Frequency of oscillations=218Hz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter22_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter22_1.ipynb
new file mode 100644
index 00000000..5f13ea0e
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter22_1.ipynb
@@ -0,0 +1,668 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:a688629536ad6915939234eacc1ed3eaaf36e0aaa88de5df5b6a309da4d2c64d"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 22: ELECTRONIC INSTRUMENTS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.1 : Page number 606\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_g=1; #Full scale deflection current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "MS=1/(I_g/1000.0); #Multimeter sensitivity, \u03a9 per volt\n",
+ "\n",
+ "#Result\n",
+ "print(\"The multimeter sensitivity=%d \u03a9 per volt.\"%MS);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The multimeter sensitivity=1000 \u03a9 per volt.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.2 : Page number 606-607\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "meter_sensitivity=1000.0; #Meter sensitivity, \u03a9 per volt\n",
+ "V_full_scale=50.0; #Full scale volts\n",
+ "R=50000.0; #Resistance to be measured, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "meter_resistance=V_full_scale*meter_sensitivity; #Meter resistance, \u03a9\n",
+ "R_p=R*meter_resistance/(R+meter_resistance); #Parallel resistance, \u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"When the meter is used to measure the voltage across the resistance %d\u03a9, total resistance =%d\u03a9.\"%(R,R_p));\n",
+ "print(\"\u2234 Meter will give highly incorrect reading.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "When the meter is used to measure the voltage across the resistance 50000\u03a9, total resistance =25000\u03a9.\n",
+ "\u2234 Meter will give highly incorrect reading.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.3 : Page number 607\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "meter_sensitivity=4.0; #Meter sensitivity, k\u03a9/V\n",
+ "R_1=10.0; #Resistance across which voltage is to be measured, k\u03a9\n",
+ "R_2=10.0; #Resistance, k\u03a9\n",
+ "range_max=10.0; #Maximum range of the meter, V\n",
+ "range_min=0; #Minimum range of the meter, V\n",
+ "V=20.0; #Battery voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "R_meter=meter_sensitivity*range_max; #Resistance of the meter, k\u03a9\n",
+ "R_T=(R_meter*R_1)/(R_1+R_meter) + R_2; #Total circuit resistance, k\u03a9\n",
+ "I_circuit=round(V/R_T,2); #Circuit current, mA\n",
+ "V_multimeter=I_circuit*((R_meter*R_1)/(R_1+R_meter)); #Voltage read by multimeter, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Voltage read by multimeter=%.2fV.\"%V_multimeter);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage read by multimeter=8.88V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.4 : Page number 607-608\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "meter_sensitivity=20.0; #Meter sensitivity, k\u03a9/V\n",
+ "R_1=10.0; #Resistance across which voltage is to be measured, k\u03a9\n",
+ "R_2=10.0; #Resistance, k\u03a9\n",
+ "range_max=10.0; #Maximum range of the meter, V\n",
+ "range_min=0; #Minimum range of the meter, V\n",
+ "V=20.0; #Battery voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "R_meter=meter_sensitivity*range_max; #Resistance of the meter, k\u03a9\n",
+ "R_T=round((R_meter*R_1)/(R_1+R_meter) + R_2,1); #Total circuit resistance, k\u03a9\n",
+ "I_circuit=round(V/R_T,2); #Circuit current, mA\n",
+ "V_multimeter=I_circuit*((R_meter*R_1)/(R_1+R_meter)); #Voltage read by multimeter, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Voltage read by multimeter=%.2fV.\"%V_multimeter);\n",
+ "\n",
+ "\n",
+ "#Note: The circuit current=1.0256mA, has been approximated in the text as 1.04mA. But, in the code 1.03 mA has been used. Therefore, the final answer is obtained as 9.81V and not 9.88V.\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage read by multimeter=9.81V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.5 : Page number 608-609\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import floor\n",
+ "\n",
+ "#Variable declaration\n",
+ "R_A=20.0; #Resistance after point A, k\u03a9\n",
+ "R_B=20.0; #Resistance after point B, k\u03a9\n",
+ "R_C=30.0; #Resistance after point C, k\u03a9\n",
+ "R_D=30.0; #Resistance after point D, k\u03a9\n",
+ "R_meter=60.0; #Resistance of the meter, k\u03a9\n",
+ "V=100.0; #Battery voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) When meter is not connected:\n",
+ "R_T=R_A+R_B+R_C+R_D; #Total circuit resistance, k\u03a9\n",
+ "I_circuit=V/R_T; #Circuit current, mA\n",
+ "V_A=V; #Voltage at point A, V\n",
+ "V_B=V-(I_circuit*R_A); #Voltage at point B, V\n",
+ "V_C=V-(I_circuit*(R_A+R_B)); #Voltage at point C, V\n",
+ "V_D=V-(I_circuit*(R_T-R_D)); #Voltage at point D, V\n",
+ "\n",
+ "print(\"(i) When meter is not connected:\");\n",
+ "print(\" Voltage at point A=%dV.\"%V_A);\n",
+ "print(\" Voltage at point B=%dV.\"%V_B);\n",
+ "print(\" Voltage at point C=%dV.\"%V_C);\n",
+ "print(\" Voltage at point D=%dV.\"%V_D);\n",
+ "\n",
+ "\n",
+ "#(ii) When meter is connected:\n",
+ "#(a) Since, point A is directly connected to the source, voltage at point A is equal to source voltage.\n",
+ "V_A=V; #Voltage at point A, V\n",
+ "\n",
+ "#(b)\n",
+ "R_T_B=R_A + round((R_T-R_A)*R_meter/(R_meter + (R_T-R_A)),2); #Total circuit resistance, k\u03a9\n",
+ "I_circuit=round(V/R_T_B,2); #Circuit current, mA\n",
+ "V_B=I_circuit*(R_T-R_A)*R_meter/(R_meter + (R_T-R_A)); #Voltage at point B, V\n",
+ "\n",
+ "\n",
+ "#(c)\n",
+ "R_T_C=(R_A+R_B) + (R_T-R_A-R_B)*R_meter/(R_meter + (R_T-R_A-R_B)); #Total circuit resistance, k\u03a9\n",
+ "I_circuit=V/R_T_C; #Circuit current, mA\n",
+ "V_C=floor((I_circuit*(R_T-R_A-R_B)*R_meter/(R_meter + (R_T-R_A-R_B)))*10)/10; #Voltage at point C, V\n",
+ "\n",
+ "\n",
+ "\n",
+ "#(c)\n",
+ "R_T_D=(R_T-R_D) + R_D*R_meter/(R_meter + R_D); #Total circuit resistance, k\u03a9\n",
+ "I_circuit=round(V/R_T_D,2); #Circuit current, mA\n",
+ "V_D=I_circuit*(R_D*R_meter)/(R_meter + R_D); #Voltage at point D, V\n",
+ "\n",
+ "\n",
+ "print(\"(ii) When meter is connected:\");\n",
+ "print(\" Voltage at point A=%dV.\"%V_A);\n",
+ "print(\" Voltage at point B=%dV.\"%V_B);\n",
+ "print(\" Voltage at point C=%.1fV.\"%V_C);\n",
+ "print(\" Voltage at point D=%.1fV.\"%V_D);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) When meter is not connected:\n",
+ " Voltage at point A=100V.\n",
+ " Voltage at point B=80V.\n",
+ " Voltage at point C=60V.\n",
+ " Voltage at point D=30V.\n",
+ "(ii) When meter is connected:\n",
+ " Voltage at point A=100V.\n",
+ " Voltage at point B=63V.\n",
+ " Voltage at point C=42.8V.\n",
+ " Voltage at point D=22.2V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.6 : Page number 614\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Supply voltage, V\n",
+ "R_m=1.0; #Meter resistance, k\u03a9\n",
+ "I_m_fsd=2.0; #Full scale deflection of meter current, mA\n",
+ "beta=80.0; #Base current amplification factor\n",
+ "E=5.0; #Voltage to be measured, V\n",
+ "V_BE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_E=E-V_BE; #Emitter voltage, V\n",
+ "\n",
+ "#(i)\n",
+ "#I_m_fsd=V_E/(R_s+R_m), (OHM's LAW)\n",
+ "R_s=((V_E/I_m_fsd)-R_m)*1000; #Multiplier resistor, \u03a9\n",
+ "\n",
+ "#(ii)\n",
+ "IB=I_m_fsd/beta; \t\t\t\t#Base current, mA\n",
+ "R_i=E/IB; \t\t\t#Input resistance of voltmeter, k\u03a9\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The multiplier resistor=%d\u03a9.\"%R_s);\n",
+ "print(\"(ii) The voltmeter input resistance=%dk\u03a9\"%R_i);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The multiplier resistor=1150\u03a9.\n",
+ "(ii) The voltmeter input resistance=200k\u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.7 : Page number 614\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20; #Supply voltage, V\n",
+ "Rs_Rm=9.3; #Sum of multipier resistance and meter resistance, k\u03a9\n",
+ "I_m=1; #Meter current, mA\n",
+ "beta=100; #Base current amplification factor\n",
+ "E=10; #Voltage to be measured, V\n",
+ "V_BE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "V_E=E-V_BE; #Emitter voltage, V\n",
+ "I_m=V_E/Rs_Rm; #Meter current, mA\n",
+ "\n",
+ "#(ii)\n",
+ "I_B=I_m/beta; #Base current, mA\n",
+ "R_i_T=(E/I_B)/1000; #Input resistance of voltmeter, with transistor, M\u03a9\n",
+ "R_i_WT=Rs_Rm; #Input resistance of voltmeter, without transistor, k\u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The meter current=%dmA\"%I_m);\n",
+ "print(\"(ii) The input resistance of voltmeter with transistor=%dM\u03a9.\"%R_i_T);\n",
+ "print(\" The input resistance of voltmeter without transistor=%.1fk\u03a9.\"%R_i_WT);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The meter current=1mA\n",
+ "(ii) The input resistance of voltmeter with transistor=1M\u03a9.\n",
+ " The input resistance of voltmeter without transistor=9.3k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.8 : Page number 614-615\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20; #Supply voltage, V\n",
+ "Rs_Rm=9.3; #Sum of multipier resistance and meter resistance, k\u03a9\n",
+ "I_m=1; #Meter current, mA\n",
+ "beta=100; #Base current amplification factor\n",
+ "E=5; #Voltage to be measured, V\n",
+ "V_BE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "I_m=(E-V_BE)/Rs_Rm; #Meter current, mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The meter current=%.2fmA\"%I_m);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The meter current=0.46mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.9 : Page number 616\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "from math import floor\n",
+ "\n",
+ "#Variable declaration\n",
+ "I_m_fsd=100.0; #Full scale deflection of meter current, \u03bcA\n",
+ "R_m=1.0; #Meter resistance, k\u03a9\n",
+ "V_rms=100.0; #r.m.s voltage to be measured, V\n",
+ "V_F=0.7; #Forward voltage drop of rectifier diode, V \n",
+ "\n",
+ "#Calculation\n",
+ "V_m=round(sqrt(2)*V_rms,1); #Peak value of applied voltage, V\n",
+ "V_rectifier_drop=2*V_F; #Total rectifier drop, V\n",
+ "I_peak=round(I_m_fsd/0.637,2); #Peak f.s.d current, \u03bcA\n",
+ "R_s=floor(((((V_m-V_rectifier_drop)/(I_peak*10**-6))-(R_m*1000))/1000)*10)/10; #Multiplier resistance, k\u03a9 (OHM's LAW)\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The multiplier resistance=%.1fk\u03a9.\"%R_s);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The multiplier resistance=890.7k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.10 : Page number 616\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "I_av=75; #Full scale deflection of meter current, \u03bcA\n",
+ "R_s=708; #Multiplier resistor, k\u03a9\n",
+ "R_m=900; #Meter coil resistor, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "I_peak=I_av*10**-6/0.637; #Peak f.s.d meter current, A\n",
+ "R_T=R_s*1000+R_m; #Total circuit resistance, \u03a9\n",
+ "\n",
+ "#I_peak=(Vm-V_drop)/R_T; (OHM's LAW)\n",
+ "#And, Vm=sqrt(2)*Vrms\n",
+ "V_rms=(I_peak*R_T+(2*0.7))/sqrt(2) ; #applied r.m.s voltage, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The applied r.m.s voltage=%dV\"%V_rms);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The applied r.m.s voltage=60V\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.11 : Page number 618\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "deflection_sensitivity=0.01; #Deflection sensitivity, mm/V\n",
+ "V=400; #Applied voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "spot_shift=V*deflection_sensitivity; #Spot shift produced, mm\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The shift produced in the spot=%dmm.\"%spot_shift);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The shift produced in the spot=4mm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.12 : Page number 618-619\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "deflection_sensitivity=0.03; #Deflection sensitivity, mm/V\n",
+ "spot_shift=3; #Spot shift produced, mm\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, spot_shift=Applied_Voltage*deflection_sensitivity,\n",
+ "V=spot_shift/deflection_sensitivity; #Applied voltage, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Applied voltage=%dV.\"%V);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Applied voltage=100V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.13 : Page number 622\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "deflection=2; #Deflection produced by applied voltage, cm\n",
+ "V=200; #Applied voltage, V\n",
+ "deflection_by_another_voltage=3; #Deflection by another voltage, cm\n",
+ "\n",
+ "#Calculation\n",
+ "deflection_sensitivity=V/deflection; #deflection sensitivity, V/cm\n",
+ "V_unknown=deflection_sensitivity*deflection_by_another_voltage; #Unknown voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The unknown voltage=%dV.\"%V_unknown);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The unknown voltage=300V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 22.14 : Page number 622\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "f_H=1000; #Frequency applied to horizontal plates, Hz\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Loops_H=1; #Number of loops cut by horizontal line\n",
+ "Loops_V=1; #Number of loops cut by vertical line\n",
+ "f_V=f_H*(Loops_H/Loops_V); #Unknown frequency, Hz\n",
+ "\n",
+ "print(\"(i) Unknown frequency=%dHz.\"%f_V);\n",
+ "\n",
+ "#(ii)\n",
+ "Loops_H=2; #Number of loops cut by horizontal line\n",
+ "Loops_V=1; #Number of loops cut by vertical line\n",
+ "f_V=f_H*(Loops_H/Loops_V); #Unknown frequency, Hz\n",
+ "\n",
+ "print(\"(ii) Unknown frequency=%dHz.\"%f_V);\n",
+ "\n",
+ "#(iii)\n",
+ "Loops_H=6; #Number of loops cut by horizontal line\n",
+ "Loops_V=1; #Number of loops cut by vertical line\n",
+ "f_V=f_H*(Loops_H/Loops_V); #Unknown frequency, Hz\n",
+ "\n",
+ "print(\"(iii) Unknown frequency=%dHz.\"%f_V);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Unknown frequency=1000Hz.\n",
+ "(ii) Unknown frequency=2000Hz.\n",
+ "(iii) Unknown frequency=6000Hz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter23_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter23_1.ipynb
new file mode 100644
index 00000000..19741354
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter23_1.ipynb
@@ -0,0 +1,133 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:87bd5c8d9448f5bb2e75909f89934a6fb2b64e65e6ea37b085ce080a58026071"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 23 : INTEGRATED CIRCUITS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 23.1: Page number 637"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=240; #Adjusted resistance of R2 resistor of LM317 voltage regulator, in kilo ohm\n",
+ "R2=2.4; #Fixed value of R1 resistor of LM317 voltage regulator, in ohm\n",
+ "\n",
+ "#Calculations\n",
+ "#Output voltage of LM317 voltage regulator IC = 1.25(R2/R1 +1)\n",
+ "Vout=1.25*((R2*1000)/R1 + 1); #Regulated d.c output voltage for the circuit in V\n",
+ "\n",
+ "#Results\n",
+ "print(\"The regulated d.c output voltage = %.2fV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The regulated d.c output voltage = 13.75V\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 23.2 : Page number 638"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R=1.2; #Value of resistance of monostable multivibrator in kilo ohm\n",
+ "C=0.1; #Value of capacitance of monostable multivibrator in microfarad\n",
+ "\n",
+ "#Calculations\n",
+ "T=1.1*(R*1000)*C; #Time for which the circuit is ON, in microseconds\n",
+ "\n",
+ "#Results\n",
+ "print(\"Time for which the circuit is ON = %d microseconds.\"%T); \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Time for which the circuit is ON = 132 microseconds.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 23.3 : Page number 639\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=3.0; #Resistance of R1 resistor of 555 timer circuit in kilo ohm\n",
+ "R2=2.7; #Resistance of R2 resistor of 555 timer circuit in kilo ohm\n",
+ "C=0.033; #Capacitance of the capacitor of 555 timer circuit in microfarad\n",
+ "\n",
+ "#Calculations\n",
+ "f=1.44/(((R1*1000) + 2*(R2*1000))*(C*pow(10,-6))); #Frequency of the circuit in Hz\n",
+ "f=f/1000; #Frequency of the circuit in kHz\n",
+ "\n",
+ "#Results\n",
+ "print(\"The frequency of the circuit = %.2fkHz\"%f);\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The frequency of the circuit = 5.19kHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter24_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter24_1.ipynb
new file mode 100644
index 00000000..e63c17a6
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter24_1.ipynb
@@ -0,0 +1,604 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:947f358cf49d029c94d008f72a340051744678cf2e36ecc199100b78d31fcba5"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 24 : HYBRID PARAMETERS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.1 : Page number 644-645\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=10.0; #1st resistor, \u03a9\n",
+ "R2=5.0; #2nd resistor, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "print(\"To find h11 and h21, output terminals are shorted.\");\n",
+ "h11=R1; #Input impedance with output shorted, \u03a9\n",
+ "\n",
+ "print(\"h11=%d\u03a9.\"%h11);\n",
+ "\n",
+ "print(\"Output current flowing into the box= input current flowing out of the box.\");\n",
+ "print(\"i2=-i1\"); #Output current flowing into the box= input current flowing out of the box.\n",
+ "print(\"h21=i2/i1 = -i1/i1= -1.\"); #Current gain with output shorted.\n",
+ "\n",
+ "\n",
+ "print(\"For finding h22 and h12, voltage source is connected at the output\");\n",
+ "#As, there will be no current through 10k\u03a9 resistor due to open circuited input,\n",
+ "print(\"v1=v2\"); #Output voltage is equal to input voltage(equal to voltage drop across 5k\u03a9 resistor)\n",
+ "print(\"h12=v1/v2 = v2/v2 = 1\"); #Voltage feedback ratio with input terminals open\n",
+ "\n",
+ "h22=1/R2; #Output admittance, mho\n",
+ "print(\"h22=%.1f mho\"%h22);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "To find h11 and h21, output terminals are shorted.\n",
+ "h11=10\u03a9.\n",
+ "Output current flowing into the box= input current flowing out of the box.\n",
+ "i2=-i1\n",
+ "h21=i2/i1 = -i1/i1= -1.\n",
+ "For finding h22 and h12, voltage source is connected at the output\n",
+ "v1=v2\n",
+ "h12=v1/v2 = v2/v2 = 1\n",
+ "h22=0.2 mho\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.2 : Page number 645-646\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=4.0; #1st resistor(at the input side), \u03a9\n",
+ "R2=4.0; #2nd resistor(at the middle), \u03a9\n",
+ "R3=4.0; #3rd resistor(at the output side), \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "print(\"To find h11 and h21, output terminals are shorted.\");\n",
+ "h11=R1 + (R2*R3/(R2+R3)); #Input impedance with output shorted, \u03a9\n",
+ "print(\"h11=%d\u03a9.\"%h11);\n",
+ "\n",
+ "#As the input current gets divided in half due to R2=R3.\n",
+ "print(\"Output current flowing into the box=negative of half of input current flowing out of the box.\");\n",
+ "print(\"i2=-i1/2 = -0.5i1\"); \n",
+ "print(\"h21=i2/i1 = -0.5i1/i1= -0.5.\"); #Current gain with output shorted.\n",
+ "\n",
+ "print(\"For finding h22 and h12, voltage source is connected at the output\");\n",
+ "#As, there will be no current through the 1st 4k\u03a9 resistor due to open circuited input,\n",
+ "#Voltage gets equally divided across R2 and R3 resistor\n",
+ "print(\"v1=v2/2 = 0.5v2\"); #Input voltage is equal to half of input voltage\n",
+ "print(\"h12=v1/v2 = 0.5v2/v2 = 0.5\"); #Voltage feedback ratio with input terminals open\n",
+ "\n",
+ "h22=1/(R2+R3); #Output admittance, mho\n",
+ "print(\"h22=%.3f mho\"%h22);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "To find h11 and h21, output terminals are shorted.\n",
+ "h11=6\u03a9.\n",
+ "Output current flowing into the box=negative of half of input current flowing out of the box.\n",
+ "i2=-i1/2 = -0.5i1\n",
+ "h21=i2/i1 = -0.5i1/i1= -0.5.\n",
+ "For finding h22 and h12, voltage source is connected at the output\n",
+ "v1=v2/2 = 0.5v2\n",
+ "h12=v1/v2 = 0.5v2/v2 = 0.5\n",
+ "h22=0.125 mho\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.3 ; Page number 649-650\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R1=10.0; #Resistor at the input side, \u03a9\n",
+ "R2=5.0; #Resistor at the middle, \u03a9\n",
+ "rL=5.0; #Load resistor, \u03a9\n",
+ "\n",
+ "#h-parameter values from 24.1\n",
+ "h11=10.0; #Input impedance with output shorted, \u03a9\n",
+ "h21=-1.0; #Current gain with output shorted\n",
+ "h12=1.0; #Voltage feedback ratio with input terminal open\n",
+ "h22=0.2; #Output admittance, mho\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Zin=h11-(h12*h21/(h22+(1/rL))); #Input impedance, \u03a9\n",
+ "\n",
+ "#(ii)\n",
+ "Av=-h21/(Zin*(h22+(1/rL))); #voltage gain,\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The input impedance=%.1f\u03a9.\"%Zin );\n",
+ "print(\"(ii) The voltage gain=1/%d.\"%(1/Av));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The input impedance=12.5\u03a9.\n",
+ "(ii) The voltage gain=1/5.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.4 : Page number 652-653\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCE=10.0; #Collector-emitter voltage, V\n",
+ "IC=1.0; #Collector current, mA\n",
+ "rL=600.0; #a.c load seen by the transistor,\u03a9\n",
+ "\n",
+ "#h-parameters\n",
+ "hie=2000.0; #Input impedance with output shorted, \u03a9\n",
+ "hoe=10**-4; #Output impedance, mho\n",
+ "hre=10**-3; #Voltage feedback ratio with input terminal open\n",
+ "hfe=50.0; #Current gain with output shorted\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Zin=hie - (hre*hfe/(hoe+(1/rL))); #Input impedance, \u03a9\n",
+ "print(\"Input impedance=%.0f \u03a9. \\n As second term in the expression of Zin is small compared to first, Zin~hie=%d\u03a9.\"%(Zin,hie));\n",
+ "\n",
+ "#(ii)\n",
+ "Ai=hfe/(1+hoe*rL); #Current gain\n",
+ "print(\"Current gain=%d\"%Ai);\n",
+ "print(\"if hoe*rL<<1, then Ai~hfe=%d.\"%hfe);\n",
+ "\n",
+ "#(iii)\n",
+ "Av=-hfe/(Zin*(hoe+(1/rL))); #Voltage gain\n",
+ "print(\"Voltage gain=%.1f\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input impedance=1972 \u03a9. \n",
+ " As second term in the expression of Zin is small compared to first, Zin~hie=2000\u03a9.\n",
+ "Current gain=47\n",
+ "if hoe*rL<<1, then Ai~hfe=50.\n",
+ "Voltage gain=-14.4\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.5 : Page number 653\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import ceil\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCE=5.0; #Collector-emitter voltage, V\n",
+ "IC=1.0; #Collector current, mA\n",
+ "rL=2.0; #a.c load seen by the transistor,\u03a9\n",
+ "\n",
+ "\n",
+ "#h-parameters\n",
+ "hie=1700.0; #Input impedance with output shorted, \u03a9\n",
+ "hoe=6*10**-6; #Output impedance, mho\n",
+ "hre=1.3*10**-4; #Voltage feedback ratio with input terminal open\n",
+ "hfe=38.0; #Current gain with output shorted\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Zin=hie - (hre*hfe/(hoe+(1/(rL*1000)))); #Input impedance, \u03a9\n",
+ "print(\"Input impedance=%.0f \u03a9.\"%Zin);\n",
+ "\n",
+ "#(ii)\n",
+ "Ai=ceil((hfe/round((1+hoe*rL*1000),3))*10)/10; #Current gain\n",
+ "print(\"Current gain=%.1f\"%Ai);\n",
+ "\n",
+ "#(iii)\n",
+ "Av=-hfe/(Zin*(hoe+(1/(rL*1000)))); #Voltage gain\n",
+ "print(\"Voltage gain=%.1f\"%abs(Av));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input impedance=1690 \u03a9.\n",
+ "Current gain=37.6\n",
+ "Voltage gain=44.4\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.6 : Page number 653-654\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Function for calculating parallel resistance\n",
+ "def pr(r1,r2):\n",
+ " return r1*r2/(r1+r2);\n",
+ "\n",
+ "\n",
+ "#Variable declaration\n",
+ "RC=10.0; #Collector resistance, k\u03a9\n",
+ "RL=30.0; #Load resistance, k\u03a9\n",
+ "R1=80.0; #Resistor R1, k\u03a9\n",
+ "R2=40.0; #Resistor R2, k\u03a9\n",
+ "\n",
+ "#h-parameters\n",
+ "hie=1500.0; #Input impedance with output shorted, \u03a9\n",
+ "hoe=5*10**-5; #Output impedance, mho\n",
+ "hre=4*10**-4; #Voltage feedback ratio with input terminal open\n",
+ "hfe=50.0; #Current gain with output shorted\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "rL=((RC*RL)/(RC+RL))*1000; #a.c load as seen by resistance, \u03a9\n",
+ "\n",
+ "#(i)\n",
+ "Zin=round(hie - (hre*hfe/(hoe+(1/rL))),-1); #Input impedance, \u03a9\n",
+ "print(\"Input impedance=%.0f \u03a9.\"%Zin);\n",
+ "\n",
+ "#Input impedance of stage=input impedance || bias resistors\n",
+ "Zin_stage=round(pr(pr(R1,R2)*1000,Zin),-1); #\u03a9\n",
+ "print(\"Input impedance of the stage=%.0f \u03a9.\"%Zin_stage);\n",
+ "\n",
+ "#(ii)\n",
+ "Av=-hfe/(Zin*(hoe+(1/rL))); #Voltage gain\n",
+ "print(\"Voltage gain=%d\"%Av);\n",
+ "print(\"The negative sign represents phase reversal.\");\n",
+ "\n",
+ "\n",
+ "#(iii)\n",
+ "Zout=(1/(hoe-(hfe*hre/hie)))/1000; #Output impedance of transistor, k\u03a9\n",
+ "Zout_stage=pr(Zout,pr(RL,RC)); #Output impedance of the stage, k\u03a9\n",
+ "print(\"Output impedance=%.2f k\u03a9.\"%Zout);\n",
+ "print(\"Output impedance of the stage=%.2f k\u03a9.\"%Zout_stage);\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input impedance=1390 \u03a9.\n",
+ "Input impedance of the stage=1320 \u03a9.\n",
+ "Voltage gain=-196\n",
+ "The negative sign represents phase reversal.\n",
+ "Output impedance=27.27 k\u03a9.\n",
+ "Output impedance of the stage=5.88 k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.7 : Page number 654\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Function for calculating parallel resistance\n",
+ "def pr(r1,r2):\n",
+ " return r1*r2/(r1+r2);\n",
+ "\n",
+ "#Variable declaration\n",
+ "RC=4.7; #Collector resistance, k\u03a9\n",
+ "RL=10.0; #Load resistance, k\u03a9\n",
+ "R1=33.0; #Resistor R1, k\u03a9\n",
+ "R2=10.0; #Resistor R2, k\u03a9\n",
+ "\n",
+ "#h-parameters\n",
+ "hie=1; #Input impedance with output shorted, k\u03a9\n",
+ "hoe=25; #Output impedance, \u03bcS\n",
+ "hre=2.5*10**-4; #Voltage feedback ratio with input terminal open\n",
+ "hfe=50; #Current gain with output shorted\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "rL=(RC*RL)/(RC+RL); #a.c load as seen by resistance, k\u03a9\n",
+ "\n",
+ "Ai=hfe/(1+hoe*10**-6*rL*1000); #Current gain\n",
+ "print(\"Current gain=%.1f\"%Ai);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Current gain=46.3\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.8 : Page number 654-655\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R_S=100.0; #Series resistance, \u03a9 \n",
+ "\n",
+ "#h-parameters\n",
+ "hie=1.0; #Input impedance with output shorted, k\u03a9\n",
+ "hoe=25.0; #Output impedance, \u03bcS\n",
+ "hre=2.5*10**-4; #Voltage feedback ratio with input terminal open\n",
+ "hfe=50.0; #Current gain with output shorted\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "Zout=(1/(hoe*10**-6-(hfe*hre/(hie*1000+R_S))))/1000; #Output impedance of transistor, k\u03a9\n",
+ "print(\"Output impedance=%.1f k\u03a9.\"%Zout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output impedance=73.3 k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.9 : Page number 656\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import floor\n",
+ "\n",
+ "#Function for calculating parallel resistance\n",
+ "def pr(r1,r2):\n",
+ " return r1*r2/(r1+r2);\n",
+ "\n",
+ "#Variable declaration\n",
+ "RC=12.0; #Collector resistance, k\u03a9\n",
+ "RL=15.0; #Load resistance, k\u03a9\n",
+ "R1=50.0; #Resistor R1, k\u03a9\n",
+ "R2=5.0; #Resistor R2, k\u03a9\n",
+ "hie=1.94; #Input impedance with output shorted, k\u03a9\n",
+ "hfe=71.0; #Current gain with output shorted\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "rL=(RC*RL)/(RC+RL); #a.c load as seen by resistance, \u03a9\n",
+ "\n",
+ "#(i)\n",
+ "Zin_base=hie; #Transistor input impedance, k\u03a9\n",
+ "Zin_circuit=floor(pr(Zin_base,pr(R1,R2))*100)/100; #Circuit input impedance, k\u03a9\n",
+ "print(\"Circuit input impedance=%.2fk\u03a9\"%Zin_circuit);\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "Av=hfe*rL/hie; #Voltage gain\n",
+ "print(\"Voltage gain=%.0f\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Circuit input impedance=1.35k\u03a9\n",
+ "Voltage gain=244\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.10 : Page number 656\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "hie_min=600; #Minimum input impedance with output shorted, \u03a9\n",
+ "hfe_min=110; #Minimum current gain with output shorted\n",
+ "hie_max=800; #Maximum input impedance with output shorted, \u03a9\n",
+ "hfe_max=140; #Maximum current gain with output shorted\n",
+ "rL=460; #a.c collector load, \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "hie=round(sqrt(hie_min*hie_max)); #Input impedance with output shorted, \u03a9\n",
+ "hfe=round(sqrt(hfe_min*hfe_max)); #Current gain with output shorted\n",
+ "Av=hfe*rL/hie; #Voltage gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"Voltage gain=%.1f\"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage gain=82.3\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 24.11 : Page number 658-659\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#(a)Variable declaration\n",
+ "Ib=10; #Base current, \u03bcA\n",
+ "Ic=1; #Collector current, mA\n",
+ "Vbe=10; #Base-emitter voltage, mV\n",
+ "\n",
+ "#Calculation\n",
+ "hie=Vbe*10**-3/(Ib*10**-6); #Input impedance with output shorted, \u03a9\n",
+ "hfe=Ic*10**-3/(Ib*10**-6); #Current gain with output shorted\n",
+ "\n",
+ "#(b) Variable declaration\n",
+ "Vbe=0.65; #Base-emitter voltage, mV\n",
+ "Ic=60; #Collector current, \u03bcA\n",
+ "Vce=1; #Collector-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "hre=Vbe*10**-3/Vce; #Voltage feedback ratio with input terminal open\n",
+ "hoe=Ic/Vce; #Output impedance, \u03bcmho\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"hie=%d\u03a9\"%hie);\n",
+ "print(\"hfe=%d\"%hfe);\n",
+ "print(\"hre=%.2fe\u201303\"%(hre*1000));\n",
+ "print(\"hoe=%d\u03bcmho\"%hoe);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "hie=1000\u03a9\n",
+ "hfe=100\n",
+ "hre=0.65e\u201303\n",
+ "hoe=60\u03bcmho\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter25_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter25_1.ipynb
new file mode 100644
index 00000000..6add7ba9
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter25_1.ipynb
@@ -0,0 +1,2552 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:f21def3bd5ac5e7f3368a4e0e9a53b6961ecc94a2dca6b1917cdfda88271b542"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 25 : OPERATIONAL AMPLIFIERS"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.1: Page number 664\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A=100.0; #Open-circuit voltage gain of differential amplifier\n",
+ "V1=3.25; #Input voltage to terminal 1 in V\n",
+ "V2=3.15; #Input voltage to terminal 2 in V\n",
+ "\n",
+ "#Calculations\n",
+ "V0=A*(V1-V2); #Output voltage in V\n",
+ "\n",
+ "#Results\n",
+ "print(\"The output voltage of the differential amplifier = %dV\"%V0);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output voltage of the differential amplifier = 10V\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.2: Page number 672\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "A_DM=2000.0; #Differential mode voltage gain\n",
+ "A_CM=0.2; #Common mode voltage gain\n",
+ "\n",
+ "#Calculations\n",
+ "CMRR=A_DM/A_CM; #Common mode rejection ratio\n",
+ "CMRR_dB=20*log10(CMRR); #Common mode rejection ratio in dB\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The common mode rejection ratio = %d.\"%CMRR);\n",
+ "print(\"The common mode rejection ratio in decibels= %ddB.\"%CMRR_dB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The common mode rejection ratio = 10000.\n",
+ "The common mode rejection ratio in decibels= 80dB.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.3: Page number 672\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "VD_in=10.0; #Differential mode input in mV\n",
+ "VD_out=1.0; #Output for differential mode input in V\n",
+ "VC_in=10.0; #Common mode input in mV\n",
+ "VC_out=5.0; #Output for common mode input in mV\\\n",
+ "\n",
+ "#Calculations\n",
+ "A_DM=(VD_out*1000)/VD_in; #Differntial mode voltage gain\n",
+ "A_CM=VC_out/VC_in; #Common mode voltage gain\n",
+ "CMRR=A_DM/A_CM; #Common mode rejection ratio\n",
+ "CMRR_dB=20*log10(CMRR); #Common mode rejection ratio in dB\n",
+ "\n",
+ "#Results\n",
+ "print(\"The common mode rejection ratio in decibels= %ddB.\"%CMRR_dB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The common mode rejection ratio in decibels= 46dB.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.4: Page number 672\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_DM=150.0; #Differential mode voltage gain\n",
+ "CMRR_dB=90.0; #Common mode rejection ratio\n",
+ "V1=100.0; #Input voltage for terminal 1 in mV\n",
+ "V2=50.0; #Input voltage for terminal 2 in mV\n",
+ "V_noise=1.0; #Voltage of noise signal in mV\n",
+ "\n",
+ "#Calculation\n",
+ "\n",
+ "#Case(i)\n",
+ "V_out=A_DM*(V1-V2)/1000.0; #Output voltage for differntial mode input, in V\n",
+ "\n",
+ "#Since CMRR_dB=20*log10(differential mode gain/common mode gain),\n",
+ "A_CM=A_DM/pow(10,(CMRR_dB/20)); #Common mode gain\n",
+ "V_OUT_noise=A_CM*(V_noise/1000); #Noise on output in V\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Output voltage =%.1fV\"%V_out);\n",
+ "print(\"Noise on output = %.1fx10^-6V\"%(V_OUT_noise*pow(10,6)));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage =7.5V\n",
+ "Noise on output = 4.7x10^-6V\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.5 : Page number 672-673\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "A_DM=2500.0; #Differential mode voltage gain\n",
+ "CMRR=30000.0; #Common mode rejection ratio\n",
+ "Input_signal=500.0; #Single ended input r.m.s signal in microvolts\n",
+ "Interference=1.0; #Interference signal, in V\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#(i)\n",
+ "A_CM=A_DM/CMRR; #Common mode gain\n",
+ "\n",
+ "#(ii)\n",
+ "CMRR_dB=20*log10(CMRR); #Common mode rejection ratio in decibels\n",
+ "\n",
+ "#(iii)\n",
+ "V_out=A_DM*(Input_signal/pow(10,6)-0); #r.m.s output signal in V\n",
+ "\n",
+ "#(iv)\n",
+ "Interference_out=A_CM*Interference; #r.m.s interference output in V\n",
+ "Interference_out=Interference_out*1000; #r.m.s interference output in mV\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Common mode gain =%.3f\"%A_CM);\n",
+ "print(\"Common mode rejection ratio in decibels=%.1fdB\"%CMRR_dB);\n",
+ "print(\"r.m.s output signal =%.2fV\"%V_out);\n",
+ "print(\"r.m.s interfernce output voltage = %dmV\"%Interference_out);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Common mode gain =0.083\n",
+ "Common mode rejection ratio in decibels=89.5dB\n",
+ "r.m.s output signal =1.25V\n",
+ "r.m.s interfernce output voltage = 83mV\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.6 : Page number 674-675\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12; #Collector supply voltage, V\n",
+ "VEE=12; #Emitter supply voltage, V\n",
+ "RB=10; #Base resistor, k\u03a9\n",
+ "RC2=10; #Collector resistor, k\u03a9\n",
+ "RE=25; #Emitter resistor, k\u03a9\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=100; #Base amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "VE=-VBE; #Emitter voltage, V (Ignoring the base current)\n",
+ "IE=(VEE-VBE)/RE; #Tail current, mA\n",
+ "IE1=IE/2; #Emitter current of 1st transistor, mA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, mA\n",
+ "IC1=IE1; #Collector current(= emitter current) of 1st transistor, mA\n",
+ "IC2=IC1; #Collector current of 2nd transistor, mA\n",
+ "IB1=(IC1/beta)*1000; #Base current of 1st transistor, \u03bcA\n",
+ "IB2=IB1; #Base current of 2nd transistor, \u03bcA\n",
+ "VC1=VCC; #Collector voltage of 1st transistor, V\n",
+ "VC2=VCC-IC2*RC2; #Collector voltage of 2nd transistor, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"VE=%.1fV\"%VE);\n",
+ "print(\"IE=%.3fmA\"%IE);\n",
+ "print(\"IE1=%.3fmA\"%IE1);\n",
+ "print(\"IE2=%.3fmA\"%IE2);\n",
+ "print(\"IC1=%.3fmA\"%IC1);\n",
+ "print(\"IC2=%.3fmA\"%IC2);\n",
+ "print(\"IB1=%.2f\u03bcA\"%IB1);\n",
+ "print(\"IB2=%.2f\u03bcA\"%IB2);\n",
+ "print(\"VC1=%dV\"%VC1);\n",
+ "print(\"VC2=%.1fV\"%VC2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "VE=-0.7V\n",
+ "IE=0.452mA\n",
+ "IE1=0.226mA\n",
+ "IE2=0.226mA\n",
+ "IC1=0.226mA\n",
+ "IC2=0.226mA\n",
+ "IB1=2.26\u03bcA\n",
+ "IB2=2.26\u03bcA\n",
+ "VC1=12V\n",
+ "VC2=9.7V\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.7 : Page number 675\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15; #Collector supply voltage, V\n",
+ "VEE=15; #Emitter supply voltage, V\n",
+ "RB=33; #Base resistor, k\u03a9\n",
+ "RC=15; #Collector resistor, k\u03a9\n",
+ "RE=15; #Emitter resistor, k\u03a9\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "IE_tail=(VEE-VBE)/RE; #Tail current, mA\n",
+ "IE=round(IE_tail/2,3); #Emitter current in each transistor, mA\n",
+ "IC=IE; #Collector current(=emitter current), mA\n",
+ "Vout=VCC-IC*RC; #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output voltage=%.2fV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output voltage=7.85V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.8 : Page number 675\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage, V\n",
+ "VEE=15.0; #Emitter supply voltage, V\n",
+ "RB=33.0; #Base resistor, k\u03a9\n",
+ "RC=15.0; #Collector resistor, k\u03a9\n",
+ "RE=15.0; #Emitter resistor, k\u03a9\n",
+ "VBE=0; #Base-emitter voltage, V\n",
+ "beta_dc_l=90.0; #base current amplification factor for left transistor\n",
+ "beta_dc_r=110.0; #base current amplification factor for right transistor\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "IE_tail=(VEE-VBE)/RE; #Tail current, mA\n",
+ "IE=IE_tail/2; #Emitter current in each transistor, mA\n",
+ "IB1=(IE/beta_dc_l)*1000; #Base current of 1st transistor, \u03bcA\n",
+ "IB2=(IE/beta_dc_r)*1000; #Base current of 2nd transistor, \u03bcA\n",
+ "\n",
+ "#(ii)\n",
+ "VB1=-IB1/1000*RB; #Base voltage of 1st transistor, V\n",
+ "VB2=-IB2/1000*RB; #Base voltage of 1st transistor, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) IB1=%.2f\u03bcA\"%IB1);\n",
+ "print(\" IB2=%.2f\u03bcA\"%IB2);\n",
+ "print(\"(ii) VB1=%.3fV\"%VB1);\n",
+ "print(\" VB2=%.2fV\"%VB2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) IB1=5.56\u03bcA\n",
+ " IB2=4.55\u03bcA\n",
+ "(ii) VB1=-0.183V\n",
+ " VB2=-0.15V\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.9 : Page number 675-676\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage, V\n",
+ "VEE=15.0; #Emitter supply voltage, V\n",
+ "RB=10.0; #Base resistor, k\u03a9\n",
+ "RC1=10.0; #Collector resistor of 1st transistor, k\u03a9\n",
+ "RC2=10.0; #Collector resistor of 2nd transistor, k\u03a9\n",
+ "IE=1.0; #Tail current, mA\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "VE=-VBE; #Emitter voltage, V (Ignoring the base current)\n",
+ "IE1=IE/2.0; #Emitter current of 1st transistor, mA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, mA\n",
+ "IC1=IE1; #Collector current(= emitter current) of 1st transistor, mA\n",
+ "IC2=IE2; #Collector current of 2nd transistor, mA\n",
+ "VC1=VCC-IC1*RC1; #Collector voltage of 1st transistor, V\n",
+ "VC2=VCC-IC2*RC2; #Collector voltage of 2nd transistor, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"VE=%.1fV\"%VE);\n",
+ "print(\"Emitter current in each transistor=%.1fmA.\"%(IE/2.0));\n",
+ "print(\"IC1~IE1=%.1fmA and IC2~IE2=%.1fmA\"%(IE1,IE2));\n",
+ "print(\"VC1=VC2=%dV.\"%VC2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "VE=-0.7V\n",
+ "Emitter current in each transistor=0.5mA.\n",
+ "IC1~IE1=0.5mA and IC2~IE2=0.5mA\n",
+ "VC1=VC2=10V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.10 : Page number 676-677\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage, V\n",
+ "VEE=12.0; #Emitter supply voltage, V\n",
+ "RC2=10.0; #Collector resistor of 2nd transistor, k\u03a9\n",
+ "RE=25.0; #Emitter current, k\u03a9\n",
+ "VBE=-0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "VE=-VBE; #Emitter voltage, V (Ignoring the base current)\n",
+ "IE=(VCC-VE)/RE; #Tail current, mA\n",
+ "IE1=IE/2.0; #Emitter current of 1st transistor, mA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, mA\n",
+ "IC1=IE1; #Collector current(= emitter current) of 1st transistor, mA\n",
+ "IC2=IE2; #Collector current of 2nd transistor, mA\n",
+ "VC1=-VEE; #Collector voltage of 1st transistor, V\n",
+ "VC2=-VEE+IC2*RC2; #Collector voltage of 2nd transistor, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"VE=%.1fV\"%VE);\n",
+ "print(\"Tail current=%.3fmA.\"%IE);\n",
+ "print(\"Emitter current in each transistor=%.3fmA.\"%(IE/2.0));\n",
+ "print(\"IC1~IE1=%.3fmA and IC2~IE2=%.3fmA\"%(IC1,IC2));\n",
+ "print(\"VC1=%dV\"%VC1);\n",
+ "print(\"VC2=%.2fV\"%VC2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "VE=0.7V\n",
+ "Tail current=0.452mA.\n",
+ "Emitter current in each transistor=0.226mA.\n",
+ "IC1~IE1=0.226mA and IC2~IE2=0.226mA\n",
+ "VC1=-12V\n",
+ "VC2=-9.74V\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.11 : Page number 679\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15; #Collector supply voltage, V\n",
+ "VEE=15; #Emitter supply voltage, V\n",
+ "RB=1; #Base resistor, M\u03a9\n",
+ "RC2=1; #Collector resistor, M\u03a9\n",
+ "RE=1; #Emitter resistor, M\u03a9\n",
+ "VBE=0; #Base-emitter voltage, V (Neglected)\n",
+ "beta_dc_l=90.0; #base current amplification factor for left transistor\n",
+ "beta_dc_r=110.0; #base current amplification factor for right transistor\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "IE=(VEE-VBE)/RE; #Tail current, \u03bcA\n",
+ "IE1=IE/2.0; #Emitter current of 1st transistor, \u03bcA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, \u03bcA\n",
+ "IB1=round((IE1/beta_dc_l)*1000,1); #Base current of 1st transistor, nA\n",
+ "IB2=round((IE2/beta_dc_r)*1000,1); #Base current of 2nd transistor, nA\n",
+ "I_in_offset=IB1-IB2; #Input offset current, nA\n",
+ "\n",
+ "#(ii)\n",
+ "I_in_bias=(IB1+IB2)/2; #Input bias current, nA\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The input offset current=%.1fnA\"%I_in_offset);\n",
+ "print(\"(ii) The input bias current=%.1fnA\"%I_in_bias);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The input offset current=15.1nA\n",
+ "(ii) The input bias current=75.8nA\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.12 : Page number 679\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_in_offset=20; #Input offset current, nA\n",
+ "I_in_bias=80; #Input bias current, nA\n",
+ "\n",
+ "#Calculation\n",
+ "IB1=I_in_bias+I_in_offset/2; #Base current in 1st transistor, nA\n",
+ "IB2=I_in_bias-I_in_offset/2; #Base current in 2nd transistor, nA\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The two base currents are: IB1=%dnA and IB2=%dnA.\"%(IB1,IB2));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The two base currents are: IB1=90nA and IB2=70nA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.13 : Page number 679-680\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declration\n",
+ "I_in_offset=20; #Input offset current, nA\n",
+ "I_in_bias=80; #Input bias current, nA\n",
+ "A=150; #Voltage gain\n",
+ "RB=100; #Base resistor, k\u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_io=(I_in_offset*10**-9*RB*1000)*1000; #Input offset voltage, mV\n",
+ "V_out_offset=(A*V_io)/1000; #Output offset voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The input offset voltage=%dmV.\"%V_io);\n",
+ "print(\"The output offset voltage=%.1fV.\"%V_out_offset);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The input offset voltage=2mV.\n",
+ "The output offset voltage=0.3V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.14 : Page number 682\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15; #Collector supply voltage, V\n",
+ "VEE=15; #Emitter supply voltage, V\n",
+ "RE=1; #Emitter resistor, M\u03a9\n",
+ "RC=1; #Collector resistor, M\u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "IE=VEE/RE; #Tail current, \u03bcA\n",
+ "IE1=IE/2.0; #Emitter current of 1st transistor, \u03bcA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, \u03bcA\n",
+ "re=25/IE1; #a.c emitter resistance, k\u03a9\n",
+ "A_DM=RC/(2.0*re); #Differential voltage gain,\n",
+ "\n",
+ "#(i)\n",
+ "vin=1; #Input voltage, V\n",
+ "Vout=A_DM*vin; #Output voltage, V\n",
+ "\n",
+ "print(\"(i) Output voltage=%.2fV.\"%Vout);\n",
+ "\n",
+ "#(ii)\n",
+ "vin=-1; #Input voltage, V\n",
+ "Vout=A_DM*vin; #Output voltage, V;\n",
+ "print(\"(ii) Output voltage=%.2fV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Output voltage=0.15V.\n",
+ "(ii) Output voltage=-0.15V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.15 : Page number 682-683\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12; #Collector supply voltage, V\n",
+ "VEE=12; #Emitter supply voltage, V\n",
+ "RE=100; #Emitter resistor, k\u03a9\n",
+ "RC1=120; #Collector resistor of 1st transistor, k\u03a9\n",
+ "RC2=120; #Collector resistor of 2nd transistor, k\u03a9\n",
+ "beta=220; #Base amplification factor\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calcualtion\n",
+ "IE=((VEE-VBE)/RE)*1000; #Tail current, \u03bcA\n",
+ "IE1=IE/2.0; #Emitter current of 1st transistor, \u03bcA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, \u03bcA\n",
+ "re=(25/IE1)*1000; #a.c emitter resistance, \u03a9\n",
+ "Zin=2*beta*re/1000; #Input impedance, k\u03a9\n",
+ "A_DM=RC1*1000/(2.0*re); #Differential voltage gain,\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The input impedance=%dk\u03a9.\"%Zin);\n",
+ "print(\"(ii) The differential voltage gain=%.0f.\"%A_DM);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The input impedance=194k\u03a9.\n",
+ "(ii) The differential voltage gain=136.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.16: Page number 683-684\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12; #Collector supply voltage, V\n",
+ "VEE=12; #Emitter supply voltage, V\n",
+ "RE=200; #Emitter resistor, k\u03a9\n",
+ "RC=100; #Collector resistor, k\u03a9\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "IE=round((VEE-VBE)/RE,4); #Tail current, mA\n",
+ "IE1=round(IE/2,4); #Emitter current of 1st transistor, mA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, mA\n",
+ "re=round(25/IE1,1); #a.c emitter resistance, \u03a9\n",
+ "A_DM=RC*1000/(2*re); #Differential voltage gain,\n",
+ "\n",
+ "#Result\n",
+ "print(\"Differential voltage gain=%.1f.\"%A_DM);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Differential voltage gain=56.6.\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.17 : Page number 685-686\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "v1=0.5; #Voltage in terminal 1, mV\n",
+ "v2=-0.5; #Voltage in terminal 2, mV\n",
+ "vo=8.0; #Output voltage, V\n",
+ "vo_cm=12.0; #Common mode output, mV\n",
+ "\n",
+ "#Calculation\n",
+ "vin=v1-v2; #Differential input, mV\n",
+ "A_DM=vo/(vin/1000.0); #Differential mode gain,\n",
+ "vin_cm=1; #Common mode input, mV\n",
+ "A_CM=vo_cm/vin_cm; #Common mode gain\n",
+ "CMRR=A_DM/A_CM; #Common mode rejection ratio\n",
+ "CMRR_dB=20*log10(CMRR); #Common mode rejection ratio in dB\n",
+ "\n",
+ "#Result\n",
+ "print(\"Common mode rejection ratio=%.1f.\"%CMRR)\n",
+ "print(\"Common mode rejection ratio in decibel=%.2fdB\"%CMRR_dB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Common mode rejection ratio=666.7.\n",
+ "Common mode rejection ratio in decibel=56.48dB\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.18 : Page number 686\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_DM=200000; #Differential mode gain\n",
+ "CMRR_dB=90; #Common mode rejection ratio, dB\n",
+ "\n",
+ "#Calculation\n",
+ "CMRR=10**(CMRR_dB/20.0); #Common mode rejection ratio\n",
+ "A_CM=A_DM/CMRR; #Common mode gain\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Common mode voltage gain=%.2f.\"%A_CM);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Common mode voltage gain=6.32.\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.19 : Page number 686\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "vin_cm=3.2; #Common input voltage, V\n",
+ "vout=26; #Output voltage, V\n",
+ "A_DM=100; #Open-circuit voltage gain\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "A_CM=vout*10**-3/vin_cm; #Common mode gain\n",
+ "\n",
+ "#(ii)\n",
+ "CMRR_dB=20*log10(A_DM/A_CM); #Common mode rejection ratio, dB\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The Common mode gain=%.4f\"%A_CM);\n",
+ "print(\"(ii) The common mode rejection ratio=%.1fdB.\"%CMRR_dB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The Common mode gain=0.0081\n",
+ "(ii) The common mode rejection ratio=81.8dB.\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.20 : Page number 686-687\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "from math import floor\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=12; #Collector supply voltage, V\n",
+ "VEE=12; #Emitter supply voltage, V\n",
+ "RE=200.0; #Emitter resistor, k\u03a9\n",
+ "RC=100.0; #Collector resistor, k\u03a9\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "A_CM=round(RC/(2*RE),2); #Common mode voltage gain\n",
+ "\n",
+ "#(ii)\n",
+ "IE=round((VEE-VBE)/RE,4); #Tail current, mA\n",
+ "IE1=round(IE/2,4); #Emitter current of 1st transistor, mA\n",
+ "IE2=IE1; #Emitter current of 2nd transistor, mA\n",
+ "re=round(25/IE1,1); #a.c emitter resistance, \u03a9\n",
+ "A_DM=RC*1000/(2*re); #Differential voltage gain,\n",
+ "CMRR_dB=floor(20*log10(A_DM/A_CM)*100)/100; #Common mode rejection ratio, dB\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Common mode gain=%.2f\"%A_CM);\n",
+ "print(\"(ii)Common mode rejection ratio=%.2fdB\"%CMRR_dB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Common mode gain=0.25\n",
+ "(ii)Common mode rejection ratio=47.09dB\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.21 : Page number 691\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log10\n",
+ "\n",
+ "#Variable declaration\n",
+ "ACL=500; #closed loop gain\n",
+ "f_unity=15; #frequency with cloased-loop unity gain, MHz\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "f2=f_unity*1000/500 #Upper frequency of bandwidth,kHz\n",
+ "BW=f2-0; #Bandwidth, kHz\n",
+ "A_CL=f_unity*1000/200; #Maximum value of A_CL when f2=200kHz\n",
+ "A_CL_dB=20*log10(A_CL); #Maximum value of A_CL in decibel\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"f2=%dkHz\"%f2);\n",
+ "print(\"ACL=%d or %.1fdB.\"%(A_CL,A_CL_dB));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "f2=30kHz\n",
+ "ACL=75 or 37.5dB.\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.22 : Page number 691-692\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "GBW=1.5; #Gain-bandwidth, MHz\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) For A_CL=1;\n",
+ "A_CL=1; #Closed loop gain\n",
+ "BW=GBW/A_CL; #Bandwidth, MHz\n",
+ "\n",
+ "print(\"(i) Operating Bandwidth=%.1fMHz.\"%BW);\n",
+ "\n",
+ "#(ii) For A_CL=10;\n",
+ "A_CL=10; #Closed loop gain\n",
+ "BW=(GBW/A_CL)*1000; #Bandwidth, kHz\n",
+ "\n",
+ "print(\"(ii) Operating Bandwidth=%dkHz.\"%BW);\n",
+ "\n",
+ "#(iii) For A_CL=100;\n",
+ "A_CL=100; #Closed loop gain\n",
+ "BW=(GBW/A_CL)*1000; #Bandwidth, kHz\n",
+ "\n",
+ "print(\"(iii) Operating Bandwidth=%dkHz.\"%BW);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Operating Bandwidth=1.5MHz.\n",
+ "(ii) Operating Bandwidth=150kHz.\n",
+ "(iii) Operating Bandwidth=15kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.23 : Page number 692\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "slew_rate=0.5; #Slew rate, V/\u03bcs\n",
+ "V_supply=10; #Supply voltage, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_sat=V_supply-2; #Saturation voltage, V\n",
+ "V_pk=V_sat; #Maximum peak-output voltage, V\n",
+ "f_max=((slew_rate*10**6)/(2*pi*V_pk))/1000; #Maximum operating frequency, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"Maximum operating frequency=%.2fkHz.\"%f_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Maximum operating frequency=9.95kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.24 : Page number 692\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "slew_rate=0.5; #Slew rate, V/\u03bcs\n",
+ "V_pk=100.0; #Peak-output voltage, mV\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "V_pk=V_pk/1000.0; #Peak-output voltage, V\n",
+ "f_max=(slew_rate*10**6/(2*pi*V_pk))/1000.0; #Maximum operating frequency, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"Maximum operating frequency=%.0fkHz\"%f_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Maximum operating frequency=796kHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.25 : Page number 695-696\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_CL=-100; #Closed-loop voltage gain\n",
+ "Ri=2.2; #Input resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, A_CL=-(Rf/Ri)\n",
+ "Rf=-A_CL*Ri; #Feedback resistor, k\u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"Feedback resistor=%dk\u03a9\"%Rf);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Feedback resistor=220k\u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 32
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.26 : Page number 696\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "vin=2.5; #Input voltage, mV\n",
+ "Rf=200; #Feedback resistor, k\u03a9\n",
+ "Ri=2; #Input resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "A_CL=-(Rf/Ri); #Closed-loop voltage gain\n",
+ "vout=A_CL*vin/1000; #Output voltage,V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%.2fV\"%vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=-0.25V\n"
+ ]
+ }
+ ],
+ "prompt_number": 33
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.27 : Page number 696\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Varaiable declaration\n",
+ "Rf=1.0; #Feedback resistor, k\u03a9\n",
+ "Ri=1.0; #Input resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "A_CL=-(Rf/Ri); #Closed-loop voltage gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"Closed-loop voltage gain=%d\"%A_CL);\n",
+ "print(\"Therefore, output will have same amplitude but 180\u00b0 phase inversion.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Closed-loop voltage gain=-1\n",
+ "Therefore, output will have same amplitude but 180\u00b0 phase inversion.\n"
+ ]
+ }
+ ],
+ "prompt_number": 35
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.28 : Page number 696-697\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=40; #Feedback resistor, k\u03a9\n",
+ "Ri=1; #Input resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "A_CL=-(Rf/Ri); #Closed-loop voltage gain\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Closed-loop voltage gain=%d\"%A_CL);\n",
+ "print(\"Supply voltage=\u00b115V, saturation voltage=\u00b113V. Since gain=-40, op-Amp will be driven to saturation.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Closed-loop voltage gain=-40\n",
+ "Supply voltage=\u00b115V, saturation voltage=\u00b113V. Since gain=-40, op-Amp will be driven to saturation.\n"
+ ]
+ }
+ ],
+ "prompt_number": 36
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.29 : Page number 697\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "Rf=100; #Feedback resistor, k\u03a9\n",
+ "Ri=10; #Input resistor, k\u03a9\n",
+ "Vpp=1; #Input peak-peak voltage, V\n",
+ "slew_rate=0.5; #Slew rate, V//\u03bcs\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "A_CL=-(Rf/Ri); #Closed-loop voltage gain\n",
+ "\n",
+ "#(ii)\n",
+ "Zi=Ri; #Input impedance(~ Input resistor), k\u03a9\n",
+ "\n",
+ "#(iii)\n",
+ "Vout=A_CL*Vpp; #Peak-to-peak voltage, V\n",
+ "Vpk=Vout/2; #Peak output voltage, V\n",
+ "f_max=(slew_rate*10**6/(2*pi*abs(Vpk)))/1000; #Maximum operating frequency, kHz\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) A_CL=%d.\"%A_CL);\n",
+ "print(\"(ii) Zi=%dk\u03a9\"%Zi);\n",
+ "print(\"(iii) Maximum operating frequency=%.1fkHz.\"%f_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) A_CL=-10.\n",
+ "(ii) Zi=10k\u03a9\n",
+ "(iii) Maximum operating frequency=15.9kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 37
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.30 : Page number 697\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A_CL=-4; #Closed loop voltage gain\n",
+ "R=[1.0,5.0,10.0,20.0]; #List of available resistors, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "for i in R[:]:\n",
+ " for j in R[:]:\n",
+ " if -(i/j)==A_CL :\n",
+ " print(\"Rf=%dk\u03a9 and Ri=%dk\u03a9.\"%(i,j));\n",
+ " break;\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Rf=20k\u03a9 and Ri=5k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 38
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.31 : Page number 697-698\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=100; #Feedback resistor, k\u03a9\n",
+ "Ri=1; #Input resistor, k\u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "R_source=0; #Source resistor, k\u03a9\n",
+ "A_CL=-Rf/(R_source+Ri); #Closed-loop voltage gain\n",
+ "\n",
+ "print(\"(i) Closed loop voltage gain=%d.\"%A_CL);\n",
+ "\n",
+ "#(ii)\n",
+ "R_source=1; #Source resistor, k\u03a9\n",
+ "A_CL=-Rf/(R_source+Ri); #Closed-loop voltage gain\n",
+ "\n",
+ "print(\"(ii) Closed loop voltage gain=%d.\"%A_CL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Closed loop voltage gain=-100.\n",
+ "(ii) Closed loop voltage gain=-50.\n"
+ ]
+ }
+ ],
+ "prompt_number": 39
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.32 : Page number 699-700\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=240; #Feedback resistor, k\u03a9\n",
+ "Ri=2.4; #Input resistor, k\u03a9\n",
+ "Vin=120; #Input voltage, \u03bcV\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "A_CL=1+(Rf/Ri); #Closed loop voltage gain\n",
+ "Vout=(A_CL*Vin)/1000; #Output voltage, mV\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%.2fmV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=12.12mV\n"
+ ]
+ }
+ ],
+ "prompt_number": 40
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.33 : Page number 700\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=10; #Feedback resistor, k\u03a9\n",
+ "Ri=1; #Input resistor, k\u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "A_CL=1+(Rf/Ri); #Closed loop voltage gain\n",
+ "#(i)\n",
+ "Vin=1; #Input voltage, V\n",
+ "Vout=A_CL*Vin; #Output voltage, V\n",
+ "\n",
+ "print(\"(i) Output voltage=%dV\"%Vout);\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "Vin=-1; #Input voltage, V\n",
+ "Vout=A_CL*Vin; #Output voltage, V\n",
+ "\n",
+ "print(\"(ii) Output voltage=%dV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Output voltage=11V\n",
+ "(ii) Output voltage=-11V\n"
+ ]
+ }
+ ],
+ "prompt_number": 41
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.34 : Page number 700\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=5; #Feedback resistor, k\u03a9\n",
+ "Ri=1; #Input resistor, k\u03a9\n",
+ "Vin_max=1; #Maximum input voltage, V\n",
+ "Vin_min=-1; #Minimum input voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "V_inpp=Vin_max-Vin_min; #Peak-peak input voltage, V\n",
+ "A_CL=1+(Rf/Ri); #Closed loop voltage gain\n",
+ "Vout_pp=A_CL*V_inpp; #Peak-peak output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Peak to peak output voltage=%dV\"%Vout_pp);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Peak to peak output voltage=12V\n"
+ ]
+ }
+ ],
+ "prompt_number": 42
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.35 : Page number 700-701\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "Rf=100; #Feedback resistor, k\u03a9\n",
+ "Ri=10; #Input resistor, k\u03a9\n",
+ "Vpp=1; #Input peak-peak voltage, V\n",
+ "slew_rate=0.5; #Slew rate, V/\u03bcs\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "A_CL=1+(Rf/Ri); #Closed loop voltage gain\n",
+ "\n",
+ "#(ii)\n",
+ "Vout_pp=A_CL*Vpp; #Peak-peak output voltage, V\n",
+ "Vpk=Vout_pp/2.0; #Peak output voltage, V\n",
+ "f_max=((slew_rate*10**6)/(2*pi*Vpk))/1000.0; #Maximum operating frequency, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Closed-loop voltage gain=%d\"%A_CL);\n",
+ "\n",
+ "print(\"(ii) Maximum operating frequency=%.2fkHz\"%f_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Closed-loop voltage gain=11\n",
+ "(ii) Maximum operating frequency=14.47kHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 45
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.36 : Page number 701\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=220; #Feedback resistor, k\u03a9\n",
+ "Ri=3.3; #Input resistor, k\u03a9\n",
+ "unity_gain_BW=3; #Unity gain bandwidth, MHz\n",
+ "\n",
+ "#Calculation\n",
+ "#(i) For non-inverting amplifier\n",
+ "A_CL=1+(Rf/Ri); #Closed loop voltage gain\n",
+ "BW=unity_gain_BW*1000.0/A_CL; #Bandwidth, kHz\n",
+ "\n",
+ "print(\"(i) Bandwidth=%.1fkHz.\"%BW);\n",
+ "\n",
+ "#(ii) For inverting amplifier\n",
+ "Rf=47; #Feedback resistor, k\u03a9\n",
+ "Ri=1; #Input resistor, k\u03a9\n",
+ "A_CL=-(Rf/Ri); #Closed loop voltage gain\n",
+ "BW=unity_gain_BW*1000.0/abs(A_CL); #Bandwidth, kHz\n",
+ "\n",
+ "print(\"(ii) Bandwidth=%.1fkHz.\"%BW);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Bandwidth=44.3kHz.\n",
+ "(ii) Bandwidth=63.8kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 47
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.37 : Page number 701-702\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#(i)\n",
+ "A_CL=1; #Closed loop voltage gain for voltage follower\n",
+ "print(\"(i) For voltage follower A_CL=1.\");\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "slew_rate=0.5; #Slew rate, V/\u03bcs\n",
+ "V_inpp=6; #peak-peak input voltage, V\n",
+ "Vout=A_CL*V_inpp; #Peak-peak output voltage, V\n",
+ "Vpk=Vout/2; #Peak output voltage, V\n",
+ "\n",
+ "f_max=(slew_rate*10**6/(2*pi*Vpk))/1000; #Maximum operating frequency, kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"(ii) The maximum output frequency=%.2fkHz.\"%f_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) For voltage follower A_CL=1.\n",
+ "(ii) The maximum output frequency=26.53kHz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 48
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.38 : Page number 702\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=470.0; #Feedback resistor, k\u03a9\n",
+ "R1=4.3; #Input resistor of 1st op-Amp, k\u03a9\n",
+ "R2=33.0; #Input resistor of 2nd op-Amp, k\u03a9\n",
+ "R3=33.0; #Input resistor of 3rd op-Amp, k\u03a9\n",
+ "Vin=80.0; #Input voltage, \u03bcV.\n",
+ "\n",
+ "#Calculation\n",
+ "A1=1+Rf/R1; #Gain of first op-Amp\n",
+ "A2=-round(Rf/R2,1); #Gain of second op-Amp\n",
+ "A3=-round(Rf/R3,1); #Gain of third op-Amp\n",
+ "A=A1*A2*A3; #Overall gain\n",
+ "Vout=A*Vin*10**-6; #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%.2fV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=1.78V\n"
+ ]
+ }
+ ],
+ "prompt_number": 50
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.39 : Page number 702-703\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "A1=10; #Voltage gain of 1st op-Amp\n",
+ "A2=-18; #Voltage gain of 2nd op-Amp\n",
+ "A3=-27; #Voltage gain of 3rd op-Amp\n",
+ "Rf=270; #Feedback resistor, k\u03a9\n",
+ "Vin=150; #Input voltage, \u03bcV \n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "R1=Rf/(A1-1); #Input resistor of 1st op-Amp, k\u03a9\n",
+ "R2=-Rf/A2; #Input resistr of 2nd op-Amp, k\u03a9\n",
+ "R3=-Rf/A3; #Input resistor of 3rd op-Amp, k\u03a9\n",
+ "\n",
+ "A=A1*A2*A3; #overall gain,\n",
+ "Vout=Vin*10**-6*A; #Output voltage, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"R1=%dk\u03a9, R2=%dk\u03a9 and R3=%dk\u03a9.\"%(R1,R2,R3));\n",
+ "print(\"Output voltage=%.3fV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "R1=30k\u03a9, R2=15k\u03a9 and R3=10k\u03a9.\n",
+ "Output voltage=0.729V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 51
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.40 : Page number 703-704\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=500; #Feedback resistor, k\u03a9\n",
+ "A1=-10; #Gain of 1st op-Amp\n",
+ "A2=-20; #Gain of 2nd op-Amp\n",
+ "A3=-50; #Gain of 3rd op-Amp\n",
+ "\n",
+ "#Calculation\n",
+ "R1=-Rf/A1; #Input resistor of 1st op-Amp, k\u03a9\n",
+ "R2=-Rf/A2; #Input resistor of 2nd op-Amp, k\u03a9\n",
+ "R3=-Rf/A3; #Input resistor of 3rd op-Amp, k\u03a9\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"R1=%dk\u03a9, R2=%dk\u03a9 and R3=%dk\u03a9.\"%(R1,R2,R3));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "R1=50k\u03a9, R2=25k\u03a9 and R3=10k\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 52
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.41 : Page number 705\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Zin=2.0; #Input impedance of op-Amp, M\u03a9\n",
+ "Zout=75.0; #Output impedance of op-Amp, \u03a9\n",
+ "A_OL=200000.0; #Open-loop voltage gain\n",
+ "Rf=220.0; #Feedback resistor, k\u03a9\n",
+ "Ri=10.0; #Input resistor, k\u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "mv=round(Ri/(Ri+Rf),3); #Feedback fraction\n",
+ "Zin_NI=Zin*(1+(A_OL*mv)); #Input impedance, M\u03a9\n",
+ "Zout_NI=Zout/(1+A_OL*mv); #Output impedance, \u03a9\n",
+ "\n",
+ "#(ii)\n",
+ "A_CL=1+Rf/Ri; #Closed loop voltage gain\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The input impedance=%dM\u03a9 and output impedance=%.1e\u03a9.\"%(Zin_NI,Zout_NI));\n",
+ "print(\"(ii) The closed loop voltage gain=%d.\"%A_CL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The input impedance=17202M\u03a9 and output impedance=8.7e-03\u03a9.\n",
+ "(ii) The closed loop voltage gain=23.\n"
+ ]
+ }
+ ],
+ "prompt_number": 54
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.42 : Page number 705-706\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "#For voltage follower,\n",
+ "mv=1.0; #Feedback fraction\n",
+ "A_OL=200000.0; #Open-loop voltage gain\n",
+ "Zin=2.0; #Input impedance of op-Amp, M\u03a9\n",
+ "Zout=75.0; #Output impedance of op-Amp, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "Zin_VF=Zin*(1+(A_OL*mv)); #Input impedance, M\u03a9\n",
+ "Zout_VF=round(round(Zout/(1+A_OL*mv),6),5); #Output impedance, \u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"The input impedance=%dM\u03a9 and output impedance=%.2fe-03\u03a9.\"%(Zin_VF,Zout_VF*1000));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The input impedance=400002M\u03a9 and output impedance=0.38e-03\u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 63
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.43 : Page number 706\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=100; #Feedback resistor, k\u03a9\n",
+ "Ri=1.0; #Input resistor, k\u03a9\n",
+ "Zin=4; #Input impedance of op-Amp, M\u03a9\n",
+ "Zout=50; #Output impedance of op-Amp, \u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "Zin_I=Ri; #Input impedance, k\u03a9\n",
+ "Zout_I=Zout; #Output impedance, \u03a9\n",
+ "A_CL=-(Rf/Ri); #Closed loop voltage gain\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The input impedance=%dk\u03a9 and output impedance=%d\u03a9.\"%(Zin_I,Zout_I));\n",
+ "print(\"Closed-loop voltage gain=%d\"%A_CL);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The input impedance=1k\u03a9 and output impedance=50\u03a9.\n",
+ "Closed-loop voltage gain=-100\n"
+ ]
+ }
+ ],
+ "prompt_number": 65
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.44 : Page number 709\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=10; #Feedback resistor, k\u03a9\n",
+ "Ri=10; #Input resistor, k\u03a9\n",
+ "V1=3; #Input voltage 1st, V\n",
+ "V2=1; #Input voltage 2nd, V\n",
+ "V3=8; #Input voltage 3rd, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Rf=Ri, Vout=-(Rf/Ri)*(V1+V2+V3)= -(V1+V2+V3);\n",
+ "Vout=-(V1+V2+V3); #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%dV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=-12V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 66
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.45 : Page number 709\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=10; #Feedback resistor, k\u03a9\n",
+ "R1=1; #Input resistor for input 1, k\u03a9\n",
+ "R2=1; #Input resistor for input 2, k\u03a9\n",
+ "V1=0.2; #Input voltage 1st, V\n",
+ "V2=0.5; #Input voltage 2nd, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "R=R1; #Input resistor(=R1 or R2), k\u03a9\n",
+ "Vout=-(Rf/R)*(V1+V2); #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%dV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=-7V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 67
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.46 : Page number 709-710\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=1; #Feedback resistor, k\u03a9\n",
+ "Ri=10.0; #Input resistor, k\u03a9\n",
+ "V1=10; #Input voltage 1st, V\n",
+ "V2=8.0; #Input voltage 2nd, V\n",
+ "V3=7.0; #Input voltage 3rd, V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Vout=-(Rf/Ri)*(V1+V2+V3);\n",
+ "Vout=-(Rf/Ri)*(V1+V2+V3); #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%.1fV.\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=-2.5V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 70
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.47 : Page number 710\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V1=0.6; #Input voltage to 1st input resistor, V\n",
+ "V2=-1.4; #Input voltage to 2nd input resistor, V\n",
+ "Rf=200; #Feedback resistor, k\u03a9\n",
+ "R1=400; #Input resistor 1, k\u03a9\n",
+ "R2=100.0; #Input resistor 2, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "Vout=-Rf*(V1/R1 +V2/R2); #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Output voltage=%.1fV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Output voltage=2.5V\n"
+ ]
+ }
+ ],
+ "prompt_number": 71
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.48 : Page number 710-711\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=1.0; #Feedback resistor, k\u03a9\n",
+ "R1=1.0; #Input resistor 1, k\u03a9\n",
+ "R2=2.0; #Input resistor 2, k\u03a9\n",
+ "R3=4.0; #Input resistor 3, k\u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "Rf_R1=Rf/R1; #Ratio of feedback resistor and 1st input resistor\n",
+ "Rf_R2=Rf/R2; #Ratio of feedback resistor and 2nd input resistor\n",
+ "Rf_R3=Rf/R3; #Ratio of feedback resistor and 3rd input resistor\n",
+ "\n",
+ "#(i) First input combination\n",
+ "V1=10; #Input voltage to 1st input resistor, V\n",
+ "V2=0; #Input voltage to 2nd input resistor, V\n",
+ "V3=10; #Input voltage to 3rd input resistor, V\n",
+ "Vout=-(V1*Rf_R1 +V2*Rf_R2 +V3*Rf_R3); #Output voltage, V\n",
+ "print(\"(i) The output voltage=%.1fV\"%Vout);\n",
+ "\n",
+ "#(i) First input combination\n",
+ "V1=0; #Input voltage to 1st input resistor, V\n",
+ "V2=10; #Input voltage to 2nd input resistor, V\n",
+ "V3=10; #Input voltage to 3rd input resistor, V\n",
+ "Vout=-(V1*Rf_R1 +V2*Rf_R2 +V3*Rf_R3); #Output voltage, V\n",
+ "print(\"(ii) The output voltage=%.1fV\"%Vout);\n",
+ "\n",
+ "\n",
+ "#(i) First input combination\n",
+ "V1=10; #Input voltage to 1st input resistor, V\n",
+ "V2=10; #Input voltage to 2nd input resistor, V\n",
+ "V3=10; #Input voltage to 3rd input resistor, V\n",
+ "Vout=-(V1*Rf_R1 +V2*Rf_R2 +V3*Rf_R3); #Output voltage, V\n",
+ "print(\"(iii) The output voltage=%.1fV\"%Vout);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The output voltage=-12.5V\n",
+ "(ii) The output voltage=-7.5V\n",
+ "(iii) The output voltage=-17.5V\n"
+ ]
+ }
+ ],
+ "prompt_number": 72
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.49 : Page number 711\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Rf=330; #Feedback resistor, k\u03a9\n",
+ "R1=33.0; #Input resistor 1, k\u03a9\n",
+ "R2=10.0; #Input resistor 2, k\u03a9\n",
+ "V1_m=50; #Peak voltage of 1st input, mV\n",
+ "V2_m=10; #Peak voltage of 2nd input, mV\n",
+ "\n",
+ "#Calculation\n",
+ "#Since, Vout=-((Rf/R1)*V1 + (Rf/R2)*V2)\n",
+ "print(\"Vout=-[%.1fsin(1000t)+%.2fsin(3000t)]V\"%((V1_m/1000.0)*(Rf/R1),(V2_m/1000.0)*(Rf/R2)));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Vout=-[0.5sin(1000t)+0.33sin(3000t)]V\n"
+ ]
+ }
+ ],
+ "prompt_number": 74
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.50 : Page number 715\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R=100; #Input resistor, k\u03a9\n",
+ "C=10; #Feedback capacitor, \u03bcF\n",
+ "\n",
+ "#Calculation\n",
+ "RC=R*10**3*C*10**-6; #product of input resistance and feedback capacitance, s\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Vo=-1*(1/RC)\u222bvi dt.\");\n",
+ "print(\"=>Vo=-1*(1/%d)\u222bvi dt\"%RC);\n",
+ "print(\"=>Vo=\u222bvi dt\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Vo=-1*(1/RC)\u222bvi dt.\n",
+ "=>Vo=-1*(1/1)\u222bvi dt\n",
+ "=>Vo=\u222bvi dt\n"
+ ]
+ }
+ ],
+ "prompt_number": 75
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.51 : Page number 715-716\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "\n",
+ "#Variable declaration\n",
+ "Rf=100; #Feedback resistor, k\u03a9\n",
+ "C=0.01; #Feedback capacitor, \u03bcF\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "fc=1/(2*pi*Rf*1000*C*10**-6); #Crictical frequency, Hz\n",
+ "\n",
+ "#Result\n",
+ "print(\"The critical frequency=%dHz.\"%fc);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The critical frequency=159Hz.\n"
+ ]
+ }
+ ],
+ "prompt_number": 76
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.52 : Page number 716\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variable declaration\n",
+ "R=10.0; #Input resistor, k\u03a9\n",
+ "C=0.01; #Feedback capacitor, \u03bcF\n",
+ "vin=5; #Input voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "Vout_change_rate=-vin/(R*C); #Rate of change of output voltage, V/\u03bcs \n",
+ "print(\"(i) Vout=-1*(1/RC)\u222bvi dt.\");\n",
+ "print(\" \u0394Vout/dt = -vin/RC = %dmV/\u03bcs.\"%Vout_change_rate);\n",
+ "\n",
+ "#(ii) Plotting the output waveform\n",
+ "vin_plot=[]; #Plotting variable for input waveform, V\n",
+ "dt=100; #time between edges, \u03bcs\n",
+ "for i in range(0,3*dt+1):\n",
+ " if i<dt or i>2*dt :\n",
+ " vin_plot.append(0);\n",
+ " else:\n",
+ " vin_plot.append(5); \n",
+ "p=plot(vin_plot);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,300])\n",
+ "limit.set_ylim([-5,10])\n",
+ "xlabel(\"t(microsecond)\");\n",
+ "ylabel(\"Vin(V)\");\n",
+ "title(\"Input waveform\");\n",
+ "show(p);\n",
+ "\n",
+ " \n",
+ "vout_plot=[]; #Plotting variable for output waveform, V\n",
+ "t=[i for i in range(0,301)]; #Time scale, \u03bcs\n",
+ "for i in t[:] :\n",
+ " if i<dt:\n",
+ " vout_plot.append(0);\n",
+ " elif i>2*dt:\n",
+ " vout_plot.append((Vout_change_rate/1000.0)*dt);\n",
+ " else :\n",
+ " vout_plot.append((-vin_plot[i]/(R*C))/1000*(i-dt));\n",
+ "\n",
+ " \n",
+ "p=plot(vout_plot);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,300])\n",
+ "limit.set_ylim([-5,5]);\n",
+ "xlabel('t(microsecond)');\n",
+ "ylabel(\"Vout(V)\");\n",
+ "title(\"output waveform\");\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Vout=-1*(1/RC)\u222bvi dt.\n",
+ " \u0394Vout/dt = -vin/RC = -50mV/\u03bcs.\n"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYYAAAEZCAYAAACTsIJzAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlYFfX+B/D3sJiiiKCyyCLGoiCrGipoHDWUusklExMU\n99tT97G0ejTt/iq0W2qUXrW6XStQs5KMVDLCJT1Ii3kztMweTIVCFjMhYpPN7+8Pda4TSyjnMMw5\n79fz+HiWYebzPcPMm+935sxIQggBIiKiayzULoCIiLoWBgMRESkwGIiISIHBQERECgwGIiJSYDAQ\nEZECg4GoC/n888/h4+MDW1tbZGRkqF0OmSkGA6nO09MTn376qdGXk5SUhMTERKMvpyOeeeYZPPro\no6isrERMTIza5ZCZYjCQ6iRJgiRJapfRJfz888/w9/e/pZ9tamoycDVkrhgM1KVs3rwZY8aMwZIl\nS+Dg4IDbb78dWVlZ8vs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6fPo2AgIA250HUXlZq\nF0DUHn379kVERAQCAwNx9913w9vbG2fPnoWXl1ez2xj+8fEfewjW1tZIS0vDI488gtraWtjY2GD/\n/v3Npk1KSsK8efMQHByMnj17yjdBWb9+PQ4dOgQLCwsEBATg7rvvhrW1NX744QeMHj0awNUg27Zt\nG/z9/fGPf/wDkZGRsLS0xLBhw5CSkoKNGzdi7ty5SE5OhqOjI1JTU1utHwDuu+8+HDx4EP7+/vDw\n8EB4eLg8zYULF9CjRw/N3wGQug7ej4E0adeuXTh27Biee+45tUtR3bp169CnTx956Iqoo9hjIE2K\njY3FpUuX1C6jS7C3t5cPkhMZAnsMRESkwIPPRESkwGAgIiIFBgMRESkwGIiISIHBQERECv8PcMuj\nSGNftWoAAAAASUVORK5CYII=\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7fdd1397e4d0>"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYYAAAEZCAYAAACTsIJzAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAHyNJREFUeJzt3XtUlHXix/HPoFQqpHhDEfOKCqKAlkqagoprm5ot2opp\nZprHOnXK7XSx9pwo1yitzNzs13q8dNHwpJZpapoKWmmWlzbT1bzgokAXxAumcvv+/vDn/HpUCBiY\nZ2Z4v87xHGbm2ef5fudp580zzzCPwxhjBADA//GzewAAAM9CGAAAFoQBAGBBGAAAFoQBAGBBGAAA\nFoQB8GDjx49Xw4YN1atXL7uHghqEMMBr+Pn56ciRIx67vqq2detWff7558rKytL27dvtHg5qEMIA\nr1LVf4/pyX/feezYMbVu3Vo33HBDhf+3RUVF1TAi1BSEAW61f/9+xcXFKSgoSJGRkVq1apXzsbi4\nOM2fP995e9GiRbrtttskSX379pUkRUVFKTAwUB9++KHS0tIUGhqqlJQUNWnSRG3atNGSJUsqvb4r\ntWrVSrt27ZIkLV68WH5+ftq/f78kaf78+brrrrskSTt27FB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582ZL4A4ePKjI\nyMgy1wGUV227BwCUR6NGjdS7d2916dJFt99+u9q3b6/Dhw+rXbt2V13G8MqfrzxC8Pf319KlS/XI\nI4/o/Pnzqlu3rjZs2HDVssnJybr//vsVFRWlevXqOS+CMnv2bG3evFl+fn6KjIzU7bffLn9/f+3f\nv1+xsbGSLoXs/fffV0REhJ599ln169dPtWrVUrdu3bRgwQLNmTNH48eP18yZM9W0aVMtXLiw1PFL\n0l133aVNmzYpIiJCN910k2699VbnMj/99JPq1Knj9VcAhOfgegzwSh9//LF27typadOm2T0U282a\nNUsNGjRwvnUFuIojBnil4cOHKzc31+5heISgoCDnSXKgKnDEAACw4OQzAMCCMAAALAgDAMCCMAAA\nLAgDAMDifwGSFOcKwPnWKgAAAABJRU5ErkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7fdd137a8390>"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.53 : Page number 716-717\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_supply=15; #Supply voltage, V\n",
+ "R=10; #Input resistor, k\u03a9\n",
+ "C=0.2; #Feedback capacitor, \u03bcF\n",
+ "vin=10; #Input voltage, mV\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "Vs=-V_supply+2; #Saturation voltage, V\n",
+ "print(\"Vout=-1*(1/RC)\u222bvi dt.\");\n",
+ "print(\"Vout=%d*t volts\"%(-vin/(R*C)));\n",
+ "t=Vs/(-vin/(R*C)); #Time required, seconds\n",
+ "print(\"Time required=%.1fseconds.\"%t);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Vout=-1*(1/RC)\u222bvi dt.\n",
+ "Vout=-5*t volts\n",
+ "Time required=2.6seconds.\n"
+ ]
+ }
+ ],
+ "prompt_number": 78
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.54 : Page number 717-718\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R=1; #Feedback resistor, k\u03a9\n",
+ "C=0.1; #Input capacitor, \u03bcF\n",
+ "Vin_change=5; #Change in input voltage, V\n",
+ "t=0.1; #Time taken for change in input voltage, ms\n",
+ "\n",
+ "#Calcualtion\n",
+ "dvi_dt=Vin_change/(t/1000); #Rate of change of input voltage, V/s\n",
+ "RC=R*1000*C*10**-6; #Product of feedback resistance and input capacitance, s\n",
+ "#Since, Vo=-R*C*(dvi/dt);\n",
+ "Vo=-RC*dvi_dt; #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Vo=%dV.\"%Vo);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Vo=-5V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 79
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.55 : Page number 718\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R=10; #Feedback resistor, k\u03a9\n",
+ "C=2.2; #Input capacitor, \u03bcF\n",
+ "Vin_change=10; #Change in input voltage, V\n",
+ "t=0.4; #Time taken for change in input voltage, s\n",
+ "\n",
+ "#Calcualtin\n",
+ "dvi_dt=Vin_change/t; #Rate of change of input voltage, V/s\n",
+ "RC=R*1000*C*10**-6; #Product of feedback resistance and input capacitance, s\n",
+ "#Since, Vo=-R*C*(dvi/dt);\n",
+ "Vo=-RC*dvi_dt; #Output voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Vo=%.2fV.\"%Vo);\n",
+ "print(\"The output voltage stays constant at %.2fV.\"%Vo);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Vo=-0.55V.\n",
+ "The output voltage stays constant at -0.55V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 80
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 25.56 : Page number 718-719\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R=100; #Feedback resistor, k\u03a9\n",
+ "C=10; #Input capacitor, \u03bcF\n",
+ "Vin_change=1; #Change in input voltage, V\n",
+ "t=0.2; #Time taken for change in input voltage, s\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "RC=R*1000*C*10**-6; #Product of feedback resistor and input capacitance, s\n",
+ "#(i)\n",
+ "print(\"vo=-%d*(dvi/dt).\"%RC);\n",
+ "\n",
+ "#(ii)\n",
+ "dvi_dt=Vin_change/t; #Rate of change of input voltage, V\n",
+ "vo=-dvi_dt; #Output voltage, V\n",
+ "print(\"vo=%dV.\"%vo);\n",
+ "\n",
+ "print(\"Therefore, between 0 to 0.2s, the output voltage is constant at %dV.\"%vo);\n",
+ "print(\"For t>0.2s, the input is constant so that output voltage is zero.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "vo=-1*(dvi/dt).\n",
+ "vo=-5V.\n",
+ "Therefore, between 0 to 0.2s, the output voltage is constant at -5V.\n",
+ "For t>0.2s, the input is constant so that output voltage is zero.\n"
+ ]
+ }
+ ],
+ "prompt_number": 82
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter26_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter26_1.ipynb
new file mode 100644
index 00000000..670a61b0
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter26_1.ipynb
@@ -0,0 +1,472 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:a1845801144904256bc26f3ca2e0294eb55dcabb139a523d403624121bc6876a"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "#CHAPTER 26 : DIGITAL ELECTRONICS"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.1 : Page 732"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "d=37; #Given decimal number\n",
+ "\n",
+ "#Calculation\n",
+ "b=int(bin(d)[2:]); #Equivalent Octal number \n",
+ "\n",
+ "#Result\n",
+ "print(\"The equivalent binary number=%s.\"%b);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The equivalent binary number=100101.\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.2 : Page number 733"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "d=23; #Given decimal number\n",
+ "\n",
+ "#Calculation\n",
+ "b=int(bin(d)[2:]); #Equivalent Octal number\n",
+ "\n",
+ "#Result\n",
+ "print(\"The equivalent binary number=%d.\"%b);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The equivalent binary number=10111.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.3 : Page number 733"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given \n",
+ "b=0b110001; #Given binary number\n",
+ "\n",
+ "#Calculation\n",
+ "d=int(b); #Equivalent decimal number\n",
+ "\n",
+ "#Result\n",
+ "print(\"Equivalent decimal number=%d.\"%d);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Equivalent decimal number=49.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.4 : Page number 735"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given \n",
+ "d1=76; #Given decimal number\n",
+ "d2=255; #Given decimal number\n",
+ "d3=372; #Given decimal number\n",
+ "\n",
+ "#Calculation\n",
+ "o1=int(oct(d1)[1:]); #Equivalent octal number\n",
+ "o2=int(oct(d2)[1:]); #Equivalent octal number\n",
+ "o3=int(oct(d3)[1:]); #Equivalent octal number\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Equivalent octal number=%d.\"%o1);\n",
+ "print(\"(ii) Equivalent octal number=%d.\"%o2);\n",
+ "print(\"(iii) Equivalent octal number=%d.\"%o3);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Equivalent octal number=114.\n",
+ "(ii) Equivalent octal number=377.\n",
+ "(iii) Equivalent octal number=564.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.5 : Page number 735"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given \n",
+ "o=24.6; #Given octal number\n",
+ "\n",
+ "#Calculation\n",
+ "o_f=o%1; #Floating part of octal number\n",
+ "o_i=(int)(o-(o%1)); #Integer part of octal number\n",
+ "d=int(str(o_i),8); #Equivalent decimal number\n",
+ "\n",
+ "s=str(o_f); #String value of floating part \n",
+ "i=2\n",
+ "while(i<len(s)):\n",
+ " d=d+int(s[i])*8**-(i-1);\n",
+ " i+=1;\n",
+ "#Result\n",
+ "print(\"Equivalent decimal number=%.2f.\"%d);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Equivalent decimal number=20.75.\n"
+ ]
+ }
+ ],
+ "prompt_number": 64
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.6 : Page number 735"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given \n",
+ "d=177; #Given decimal number\n",
+ "\n",
+ "#Calculation\n",
+ "o=oct(d)[1:]; #Equivalent octal number\n",
+ "\n",
+ "b=\"\";\n",
+ "for i in o:\n",
+ " bo=bin(int(i))[2:]; #Binary of individual octal digit\n",
+ " b=b+((\"0\" if len(bo)==2 else (\"00\" if len(bo)==1 else\"\")) +bo); #Equivalent binary number\n",
+ " \n",
+ "#Result\n",
+ "print(\"Equivalent octal number=%s.\"%o);\n",
+ "print(\"Equivalent binary number=%s.\"%b);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Equivalent octal number=261.\n",
+ "Equivalent binary number=010110001.\n"
+ ]
+ }
+ ],
+ "prompt_number": 63
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.7 : Page number 737"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given \n",
+ "d=541; #Given decimal number\n",
+ "\n",
+ "#Calculation\n",
+ "h=hex(d)[2:]; #Equivalent hexadecimal number\n",
+ "\n",
+ "#Result\n",
+ "print(\"Equivalent hexadecimal number=%s.\"%h);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Equivalent hexadecimal number=21d.\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.8 : Page number 737"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "hex_to_dec={'0':0,'1':1,'2':2,'3':3,'4':4,'5':5,'6':6,'7':7,'8':8,'9':9,'a':10,'b':11,'c':12,'d':13,'e':14,'f':15};\n",
+ " \n",
+ "#Given \n",
+ "d=378; #Given decimal number\n",
+ "\n",
+ "#Calculation\n",
+ "h=hex(d)[2:]; #Equivalent Hexadecimal number\n",
+ "\n",
+ "\n",
+ "b=\"\";\n",
+ "for i in h:\n",
+ " bh=bin(hex_to_dec[i])[2:]; #Binary of individual hexadecimaldigit\n",
+ " b=b+((\"0\" if len(bh)==3 else (\"00\" if len(bh)==2 else (\"000\" if len(bh)==1 else \"\")))+bh); #Equivalent binary number\n",
+ "\n",
+ "#Result\n",
+ "print(\"Equivalent hexadeciaml number=%s.\"%h);\n",
+ "print(\"Equivalent binary number=%s.\"%b);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Equivalent hexadeciaml number=17a.\n",
+ "Equivalent binary number=000101111010.\n"
+ ]
+ }
+ ],
+ "prompt_number": 56
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 26.9 : Page number 737"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "h=0xB2F; #Given hexadecimal number\n",
+ "\n",
+ "#Calculation\n",
+ "o=oct(h)[1:]; #Equivalent octal number\n",
+ "\n",
+ "#Result\n",
+ "print(\"Equivalent octal number=%s.\"%o);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Equivalent octal number=5457.\n"
+ ]
+ }
+ ],
+ "prompt_number": 58
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.10 : Page number 738"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "BCD=\"0100 0000 0010\" #Given BCD string\n",
+ "BCD_split=BCD.split(\" \"); #Splitting th binary string into individual BCD \n",
+ "d=0;\n",
+ "for i in range(len(BCD_split),0,-1):\n",
+ " d+=int(BCD_split[len(BCD_split)-i],2)*10**(i-1);\n",
+ "\n",
+ "#Result\n",
+ "print(\"The equivalent decimal =%d.\"%d);\n",
+ " "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The equivalent decimal =402.\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.11 : Page number 745"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print(\"Boolean Expression obtained from the circuit: \\n Y'=A+B \\n Y=((A+B).A)\");\n",
+ "print(\"Truth Table:\");\n",
+ "print(\"a\\tb\\tY'=A+B\\t Y=Y'.A\");\n",
+ "for b in range(0,2):\n",
+ " for a in range(0,2):\n",
+ " Y_dash=1 if a or b else 0;\n",
+ " Y=1 if Y_dash and a else 0;\n",
+ " print(\"%d\\t%d\\t%d\\t %d\"%(a,b,Y_dash,Y));"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Boolean Expression obtained from the circuit: \n",
+ " Y'=A+B \n",
+ " Y=((A+B).A)\n",
+ "Truth Table:\n",
+ "a\tb\tY'=A+B\t Y=Y'.A\n",
+ "0\t0\t0\t 0\n",
+ "1\t0\t1\t 1\n",
+ "0\t1\t1\t 0\n",
+ "1\t1\t1\t 1\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 26.12 : Page number 745-746"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print(\"Boolean Expression obtained from the circuit: \\n Y'=A'.B \\n Y=Y'+B'\");\n",
+ "print(\"Truth Table:\");\n",
+ "print(\"A\\tB\\tA'\\tY'=A'.B\\t B'\\tY=Y'+B'\");\n",
+ "for b in range(0,2):\n",
+ " for a in range(0,2):\n",
+ " a_dash=1 if not a else 0;\n",
+ " b_dash=1 if not b else 0;\n",
+ " Y_dash=1 if a_dash and b else 0;\n",
+ " Y=1 if Y_dash or b_dash else 0;\n",
+ " print(\"%d\\t%d\\t%d\\t%d\\t %d\\t%d\"%(a,b,a_dash,Y_dash,b_dash,Y));"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Boolean Expression obtained from the circuit: \n",
+ " Y'=A'.B \n",
+ " Y=Y'+B'\n",
+ "Truth Table:\n",
+ "A\tB\tA'\tY'=A'.B\t B'\tY=Y'+B'\n",
+ "0\t0\t1\t0\t 1\t1\n",
+ "1\t0\t0\t0\t 1\t1\n",
+ "0\t1\t1\t1\t 0\t1\n",
+ "1\t1\t0\t0\t 0\t0\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter2_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter2_1.ipynb
new file mode 100644
index 00000000..06a555a6
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter2_1.ipynb
@@ -0,0 +1,125 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:c0ff4f67576afe73a11c06eedd0a50709b7f5831737f83db1cd640098e3e9740"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 2 : ELECTRONIC EMISSION"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.1: Page number 31\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#variable declaration\n",
+ "\n",
+ "from math import exp\n",
+ "from math import pi\n",
+ "\n",
+ "l=5.0; #length of tungsten filament in cm\n",
+ "d=0.01; #diameter of the filament in cm\n",
+ "T=2500.0; #operating temperature in K\n",
+ "A=60.2*pow(10,4); #constant, depending upon the type of thermionic emitter, in amp/m\u00b2/K\u00b2\n",
+ "phi=4.517; #work function of emitter in eV\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "b=round(11600*phi,-1); #constant for a metal, in K\n",
+ "Js=round(A*T*T*exp(-b/T),-2); #Emission current density in amp/m\u00b2\n",
+ "a=pi*(d/100)*(l/100); #Surface area of the cathode in m\u00b2\n",
+ "E_I=Js*a; #Emission current in A\n",
+ "\n",
+ "#Result\n",
+ "print(\"emission current =%.3f A\"%E_I);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "emission current =0.047 A\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.2:Page number 31\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import log\n",
+ "\n",
+ "#Variable declaration\n",
+ "Js=0.1; #Emission current density in amp/cm\u00b2\n",
+ "A=60.2; #Constant depending upon the type of thermionic emitter, in amp/cm\u00b2/K\u00b2\n",
+ "T=1900.0; #Absolute temperature in K\n",
+ "\n",
+ "\n",
+ "#calculations\n",
+ "#Calculating b according to the formula Js=A*T\u00b2*exp(-b/T) for emission current density\n",
+ "b=-T*(log(Js/(A*T*T))); #constant for emitter, in K\n",
+ "phi= round(b/11600,2); # work function in eV\n",
+ "\n",
+ "print (\"Work function of the tungsten wire = %.2f eV\"%phi);\n",
+ "\n",
+ "if(phi==4.52):\n",
+ "\tprint(\"Given sample is pure Tungsten\");\n",
+ "elif(phi!=4.52 and phi>=2.63 and phi<=4.52):\n",
+ "\tprint (\"The sample is not pure Tungsten\");\n",
+ " \n",
+ "#Note : In the text book, the work function has been approximated to 3.56eV, but in the code it calculates as 3.52eV\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Work function of the tungsten wire = 3.52 eV\n",
+ "The sample is not pure Tungsten\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter6_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter6_1.ipynb
new file mode 100644
index 00000000..a6008ee1
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter6_1.ipynb
@@ -0,0 +1,1624 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:3452607f2168b562d941493f83083042eaa5a2d316715f9d9f089ff03d73fdb8"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 6: SEMICONDUCTOR DIODE"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.2, Page number 81"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration \n",
+ "Vf =20; #Peak Input Voltage in V\n",
+ "rf=10; #Forward Resistance in ohms\n",
+ "RL=500.0; #Load Resistance in ohms\n",
+ "V0=0.7; #Potential Barrier Voltage of the diodes in V\n",
+ "\n",
+ "#Calculation\n",
+ "#(1)\n",
+ "If_peak=(Vf-V0)/(rf+RL); #Peak current through the diode in A\n",
+ "If_peak=If_peak*1000; #Peak current through the diode in mA\n",
+ "#(2)\n",
+ "V_out_peak =If_peak * RL/1000 ; #Peak output voltage in V\n",
+ "\n",
+ "#For an Ideal diode\n",
+ "If_peak_ideal=Vf/RL; #Peak current through the ideal diode in A\n",
+ "If_peak_ideal=If_peak_ideal*1000; #Peak current through the ideal diode in mA\n",
+ "\n",
+ "V_out_peak_ideal=If_peak_ideal * RL/1000; # Peak output voltage in case of the ideal diode in V\n",
+ "\n",
+ "#Result\n",
+ "print '(i) Peak current through the diode = %.1f mA '%If_peak;\n",
+ "print '(ii) Peak output voltage = %.1f V'%V_out_peak;\n",
+ "print '(iii) Peak current through the ideal diode = %d mA '%If_peak_ideal;\n",
+ "print '(iv) Peak output voltage in case of the ideal diode = %d V'%V_out_peak_ideal;\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Peak current through the diode = 37.8 mA \n",
+ "(ii) Peak output voltage = 18.9 V\n",
+ "(iii) Peak current through the ideal diode = 40 mA \n",
+ "(iv) Peak output voltage in case of the ideal diode = 20 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.3, Page number 82"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "V =10.0; #Battery voltage in V\n",
+ "R1=50.0; #Resistor 1's resistance in ohms\n",
+ "R2=5.0; #Resistor 2's resistance in ohms\n",
+ "\n",
+ "#Calculation\n",
+ "#Using Thevenin's Theorem to find current in the diode\n",
+ "E0=(R2/(R1+R2))*V; #Thevenin's Voltage in V\n",
+ "R0=(R1*R2)/(R1+R2); #Thevenin's Resistance in ohms\n",
+ "\n",
+ "I0=E0/R0; #Current through the diode in A\n",
+ "I0=I0*1000; #Current through the diode in mA\n",
+ "\n",
+ "#Result\n",
+ "print 'Current through the diode = %d mA '%Io;\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Current through the diode = 200 mA \n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.4, Page number 82-83 "
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "V =10.0; #Battery voltage in V\n",
+ "R0=48.0; #Resistance of the resistor in ohms\n",
+ "Rd=1.0; #Forward resistance of the diodes in ohms\n",
+ "Vd=0.7; #Potential barrier of the diodes in V\n",
+ "#Calculation\n",
+ "V_net=V-Vd-Vd; #Net voltage in the circuit in V\n",
+ "R_net=R0+Rd+Rd #Net resistance of the circuit in ohms\n",
+ "I_net=V_net/R_net; #Net current in the circuit in A\n",
+ "I_net=I_net*1000; #Net current in mA\n",
+ "\n",
+ "#Result\n",
+ "print 'Net current in the circuit = %d mA '%I_net;\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Net current in the circuit = 172 mA \n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.5, Page number 83"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "E1=24; #Voltage of first source in V\n",
+ "E2=4; #Voltage of second source in V\n",
+ "V0=0.7; #Potential barrier of diodes in V\n",
+ "R=2000; #Resistance of the given resistor in ohms\n",
+ "Rd=0; #Forward resistance of the diodes in ohms\n",
+ "\n",
+ "#Calculation\n",
+ "I=(E1-E2-V0)/(R+Rd); #Current in the circuit in A\n",
+ "I=I*1000; #Current in the circuit in mA \n",
+ "\n",
+ "#Result\n",
+ "print 'Current in the circuit = %.2f mA '%I;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Current in the circuit = 9.65 mA \n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.6, Page number 83-84"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "V=20; #Voltage of source in V\n",
+ "V0=0.3; #Potential barrier of Germanium diode in V\n",
+ "V0_Si=0.7; #Potetial barrier of Silicon diode in V \n",
+ "\n",
+ "#Calculation\n",
+ "#As only Ge diode is turned on due to less potential barrier,\n",
+ "VA=V-V0; #Voltage VA acroos resistor of 3k ohms\n",
+ "\n",
+ "#Result\n",
+ "print 'Voltage VA = %.1f mA '%VA;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage VA = 19.7 mA \n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.7, Page number 84"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "V=10; #Voltage of source in V\n",
+ "V0=0.7; #Potetial barrier of Silicon diode in V \n",
+ "# Resistance of all resistors in ohms\n",
+ "R1=2000;\n",
+ "R2=2000;\n",
+ "R3=2000;\n",
+ "\n",
+ "#Calculation\n",
+ "Id=(V-V0)/(R2+2*R3); #Current through the diodes in A\n",
+ "VQ=2*Id*R3; #Voltage VQ across the grounded 2k ohm resistor in V\n",
+ "Id=Id*1000; #Current through the diodes in mA\n",
+ "\n",
+ "#Result\n",
+ "print 'Voltage VQ = %.1f V '%VQ;\n",
+ "print 'Current through the diodes, Id = %.2f mA '%Id;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Voltage VQ = 6.2 V \n",
+ "Current through the diodes, Id = 1.55 mA \n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.8, Page number 84"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "V=15; #Voltage of source in V\n",
+ "V0=0.7; #Potetial barrier of Silicon diode in V \n",
+ "R=500 # Resistance of all resistors in ohms\n",
+ "\n",
+ "#Calculation\n",
+ "I1=(V-V0)/R; #total current in the circuit in A\n",
+ "Id1=I1/2; #current in first diode in A\n",
+ "Id1=Id1*1000; #current in first diode in mA\n",
+ "Id2=Id1 #current in second diode in mA\n",
+ "\n",
+ "#Result\n",
+ "print ('Current in first diode = %.1f mA'%Id1);\n",
+ "print ('Current in second diode = %.1f mA'%Id2);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Current in first diode = 14.3 mA\n",
+ "Current in second diode = 14.3 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.9, Page number 85"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "E=20; #Voltage of source in V\n",
+ "V0_d1=0.7; #Potetial barrier of first Silicon diode in V\n",
+ "V0_d2=0.7; #Potetial barrier of second Silicon diode in V\n",
+ "R1=5600; # Resistance of first resistor in ohms\n",
+ "R2=3300; # Resistance of second resistor in ohms\n",
+ "\n",
+ "#Calculation\n",
+ "I2=V0_d2/R2; #Current I2 through resistor R2 in A\n",
+ "I2=round((I2*1000),3); #Current I2 through resistor R2 in mA\n",
+ "I1=(E-V0_d1-V0_d2)/R1; #Current I1 through resistor R1 in A\n",
+ "I1=round((I1*1000),2); #Current I1 through resistor R1 in mA\n",
+ "I3=I1-I2; #Current I3 through diode D2 in mA\n",
+ "\n",
+ "#Result\n",
+ "print 'Current I1= %.2f mA'%I1;\n",
+ "print 'Current I1= %.3f mA'%I2;\n",
+ "print 'Current I1= %.3f mA'%I3;\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Current I1= 3.32 mA\n",
+ "Current I1= 0.212 mA\n",
+ "Current I1= 3.108 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.10, Page number 85-86"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable Declaration\n",
+ "E=10.0; #Voltage of source in V\n",
+ "V0=0.7; #Potetial barrier of Silicon diode in V\n",
+ "R1=2000; # Resistance of first resistor in ohms\n",
+ "R2=8000; # Resistance of second resistor in ohms\n",
+ "R3=4000; #Resistance of third resistor in ohms\n",
+ "R4=6000; #Resistance of fourth resistor in ohms\n",
+ "\n",
+ "#Calculation\n",
+ "#Assuming the given diode to be reverse bised and calculating voltage across it's terminals\n",
+ "V1=(E/(R1+R2))*R2; #voltage at the P side of the diode, i.e, voltage across R2 resistor,according to voltage divider rule, in V\n",
+ "V2=(E/(R3+R4))*R4; #voltage at the N side of the diode, i.e, voltage across R4 resistor,according to voltage divider rule, in V\n",
+ "\n",
+ "#Result\n",
+ "if((V1-V2)>=V0):\n",
+ " print 'Our assumption was wrong and, the diode is forward biased';\n",
+ "else:\n",
+ " print 'The diode is reverse biased';\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Our assumption was wrong and, the diode is forward biased\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.11, Page number 86"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V=2; #Supply voltage in V\n",
+ "V0=0.7; #Potential barrier voltage of the diode in V \n",
+ "R1=4000.0; #Resistance of first resistor in \u03a9\n",
+ "R2=1000.0; ##Resistance of second resistor in \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#Assuming the diode to be in ON state\n",
+ "I1=((V-V0)/R1)*1000; #Current through resistor R1, in mA\n",
+ "I2=(V0/R2)*1000; #Current through resistor R2, in mA\n",
+ "ID=I1-I2; #Diode current, in mA\n",
+ "\n",
+ "if(ID<0):\n",
+ " #Since the diode current is negative, the diode must be OFF \n",
+ " ID=0; #True value of diode current, mA\n",
+ " \n",
+ "#As the diode is in OFF state it can be replaced by an open ciruit equivalent \n",
+ "VD=V*R2/(R1 +R2); #Voltage across the diode, in V\n",
+ "\n",
+ "#Result\n",
+ "print 'ID =%d mA'%ID;\n",
+ "print 'VD =%.1f V'%VD;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "ID =0 mA\n",
+ "VD =0.4 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.12, Page number 89-90"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "AC_Input_Power=100.0; #Input AC Power in watts\n",
+ "AC_Output_Power=40.0; #Output AC Power in watts\n",
+ "Accepted_Power=50.0; #Power accepted by the half-wave rectifier in watt\n",
+ "\n",
+ "#Calculation\n",
+ "R_eff=(AC_Output_Power/AC_Input_Power)*100; #Rectification efficiency of the half-wave rectifier\n",
+ "Unused_power=AC_Input_Power-Accepted_Power; #Power not used by the half_wave rectifier due to open circuited condition of the diode in watt\n",
+ "Power_dissipated=Accepted_Power-AC_Output_Power; #Power dissipated by the diode watt\n",
+ "\n",
+ "#Result\n",
+ "print 'The rectification efficiency of the half-wave rectifier= %d%% '%R_eff;\n",
+ "\n",
+ "print 'Rest 60%% of the power is the unused power and power dissipated by the diode = %d watts and %d watts' %(Unused_power ,Power_dissipated);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The rectification efficiency of the half-wave rectifier= 40% \n",
+ "Rest 60% of the power is the unused power and power dissipated by the diode = 50 watts and 10 watts\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.13, Page number 90"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "from math import sqrt\n",
+ "#Variable declaration\n",
+ "Vrms=230.0; #AC supply RMS voltage in V\n",
+ "Turns_Ratio=10/1; #turn ratio of the transformer \n",
+ "\n",
+ "#Calculation\n",
+ "Vpm=sqrt(2)*Vrms; #Maximum primary voltage in V\n",
+ "Vsm=Vpm/Turns_Ratio; #Maximum secondary voltage in V\n",
+ "#Case 1\n",
+ "Vdc=Vsm/(round(pi,2)); #Output D.C voltage, which is the average voltage in V\n",
+ "Vdc=round(Vdc,2);\n",
+ "#Case 2\n",
+ "PIV=Vsm; #Peak Inverse Voltage in V\n",
+ "\n",
+ "#Result\n",
+ "print 'The output d.c voltage= %.2f V'%Vdc;\n",
+ "print 'The peak inverse voltage= %.2f V'%PIV;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output d.c voltage= 10.36 V\n",
+ "The peak inverse voltage= 32.53 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.14, Page number 90-91"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "#Variable declaration\n",
+ "rf=20.0; #Internal resistance of the crystal diode in ohms\n",
+ "Vm=50.0; #Maximum applied voltage in V\n",
+ "RL=800.0; #Load Resistance in ohms\n",
+ "\n",
+ "#Calculation\n",
+ "# 1\n",
+ "Im=Vm/(rf+RL); #Maximum current in A\n",
+ "Im=Im*1000; #Maximum current in \n",
+ "Im=round(Im,0);\n",
+ "Idc=Im/pi; #Average voltage in mA\n",
+ "Idc=round(Idc,1);\n",
+ "Irms=Im/2; #RMS value of the current in mA\n",
+ "Irms=round(Irms,1)\n",
+ "\n",
+ "# 2\n",
+ "AC_Input_Power=pow(Irms/1000,2)*(rf+RL); #Input a.c power in watt\n",
+ "\n",
+ "DC_Output_Power=pow(Idc/1000,2)*RL; #Output d.c power in watt\n",
+ "\n",
+ "# 3\n",
+ "DC_Output_Voltage=(Idc/1000)*RL; #Output d.c voltage in V\n",
+ "\n",
+ "# 4\n",
+ "Rectifier_efficiency=(DC_Output_Power/AC_Input_Power)*100; # Efficiency of rectification of the half-wave rectifier\n",
+ "\n",
+ "#Result\n",
+ "print ' i:';\n",
+ "print ' Im = %d mA'%Im;\n",
+ "print ' Idc = %.1f mA'%Idc;\n",
+ "print ' Irms = %.1f mA'%Irms;\n",
+ "print ' ii: ';\n",
+ "print ' a.c input power= %.3f watt'%AC_Input_Power;\n",
+ "print ' d.c output power= %.3f watt'%DC_Output_Power;\n",
+ "print ' iii: ';\n",
+ "print ' d.c output voltage = %.2f volts'%DC_Output_Voltage;\n",
+ "print ' iv: '\n",
+ "print ' Efficiency of rectification = %.1f%%'%Rectifier_efficiency;\n",
+ "\n",
+ " "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " i:\n",
+ " Im = 61 mA\n",
+ " Idc = 19.4 mA\n",
+ " Irms = 30.5 mA\n",
+ " ii: \n",
+ " a.c input power= 0.763 watt\n",
+ " d.c output power= 0.301 watt\n",
+ " iii: \n",
+ " d.c output voltage = 15.52 volts\n",
+ " iv: \n",
+ " Efficiency of rectification = 39.5%\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.15, Page number 91"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "#Variable declaration\n",
+ "Vdc=50.0; #Output d.c voltage in V\n",
+ "rf=25; #Diode resistance in ohm\n",
+ "RL=800; #Load resistance in ohm\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "Vm=(pi*(rf+RL)*Vdc)/RL; #[ Vdc=Vm*RL/(pi*(rf+RL)) ]Maximum value of a.c voltage required to get a volatge of Vdc from the half-wave rectifier, in V\n",
+ "Vm=round(Vm,0); \n",
+ "#Result\n",
+ "print 'The a.c voltage required should have maximum value of = %d V' %Vm;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The a.c voltage required should have maximum value of = 162 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.16, Page number 95"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt \n",
+ "from math import pi\n",
+ "#Variable declaration\n",
+ "rf=20; #Internal resistance of the diodes in ohm\n",
+ "Vrms=50; #RMS value of transformer's secondary voltage from centre tap to each end of secondary\n",
+ "RL=980; #Load resistance in ohm\n",
+ "\n",
+ "#Calculation\n",
+ "Vm=Vrms*sqrt(2); #Maximum a.c voltage in V\n",
+ "Im=Vm/(rf+RL); #Maximum load current in A\n",
+ "Im=Im*1000; #Maximum load current in mA\n",
+ " \n",
+ "# 1:\n",
+ "Idc=2*Im/pi; #Mean load current\n",
+ "\n",
+ "# 2:\n",
+ "Irms=Im/sqrt(2); #RMS value of load current in A\n",
+ "\n",
+ "#Result\n",
+ "print 'i:';\n",
+ "print' The mean load current= %d mA'%Idc;\n",
+ "print 'ii:';\n",
+ "print ' The r.m.s value of the load current = %d mA'%Irms; "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i:\n",
+ " The mean load current= 45 mA\n",
+ "ii:\n",
+ " The r.m.s value of the load current = 50 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.17, Page number 95-96"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt \n",
+ "#Variable declaration\n",
+ "RL=100; #Load resistance in ohm \n",
+ "rf=0; #Internal resistance of the diodes in ohm\n",
+ "Turns_ratio=5/1; #Primary to secondary turns ratio of transformer \n",
+ "P_Vrms=230; #R.M.S value of voltage in primary winding in V\n",
+ "S_Vrms=P_Vrms/Turns_ratio; #R.M.S value of voltage in secondary winding in V\n",
+ "S_Vm=S_Vrms*sqrt(2); #Maximum voltage across secondary winding in V\n",
+ "Vm=S_Vm/2; #Maximum voltage across half seconfdary winding in V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "# 1:\n",
+ "Idc=2*Vm/(pi*RL); #Average current in A\n",
+ "Vdc=Idc*RL; #d.c output voltage in V\n",
+ "\n",
+ "# 2:\n",
+ "PIV=S_Vm; #Peak Invers Voltage(= Maximum secondary voltage) in V\n",
+ "\n",
+ "# 3:\n",
+ "Pac=pow(Vm/(RL*sqrt(2)),2)*(rf+RL); #a.c input power in watt\n",
+ "Pdc=(pow(Idc,2)*RL); #d.c output power in watt\n",
+ "R_eff=(Pdc/Pac)*100; #Rectification efficiency\n",
+ "R_eff=round(R_eff,1);\n",
+ "\n",
+ "#Result\n",
+ "print 'i:';\n",
+ "print ' The d.c output voltage= %.1f V'%Vdc;\n",
+ "print 'ii:';\n",
+ "print ' The peak inverse voltage= %d V'%PIV;\n",
+ "print 'iii:';\n",
+ "print ' Rectification efficiency= %.1f%%'%R_eff;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i:\n",
+ " The d.c output voltage= 20.7 V\n",
+ "ii:\n",
+ " The peak inverse voltage= 65 V\n",
+ "iii:\n",
+ " Rectification efficiency= 81.1%\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "NOTE: The value of rectification efficiency is calculated as 81.2% in the textbook using the formula 0.812/(1 + (rf/RL)), but by calculating using the correct values in the formula we get 81.1%."
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.18, Page number 96-97"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt \n",
+ "#Variable declaration\n",
+ "fin=50; #frequency of input ac source in Hz\n",
+ "RL=200; #Load resistance in ohm\n",
+ "Turns_ratio=4/1; #Transformers turns ratio, primary to secondary.\n",
+ "P_Vrms=230.0; #R.M.S value of voltage in primary winding in V\n",
+ "S_Vrms=P_Vrms/Turns_ratio #R.M.S value of voltage in secondary winding in V\n",
+ "Vm=S_Vrms*sqrt(2); #Maximum voltage across secondary winding in V\n",
+ "\n",
+ "#Calculation\n",
+ "# 1:\n",
+ "Idc=2*Vm/(pi*RL); # Average current in A\n",
+ "Vdc=Idc*RL; #Output d.c voltage in V\n",
+ "Vdc=round(Vdc,0);\n",
+ "# 2:\n",
+ "PIV= Vm; #Peak Inverse Voltage(= Maximum volutage across secondary winding) in V\n",
+ "\n",
+ "# 3:\n",
+ "fout=2*fin; #Output frequency in Hz\n",
+ "\n",
+ "#Result\n",
+ "print 'i:';\n",
+ "print ' The d.c output voltage = %d V' %Vdc;\n",
+ "print 'ii:';\n",
+ "print ' The peak inverse voltage = %.1f V'%PIV;\n",
+ "print 'iii:';\n",
+ "print ' The output frequency = %d Hz'%fout;\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i:\n",
+ " The d.c output voltage = 52 V\n",
+ "ii:\n",
+ " The peak inverse voltage = 81.3 V\n",
+ "iii:\n",
+ " The output frequency = 100 Hz\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.19, Page number 97"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "RL=100.0; #Load Resistance in ohm\n",
+ "Turns_ratio=5/1; #Primary to secondary turns ratio of the transformer\n",
+ "Vin=230.0; #R.M.S value of input voltage in V\n",
+ "fin=50; #Input frequency in Hz\n",
+ "\n",
+ "#Calculation\n",
+ "Vs_rms=Vin/Turns_ratio; #R.M.S value of the voltage in secondary winding, in v\n",
+ "Vs_max=Vs_rms*sqrt(2); #Maximum voltage across secondary, in V\n",
+ "\n",
+ "# (i)\n",
+ "#Case i: Centre-tap circuit\n",
+ "Vm=Vs_max/2; #Maximum voltage across half secondary winding, in V \n",
+ "Vdc=2*Vm*RL/(pi*RL); #DC output voltage, in V \n",
+ "print 'The d.c output voltage for the centre-tap circuit = %.1f V'%Vdc;\n",
+ "\n",
+ "#Case ii:\n",
+ "Vm=Vs_max; #Maximum voltage across secondary, in V\n",
+ "Vdc=2*Vm*RL/(pi*RL); #DC output voltage, in V \n",
+ "print 'The d.c output voltage for the bridge circuit = %.1f V'%Vdc; \n",
+ "\n",
+ "# ii:\n",
+ "#Case i: Centre-tap circuit\n",
+ "Turns_ratio=5/1; #Turns ratio of the transformer\n",
+ "Vs_rms=Vin/Turns_ratio; #R.M.S value of the secondary voltage in V\n",
+ "Vs_max=Vs_rms*sqrt(2); #Maximum voltage across the secondary in V\n",
+ "Vm=Vs_max/2; #Maximum voltage across half of the secondary in V\n",
+ "PIV=2*Vm; #Peak Inverse Voltage in V\n",
+ "print 'PIV in case of centre-tap circuit = %d V'%PIV;\n",
+ "\n",
+ "#Case ii: Bridge circuit\n",
+ "Turns_ratio=10/1; #Turns ratio of the transformer\n",
+ "Vs_rms=Vin/Turns_ratio; #R.M.S value of the secondary voltage in V\n",
+ "Vs_max=Vs_rms*sqrt(2); #Maximum voltage across the secondary in V\n",
+ "PIV=Vm; #Peak Inverse Voltage in V\n",
+ "print 'PIV in case of bridge circuit = %.1f V'%PIV;\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The d.c output voltage for the centre-tap circuit = 20.7 V\n",
+ "The d.c output voltage for the bridge circuit = 41.4 V\n",
+ "PIV in case of centre-tap circuit = 65 V\n",
+ "PIV in case of bridge circuit = 32.5 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 46
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.20, Page number 98"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "from math import sqrt\n",
+ "#Variable declaration\n",
+ "rf=1; #forward resistance of diodes of the rectifier in ohm\n",
+ "RL=480; #Load resistance in ohm\n",
+ "Vrms=240.0; #a.c supply voltage in V\n",
+ "Vm=Vrms*sqrt(2); #Maximum a.c voltage in V \n",
+ "\n",
+ "#Calculation\n",
+ "# 1:\n",
+ "Rt=2*rf+RL; #Total circuit resistance at any instance in ohm\n",
+ "Im=Vm/Rt; #Maximum load current in A\n",
+ "Idc=2*Im/pi; #Mean load current in A\n",
+ "\n",
+ "# 2:\n",
+ "Irms=Im/2; #R.M.S value of current in A\n",
+ "P=pow(Irms,2)*rf; #Power dissipated in each diode in watt\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print 'i:';\n",
+ "print ' Mean load current = %.2f A'%Idc;\n",
+ "print 'ii:';\n",
+ "print ' Power dissipated in each diode= %.3f W'%P;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i:\n",
+ " Mean load current = 0.45 A\n",
+ "ii:\n",
+ " Power dissipated in each diode= 0.124 W\n"
+ ]
+ }
+ ],
+ "prompt_number": 39
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "NOTE: The value of power dissipated is approximately 0.124 W , but in the textbook it is approximated as 0.123W."
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.21, Page number 98-99"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt,pi\n",
+ "#Variable declaration\n",
+ "RL=12000; #Load resistance in ohm\n",
+ "V0=0.7; #Potential barrier voltage of diodes in V\n",
+ "Vrms=12; #R.M.S value of input a.c voltage in V\n",
+ "Vs_pk=Vrms*sqrt(2); #Peak secondary voltage in V\n",
+ "\n",
+ "#Calculation\n",
+ "# 1:\n",
+ "Vout_pk=Vs_pk-(2*V0); #Peak output voltage in V\n",
+ "Vav=2*Vout_pk/pi; #Average output voltage in V\n",
+ "Vav=round(Vav,2);\n",
+ "\n",
+ "# 2:\n",
+ "Iav=Vav/RL; #Average output current in A\n",
+ "Iav=Iav*pow(10,6); #Average output current in \u03bcA\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print 'i:';\n",
+ "print ' Average output voltage=%.2f V'%Vav;\n",
+ "print 'ii:';\n",
+ "print ' Average output current=%.1f \u03bcA'%Iav;\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i:\n",
+ " Average output voltage=9.91 V\n",
+ "ii:\n",
+ " Average output current=825.8 \u03bcA\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.22, Page number 102"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vdc_A=10; #Supply voltage of A in V\n",
+ "Vdc_B=25; #Supply voltage of B in V\n",
+ "Vac_rms_a=0.5; #Ripples in power supply A in V\n",
+ "Vac_rms_b=0.001; #Ripples in power supply B in V\n",
+ "\n",
+ "#Calculation\n",
+ "#For power supply A\n",
+ "ripple_factor_A=Vac_rms_a/Vdc_A; #Ripple factor of power supply A\n",
+ "\n",
+ "#For power supply B\n",
+ "ripple_factor_B=Vac_rms_b/Vdc_B; #Ripple factor of power supply B\n",
+ "\n",
+ "#Result\n",
+ "if(ripple_factor_A<ripple_factor_B):\n",
+ " print 'Power supply A is better';\n",
+ "else :\n",
+ " print 'Power supply B is better';"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Power supply B is better\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.23, Page number 105-106"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "#Variable declaration\n",
+ "RL=2200; #Load resistance in ohm\n",
+ "C=50*pow(10,-6); #Capacitance of the capacitor used in filter circuit in F\n",
+ "V0=0.7; #Potential barrier voltage of the diodes of the rectifier in V\n",
+ "Vrms=115.0; #R.M.S value of input a.c voltage in V \n",
+ "fin=60; #Frequency of input a.c voltage in Hz\n",
+ "Turns_ratio=10/1; #Primary to secondary, turns ratio of the transformer \n",
+ "\n",
+ "#Calculation\n",
+ "Vp_prim=Vrms*sqrt(2); #Peak primary voltage in V\n",
+ "Vp_sec=Vp_prim/Turns_ratio; #Peak secondary voltage in V\n",
+ "Vp_in= Vp_sec - 2*V0; #Peak full wave rectified voltage at the filter input in V\n",
+ "f=2*fin; #Output frequency in Hz\n",
+ "Vdc=Vp_in*(1-(1/(2*f*RL*C))); #Output d.c voltage in V\n",
+ "\n",
+ "#Result\n",
+ "print 'The output d.c voltage is = %.1f V'%Vdc;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output d.c voltage is = 14.3 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.24, Page number 106"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "#Variable declaration\n",
+ "R=25; #d.c resistance of the choke in ohm\n",
+ "RL=750; #Load resistance in ohm\n",
+ "Vm=25.7; #Maximum value of the pulsating output from the rectifier in V\n",
+ "\n",
+ "#Calculation\n",
+ "V_dc=2*Vm/pi; #d.c component of the pulsating output in V\n",
+ "V_dc=round(V_dc,1);\n",
+ "V_dc_out=(V_dc*RL)/(R+RL); #Output d.c voltage in V\n",
+ "V_dc_out=round(V_dc_out,1);\n",
+ "\n",
+ "#Result\n",
+ "print ' The output d.c voltage accross the load resistance is = %.1f V'%V_dc_out;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " The output d.c voltage accross the load resistance is = 15.9 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.25, Page number 113-114"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ei=120.0; #Input Voltage in V\n",
+ "Vz=50.0; #Zener Voltage in V\n",
+ "R=5000.0; #Resistance of the series resistor in ohm\n",
+ "RL=10000.0; #Load resistance in ohm\n",
+ "\n",
+ "#Calculation\n",
+ "V=Ei*RL/(R+RL); #Voltage across the open circuit if the zener diode is removed\n",
+ "if(V>Vz):\n",
+ " #Zener diode is in ON state\n",
+ " # i:\n",
+ " Output_voltage=Vz; #Voltage across load resistance, in V\n",
+ " #ii:\n",
+ " Voltage_R=Ei-Vz; #Voltage across the series resistance R, in V\n",
+ " #iii:\n",
+ " IL=Vz/RL; #Load current through RL in A\n",
+ " IL=IL*1000; #Load current through RL in mA\n",
+ " I=Voltage_R/R; #Current through the series resistance in A\n",
+ " I=I*1000; #Current through the series resistance in mA\n",
+ " Iz=I-IL; #Applying Kirchhoff's first law, Zener current in mA\n",
+ " \n",
+ " #Result\n",
+ " print 'i) The output voltage across the load resistance RL = %d V'%Output_voltage;\n",
+ " print 'ii) The voltage drop across the series resistance R = %d V'%Voltage_R;\n",
+ " print 'iii) The current through the zener diode = %d mA'%Iz;\n",
+ " "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i) The output voltage across the load resistance RL = 50 V\n",
+ "ii) The voltage drop across the series resistance R = 70 V\n",
+ "iii) The current through the zener diode = 9 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.26, Page number 114-115"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Max_V=120.0; #Maximum input voltage in V\n",
+ "Min_V=80.0; #Minimum input voltage in V\n",
+ "R=5000.0; #Series resistance in ohm\n",
+ "RL=10000.0; #Load resistance in ohm\n",
+ "Vz=50.0; #Zener voltage in V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#Case i: Maximum zener current\n",
+ "#Zener current will be maximum when the input voltage is maximum\n",
+ "V_R_max=Max_V-Vz; #Voltage across series resistance R, in V\n",
+ "I_max=V_R_max/R; #Current through series resistance R, in A\n",
+ "I_max=I_max*1000; #Current through series resistance R, in mA\n",
+ "IL_max=Vz/RL; #Load current in A\n",
+ "IL_max=IL_max*1000; #Load current in mA\n",
+ "Iz_max=I_max-IL_max; #Applying Kirchhoff's first law, Zener current in mA;\n",
+ "\n",
+ "#Case ii: Minimum zener current\n",
+ "#The zener will conduct minimum current when the input voltage is minimum\n",
+ "V_R_min=Min_V-Vz; #Voltage across series resistance R, in V\n",
+ "I_min=V_R_min/R; #Current through series resistance R, in A\n",
+ "I_min=I_min*1000; #Current through series resistance R, in mA\n",
+ "IL_min=Vz/RL; #Load current in A\n",
+ "IL_min=IL_min*1000; #Load current in mA\n",
+ "Iz_min=I_min-IL_min; #Applying Kirchhoff's first law, Zener current in mA\n",
+ "\n",
+ "#Result\n",
+ "print 'Case i: ';\n",
+ "print 'Maximum zener current = %d mA'%Iz_max;\n",
+ "print 'Case ii: ';\n",
+ "print 'Minimum zener current = %d mA'%Iz_min;\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Case i: \n",
+ "Maximum zener current = 9 mA\n",
+ "Case ii: \n",
+ "Minimum zener current = 1 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.27, Page number 115"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ei=12; #Input voltage in V\n",
+ "Vz=7.2; #Zener voltage in V\n",
+ "E0=Vz; #Voltage to be maintained across the load in V\n",
+ "IL_max=0.1; #Maximum load current in A\n",
+ "IL_min=0.012; #Minimum load current in A\n",
+ "Iz_min=0.01; #Minimum zener current in A\n",
+ "\n",
+ "#Calculation\n",
+ "#When the load current is maximum at minimum value of RL, the zener current is minimum and, as the load current decreases due to increase in value of RL\n",
+ "R=(Ei-E0)/(Iz_min+IL_max); #The value of series resistance R to maintain a voltage=E0 across load, in ohm\n",
+ "\n",
+ "#Result\n",
+ "print 'The minimum value of series resistance R to maintain a constant value of 7.2 V is = %.1f \u03a9'%R;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The minimum value of series resistance R to maintain a constant value of 7.2 V is = 43.6 \u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "NOTE: The actual value of R is 43.636363 (recurring) but, in the textbook the value of R is wrongly approximated 43.5 \u03a9"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.28, Page number 115"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ei_min=22; #Minimum input voltage in V\n",
+ "Ei_max=28; #Maximum input voltage in V\n",
+ "Vz=18; #Zener voltage in V\n",
+ "E0=Vz; #Constant voltage maintained across the load resistance in V\n",
+ "Iz_min=0.2; #Minimum zener current in A\n",
+ "Iz_max=2; #Maximum zener current in A\n",
+ "RL=18; #Load resistance in \u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "IL=Vz/RL; #Constant value of load current in A\n",
+ "#When the input voltage is minimum, the zener current will be minimum\n",
+ "R=(Ei_min-E0)/(Iz_min+IL) #The value of series resistance so that the voltage E0 across RL remains constant\n",
+ "\n",
+ "print 'The value of series resistance R, to maintain constant voltage E0 across RL = %.2f \u03a9.'%R;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of series resistance R, to maintain constant voltage E0 across RL = 3.33 \u03a9.\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.29, Page number 116 "
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=10 #Zener voltage in V\n",
+ "Ei_min=13; #Minimum input voltage in V\n",
+ "Ei_max=16; #Maximum input voltage in V\n",
+ "Iz_min=0.015; #Minimum zener current in A\n",
+ "IL_min=0.01; #Minimum load current in A \n",
+ "IL_max=0.085; #Maximum load curremt in A\n",
+ "E0=Vz; #Constant voltage to be maintained in V \n",
+ "\n",
+ "#Calculation\n",
+ "#The zener current will be minimum when the input voltage will be minimum and at that time the load current will be maximum\n",
+ "R=(Ei_min-E0)/(Iz_min+IL_max); #The value of series resistance R to maintain a constant voltage across load\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print 'The value of series resistance to maintain a constant voltage across the load resistance is = %d \u03a9'%R;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of series resistance to maintain a constant voltage across the load resistance is = 30 \u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.30, Page number 116"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Iz=0.2; #Current rating of each zener in A\n",
+ "Vz=15; #Voltage rating of each zener in V\n",
+ "Ei=45; #Input voltage in V\n",
+ "\n",
+ "#Calculation\n",
+ "# i: Regulated output voltage across the two zener diodes \n",
+ "E0=2*Vz; # V\n",
+ "\n",
+ "# ii: Value of series resistance \n",
+ "R=(Ei-E0)/Iz; # \u03a9\n",
+ "\n",
+ "#Result\n",
+ "print 'i) The regulated output voltage = %d V'%E0;\n",
+ "print 'ii) The value of the series resistance = %d \u03a9'%R;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i) The regulated output voltage = 30 V\n",
+ "ii) The value of the series resistance = 75 \u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.31, Page number 116-117"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Vz=10; #Voltage rating of each zener in V\n",
+ "Iz=1; #Current rating of each zener in A\n",
+ "Ei=45; #Input unregulated voltage in V\n",
+ "\n",
+ "#Calculation\n",
+ "#Regulated output voltage across the three zener diodes\n",
+ "E0=3*Vz; # V\n",
+ "\n",
+ "#Value of series resistance to obtain a 30V regulated output voltage\n",
+ "R=(Ei-E0)/Iz; # \u03a9\n",
+ "\n",
+ "#Result\n",
+ "print 'Value of series resistance to obtain a 30V regulated output voltage = %d \u03a9'%R;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Value of series resistance to obtain a 30V regulated output voltage = 15 \u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.32, Page number 117"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#variable declaration\n",
+ "RL=2000.0; #Load resistance in \u03a9\n",
+ "R=200.0; #Series resistance in \u03a9\n",
+ "Iz=0.025; #Zener current rating in A\n",
+ "E0=30.0; #Output regulated voltage in V \n",
+ "\n",
+ "#Calculation\n",
+ "#Minimum input voltage will be required when Iz=0 A, and at this condition\n",
+ "IL=E0/RL; #Load current during Iz=0, in A\n",
+ "I=IL; #According to Kirchhoff's law, total current, in A\n",
+ "Ei_min=E0+(I*R); #Minimum input voltage in V\n",
+ "\n",
+ "#The maximum input voltage required will be when Iz=0.025 A, and at that condition \n",
+ "I=IL+Iz; #According to Kirchhoff's law, total current, in A\n",
+ "Ei_max=E0+(I*R); #maximum input voltage in V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print 'The required range of input voltage is from %d V to %d V'%(Ei_min,Ei_max); \n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required range of input voltage is from 33 V to 38 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.33, Page number 117-118"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ei=16; #Unregulated input voltage in V\n",
+ "E0=12; #Output regulated voltage in V\n",
+ "IL_min=0; #Minimum load current in A\n",
+ "IL_max=0.2; #Maximum load current in A\n",
+ "Iz_min=0; #Minimum zener current in A\n",
+ "Iz_max=0.2; #Maximum zener current in A\n",
+ "\n",
+ "#Calculation\n",
+ "#As the regulated voltage required across the load is 12V\n",
+ "Vz=E0; #Voltage rating of zener diode in V\n",
+ "V_R=Ei-E0; #Constant Voltage that should remain across series resistance \n",
+ "#The minimum zener current will occur when the curent in the load in maximum\n",
+ "R=V_R/(Iz_min+IL_max); #Series resistance in \u03a9\n",
+ "\n",
+ "Max_power_rating=Vz*Iz_max; #Maximum power rating of zener diode in W\n",
+ "\n",
+ "#Result\n",
+ "print 'The regulator is designed using a Seris resistance of %d \u03a9 and a zener diode of zener voltage %d V'%(R,Vz);\n",
+ "print 'The maximum power rating of the zener diode is = %.1f W '%Max_power_rating;"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The regulator is designed using a Seris resistance of 20 \u03a9 and a zener diode of zener voltage 12 V\n",
+ "The maximum power rating of the zener diode is = 2.4 W \n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.34, Page number 118"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V=12; #Source voltage in V\n",
+ "R=1000; #Series resistance in \u03a9\n",
+ "RL=5000; #Load resistance in \u03a9\n",
+ "Vz=6; #Voltage rating of zener in V\n",
+ "\n",
+ "#Calculation\n",
+ "#Case i: zener is working properly\n",
+ "#The output voltage across the load will be equal to the zener voltage.\n",
+ "V0=Vz; # V\n",
+ "\n",
+ "#Result\n",
+ "print 'Case i: Output voltage when zener is working properly is %d V'%V0;\n",
+ "\n",
+ "#Case ii: zener is shorted\n",
+ "#As the zener is shorted, the potential difference across the load will be zero\n",
+ "V0=0; #V\n",
+ "\n",
+ "#Result\n",
+ "print 'Case ii: Output voltage when zener is short circuited is %d V'%V0;\n",
+ " \n",
+ "#Case iii: zener is open circuited\n",
+ "#If the zener is open circuited, the total voltage will drop across R and RL according to the voltage divider rule\n",
+ "V0=V*RL/(R+RL); #V\n",
+ "\n",
+ "#Result\n",
+ "print 'Case iii: Output voltage when zener is open circuited is %d V'%V0;\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Case i: Output voltage when zener is working properly is 6 V\n",
+ "Case ii: Output voltage when zener is short circuited is 0 V\n",
+ "Case iii: Output voltage when zener is open circuited is 10 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter7_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter7_1.ipynb
new file mode 100644
index 00000000..537a179e
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter7_1.ipynb
@@ -0,0 +1,212 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:e210474f5c4fc6668f4c7b5af2adf833a1c7f62577017a980ab8d11cd8ce2886"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 7 : SPECIAL-PURPOSE DIODES"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.1 : Page number 127-128\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_S=10.0; #Supply voltage in V\n",
+ "V_D=1.6; #Forward voltage drop of LED, in V\n",
+ "I_F=20.0; #Required limited current through LED, in mA\n",
+ "\n",
+ "#Calculations\n",
+ "R_S=(V_S-V_D)/(I_F/1000); #Series resistor required to limit the current through the LED, in \u2126\n",
+ "\n",
+ "#Result \n",
+ "print(\"The value of series resistor required to limit the current through the LED = %d \u2126.\"%R_S);\n",
+ " \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of series resistor required to limit the current through the LED = 420 \u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.2: Page number 128"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_S=15.0; #Supply voltage in V\n",
+ "V_D=2.0; #Forward voltage drop of LED, in V\n",
+ "R_S=2200.0; #Series resistor required to limit the current through the LED, in \u2126\n",
+ "\n",
+ "#Calculations\n",
+ "I_F=((V_S-V_D)/R_S)*1000; #Required limited current through LED, in mA\n",
+ "\n",
+ "#Result \n",
+ "print(\"The current through the LED in the circuit = %.2f mA\"%I_F);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The current through the LED in the circuit = 5.91 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.3: Page number 132-133"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Ir=50.0; #Dark current as observed from the current Illumination curve, in mA \n",
+ "V_R=10.0; #Reverse voltage in V\n",
+ "\n",
+ "#Calculation\n",
+ "R_R=V_R/(Ir/pow(10,6)); #Dark Resistance in \u2126\n",
+ "\n",
+ "#Result\n",
+ "print(\"The dark resistance is=%d k\u2126\"%(R_R/1000));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The dark resistance is=200 k\u2126\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.4: Page number 133"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "E=2.5; #Illumination in mW/cm\u00b2\n",
+ "m=37.4; #sensitivity of the photodiode in \ud835\udf07A/mW/cm\u00b2\n",
+ "\n",
+ "#Calculations\n",
+ "I_R=m*E; #Reverse current in \ud835\udf07A\n",
+ "\n",
+ "#Result\n",
+ "print(\"The reverese current in the photodiode = %.1f \ud835\udf07A\"%I_R);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The reverese current in the photodiode = 93.5 \ud835\udf07A\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.5: Page number 137"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import pi\n",
+ "from math import sqrt\t\n",
+ "#Variable declaration\n",
+ "L=1.0; #Inductance of the inductor in mH\n",
+ "C=100.0; #Capacitance of the varactor in pF\n",
+ "\n",
+ "#Result\n",
+ "f_r=1/(2*pi*sqrt(L*pow(10,-3)*C*pow(10,-12))); #Resonant frequency of the circuit in Hz\n",
+ "f_r=f_r/1000; #Resonant frequency of the circuit in kHz\n",
+ "\n",
+ "#Result\n",
+ "print(\"The resonant frequency of the circuit = %.1f kHz\"%f_r);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The resonant frequency of the circuit = 503.3 kHz\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter8_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter8_1.ipynb
new file mode 100644
index 00000000..4afe0858
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter8_1.ipynb
@@ -0,0 +1,1851 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:9c13bdd66a3dbb3eae04903205b69bc52bf35e6dadf8b1b3ade1bab68394ae3b"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.1: Page number 147-148\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "Signal=500.0; #Signal voltage in V\n",
+ "Rin=20.0; #Input resistance in \u03a9 \n",
+ "Rout=100.0; #Output resistance in \u03a9\n",
+ "R_C=1000.0; #Collector load in \u03a9\n",
+ "alpha_ac=1.0; #current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "I_E=(Signal/1000)/Rin; \t#Input current in mA\n",
+ "I_C=I_E*alpha_ac; #Output current in mA\n",
+ "Vout=I_C*R_C; #Output voltage in V \n",
+ "Av=Vout/(Signal/1000); #Voltage amplification \n",
+ "\n",
+ "#Result\n",
+ "print(\"The voltage amplification = %d. \"%Av);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage amplification = 50. \n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.2: Page number 150\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_E=1; #Emitter curent in mA\n",
+ "I_C=0.95; #Collector current in mA\n",
+ "\n",
+ "#Calculation\n",
+ "I_B=I_E-I_C; #Base current in mA\n",
+ "\n",
+ "#Result \n",
+ "print(\"The base current = %.2f mA \"%I_B);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The base current = 0.05 mA \n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 8.3: Page number 150\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#variable declaration\n",
+ "alpha=0.9; #Current amplification factor\n",
+ "I_E=1; #Emitter current in mA\n",
+ "\n",
+ "#Calculation\n",
+ "I_C=alpha*I_E; #Collector current in mA\n",
+ "I_B=I_E-I_C; #Base current in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The base current =%.1f mA\"%I_B);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The base current =0.1 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.4: Page number 150\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_C=0.95;\t\t\t#Collector current in mA\n",
+ "I_B=0.05;\t\t\t#Base current in mA\n",
+ "\n",
+ "#Calculation\n",
+ "I_E=I_B+I_C; #Emitter current in mA\n",
+ "alpha=I_C/I_E; #Current amplification factor \n",
+ "\n",
+ "#Result\n",
+ "print(\"The current amplification factor = %.2f .\"%alpha);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The current amplification factor = 0.95 .\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.5: Page number 150\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_E=1; #Emitter current in mA\n",
+ "I_CBO=50.0; #Collector current with emitter circuit open, in microAmp\n",
+ "alpha=0.92; #Current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "I_C=alpha*I_E + (I_CBO/1000); #Total collector current in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The total collector current = %.2f mA.\"%I_C);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total collector current = 0.97 mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.6: Page number 150-151\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "alpha=0.95; #Current amplification factor\n",
+ "Rc=2.0; #Resistor connected to the collector, in kilo ohm\n",
+ "V_Rc=2.0; #Voltage drop across the resistor connected to the collector in V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "I_C=V_Rc/Rc; #Collector current in mA\n",
+ "I_E=I_C/alpha; #Emitter current in mA\n",
+ "I_B=I_E-I_C; #Base current in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The base current = %.2f mA\"%I_B); \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The base current = 0.05 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.7: Page number 151\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_EE=8.0; #Supply voltage at the emitter in V\n",
+ "V_CC=18.0; #Supply voltage at the collector in V\n",
+ "V_BE=0.7; #Base to emitter voltage in V\n",
+ "R_E=1.5; #Emitter resistance in \u03a9\n",
+ "R_C=1.2; #Collector resistance in \u03a9\n",
+ "\n",
+ "#Calculations\n",
+ "I_E=(V_EE-V_BE)/R_E; #Emitter current in mA\n",
+ "I_C=I_E; #Collector current in mA (approximately equal to emitter current)\n",
+ "V_CB=V_CC-(I_C*R_C); #Collector to base voltage in V\n",
+ "\n",
+ "#Result\n",
+ "print(\"The collector current =%.2f mA\"%I_C);\n",
+ "print(\"The collector to base voltage = %.2f V\"%V_CB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The collector current =4.87 mA\n",
+ "The collector to base voltage = 12.16 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.8:Page number 155\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Function for calculating beta from alpha\n",
+ "def calc_beta(a): #a is the value of alpha\n",
+ "\treturn(a/(1-a));\n",
+ "\n",
+ "#Case (i)\n",
+ "alpha=0.9; #current amplification factor\n",
+ "beta=calc_beta(alpha);\t\t#Base current amplification factor \n",
+ "print(\"(i) Value of beta =%d\"%beta );\t\t\t\t\t\t\t\t\t\n",
+ "\n",
+ "#Case (ii)\n",
+ "alpha=0.98; #current amplification factor\n",
+ "beta=calc_beta(alpha); #Base current amplification factor\n",
+ "print(\"(ii) Value of beta =%.0f\"%beta );\n",
+ "\n",
+ "\n",
+ "#Case (iii)\n",
+ "alpha=0.99; #current amplification factor\n",
+ "beta=calc_beta(alpha); #Base current amplification factor \n",
+ "print(\"(iii) Value of beta =%.0f\"%beta );\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Value of beta =9\n",
+ "(ii) Value of beta =49\n",
+ "(iii) Value of beta =99\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.9: Page number 155\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "I_B=20.0; #Base current in microAmp\n",
+ "\n",
+ "#Calculation\n",
+ "I_B=I_B/1000; #Base current in mA\n",
+ "I_C=beta*I_B; #Collector current in mA\n",
+ "I_E=I_B+I_C; #Emitter current in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The emitter curent = %.2f mA\"%I_E);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The emitter curent = 1.02 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.10: Page number 155\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_B=240.0; #Base current in microAmp\n",
+ "I_E=12; #Emitter current in mA\n",
+ "beta=49.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "alpha=beta/(1+beta); #current amplification factor \n",
+ "I_C_alpha=alpha*I_E; #Collector current in mA calculated using alpha\n",
+ "I_C_beta=beta*(I_B/1000); #Collector current in mA calculated using beta\n",
+ "\n",
+ "#Results\n",
+ "print(\"alpha=%.2f.\"%alpha);\n",
+ "print(\"Collector current determined using alpha =%.2f mA\"%I_C_alpha);\n",
+ "print(\"Collector current determined using beta =%.2f mA\"%I_C_beta);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "alpha=0.98.\n",
+ "Collector current determined using alpha =11.76 mA\n",
+ "Collector current determined using beta =11.76 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.11: Page number 156\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "beta=45.0; #Base current amplification factor\n",
+ "R_C=1.0; #Resistance of the collector resistance in k\u03a9\n",
+ "V_R_C=1.0; #Voltage drop across the collector resistance in V\n",
+ "\n",
+ "#Calculation\n",
+ "I_C=V_R_C/R_C; #Collector current in mA\n",
+ "I_B=I_C/beta; #Base current in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"The base current =%.3f mA\"%I_B);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The base current =0.022 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.12: Page number 156\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=8.0; #Collector supply voltage in V\n",
+ "R_C=800.0; #Resistance of the collector resistance in \u03a9\n",
+ "V_R_C=0.5; #Voltage drop across collector resistance in V\n",
+ "alpha=0.96; #current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "V_CE=V_CC-V_R_C; #Collector to emitter voltage in V\n",
+ "I_C=V_R_C/R_C; #Collector current in A\n",
+ "I_C=I_C*1000; #Collector current in mA\n",
+ "beta=alpha/(1-alpha); #Base current amplification factor\n",
+ "I_B=I_C/beta; #Base current in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Collector to emitter voltage = %.1f V\"%V_CE);\n",
+ "print(\"Base current= %.3f mA\"%I_B);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector to emitter voltage = 7.5 V\n",
+ "Base current= 0.026 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.13: Page number 156-157\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=5; \t#Collector supply voltage in V\n",
+ "I_CBO=0.2; \t#Leakage current at collector base junction with emitter open, in \u03bcA\n",
+ "I_CEO=20.0; \t#Leakage current with base open, in \u03bcA\n",
+ "I_C=1.0; #Collector current in mA\n",
+ "I_C=I_C*1000; \t#Collector current in \u03bcA\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "alpha=1-(I_CBO/I_CEO);\t\t#current amplification factor\n",
+ "I_E=(I_C-I_CBO)/alpha; #Emitter current in \u03bcA\n",
+ "I_E=round(I_E,-1);\n",
+ "I_B=I_E-I_C; #Base current in \u03bcA\n",
+ "I_B=round(I_B,-1);\n",
+ "\n",
+ "#Result\n",
+ "print(\"Current amplification factor = %.2f \"%alpha);\n",
+ "print(\"The emitter curent =%d \u03bcA \"%I_E);\n",
+ "print(\"The base curent =%d \u03bcA \"%I_B);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Current amplification factor = 0.99 \n",
+ "The emitter curent =1010 \u03bcA \n",
+ "The base curent =10 \u03bcA \n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.14: Page number 157\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_CEO=300.0; #Leakage current in common emitter configuration, in \u03bcA\n",
+ "beta=120.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "alpha=beta/(1+beta); #Current amplification factor\n",
+ "alpha=round(alpha,3);\n",
+ "I_CBO=(1-alpha)*I_CEO; #Leakage current in common base configuration, in \u03bcA\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Vale of I_CBO= %.1f \u03bcA\"%I_CBO);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Vale of I_CBO= 2.4 \u03bcA\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.15: Page number 157\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_B=20.0; #Base current in \u03bcA\n",
+ "I_C=2.0; #Collector current in mA\n",
+ "beta=80.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "I_CEO=I_C-(beta*I_B/1000); #Leakage current with base open, in mA \n",
+ "alpha=beta/(beta+1); #Current amplification factor\n",
+ "alpha=round(alpha,3);\n",
+ "I_CBO=(1-alpha)*I_CEO; #Leakage current with emitter open, in mA\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Value of I_CBO=%.4f mA\"%I_CBO);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Value of I_CBO=0.0048 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.17: Page number 158\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "beta=150.0; \t#Base current amplification factor\n",
+ "R_B=10.0; \t#Base resistance in kilo ohm\n",
+ "R_C=100.0; \t#Collector resistance in kilo ohm\n",
+ "V_CC=10.0; #Collector supply voltage in V\n",
+ "V_BB=5.0; #Base supply voltage in V\n",
+ "V_BE=0.7; #Base to emitter voltage in V\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "I_B=(V_BB-V_BE)/R_B; #Base current in mA\n",
+ "I_C=beta*I_B; #Collector current in mA\n",
+ "V_CE=V_CC - (I_C/1000)*R_C; #Collector to emitter voltage in V\n",
+ "V_CB=V_CE-V_BE; #Collector to base voltage in V\n",
+ "\n",
+ "\n",
+ "#Result \n",
+ "print(\"Collector to base voltage, V_CB= %.2f V\"%V_CB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector to base voltage, V_CB= 2.85 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.18: Page number158-159\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_B=68.0; #Base current in \u03bcA\n",
+ "I_E=30.0; #Emitter current in mA\n",
+ "beta=440.0;\t #Base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "alpha=beta/(beta + 1); #current amplification factor\n",
+ "I_C_alpha=alpha*I_E;\t\t#Collector current using alpha rating, in mA\n",
+ "I_C_beta=beta*(I_B/1000.0); #Collector current using beta rating, in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Collector current determined using alpha rating =%.2f mA\"%I_C_alpha);\n",
+ "print(\"Collector current determined using beta rating =%.2f mA\"%I_C_beta);\n",
+ "\n",
+ "#Note: In the textbook, the collector current obtained from beta rating is approximated to 29.93 mA\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector current determined using alpha rating =29.93 mA\n",
+ "Collector current determined using beta rating =29.92 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.19: Page number 159\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "I_C_max=500.0; #Maximum collector current in mA\n",
+ "beta_max=300.0; #Maximum base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "I_B_max=I_C_max/beta_max; #Maximum base current in mA\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"The maximum allowable value of base current = %.2f mA\"%I_B_max);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum allowable value of base current = 1.67 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.22 : Page number 167-168"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=12.5; #Collector supply voltage, V\n",
+ "RC=2.5; #Collector resistor, k\u03a9\n",
+ "\n",
+ "#Calculation\n",
+ "#VCE=VCC-IC*RC\n",
+ "#For calculating VCE, IC=0\n",
+ "IC=0; #Collector current for maximum Collector-emitter voltage, mA\n",
+ "VCE_max=VCC-IC*RC; #Maximum collector-emitter voltage, V\n",
+ "\n",
+ "#For calculating VCE, IC=0\n",
+ "VCE=0; #Collector emitter voltage for maximum collector current, V\n",
+ "IC_max=(VCC-VCE)/RC; #Maximum collector current, mA\n",
+ "\n",
+ "\n",
+ "#Plotting of d.c load line\n",
+ "VCE_plot=[0,VCE_max]; #Plotting variable for VCE\n",
+ "IC_plot=[IC_max,0]; #Plotting variable for IC\n",
+ "p=plot(VCE_plot,IC_plot);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,15])\n",
+ "limit.set_ylim([0,6])\n",
+ "xlabel('VCE(V)');\n",
+ "ylabel('IC(mA)');\n",
+ "title('d.c load line');\n",
+ "plt.grid();\n",
+ "show(p);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXUAAAEZCAYAAABoy7XpAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XtUlHX+B/D3EHYUTdEEvAwIeeWmg6KuHMlRE4vQTUGT\ntgso1VFzpWy3e7nu8VJpiu62bZs2dVzFLDfNyFJjXFeXYwmES+2SG7hcvOKVvHB7fn/wYxRlhhlm\nnsv3mffrHE7nmYH5vnlOfPj65pkZgyRJEoiISBd81A5ARESew6FORKQjHOpERDrCoU5EpCMc6kRE\nOsKhTkSkIxzqpGlpaWl45ZVX3HqMsrIy+Pj4oLGx0UOprjObzVi/fn2r9y1evBiPPPIIAOB///sf\n7rjjDvAKYpKbr9oBiBwxGAwwGAxqx7DLUb4bbw8JCcGlS5eUikVejDt10jxRd7ei5iaxcaiTphQU\nFGD48OHo2rUrZs2ahatXr9r93MbGRixbtgwDBgxA165dERsbi4qKijbXqKqqwtSpU3HnnXdi4MCB\neO+992z3HTp0CGPGjEH37t3Rp08fLFiwAHV1dbb7d+/ejSFDhsDf3x8LFiyAJElODe+bKyCz2YxX\nX30VY8eORdeuXTF58mRUV1fbPj8vLw9xcXHo3r07TCYT9u3b1+YaRACHOmlIbW0tHnjgATz22GM4\nd+4cZsyYgU8++cRuvbFq1SpkZ2fjiy++wMWLF/H+++/Dz8+vzXVmzZqFkJAQHD9+HB9//DFefPFF\n5ObmAgB8fX2RlZWF6upq/POf/8TevXvx9ttvAwDOnDmD5ORkLFu2DNXV1ejfvz8OHDjQ7npo8+bN\nsFgsOHXqFGpra7Fy5UoAQGV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HG\nG2/gX//6F9LT0xX7PoluxqFOupSamnrL65pv2bIFqampSEpKwvz581FSUoLDhw9j3rx5OH36NAwG\nA+6++24UFBTYPiZOnAig6VUBk5OT4ePjc8tjNzY24pNPPkFqaiqioqJQUVHR4rWNiJTEoU66lJyc\njM8//xz19fUAYHsVxR9//BFxcXG4//77bZ87btw4REZGOnwVvU2bNuGXv/wlgKZfGFu2bLHd9/e/\n/x39+vWzvZz0lClTNPdGGeQ9ONRJl3r06IFRo0YhJycHAJCdnY2ZM2eiuLgYw4cPt/t1+/fvb1G/\nlJaWora2Fj/99BNCQkIAAFFRUfDx8UFRUZHtsW98GdjY2Fjs379fxu+OyD4OddKtG2uSLVu2OPX6\n2/Hx8S3ql7CwMJw5cwb+/v6tPnZDQwO2b9+OGTNm2O4LCAjQ/LtikX5xqJNuTZ06FXv37kVBQQEu\nX76MmJihLsulAAABOUlEQVQYREZG4vDhwy49TqdOnXD16tUWt82aNQsfffQR9uzZg6FDhyIgIMB2\n39WrV9GpUyePfA9EruJQJ93q0qULxo8fj/T0dNsu/aGHHsLBgwdttQzQ1IkXFxfbfZzu3bujoaEB\ntbW1ttvuuusu9OzZE88///wt/wIoKSlBVFSUh78bIudwqJOupaam4siRI0hNTQUAdOzYETt37sS6\ndeswaNAgREZG4p133kFAQAAMBsMtnfq2bdsANL2T/c09eWpqKv7zn/9g+vTpLW7Pzc1FUlKSMt8g\n0U34eupETigoKMDq1avbfPeoa9euwWw248CBA8K84TfpC/+vI3JCTEwMxo8fj8bGRoefV15ejtdf\nf50DnVTDnToRkY5wO0FEpCMc6kREOsKhTkSkIxzqREQ6wqFORKQj/wfxISNkMYU3cgAAAABJRU5E\nrkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f2eadbe6710>"
+ ]
+ }
+ ],
+ "prompt_number": 41
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.23 : Page number 168"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage, V\n",
+ "RC=6.0; #Collector resistor, k\u03a9\n",
+ "IB=20.0; #Zero signal base current, \u03bcA\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "#VCE=VCC-IC*RC\n",
+ "#For calculating VCE, IC=0\n",
+ "IC=0; #Collector current for maximum Collector-emitter voltage, mA\n",
+ "VCE_max=VCC-IC*RC; #Maximum collector-emitter voltage, V\n",
+ "\n",
+ "#For calculating VCE, IC=0\n",
+ "VCE=0; #Collector emitter voltage for maximum collector current, V\n",
+ "IC_max=(VCC-VCE)/RC; #Maximum collector current, mA\n",
+ "\n",
+ "\n",
+ "#Plotting of d.c load line\n",
+ "VCE_plot=[0,VCE_max]; #Plotting variable for VCE\n",
+ "IC_plot=[IC_max,0]; #Plotting variable for IC\n",
+ "p=plot(VCE_plot,IC_plot);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,15])\n",
+ "limit.set_ylim([0,5])\n",
+ "xlabel('VCE(V)');\n",
+ "ylabel('IC(mA)');\n",
+ "title('d.c load line');\n",
+ "plt.grid();\n",
+ "show(p);\n",
+ "\n",
+ "#Calculating Q-point\n",
+ "IC=beta*(IB/1000); #Collector current, mA\n",
+ "VCE=VCC-IC*RC; #Collector emitter voltage, V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Operating point: IC=%dmA and VCE=%dV.\"%(IC,VCE));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXUAAAEZCAYAAABoy7XpAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAHmdJREFUeJzt3XlQlPcdBvBnERyvIB6AICBEJXIpKOrIeCwajSVqFdCA\n9YIYZ9RYSdomaTK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R/PbbbxETE4Onn37a9LXTpk1DWFiY2bvo\n7d27Fz/+8Y8B3P+DsW/fPtNjf/3rXzFs2DDT7aTnzp2ruQ/KIOfBoU4OaeDAgZgwYQLy8vIAADk5\nOVi0aBGKi4sxduzYTr/v1KlT7eqXsrIyNDU14b///S8CAgIAAOHh4XBxcUFRUZHpuR+8DWx0dDRO\nnTol409H1DkOdXJYD9Yk+/bts+j+21OmTGlXvwQFBeHWrVvw8PDo8LmNRiNyc3OxcOFC02Oenp6a\n/1Qsclwc6uSw5s2bh5MnT+LChQuor69HVFQUwsLCcO7cOauep3fv3mhoaGi3LykpCZ9++ilOnDiB\n0aNHw9PT0/RYQ0MDevfubZefgchaHOrksPr164fY2FikpKSYztIXL16MM2fOmGoZ4H4nXlxc3Onz\nDBgwAEajEU1NTaZ9jz/+OAYPHoxXXnnlkf8CKCkpQXh4uJ1/GiLLcKiTQ0tOTsalS5eQnJwMAOjV\nqxcOHTqEXbt2ITg4GGFhYfjtb38LT09P6HS6Rzr1AwcOALj/SfYP9+TJycn497//jfj4+Hb78/Pz\nMWfOHGV+QKKH8H7qRBa4cOECtm/f3uWnRzU2NkKv1+P06dPCfOA3ORb+v47IAlFRUYiNjUVra6vZ\nrzMYDNi8eTMHOqmGZ+pERA6EpxNERA6EQ52IyIFwqBMRORAOdSIiB8KhTkTkQP4PTEiMVfQcO/gA\nAAAASUVORK5CYII=\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f8947e0f0d0>"
+ ]
+ },
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point: IC=1mA and VCE=6V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.24 : Page number 168"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "RC=4.0; #Collector load, k\u03a9\n",
+ "IC_Q=1.0; #Quiescent current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "VCC=10; #Collector supply voltage, V\n",
+ "VCE=VCC-IC*RC; #Collector emitter voltage, V\n",
+ "\n",
+ "print(\"(i) Operating point: VCE=%dV and IC=%dmA.\"%(VCE,IC) );\n",
+ "\n",
+ "#(ii)\n",
+ "RC=5.0; #Collector load, k\u03a9\n",
+ "VCE=VCC-IC*RC; #Collector emitter voltage, V\n",
+ "print(\"(ii) Operating point: VCE=%dV and IC=%dmA.\"%(VCE,IC) );\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Operating point: VCE=6V and IC=1mA.\n",
+ "(ii) Operating point: VCE=5V and IC=1mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##Example 8.25 : Page number 168-169"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector supply voltage, V\n",
+ "VBB=10.0; #Base supply voltage, V\n",
+ "RC=330.0; #Collector resistor, \u03a9\n",
+ "RB=47.0; #Base resistoe, k\u03a9\n",
+ "beta=200.0; #Base current amplification factor\n",
+ "VBE=0.7; #Base -emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#VBB-IB*RB-VBE=0\n",
+ "IB=round(((VBB-VBE)/RB)*1000,0); #Base current, \u03bcA\n",
+ "IC=beta*IB/1000; #Collector current, mA\n",
+ "VCE=VCC-IC*(RC/1000); #Collector-emitter voltage, V\n",
+ "\n",
+ "print(\"Operating point: IC=%.1fmA and VCE=%.2fV.\"%(IC,VCE));\n",
+ "\n",
+ "#For d.c load line\n",
+ "#VCE=VCC-IC*RC\n",
+ "#For calculating VCE, IC=0\n",
+ "IC=0; #Collector current for maximum Collector-emitter voltage, mA\n",
+ "VCE_max=VCC-IC*RC; #Maximum collector-emitter voltage, V\n",
+ "\n",
+ "#For calculating VCE, IC=0\n",
+ "VCE=0; #Collector emitter voltage for maximum collector current, V\n",
+ "IC_max=(VCC-VCE)/(RC/1000.0); #Maximum collector current, mA\n",
+ "\n",
+ "\n",
+ "#Plotting of d.c load line\n",
+ "VCE_plot=[0,VCE_max]; #Plotting variable for VCE\n",
+ "IC_plot=[IC_max,0]; #Plotting variable for IC\n",
+ "p=plot(VCE_plot,IC_plot);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,25])\n",
+ "limit.set_ylim([0,65])\n",
+ "xlabel('VCE(V)');\n",
+ "ylabel('IC(mA)');\n",
+ "title('d.c load line');\n",
+ "plt.grid();\n",
+ "show(p);\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point: IC=39.6mA and VCE=6.93V.\n"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAYEAAAEZCAYAAABxbJkKAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XtcVPW6x/HPIJaaF8QLaKiYShqoYHjNC6hQmZmKolRu\nNK19Mit3e2+lm1l7Z1haafddJnbxujWlvJTanjLNNNNjmUaexFCRVKC8ZCjM+WNtmVAhGBnWzKzv\n+/Xydc6aYWYentaeh/X8fuv3szkcDgciImJJfmYHICIi5lEREBGxMBUBERELUxEQEbEwFQEREQtT\nERARsTAVAfFKo0eP5tFHH72k98jMzMTPz4+ioqJKisopJiaGOXPmXPS5qVOnMmrUKAB+/PFH6tSp\ng2Zqi1n8zQ5AxBU2mw2bzWZ2GKUqK77fP968eXOOHz9eVWGJXEBXAuK1vPWvZ2+NW3yTioB4he3b\nt9OpUyfq1q3LyJEjOX36dKk/W1RUxLRp02jdujV169YlOjqaAwcO/OFnHDp0iEGDBtG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VALCUpKYmFCxeWeGzRokUkJSUxcOBA7rnn\nHjIyMti2bRvjx4/nyJEj2Gw2evfuzfbt24v/9evXD4A333yThIQE/Pz8LnjvoqIili5dSlJSEhER\nERw4cKDE2lginkBFQCwlISGBlStXcvbsWcBYgvfQoUN8//339OjRg5tuuqn4Z/v06UN4eHiZa7PP\nnz+fW265BTAKzKJFi4qf+/TTT2nRokXx8ug333zzBQVIxGwqAmIpgYGBdOnShVWrVgGwcOFCEhMT\n2bVrF506dSr1dRs2bCjRDtq3bx8FBQX88MMPNG/eHICIiAj8/PzYuXNn8Xvfeuutxe8RHR2t5cDF\n46gIiOX8vm2zaNGiEl/UpenVq1eJdlDLli05evQoAQEBF33vwsJCVqxYwfDhw4ufa9SoEYcOHarc\nX0bkEqkIiOUMGjSI9evXs337dk6dOkVUVBTh4eFs27atQu9Ts2ZNTp8+XeKxkSNHsnjxYtatW0eH\nDh1o1KhR8XOnT5+mZs2alfI7iFQWFQGxnNq1axMbG8uYMWOKrwJuvfVWNm3aVNwmAqOnv2vXrlLf\np379+hQWFlJQUFD82FVXXUXDhg1JSUm54AojIyODiIiISv5tRC6NioBYUlJSEl9//TVJSUkA1KhR\ngw8++IAXXniBsLAwwsPDefXVV2nUqBE2m+2CMYFly5YBEB8ff0GfPykpie+++46hQ4eWePw///kP\nAwcOrJpfUKSctJ+AyCXYvn07zz33HG+99VaZP/fbb78RExPDxo0b8fPT317iOXQ2ilyCqKgoYmNj\nKSoqKvPnsrKymD59ugqAeBxdCYiIWJj+LBERsTAVARERC1MREBGxMBUBERELUxEQEbGw/weli/D6\nIRiBRQAAAABJRU5ErkJggg==\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f8947baebd0>"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.26 : Page number 169-170"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "VEE=10.0; #Emitter supply voltage, V\n",
+ "RC=1.0; #Collector resistor, k\u03a9\n",
+ "RE=4.7; #Collector resistor, k\u03a9\n",
+ "RB=47.0; #Base resistoe, k\u03a9\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "VBE=0.7; #Base -emitter voltage, V\n",
+ "\n",
+ "#Calculation\n",
+ "#-IB*RB-VBE-IE*RE+VEE=0\n",
+ "#AS, IC=beta*IB and IC~IE\n",
+ "IE=round((VEE-VBE)/(RE+(RB/beta)),1); #Emitter current, mA\n",
+ "IC=IE; #Collector current, mA\n",
+ "\n",
+ "#VCC-IC*RC-VCE-IE*RE+VEE=0\n",
+ "#IC~IE\n",
+ "VCE=VCC+VEE-IC*(RC+RE); #Collector-emitter voltage, V\n",
+ "\n",
+ "print(\"Operating point: IC=%.1fmA and VCE=%.2fV.\"%(IC,VCE));\n",
+ "\n",
+ "\n",
+ "#For d.c load line\n",
+ "#VCE=VCC-IC*RC\n",
+ "#For calculating VCE, IC=0\n",
+ "IC=0; #Collector current for maximum Collector-emitter voltage, mA\n",
+ "VCE_max=VCC+VEE-IC*(RC+RE); #Maximum collector-emitter voltage, V\n",
+ "\n",
+ "#For calculating VCE, IC=0\n",
+ "VCE=0; #Collector emitter voltage for maximum collector current, V\n",
+ "IC_max=(VCC+VEE-VCE)/(RC+RE); #Maximum collector current, mA\n",
+ "\n",
+ "\n",
+ "#Plotting of d.c load line\n",
+ "VCE_plot=[0,VCE_max]; #Plotting variable for VCE\n",
+ "IC_plot=[IC_max,0]; #Plotting variable for IC\n",
+ "p=plot(VCE_plot,IC_plot);\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,25])\n",
+ "limit.set_ylim([0,5])\n",
+ "xlabel('VCE(V)');\n",
+ "ylabel('IC(mA)');\n",
+ "title('d.c load line');\n",
+ "plt.grid();\n",
+ "show(p);\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point: IC=1.8mA and VCE=9.74V.\n"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXsAAAEZCAYAAAB2AoVaAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3Xl4VNX9x/H3hKAJsqqAwQChLAJJSEBERZaAApZNIYpg\nQRaRn2vFHbUKtRJE2RFtVQSxhSBuKAKF8hhBXCiYGAxSpBKMBAQCIgFDSDK/P06ZKxACyWTm3pn5\nvJ4nj8zCnG++3uc7l+899xyX2+12IyIiQS3M7gBERMT3VOxFREKAir2ISAhQsRcRCQEq9iIiIUDF\nXkQkBKjYi6ONGDGCp556yqvPyM7OJiwsjJKSkkqKypKUlMTcuXNLfW3ChAkMGzYMgB9++IEaNWqg\nmc5il3C7AxApi8vlwuVy2R3GGZUV32+fb9SoEYcPH/ZXWCKn0Zm9OF6gng0HatwSnFTsxVHS09Np\n164dNWvWZPDgwRQUFJzxvSUlJaSkpNCsWTNq1qxJ+/bt+fHHH886Rm5uLv379+eiiy6iefPmvPba\na57XNmzYwNVXX02dOnVo0KAB9913H8ePH/e8vnr1alq2bEnt2rW57777cLvd51TUT20lJSUl8fTT\nT9OpUydq1qxJr169yMvL87z/iy++oGPHjtSpU4fExEQ++eSTs44hUhYVe3GMwsJCbrzxRoYPH87B\ngwe5+eabeeedd87YJpk6dSqpqamsWLGCX375hXnz5lGtWrWzjjN48GAaNWrE7t27efvtt3niiSf4\n+OOPAQgPD2fmzJnk5eXx+eefs2bNGl566SUA9u/fT3JyMikpKeTl5dG0aVPWr19f4TbTokWLmD9/\nPnv37qWwsJApU6YAsGvXLvr27cvTTz/NwYMHmTJlCsnJyezfv79C44iAir04yBdffEFRURH3338/\nVapUITk5mSuuuOKM7587dy4TJ06kefPmAMTHx3PhhReWOUZOTg6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D\nlmKvufUnW79+Penp6axYsYI5c+awbt06u0NyDJfLFdLHy1133cWOHTvIyMggKiqKhx56yO6Q/Co/\nP5/k5GRmzpxJjVPWQA61YyM/P5+bbrqJmTNnUr169XIfG7YU+3O94SpURP1vY866desyYMAANmzY\nYHNE9qpfvz579uwBYPfu3dSrV8/miOxTr149T1EbPXp0SB0bx48fJzk5mWHDhnHjjTcCoXtsnMjF\n0KFDPbko77FhS7Fv37493333HdnZ2RQWFrJ48WL69+9vRyi2O3r0KIcPHwbgyJEjrFq16qTZGKGo\nf//+nrtG33jjDc/BHYp2797t+fN7770XMseG2+3m9ttvp3Xr1owdO9bzfCgeG2fKRbmPDR9cPD4n\ny5cvd7do0cLdtGlTd0pKil1h2O777793JyQkuBMSEtyxsbEhl4vBgwe7o6Ki3FWrVnVHR0e7X3/9\ndXdeXp772muvdTdv3tzdo0cP98GDB+0O0y9OzcXcuXPdw4YNc8fHx7vbtGnjvuGGG9x79uyxO0y/\nWLdundvlcrkTEhLciYmJ7sTERPeKFStC8tgoLRfLly8v97Ghm6pEREKAtiUUEQkBKvYiIiFAxV5E\nJASo2IuIhAAVexGREKBiLyISAlTsRURCgIq9BKXu3buzatWqk56bMWMGd999N9u2baN37960aNGC\nyy+/nFtuuYW9e/eSlpZGrVq1POuDt23bljVr1gDw66+/kpSURElJCb/73e/Ytm3bSZ89duxYnn/+\neb755htGjhzpt99T5Fyp2EtQGjJkCKmpqSc9t3jxYoYMGULfvn2555572LZtG5s2beLuu+9m3759\nuFwuunTpQnp6uufn2muvBeD1118nOTmZsLCw0z67pKSEd955hyFDhhAXF8ePP/540tpPIk6gYi9B\nKTk5mY8++oiioiLALA2bm5vLd999R8eOHenTp4/nvV27diU2NrbMtcEXLlzIDTfcAJgvksWLF3te\nW7t2LY0bN/Ys292vX7/TvmhE7KZiL0HpwgsvpEOHDixfvhyA1NRUBg0aRFZWFu3atTvj31u3bt1J\nbZwdO3ZQWFjI999/T6NGjQCIi4sjLCyMzMxMz2ffeuutns9o3769lqkWx1Gxl6D123bL4sWLTyrI\nZ9K5c+eT2jhNmjRh//791K5du9TPLi4uZunSpdx8882e1+rWrUtubm7l/jIiXlKxl6DVv39/1qxZ\nQ3p6OkePHqVt27bExsayadOmcn1OZGQkBQUFJz03ePBg3nrrLf71r3/Rpk0b6tat63mtoKCAyMjI\nSvkdRCqLir0ErerVq9OtWzdGjhzpOau/9dZb+eyzzzztHTA996ysrDN+Tp06dSguLqawsNDz3O9+\n9zsuvvhixo0bd9q/GLZt20ZcXFwl/zYi3lGxl6A2ZMgQNm/ezJAhQwCIiIhg2bJlzJ49mxYtWhAb\nG8tf//pX6tati8vlOq1n/+677wLQs2fP0/rwQ4YM4T//+Q8DBw486fmPP/6Yvn37+ucXFDlHWs9e\n5Bykp6czffp0FixYUOb7jh07RlJSEuvXrycsTOdS4hw6GkXOQdu2benWrRslJSVlvi8nJ4fJkyer\n0Ivj6MxeRCQE6PRDRCQEqNiLiIQAFXsRkRCgYi8iEgJU7EVEQsD/A5rk1yWn9KUgAAAAAElFTkSu\nQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f8947c78950>"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.27 : Page number 170-171"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VEE=10.0; #Emitter supply voltage, V\n",
+ "IE=1.8; #Emitter current, mA\n",
+ "RE=4.7; #Emitter resistor, k\u03a9\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "IC=1.8; #Collector current, mA\n",
+ "RC=1.0; #Collector resistor, k\u03a9\n",
+ "\n",
+ "\n",
+ "#Calculation\n",
+ "#(i)\n",
+ "VE=-VEE+IE*RE; #Emitter voltage, V\n",
+ "\n",
+ "#(ii)\n",
+ "VB=VEE+VBE; #Base voltage, V\n",
+ "\n",
+ "#(iii)\n",
+ "VC=VCC-IC*RC; #Collector voltage, V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) Emitter voltage=%.2fV.\"%VE);\n",
+ "print(\"(i) Base voltage=%.1fV.\"%VB);\n",
+ "print(\"(i) Collector voltage=%.1fV.\"%VC);\n",
+ "\n",
+ "#Note: In the textbook, VB=VE+VBE has been written, which is worng. It should be VB=VEE+VBE. "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Emitter voltage=-1.54V.\n",
+ "(i) Base voltage=10.7V.\n",
+ "(i) Collector voltage=8.2V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 39
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "\n",
+ "Example 8.28: Page number 173-174\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_BE_change=200.0; #Change in base-emitter voltage in mV\n",
+ "I_B_change=100.0; #Change in base current in \u03bcA\n",
+ "\n",
+ "#Calculations\n",
+ "Ri=V_BE_change/I_B_change; #Input resistance in k\u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"Input resistance =%d k\u03a9\"%Ri);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Input resistance =2 k\u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 35
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.29; Page number 174\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CE_final=10.0;\t\t\t#Final value of collector-emitter voltage in V\n",
+ "V_CE_initial=2.0; #Initial value of collector-emitter voltage in V\n",
+ "I_C_final=3.0; #Final value of collector current in mA\n",
+ "I_C_initial=2.0; #Initial value of collector current in mA\n",
+ "\n",
+ "#Calculations\n",
+ "V_CE_change=V_CE_final-V_CE_initial;\t\t#Change in collector to emitter voltage in V\n",
+ "I_C_change=I_C_final-I_C_initial; #Change in collector current in mA\n",
+ "R0=V_CE_change/I_C_change; #Output resistance in k\u03a9\n",
+ "\n",
+ "#Result\n",
+ "print(\"The output resistance =%dk\u03a9\"%R0);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The output resistance =8k\u03a9\n"
+ ]
+ }
+ ],
+ "prompt_number": 34
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.30: Page number 174\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "R_C=2.0;\t\t#Collector load in kilo ohm\n",
+ "R_i=1.0;\t\t#Input resistance in kilo ohm\n",
+ "R_AC=R_C; #Effective collector load for single stage in kilo ohm(appoximately equal to collector load for single stage)\n",
+ "beta=50.0; #Current gain\n",
+ "\n",
+ "#Calculations\n",
+ "A_v=beta*(R_AC/R_i);\t\t#Voltage gain of the amplifier\n",
+ "\n",
+ "#Result \n",
+ "print(\"The voltage gain of the amplifier =%d \"%A_v);\t\t\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The voltage gain of the amplifier =100 \n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.31: Page number 175-176\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=20;\t\t#Collector supply voltage in V\n",
+ "R_C=1; #Collector resistance in kilo ohm\n",
+ "V_knee_Si=1;\t\t#Knee voltage of V_CE for Si in V \n",
+ "V_knee_Ge=0.5;\t\t#Knee voltage of V_CE for Ge in V\n",
+ "\n",
+ "#Calculations\n",
+ "I_C_sat_Si=(V_CC-V_knee_Si)/R_C;\t\t#Saturation (maximum) value of collector current in mA (for Si transistor)\n",
+ "I_C_sat_Ge=(V_CC-V_knee_Ge)/R_C;\t\t#Saturation (maximum) value of collector current in mA (for Ge transistor)\n",
+ "I_C_sat=(V_CC)/R_C;\t\t\t\t#Saturation (maximum) value of collector current in mA (neglecting knee voltage)\n",
+ "V_CE_cut_off=V_CC; #Collector to emitter voltage in cutoff when base current=0, in V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Collector current during saturation = %d mA\"%I_C_sat);\n",
+ "print(\"Collector emitter voltage during cutoff = %d V.\"%V_CE_cut_off);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector current during saturation = 20 mA\n",
+ "Collector emitter voltage during cutoff = 20 V.\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.32: Page number 176-177\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=12.0;\t\t#Collector supply voltage in V\n",
+ "V_EE=12.0;\t\t#Emitter supply voltage in V\n",
+ "R_C=750.0;\t\t#Collector resistance in ohm\n",
+ "R_E=1.5;\t\t#Emitter resistance in kilo ohm\n",
+ "R_B=100.0;\t\t#Base resistance in ohm\n",
+ "beta=200;\t\t#base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law to the collector side of the circuit\n",
+ "#using the equation: Vcc -IcRc-Vce -IeRe+Vee=0\n",
+ "#we get Vce=Vcc+Vee-Ic(Rc+Re), [Ie=Ic, approximately]\n",
+ "#We get Vce(off), when Ic=0;\n",
+ "\n",
+ "I_C_Vce_off=0;\t\t\t\t\t#Collector current for Vce(off) in mA\n",
+ "V_CE_off=V_CC+V_EE -(I_C_Vce_off * (R_C +R_E));\t#Collector to emitter voltage in V, during transistor in off state\n",
+ "\n",
+ "#We get Ic(sat), when Vce=0\n",
+ "V_CE_Ic_sat=0;\t\t\t\t\t\t#Collector to emitter voltage for saturation current of collector in V\n",
+ "I_C_sat=(V_CC+V_EE-V_CE_Ic_sat)/(R_C+(R_E*1000));\t#Saturated collector current in A \n",
+ "I_C_sat=I_C_sat*1000;\t\t\t\t\t#Saturated collector current in mA\n",
+ "#Result\n",
+ "print(\"Vce(off)= %dV\"%V_CE_off);\n",
+ "print(\"Ic(sat) = %.2f mA\"%I_C_sat);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Vce(off)= 24V\n",
+ "Ic(sat) = 10.67 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.33 : Page number 177\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_knee=0.2;\t\t\t\t#Knee voltage of collector-emitter voltage in V\n",
+ "V_CC=10.0;\t\t\t\t#Collector supply voltage in V\n",
+ "V_BB=3.0;\t\t\t\t#Base supply voltage in V\n",
+ "V_BE=0.7;\t\t\t\t#Base-emitter voltage in V \t\n",
+ "R_B=10.0;\t\t\t\t#Base resistor's resistance in kilo ohm\n",
+ "R_C=1.0;\t\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "beta=50.0;\t\t\t\t#base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#applying Kirchhoff's voltage law along the collector side of the circuit,\n",
+ "#We get Vcc-Ic(sat)*Rc-V_knee=0\n",
+ "#From the above equation, we get:\n",
+ "I_C_sat=(V_CC-V_knee)/R_C;\t\t#Saturated collector current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along base emitter side,\n",
+ "#We get VBB-IB*RB-VBE=0;\n",
+ "#From the above equation, we get:\n",
+ "I_B=(V_BB-V_BE)/R_B;\t\t\t#Base current in mA\n",
+ "\n",
+ "\n",
+ "I_C=beta*I_B\t\t\t\t#Collector current in mA\n",
+ "\n",
+ "#Result\n",
+ "if(I_C>I_C_sat):\n",
+ "\tprint(\"The base current is large enough to produce Ic greater than Ic(sat), therefore the transistor is saturated.\");\n",
+ "else:\n",
+ "\tprint(\"The base current is not large enough to produce Ic greater than Ic(sat), therefore the transistor isn't saturated. \");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The base current is large enough to produce Ic greater than Ic(sat), therefore the transistor is saturated.\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.34: Page number 177-178\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "V_CC=10.0;\t\t\t\t#Collector supply voltage in V\n",
+ "V_BE=0.95;\t\t\t\t#Base-emitter voltage in V \t\n",
+ "I_B=100.0;\t\t\t\t#Base current in microAmp\n",
+ "R_C=970.0;\t\t\t\t#Collector resistor's resistance in ohm\n",
+ "beta=100.0;\t\t\t\t#base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "I_C=(I_B/1000)*beta;\t\t\t\t#Collector current in mA \n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along collector side\n",
+ "#We get Vcc-IcRc-Vce=0\n",
+ "#From the above equation, we get:\n",
+ "\n",
+ "V_CE=V_CC-((I_C/1000)*R_C);\t\t\t\t#Collector-emitter voltage in V\n",
+ "\n",
+ "#From the equation, V_CE=V_CB+V_BE,\n",
+ "V_CB=V_CE-V_BE;\t\t\t\t\t\t#Collector-base voltage in V\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "if(V_CB<0 and V_BE >0):\n",
+ "\tprint(\"As both collector-base and emitter-base junction are forward biased, the transistor is operating in the saturation region. \");\n",
+ "else:\n",
+ "\tprint(\"No. The transistor isn't operating in the saturation region.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "As both collector-base and emitter-base junction are forward biased, the transistor is operating in the saturation region. \n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.35: Page number 178\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=10.0;\t\t\t\t#Collector supplu voltage in V\n",
+ "V_BE=0.7;\t\t\t\t#Base-emitter voltage in V\n",
+ "R_B=50.0;\t\t\t\t#Base resistor's resistance in kilo ohm\n",
+ "R_C=2.0;\t\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "beta=200.0;\t\t\t\t#Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along the collector side,\n",
+ "#We get, Vcc-Ic(sat)*Rc-Vce=0;\n",
+ "#From the above equation, we get:\n",
+ "#I_C_sat=(V_CC-V_CE)/R_C, but as transistor goes into saturation, Vce=0;\n",
+ "\n",
+ "V_CE=0;\t\t\t\t\t\t#Collector-emiter voltage in V, for transistor in saturation \n",
+ "I_C_sat=(V_CC-V_CE)/R_C;\t\t\t#Saturated collector current in mA\n",
+ "\n",
+ "I_B=I_C_sat/beta;\t\t\t\t#Base current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law to the base circuit,\n",
+ "#We get, VBB - IB*RB - VBE=0\n",
+ "#From the above equation. we get:\n",
+ "V_BB=V_BE+ I_B*R_B;\t\t\t\t#Base supply voltage to put transistor in saturation, in V\n",
+ "\n",
+ "#Result\n",
+ "print(\"Therefore, for putting transistor in saturation, VBB >= %.2f V\"%V_BB);\n",
+ " \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Therefore, for putting transistor in saturation, VBB >= 1.95 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.36: Page number 178-179\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=10.0;\t\t\t#Collector supply voltage in V\n",
+ "V_BB=2.7;\t\t\t#Base supply voltage in V\n",
+ "V_BE=0.7;\t\t\t#Base-emitter voltage in V\n",
+ "beta=100.0;\t\t\t#Base current amplification factor\n",
+ "R_E=1.0;\t\t\t#Emitter resistor's resistance in kilo ohm\n",
+ "\n",
+ "\n",
+ "#Calcultaion\t\n",
+ "V_B=V_BB;\t\t\t#Base voltage in V\n",
+ "V_E=V_B-V_BE;\t\t\t#Emitter voltage in V\n",
+ "I_E=V_E/R_E;\t\t\t#Emitter current in mA\n",
+ "I_C=I_E;\t\t\t#Collector current (approximately equal to emitter current) in mA\n",
+ "I_B=I_C/beta;\t\t\t#Base current in mA\n",
+ "\n",
+ "#Case (i):\n",
+ "R_C=2;\t\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "\n",
+ "#Assuming transistor to be in active state\n",
+ "#Applying Kirchhoff's voltage law along collector side,\n",
+ "#We get,Vcc-IcRc=Vc,\n",
+ "\n",
+ "V_C=V_CC-I_C*R_C;\t\t#Collector voltage in V\n",
+ "\n",
+ "if(V_C>V_E):\n",
+ "\tprint(\"(i)Our assumption was correct, the transistor is in active state for Rc=2 kilo ohm.\");\n",
+ "elif(V_C<V_E):\n",
+ "\tprint(\"(i)Our assumption was wrong, the transistor is in saturation for Rc=2 kilo ohm.\");\n",
+ "elif(V_C==V_E):\n",
+ "\tprint(\"(i)The transistor is at the edge of saturation for Rc=2 kilo ohm, therefore relation between transistor currents are same for both saturation and active state.\");\n",
+ "\n",
+ "#Case (ii):\n",
+ "R_C=4;\t\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "\n",
+ "#Assuming transistor to be in active state\n",
+ "#Applying Kirchhoff's voltage law along collector side,\n",
+ "#We get,Vcc-IcRc=Vc,\n",
+ "\n",
+ "V_C=V_CC-I_C*R_C;\t\t#Collector voltage in V\n",
+ "if(V_C>V_E):\n",
+ "\tprint(\"(ii)Our assumption was correct, the transistor is in active state for Rc=4 kilo ohm.\");\n",
+ "elif(V_C==V_E):\n",
+ "\tprint(\"(ii)The transistor is at the edge of saturation for Rc=4 kilo ohm, therefore relation between transistor currents are same for both saturation and active state.\");\n",
+ "elif(V_C<V_E):\n",
+ "\tprint(\"(ii)Our assumption was wrong, the transistor is in saturation for Rc=4 kilo ohm.\");\n",
+ "\n",
+ "\n",
+ "#Case (iii):\n",
+ "R_C=8;\t\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "\n",
+ "#Assuming transistor to be in active state\n",
+ "#Applying Kirchhoff's voltage law along collector side,\n",
+ "#We get,Vcc-IcRc=Vc,\n",
+ "\n",
+ "V_C=V_CC-I_C*R_C;\t\t#Collector voltage in V\n",
+ "if(V_C>V_E):\n",
+ "\tprint(\"(iii)Our assumption was correct, the transistor is in active state for Rc=8 kilo ohm.\");\n",
+ "elif(V_C<V_E):\n",
+ "\tprint(\"(iii)Our assumption was wrong, the transistor is in saturation for Rc=8 kilo ohm.\");\n",
+ "elif(V_C==V_E):\n",
+ "\tprint(\"(iii)The transistor is at the edge of saturation for Rc=8 kilo ohm, therefore relation between transistor currents are same for both saturation and active state.\");\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)Our assumption was correct, the transistor is in active state for Rc=2 kilo ohm.\n",
+ "(ii)The transistor is at the edge of saturation for Rc=4 kilo ohm, therefore relation between transistor currents are same for both saturation and active state.\n",
+ "(iii)Our assumption was wrong, the transistor is in saturation for Rc=8 kilo ohm.\n"
+ ]
+ }
+ ],
+ "prompt_number": 25
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.37 : Page number 179-180"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=15.0;\t\t\t#Collector supply voltage in V\n",
+ "R_C=10.0;\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "V_BE=0.7;\t\t\t#Base-emitter voltage in V\n",
+ "beta=100.0;\t\t\t#Base current amplification factor\n",
+ "R_E=1.0;\t\t\t#Emitter resistor's resistance in kilo ohm\n",
+ "\n",
+ "\n",
+ "#Calculation\t\n",
+ "\n",
+ "#Case (i):\n",
+ "V_BB=0.5;\t\t\t#Base supply voltage in V\n",
+ "VB=V_BB; #Base voltage, V\n",
+ "print(\"(i) Base voltage =%.1fV is less than VBE=%.1fV, therefore, transistor is cut-off.\"%(VB,V_BE));\n",
+ "\n",
+ "\n",
+ "#Case (ii):\n",
+ "V_BB=1.5;\t\t\t#Base supply voltage in V\n",
+ "VB=V_BB; #Base voltage, V\n",
+ "VE=VB-V_BE; #Emitter voltage, V\n",
+ "IE=round(VE/R_E,1); #Emitter current, mA\n",
+ "#Assuming transistor to be in active state\n",
+ "#Applying Kirchhoff's voltage law along collector side,\n",
+ "IC=IE; #Collector current, mA\n",
+ "IB=IC/beta; #Base current, mA\n",
+ "VC=V_CC-IC*R_C; #Collector voltage, V\n",
+ "print(VE,IE,VC);\n",
+ "print(\"(ii) VC=%dV > VE=%.1fV, therefore the transistor is active. Our assumption was correct.\"%(VC,VE));\n",
+ "\n",
+ "#Case (iii):\n",
+ "V_BB=3; \t\t\t#Base supply voltage in V\n",
+ "VB=V_BB; #Base voltage, V\n",
+ "VE=VB-V_BE; #Emitter voltage, V\n",
+ "IE=round(VE/R_E,1); #Emitter current, mA\n",
+ "#Assuming transistor to be in active state\n",
+ "#Applying Kirchhoff's voltage law along collector side,\n",
+ "IC=IE; #Collector current, mA\n",
+ "IB=IC/beta; #Base current, mA\n",
+ "VC=V_CC-IC*R_C; #Collector voltage, V\n",
+ "\n",
+ "print(\"(iii) VC=%dV < VE=%.1fV, therefore the transistor is saturated. Our assumption was wrong.\"%(VC,VE));"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) Base voltage =0.5V is less than VBE=0.7V, therefore, transistor is cut-off.\n",
+ "(0.8, 0.8, 7.0)\n",
+ "(ii) VC=7V > VE=0.8V, therefore the transistor is active. Our assumption was correct.\n",
+ "(iii) VC=-8V < VE=2.3V, therefore the transistor is saturated. Our assumption was wrong.\n"
+ ]
+ }
+ ],
+ "prompt_number": 41
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.38: Page number 181\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "P_D_max=100.0;\t\t\t#Maximum power dissipation of a transistor in mW\n",
+ "V_CE=20.0;\t\t\t#Collector emitter voltage in V\n",
+ "\n",
+ "#Calculation\n",
+ "#As power=curent*voltage\n",
+ "#P_D_max=I_C_max*V_CE\n",
+ "#From the above equation, we get:\n",
+ "\n",
+ "I_C_max=P_D_max/V_CE;\t\t#Maximum collector current that can be allowed without destruction of the transistor, in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Maximum collector current that can be allowed without destruction of the transistor = %d mA.\"%I_C_max); \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Maximum collector current that can be allowed without destruction of the transistor = 5 mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.39: Page number 181\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=5.0;\t\t\t\t#Collector supply voltage in V\n",
+ "V_BB=5.0;\t\t\t\t#Base supply voltage in V\n",
+ "V_BE=0.7;\t\t\t\t#Base-emitter voltage in V\n",
+ "R_B=1.0;\t\t\t\t#Base resistor's resistance in kilo ohm\n",
+ "R_C=0;\t\t\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "beta=200.0;\t\t\t\t#base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along base circuit<\n",
+ "#We get, VBB- IB*RB - VBE=0.\n",
+ "#From the above equation, we get:\n",
+ "\n",
+ "I_B=(V_BB-V_BE)/R_B;\t\t\t#Base current in mA\n",
+ "\n",
+ "I_C=beta*I_B;\t\t\t\t#Collector current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along collector circuit:\n",
+ "\n",
+ "V_CE=V_CC-I_C*R_C;\t\t\t#Collector-emitter voltage in V\n",
+ "\n",
+ "#As power=curent*voltage\n",
+ "#P_D=I_C*V_CE\n",
+ "#From the above equation, we get:\n",
+ "P_D=V_CE*I_C;\t\t\t\t#Power dissipated in mW\n",
+ "P_D=P_D/1000;\t\t\t\t#Power dissipated in W\n",
+ "\n",
+ "#Result\n",
+ "print(\"Power dissipated = %.1fW\"%P_D);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Power dissipated = 4.3W\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.40: Page number 181-182\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=5.0;\t\t\t\t#Collector supply voltage in V\n",
+ "V_BB=1.0;\t\t\t\t#Base supply voltage in V\n",
+ "V_BE=0.7;\t\t\t\t#Base-emitter voltage in V\n",
+ "R_B=10.0;\t\t\t\t#Base resistor's resistance in kilo ohm\n",
+ "R_C=1.0;\t\t\t\t\t#Collector resistor's resistance in kilo ohm\n",
+ "beta=100.0;\t\t\t\t#base current amplification factor\n",
+ "\n",
+ "#Calculation\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along base circuit<\n",
+ "#We get, VBB- IB*RB - VBE=0.\n",
+ "#From the above equation, we get:\n",
+ "\n",
+ "I_B=(V_BB-V_BE)/R_B;\t\t\t#Base current in mA\n",
+ "\n",
+ "I_C=beta*I_B;\t\t\t\t#Collector current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along collector circuit:\n",
+ "\n",
+ "V_CE=V_CC-I_C*R_C;\t\t\t#Collector-emitter voltage in V\n",
+ "\n",
+ "#As power=curent*voltage\n",
+ "#P_D=I_C*V_CE\n",
+ "#From the above equation, we get:\n",
+ "P_D=V_CE*I_C;\t\t\t\t#Power dissipated in mW\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"Power dissipated = %.0fmW\"%P_D);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Power dissipated = 6mW\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 8.41 : Page number 182"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VBB=5.0; #Base supply voltage, V\n",
+ "RB=22.0; #Base resistor, kilo ohm\n",
+ "RC=1.0; #Collector resistor, kilo ohm\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "PD_max=800.0; #Maximum power dissipation, mW\n",
+ "VCE_max=15.0; #Maximum collector-emitter voltage, V\n",
+ "IC_max=100.0; #Maximum collector current, mA\n",
+ "\n",
+ "#Calculation\n",
+ "IB=((VBB-VBE)/RB)*1000; #Base current, \u03bcA\n",
+ "IC=beta*IB/1000; #Collector current, mA\n",
+ "\n",
+ "print(\"IC=%.1fmA is much less than IC_max=%dmA. Therefore, will not change with VCC and current rating is not exceeded.\"%(IC,IC_max));\n",
+ "\n",
+ "#VCC=VCE+IC*RC\n",
+ "VCC_max=VCE_max+IC*RC; #Maximum value of Collector supply voltage, V\n",
+ "PD=VCE_max*IC; #Power dissipation, mW\n",
+ "\n",
+ "print(\"PD=%dmW is less than PD_max=%dmW. Therefore, power rating is not exceeded.\"%(PD,PD_max));\n",
+ "\n",
+ "print(\"If base current is removed, transistor will turn off. Hence, VCE_max will be exceeded because entire supply voltage VCC will be dropped across the transistor.\");"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "IC=19.5mA is much less than IC_max=100mA. Therefore, will not change with VCC and current rating is not exceeded.\n",
+ "PD=293mW is less than PD_max=800mW. Therefore, power rating is not exceeded.\n",
+ "If base current is removed, transistor will turn off. Hence, VCE_max will be exceeded because entire supply voltage VCC will be dropped across the transistor.\n"
+ ]
+ }
+ ],
+ "prompt_number": 33
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter9_1.ipynb b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter9_1.ipynb
new file mode 100644
index 00000000..e8168ab8
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/chapter9_1.ipynb
@@ -0,0 +1,1907 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:1e5463fc2e8c67a2f9099cf3f6c078bc1c9dccccd63589a75ad6ce5024fe6432"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "CHAPTER 9 : TRANSISTOR BIASING"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.1: Page number 195-196"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "V_CC=6.0; #Collector supply voltage\n",
+ "R_C=2.5; #Collector load in k\u2126\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#(i)\n",
+ "#For faithful amplification Vce (collector-emitter voltage)> 1V for Si transistor.\n",
+ "V_CE_max=1; #Maximum allowed collector-emitter voltage for faithful amplification, in V.\n",
+ "V_Rc_max=V_CC-V_CE_max; #maximum voltage drop across collector load in V.\n",
+ "I_C_max=V_Rc_max/R_C; #Maximum allowed collector current in mA\n",
+ "\n",
+ "#(ii)\n",
+ "IC_min_zero_signal=I_C_max/2; #Minimum zero signal collector current in mA\n",
+ "\n",
+ "#Results\n",
+ "print(\"The maximum allowed collector current during application of signal for faithful amplification = %d mA.\"%I_C_max);\n",
+ "print(\"The minimum zero signal collector current required = %d mA.\"%IC_min_zero_signal);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum allowed collector current during application of signal for faithful amplification = 2 mA.\n",
+ "The minimum zero signal collector current required = 1 mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.2: Page number 196\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=13.0; #Collector supply voltage in V\n",
+ "V_knee=1.0; #Knee voltage in V\n",
+ "R_C=4.0; #Collector load in k\u2126\n",
+ "rate_IC_VBE=5.0; #Rate of change of collector current IC with base-emitter voltage VBE in mA/V.\n",
+ "beta=100.0; #base current amplification factor\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "V_Rc_max=VCC-V_knee; #Maximum allowed voltage across collector load in V\n",
+ "I_C_max=V_Rc_max/R_C; #Maximum allowed collector current in mA\n",
+ "I_B_max=I_C_max/beta; #Maximum base current in mA\n",
+ "I_B_max=I_B_max*1000; #Maximum base current in \ud835\udf07A\n",
+ "\n",
+ "V_B_max=I_C_max/rate_IC_VBE; #Maximum base voltage signal in V\n",
+ "V_B_max=V_B_max*1000; #Maximum base voltage signal in mV\n",
+ "\n",
+ "#Results\n",
+ "print(\"Maximum base current =%d \ud835\udf07A.\"%I_B_max);\n",
+ "print(\"Maximum input signal voltage =%d mV.\"%V_B_max);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Maximum base current =30 \ud835\udf07A.\n",
+ "Maximum input signal voltage =600 mV.\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.3: Page number 200-201"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=9.0; #Colector supply voltage in V\n",
+ "VBB=2.0; #Base supply voltage in V\n",
+ "R_B=100.0; #Base resistor's resistance in k\u2126\n",
+ "R_C=2.0; #Collector load in k\u2126\n",
+ "beta=50.0; #base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#Case (i):\n",
+ "\n",
+ "#Applying Kirchhoff's law to the input circuit\n",
+ "#We get, IB*RB +VBE =VBB.\n",
+ "#Neglecting the small base-emitter voltage, we get:\n",
+ "I_B=VBB/R_B; #Base current in mA\n",
+ "I_C=beta*I_B; #Collector current in mA\n",
+ "\n",
+ "print(\"Collector current = %dmA\"%I_C);\n",
+ "\n",
+ "#Applying Kirchhoff's law to the output ciruit\n",
+ "#We get, IC*RC + VCE= VCC.\n",
+ "#From the above equation, we get:\n",
+ "V_CE=VCC-I_C*R_C; #Collector emitter voltage in V\n",
+ "\n",
+ "print(\"Collector emitter voltage =%dV.\"%V_CE);\n",
+ "\n",
+ "\n",
+ "#Case (ii):\n",
+ "\n",
+ "R_B=50.0;\n",
+ "I_B=VBB/R_B;\n",
+ "I_C=beta*I_B;\n",
+ "V_CE=VCC - I_C*R_C;\n",
+ "\n",
+ "print(\"The new operating point for base resistor RB=50 k\u2126 is, VCE=%dV and IC=%dmA.\"%(V_CE,I_C));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector current = 1mA\n",
+ "Collector emitter voltage =7V.\n",
+ "The new operating point for base resistor RB=50 k\u2126 is, VCE=5V and IC=2mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.4: Page number 201-202"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#variable declaration\n",
+ "beta=100.0; #base current amplification factor\n",
+ "VCC=6.0; #Collector suply voltagein V\n",
+ "VBE=0.7 #Base emitter voltage in V\n",
+ "R_B=530.0; #Base resistor's resistance in k\u2126 .\n",
+ "R_C=2.0; #Collector resistor's resistance in k\u2126 .\n",
+ "\n",
+ "#Calculation\n",
+ "#D.C load line equation : VCE=VCC-IC*RC;\n",
+ "#Calculating maximum VCE ,by IC=0;\n",
+ "I_C_Vce_max=0; #Collector current for maximum collector-emitter voltage, in mA\n",
+ "VCE_max=VCC;-I_C_Vce_max*R_C; #Maximum collector-emitter voltage in V\n",
+ "\n",
+ "\n",
+ "#Calculating maximum collector current IC,by VCE=0;\n",
+ "V_CE_IC_max=0; #Collector-emitter voltage for maximum collector current, in V \n",
+ "I_C_max=(VCC-V_CE_IC_max)/R_C; #Maximum collector current in mA\n",
+ "\n",
+ "\n",
+ "#Operating point:\n",
+ "#For input circuit, applying Kirchhoff's law, We get,\n",
+ "#VCC=IB*RB + VBE.\n",
+ "#From the above equation,\n",
+ "IB=(VCC-VBE)/R_B; #Base current in mA\n",
+ "IC=beta*IB; #Collector current\n",
+ "\n",
+ "#From the output circuit, applying Kirchhoff's law, we get:\n",
+ "VCE=VCC-IC*R_C; #Collector-emitter voltage in V\n",
+ "\n",
+ "\n",
+ "#Stability factor\n",
+ "SF=beta+1; \n",
+ "\n",
+ "#Result\n",
+ "print(\"Operating point: VCE= %dV and IC=%d mA\"%(VCE,IC));\n",
+ "print(\"Stability factor= %d.\"%SF);\n",
+ "\n",
+ "\n",
+ "#plot\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,10])\n",
+ "limit.set_ylim([0,5])\n",
+ "VCE=[i for i in range(0,(int)(VCC+1))]; #Plot variable for V_CE\n",
+ "IC=[((VCC-i)/(R_C)) for i in (VCE[:])]; #Plot variable for I_C\n",
+ "\n",
+ "p=plot(VCE,IC);\n",
+ "xlabel(\"VCE(V)\");\n",
+ "ylabel(\"IC(mA)\");\n",
+ "title(\"d.c load line\");\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point: VCE= 4V and IC=1 mA\n",
+ "Stability factor= 101.\n"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXoAAAEZCAYAAACZwO5kAAAABHNCSVQICAgIf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HrplOnTrpw4YKCg4Pv+dwlJSXatm2bnnrqKfd9ISEhfv0uYfA+BD0sa8KECdq7d6+OHj2q\nGzduKC4uTtHR0Tp8+HCtnqdRo0YqKCiocNvUqVP10Ucfac+ePerVq5dCQkLc9xUUFKhRo0b18j0A\n9YGgh2U1bdpU8fHxSkpKcrf5adOm6eDBg+4tHen2HntGRkaVz9OyZUuVlJSosLDQfdvDDz+sNm3a\naOHChXf9SyEzM1N2u72evxug7gh6WFpiYqJOnDihxMRESVLDhg21Y8cOvfPOO+rWrZuio6P161//\nWiEhIbLZbHft0W/dulWSNHLkyLv23RMTE/Xvf/9bkyZNqnD7F198oXHjxnnmGwRqgOvRAzVw9OhR\nrVq16r7veHXr1i05HA4dOHDA79/gHN6Dv4lADcTFxSk+Pl6lpaXVPi47O1srVqwg5OFVaPQAYHHU\nDgCwOIIeACyOoAcAiyPoAcDiCHoAsLj/AxBRW6txz5gaAAAAAElFTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f8eea67df10>"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.5: Page number 202"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage in V\n",
+ "beta=100.0; #base current amplification factor\n",
+ "I_C_zero_signal=1.0; #zero signal collector current in mA\n",
+ "VBE=0.3; #Base-emitter voltage of Ge transistor in V\n",
+ "\n",
+ "#calculations\n",
+ "\n",
+ "#Case(i)\n",
+ "I_B_zero_signal=I_C_zero_signal/beta; #Zero signal base current in mA\n",
+ "\n",
+ "#applying the Kirchhoff's law along input circuit:\n",
+ "#We get, VCC=IB*RB +VBE\n",
+ "#From the above equation we get,\n",
+ "R_B=(VCC-VBE)/I_B_zero_signal; #Required base resistor's resistance in k\u2126\n",
+ "\n",
+ "print(\"Value of base resistor for operating the given Ge transistor at zero signal IC=1mA is = %d k\u2126\"%R_B);\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Case(ii)\n",
+ "beta=50;\n",
+ "I_B=(VCC-VBE)/R_B; #Base current of another transistor with beta=50, in mA\n",
+ "I_C_zero_signal=beta*I_B; #Zero signal collector current for beta=50 , in mA\n",
+ "\n",
+ "print(\"The new value of zero signal collector current =%.1fmA\"%I_C_zero_signal);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Value of base resistor for operating the given Ge transistor at zero signal IC=1mA is = 1170 k\u2126\n",
+ "The new value of zero signal collector current =0.5mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.6:Page number 202-203"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Varaible declaration\n",
+ "VCC=10.0; #Collector supply voltage in V\n",
+ "VBE=0; #Base emitter voltage in V(considering itas zero due to it's small value)\n",
+ "R_B=1.0; #Base resistor's resistance in M\u2126\n",
+ "R_C=2.0; #Collector resistor's resistance in k\u2126 \n",
+ "R_E=1.0; #Emitter resistor's resistance in k\u2126\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "#using Kirchhoff's law in the input circuit, we get:\n",
+ "#VCC=IB*RB +VBE +IE*RE\n",
+ "#Since, IE=(beta +1)*I_B\n",
+ "#From the above equation we get:\n",
+ "I_B=round((VCC-VBE)/((beta + 1)*R_E + R_B*1000),4); #Base current in mA\n",
+ "I_C=round(beta*I_B,2); #Collector current in mA\n",
+ "I_E=I_B+I_C; #Emitter current in mA\n",
+ "\n",
+ "#Result\n",
+ "print(\"Base current =%.4f mA\"%I_B);\n",
+ "print(\"Collector current =%.2f mA\"%I_C);\n",
+ "print(\"Emitter current =%.3f mA\"%I_E);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Base current =0.0091 mA\n",
+ "Collector current =0.91 mA\n",
+ "Emitter current =0.919 mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.7: Page number 203-204"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCE=8.0; #Collector-emitter voltage at operating point in V\n",
+ "IC=2.0; #Colector current at operating point in mA\n",
+ "VCC=15.0; #Collector supply voltagein V\n",
+ "beta=100.0; #base current amplification factor\n",
+ "VBE=0.6; #base emitter voltage in V\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's law along the output circuit,\n",
+ "#we get, VCC=VCE+IC*RC.\n",
+ "#So, from above equation we get:\n",
+ "RC=(VCC-VCE)/IC; #Collector resistor's resistance in k\u2126 .\n",
+ "IB=IC/beta; #Base current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along the input circuit,\n",
+ "#we get, VCC=IB*RB + VBE\n",
+ "#So, from the above equation:\n",
+ "RB=(VCC-VBE)/IB; #Base resistor's resistance in k\u2126 .\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Collector load =%.1f k\u2126 .\"%RC);\n",
+ "print(\"Base resistor=%d k\u2126 .\"%RB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector load =3.5 k\u2126 .\n",
+ "Base resistor=720 k\u2126 .\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.8: Page number 204"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage in V\n",
+ "VBE=0.7; #Base-emitter voltage in V\n",
+ "RB=100.0; #Base resistor's resistance in k\u2126\n",
+ "RC=560.0; #Collector resistor's resistance in \u2126\n",
+ "beta_25=100.0; #base current amplification factor at 25 degree celsius\n",
+ "beta_75=150.0; #base current amplification factor at 25 degree celsius\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "\n",
+ "#Applying Kirchhoff's law along input circuit, we get\n",
+ "#VCC=IB*RB+VBE\n",
+ "IB=(VCC-VBE)/RB; #Base current at 25 degree celsius, in mA\n",
+ "\n",
+ "\n",
+ "#For temperature 25 degree celsius\n",
+ "IC_25=beta_25*IB; #Collector current at 25 degree celsius, in mA\n",
+ "\n",
+ "\n",
+ "#Applying Kirchhoff's alw at the output circuit,\n",
+ "#we get: VCC=IC*RC + VCE\n",
+ "#From the above equation,\n",
+ "VCE_25=round(VCC-(IC_25/1000)*RC,2); #Collector emitter voltage at 25 degree celsius, in V\n",
+ "\n",
+ "\n",
+ "#For temperature 75 degree celsius\n",
+ "IC_75=round(beta_75*IB,0); #Collector current at 75 degree celsius, in mA\n",
+ "\n",
+ "#Applying Kirchhoff's alw at the output circuit,\n",
+ "#we get: VCC=IC*RC + VCE\n",
+ "#From the above equation,\n",
+ "VCE_75=round(VCC-(IC_75/1000)*RC,2); #Collector emitter voltage at 75 degree celsius, in V\n",
+ "\n",
+ "\n",
+ "change_IC=(IC_75-IC_25)*100.0/IC_25; #percentage change in collector current\n",
+ "change_VCE=(VCE_75-VCE_25)*100.0/VCE_25; #Percentage change in collector-emitter voltage \n",
+ "\n",
+ "#Results\n",
+ "print(\"The percentage change in collector current =%d%%\"%change_IC);\n",
+ "print(\"The percentage change in collector-emitter voltage =%.1f%%\"%change_VCE);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The percentage change in collector current =50%\n",
+ "The percentage change in collector-emitter voltage =-56.3%\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.10: Page number 205"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCE_max=20.0; #Maximum collector-emitter voltage in V\n",
+ "VBE=0.7; #Base-emitter voltage in V\n",
+ "IC_max=8.0; #Maximum collector current in mA\n",
+ "IB=40.0; #Base current in microampere\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#During cut off state the collector-emitter voltage is maximum and equal to collector supply voltage\n",
+ "VCC=VCE_max; #Collector supply voltage in V\n",
+ "\n",
+ "#Maximum collector current IC_max=collector supply voltage(VCC)/collector load(RC)\n",
+ "#Collector load(RC)=VCC*IC_max\n",
+ "RC=VCC/IC_max; #Collector load in k\u2126 .\n",
+ "\n",
+ "#Applying Kirchhoff's law along input circuit,\n",
+ "#we get, VCC=IB*RB +VBE.\n",
+ "#From the above equation, we get:\n",
+ "RB=(VCC-VBE)/(IB/1000); #Base resistor's resistance in k\u2126 .\n",
+ "\n",
+ "#Results\n",
+ "print(\"Collector supply voltage = %dV\"%VCC);\n",
+ "print(\"Collector load=%.1f k\u2126 .\"%RC);\n",
+ "print(\"Base resistor's resistance=%.1f k\u2126 .\"%RB);\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector supply voltage = 20V\n",
+ "Collector load=2.5 k\u2126 .\n",
+ "Base resistor's resistance=482.5 k\u2126 .\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.12: Page number 208"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector supply voltage in V\n",
+ "VEE=-20.0; #Emitter supply voltage in V\n",
+ "RB=100.0; #Base resistor's resistance in k\u2126\n",
+ "RC=4.7; #Collector resistor's resistance in k\u2126\n",
+ "RE=10.0; #Emitter resistor's resistance in k\u2126\n",
+ "VBE=0.7; #Base-emitter voltage in V\n",
+ "beta=85.0; #Base current amplification factor\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's voltage law along the base-emitter circuit (input circuit),\n",
+ "#we get,IB*RB +IE*RE +VBE -VEE=0.\n",
+ "#Since IB=IC/beta and IC~IE,\n",
+ "#(IE/beta)*RB + IE*RE + VBE + VEE =0.\n",
+ "IE=(-VEE-VBE)/(RE + RB/beta); #Emitter current in mA\n",
+ "IC=IE; #Collector current (approximately equal to emitter current) in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law from VCC till collector terminal,\n",
+ "#we get, VCC - IC*RC =VC\n",
+ "VC=VCC-IC*RC; #voltage at collector terminal in V\n",
+ "\n",
+ "#Applying Kirchhoff's law from emitter terminal to VEE\n",
+ "#we get, VE -IE*RE =VEE\n",
+ "VE=VEE + IE*RE; #Voltage at emitter treminal in V\n",
+ "\n",
+ "VCE=VC-VE; #Collector-emitter voltage in V\n",
+ "\n",
+ "#Results\n",
+ "print(\"The collector current = %.2f mA\"%IC);\n",
+ "print(\"The emitter current = %.2f mA\"%IE);\n",
+ "print(\"The voltage at collector terminal = %.1f V\"%VC);\n",
+ "print(\"The collector-emitter voltage = %.1f V\"%VCE);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The collector current = 1.73 mA\n",
+ "The emitter current = 1.73 mA\n",
+ "The voltage at collector terminal = 11.9 V\n",
+ "The collector-emitter voltage = 14.6 V\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.13: Page number 208-209\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector supply voltage in V\n",
+ "VEE=-20.0; #Emitter supply voltage in V\n",
+ "RB=100.0; #Base resistor's resistance in k\u2126\n",
+ "RC=4.7; #Collector resistor's resistance in k\u2126\n",
+ "RE=10.0; #Emitter resistor's resistance in k\u2126\n",
+ "beta1=85.0; #Base current amplification factor for case 1 \n",
+ "beta2=100.0; #Base current amplification factor for case 1\n",
+ "VBE_1=0.7; #Base emitter voltage for case 1 in V\n",
+ "VBE_2=0.6; #Base emitter voltage for case 2 in V\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#For beta=85 and VBE=0.7,\n",
+ "#As calculated in the previous question,\n",
+ "IC_1=1.73; #Collector current in mA.\n",
+ "VCE_1=14.6; #Collector-emitter voltage in V.\n",
+ "\n",
+ "\n",
+ "#For case (ii)\n",
+ "#beta=100 and VBE=0.6\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along the base-emitter circuit (input circuit),\n",
+ "#we get,IB*RB +IE*RE +VBE -VEE=0.\n",
+ "#Since IB=IC/beta and IC~IE,\n",
+ "#(IE/beta)*RB + IE*RE + VBE +VEE =0.\n",
+ "IE_2=round((-VEE-VBE_2)/(RE + RB/beta2),2); #Emitter current in mA\n",
+ "IC_2=IE_2; #Collector current (approximately equal to emitter current) in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law from VCC till collector terminal,\n",
+ "#we get, VCC - IC*RC =VC\n",
+ "VC=round(VCC-IC_2*RC,1); #voltage at collector terminal in V\n",
+ "\n",
+ "#Applying Kirchhoff's law from emitter terminal to VEE\n",
+ "#we get, VE -IE*RE =VEE\n",
+ "VE=round(VEE + IE_2*RE,1); #Voltage at emitter treminal in V\n",
+ "\n",
+ "VCE_2=VC-VE; #Collector-emitter voltage in V\n",
+ "\n",
+ "\n",
+ "change_IC= (IC_2-IC_1)*100/IC_1; #%age change in collector current\n",
+ "\n",
+ "change_VCE=(VCE_2-VCE_1)*100/VCE_2; #%age change in collector-emitter voltage\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Percentage change in collector current =%.1f%%\"%change_IC);\n",
+ "print(\"Percentage change in collector-emitter voltage =%.1f%%\"%change_VCE);"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Percentage change in collector current =1.7%\n",
+ "Percentage change in collector-emitter voltage =-3.5%\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.14: Page number 210\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector supply voltage in V\n",
+ "VBE=0.7 #Base-emitter voltage in V\n",
+ "RB=100.0; #Base resistor's resistance in k\u2126\n",
+ "RC=1.0; #Collector resistor's resistance in k\u2126\n",
+ "beta=100.0; #base current amplification factor\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's law along input circuit,\n",
+ "#we get, VCC -IC*RC -IB*RB -VBE=0.\n",
+ "#since IC= beta*IB,\n",
+ "#We get,\n",
+ "IB=(VCC-VBE)/(RB + beta*RC); #Base current in mA\n",
+ "IC=beta*IB; #Collector current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit,\n",
+ "#we get, VCC-VCE - IC*RC=0.\n",
+ "#From the above equation,\n",
+ "VCE=VCC-IC*RC; #Collector emitter voltage in V\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The operating point : VCE=%.2fV and IC=%.2fmA.\"%(VCE,IC));\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The operating point : VCE=10.35V and IC=9.65mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.15: Page number 210-211\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage in V\n",
+ "VBE=0.3; #Base emitter voltage in V\n",
+ "IC=1.0; #Collector current in mA\n",
+ "VCE=8.0; #Collector emitter voltage in V\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#Case(i)\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit,\n",
+ "#we get, VCC-IC*RC-VCE=0.\n",
+ "#from the above equation we get,\n",
+ "RC=(VCC-VCE)/IC; #Collector load in kilo ohm\n",
+ "IB=IC/beta; #Base current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along input circuit\n",
+ "#we get, VCC-VBE-(beta*IB*RC)-IB*RB=0.\n",
+ "#From the above equation we get,\n",
+ "RB=round((VCC-VBE-beta*IB*RC)/IB,0); #Base resistor's resistance in k\u2126\n",
+ "\n",
+ "#Results\n",
+ "print(\"The resistance value of base resistor=%d k\u2126 and collector load= %d k\u2126.\"%(RB,RC));\n",
+ "\n",
+ "#Case(ii)\n",
+ "\n",
+ "beta=50;\n",
+ "\n",
+ "#Applying Kirchhoff's law along input circuit,\n",
+ "#we get, VCC -IC*RC -IB*RB -VBE=0.\n",
+ "#since IC= beta*IB,\n",
+ "#We get,\n",
+ "IB=(VCC-VBE)/(RB + beta*RC); #Base current in mA\n",
+ "IC=beta*IB; #Collector current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit,\n",
+ "#we get, VCC-VCE - IC*RC=0.\n",
+ "#From the above equation,\n",
+ "VCE=round(VCC-IC*RC,1); #Collector emitter voltage in V\n",
+ "\n",
+ "#Results\n",
+ "print(\"The operating point : VCE=%.1fV and IC=%.1fmA.\"%(VCE,IC));\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The resistance value of base resistor=770 k\u2126 and collector load= 4 k\u2126.\n",
+ "The operating point : VCE=9.6V and IC=0.6mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.16 : Page number 211"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCE=2.0; #Collector-emitter voltage at operating point in V\n",
+ "VBE=0.7; #Base-emitter voltage in V \n",
+ "IC=1.0; #Collector current at operating point in mA\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "IB=IC/beta; #Base current in mA\n",
+ "\n",
+ "#As, VCE=VCB +VBE\n",
+ "#we get,\n",
+ "VCB=VCE-VBE; #Collector-base voltage in V\n",
+ "RB=VCB/IB; #Base resistor's resistance in k\u2126\n",
+ "\n",
+ "#Results\n",
+ "print(\"Value of base resistor's resistance=%d k\u2126.\"%RB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Value of base resistor's resistance=130 k\u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.17 : Page number 211-212"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage in V\n",
+ "VBE=0.7 #Base-emitter voltage in V\n",
+ "RB=400.0; #Base resistor's resistance in k\u2126\n",
+ "RC=4.0; #Collector resistor's resistance in k\u2126\n",
+ "RE=1.0; #Emitter resistor's resistance in k\u2126\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's law along outut circuit,\n",
+ "#we get, VCC -(IC+IB)*RC -IB*RB -VBE - IE*RE=0.\n",
+ "#since IC= beta*IB, IC+IB ~ IC and IE~IC,\n",
+ "#We get, VCC - IC*RC -(IC/beta)*RB -VBE - IE*RE\n",
+ "IC=(VCC-VBE)/(RB/beta + RC + RE); #Collector current current in mA.\n",
+ "IE=IC; #Emitter current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit,\n",
+ "#we get, VCC-VCE - IC*RC -IE*RE=0. (IE~IC)\n",
+ "#From the above equation,\n",
+ "VCE=VCC-IC*(RC+RE); #Collector emitter voltage in V\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The operating point : VCE=%.1fV and IC=%.2fmA.\"%(VCE,IC));\n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The operating point : VCE=5.7V and IC=1.26mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 25
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.18 : Page number 212"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage in V\n",
+ "RB=100.0; #Base resistor's resistance in k\u2126\n",
+ "RC=10.0; #Collector resistor's resistance in k\u2126\n",
+ "RE=0; #Emitter resistor's resistance in k\u2126\n",
+ "VBE=0.7; #Base-emitter voltage in V\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's law along outut circuit,\n",
+ "#we get, VCC -(IC+IB)*RC -IB*RB -VBE - IE*RE=0.\n",
+ "#since IC= beta*IB, IC+IB ~ IC and IE~IC,\n",
+ "#We get, VCC - IC*RC -(IC/beta)*RB -VBE - IE*RE\n",
+ "IC=(VCC-VBE)/(RC +RB/beta + RE); #Collector current in mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit,\n",
+ "#we get, VCC-VCE - IC*RC =0. (IE~IC)\n",
+ "#From the above equation,\n",
+ "VCE=VCC-IC*RC; #Collector-emitter voltage in V\n",
+ "\n",
+ "#Results\n",
+ "print(\"The d.c bias values are: VCE=%.2fV and IC=%.3fmA\"%(VCE,IC));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The d.c bias values are: VCE=1.55V and IC=0.845mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.19: Page number 214-215\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import matplotlib.pyplot as plt\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage in V\n",
+ "R1=10.0; #Resistor R1's resistance in k\u2126\n",
+ "R2=5.0; #Resistor R2's resistance in k\u2126\n",
+ "RC=1.0; #Collector resistor's resistance in k\u2126 \n",
+ "RE=2.0; #Emitter resistor's resistance in k\u2126\n",
+ "VBE=0.7; #Base-emitter voltage in V\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's law along output circuit\n",
+ "#VCE=VCC-IC*(RC+RE);\n",
+ "#IC=0, for VCE_max\n",
+ "VCE_max=VCC; #Maximum collector-emitter voltage in V\n",
+ "#VCE=0, for IC_max\n",
+ "IC_max=VCC/(RC+RE); #Maximum collector current in mA\n",
+ "\n",
+ "#Operating point\n",
+ "V2=(VCC*R2)/(R1+R2); #Voltage across R2 resistor V\n",
+ "IE=(V2-VBE)/RE; #Emitter current in mA\n",
+ "IC=IE; #Collector current(Approx. equal to emitter current) in mA\n",
+ "VCE=VCC-IC*(RC+RE); #Collector-emitter voltage in V\n",
+ "\n",
+ "#Results\n",
+ "print(\"Collector-emitter voltage at operating point=%.2fV\"%VCE);\n",
+ "print(\"Collector current at operating point = %.2fmA\"%IC);\n",
+ "\n",
+ "#plot\n",
+ "limit = plt.gca()\n",
+ "limit.set_xlim([0,20])\n",
+ "limit.set_ylim([0,6])\n",
+ "VCE=[i for i in range(0,(int)(VCC+1))]; #Plot variable for V_CE\n",
+ "IC=[((VCC-i)/(RC+RE)) for i in (VCE[:])]; #Plot variable for I_C\n",
+ "\n",
+ "p=plot(VCE,IC);\n",
+ "xlabel(\"VCE(V)\");\n",
+ "ylabel(\"IC(mA)\");\n",
+ "title(\"d.c load line\");\n",
+ "show(p);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector-emitter voltage at operating point=8.55V\n",
+ "Collector current at operating point = 2.15mA\n"
+ ]
+ },
+ {
+ "metadata": {},
+ "output_type": "display_data",
+ "png": "iVBORw0KGgoAAAANSUhEUgAAAXsAAAEZCAYAAAB2AoVaAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XtUVPXaB/DvIHhBQVEBQUQUNZVBGEBTChk0KD14SVJB\nQ0KpXvW4JFtvpeekvLXyZOEpseyc1/DSUYEuWqZgFq9jLi/RQTwqdg6SYgiYdwUNuc37x45RUJAZ\nZs/eM/v7WYuVzsD8HmZNz/x8Zu/9Ven1ej2IiMim2UldABERiY/NnohIAdjsiYgUgM2eiEgB2OyJ\niBSAzZ6ISAHY7EnWnnvuObz++uvteoySkhLY2dmhoaHBTFXdpdVqkZ6e/sD7UlJSEB8fDwD45Zdf\n4OTkBB7pTFKxl7oAotaoVCqoVCqpy2hRa/Xde7u3tzcqKystVRbRfbizJ9mz1t2wtdZNtonNnmSl\noKAAQUFBcHZ2RmxsLKqrq1v83oaGBqxcuRKDBg2Cs7MzQkJCcP78+YeuUV5ejsmTJ6NXr14YPHgw\nPv74Y8N9eXl5GDNmDFxcXODp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kRtUFBQgPfeew+ffPJJq993584daLVaHDx4EHZ23EuRfPDVSNQGGo0GERERaGho\naPX7SktLsWrVKjZ6kh3u7ImIFIDbDyIiBWCzJyJSADZ7IiIFYLMnIlIANnsiIgX4fwAbXN1xo6Og\nAAAAAElFTkSuQmCC\n",
+ "text": [
+ "<matplotlib.figure.Figure at 0x7f8eeacf1ad0>"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.20: Page number 215-216\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage in V\n",
+ "R1=10.0; #Resistor R1's resistance in k\u2126 .\n",
+ "R2=5.0; #Resistor R2's resistance in k\u2126 .\n",
+ "RC=1.0; #Collector resistor's resistance in k\u2126 . \n",
+ "RE=2.0; #Emitter resistor's resistance in k\u2126 .\n",
+ "VBE=0.7; #Base-emitter voltage in V\n",
+ "\n",
+ "#Calculations\n",
+ "#Using Thevenin's Theorem for replacing circuit consisting of VCC,R1,R2\n",
+ "E0=(VCC*R2)/(R1+R2); #Thevenin's voltage in V\n",
+ "R0=(R1*R2)/(R1+R2); #Thevenin's equivalent resistance in k\u2126 .\n",
+ "\n",
+ "#Applying Kirchhoff' law along thevenin's equivalent circuit,\n",
+ "#E0=IB*R0+VBE+IE*RE;\n",
+ "#Since IE~IC and IC=beta*IB\n",
+ "#IC=(E0-VBE)/(R0/beta +RE);\n",
+ "IC=(E0-VBE)/RE; #(Since R0/beta << RE) collector current in mA\n",
+ "VCE=VCC-IC*(RC+RE); #Collector emitter voltage in V\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Collector-emitter voltage at operating point=%.2fV\"%VCE);\n",
+ "print(\"Collector current at operating point = %.2fmA\"%IC);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Collector-emitter voltage at operating point=8.55V\n",
+ "Collector current at operating point = 2.15mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.21: Page number 216-217\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage in V\n",
+ "RE=1.0; #Emitter resistor, k\u2126 .\n",
+ "R1=50.0; #Resistor R1, k\u2126 .\n",
+ "R2=10.0; #Resistor R2, k\u2126 .\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#(i)\n",
+ "VBE=0.1; #Base-emitter voltage in V\n",
+ "V2=(VCC*R2)/(R1+R2); #Voltage drop across resistor R2, V \n",
+ "IE=(V2-VBE)/RE; #Emitter current in mA\n",
+ "\n",
+ "print(\"(i)Emitter current= %.1fmA\"%IE);\n",
+ "\n",
+ "#(ii)\n",
+ "VBE=0.3; #Base-emitter voltage in V\n",
+ "V2=(VCC*R2)/(R1+R2); #Voltage drop across resistor R2, V\n",
+ "IE=(V2-VBE)/RE; #Emitter current in mA\n",
+ "\n",
+ "print(\"(ii)Emitter current= %.1fmA\"%IE);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i)Emitter current= 1.9mA\n",
+ "(ii)Emitter current= 1.7mA\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.22: Page number 217\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=20.0; #Collector supply voltage, V\n",
+ "R1=10.0; #Resistor R1, k\u2126\n",
+ "R2=10.0; #Resistor R2, k\u2126 .\n",
+ "RC=1.0; #Collector resistor, k\u2126 .\n",
+ "RE=5.0; #Emitter resistor, k\u2126 .\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "V2=(VCC*R2)/(R1+R2); #Voltage drop across resistor R2, V\n",
+ "\n",
+ "#Applying kirchhoff's law from base terminal to emitter resistor\n",
+ "#V2=VBE+IE*RE\n",
+ "#VBE is neglected due to its small value\n",
+ "\n",
+ "IE=V2/RE; #Emitter current in mA\n",
+ "IC=IE; #Collector current (approx. equal to emitter current), mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along output circuit\n",
+ "VCE=VCC-IC*(RC+RE); #Collector-emitter voltage , V\n",
+ "VC=VCC-IC*RC; #Voltage at collector terminal,V\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Emitter current =%dmA\"%IE);\n",
+ "print(\"Collector-emitter voltage=%dV\"%VCE);\n",
+ "print(\"Collector terminal's voltage=%dV\"%VC);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Emitter current =2mA\n",
+ "Collector-emitter voltage=8V\n",
+ "Collector terminal's voltage=18V\n"
+ ]
+ }
+ ],
+ "prompt_number": 32
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.23: Page number 219-220\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "VCC=12.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=50; #Base current amplification factor\n",
+ "R1=150; #Resistor R1, k\u2126 .\n",
+ "R2=100; #Resistor R2, k\u2126 .\n",
+ "RC=4.7; #Collector resistor, k\u2126 .\n",
+ "RE=2.2; #Emitter resistor, k\u2126 .\n",
+ "\n",
+ "#Calculations\n",
+ "#Using Thevenin's theorem, calculating Thevenin's voltage and resistance\n",
+ "E0=(VCC*R2)/(R1+R2); #Thevenin's voltage, V\n",
+ "R0=(R1*R2)/(R1+R2); #Thevenin's resistance, k\u2126 .\n",
+ "\n",
+ "#Applying Kirchhoff' law along thevenin's equivalent circuit,\n",
+ "#E0=IB*R0+VBE+IE*RE;\n",
+ "#Since IE~IC and IC=beta*IB\n",
+ "IB=round((E0-VBE)/(R0+beta*RE),3); #Base current in mA\n",
+ "IC=round(beta*IB,1); #Collector current, mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit\n",
+ "VCE=VCC-IC*(RC+RE); #Collector-emitter voltage, V\n",
+ "\n",
+ "S=(beta+1)*(1+R0/RE)/(beta +1+R0/RE); #Stability factor\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Operating point : VCE= %.2fV and IC=%.1fmA\"%(VCE,IC));\n",
+ "print(\"Stability factor=%.1f\"%S);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point : VCE= 3.72V and IC=1.2mA\n",
+ "Stability factor=18.4\n"
+ ]
+ }
+ ],
+ "prompt_number": 33
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.24 : Page number 220\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage , V\n",
+ "beta=100.0; #Base current amplification factor\n",
+ "R1=6.0; #Resistor R1, k\u2126 .\n",
+ "R2=3.0; #Resistor R2, k\u2126 .\n",
+ "RC=470.0; #Collector resistor, \u2126.\n",
+ "RE=1.0; #Emitter resistor, k\u2126 .\n",
+ "\n",
+ "#Calculations\n",
+ "#Using Thevenin's theorem, calculating Thevenin's voltage and resistance\n",
+ "E0=(VCC*R2)/(R1+R2); #Thevenin's voltage, V\n",
+ "R0=(R1*R2)/(R1+R2); #Thevenin's resistance, k\u2126 .\n",
+ "\n",
+ "#Applying Kirchhoff' law along thevenin's equivalent circuit,\n",
+ "#E0=IB*R0+VBE+IE*RE;\n",
+ "#Since IE~IC and IC=beta*IB\n",
+ "IB=round((E0-VBE)/(R0+beta*RE),3); #Base current in mA\n",
+ "IC=round(beta*IB,1); #Collector current, mA\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit\n",
+ "VCE=VCC-IC*(RC/1000+RE); #Collector-emitter voltage, V\n",
+ "\n",
+ "S=(beta+1)*(1+R0/RE)/(beta +1+R0/RE); #Stability factor\n",
+ "\n",
+ "#Results\n",
+ "print(\"Operating point : VCE= %.2fV and IC=%.1fmA\"%(VCE,IC));\n",
+ "print(\"Stability factor=%.2f\"%S);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point : VCE= 8.83V and IC=4.2mA\n",
+ "Stability factor=2.94\n"
+ ]
+ }
+ ],
+ "prompt_number": 36
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.25 : Page number 221-222\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Varaible declaration\n",
+ "VCC=9; #Collector supply voltage, V\n",
+ "VCE=3; #Collector-emitter voltage, V\n",
+ "VBE=0.3; #Base-emitter voltage in V\n",
+ "RC=2.2; #Collector resistor , k\u2126 .\n",
+ "IC=2; #Collector current, mA\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "IB=IC/beta; #Base current in mA\n",
+ "\n",
+ "#According to given relation, I1=10*IB\n",
+ "I1=IB*10; #Current through the resistor R1, mA\n",
+ "\n",
+ "#I1=VCC/(R1+R2), .'s LAW\n",
+ "R1_R2_sum=VCC/I1; #Sum of the resistor's R1 and R2, k\u2126 (OHM'S LAW).\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit\n",
+ "#VCC=IC*RC+VCE+IE*RE\n",
+ "#IC~IE\n",
+ "RE=(VCC-IC*RC-VCE)/IC; #Emitter resistor, k\u2126 .\n",
+ "RE=round(RE*1000,0); #Emittter resistor, \u2126 .\n",
+ "\n",
+ "IE=IC; #Emittter current(approximately equal to collector current), mA\n",
+ "VE=IE*(RE/1000); #Voltage at emitter terminal (OHM's LAW), V\n",
+ "V2=VBE+VE; #Voltage drop across resistor R2, V\n",
+ "\n",
+ "R2=V2/I1; #Resistor R2,(OHM's LAW), k\u2126 .\n",
+ "R1=R1_R2_sum-R2; #Resistor R1, k\u2126 .\n",
+ "\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"RE=%d \u2126., R1=%.2f k\u2126 . and R2=%.2f k\u2126 .\"%(RE,R1,R2));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "RE=800 \u2126., R1=17.75 k\u2126 . and R2=4.75 k\u2126 .\n"
+ ]
+ }
+ ],
+ "prompt_number": 38
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.26 : Page number 222\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=16.0; #Collector supply voltage, V\n",
+ "R2=20.0; #Resistor R2, k\u2126\n",
+ "RE=2.0; #Emitter resistor, k\u2126\n",
+ "VCE=6.0; #Collector-emitter voltage, V\n",
+ "IC=2.0; #Collector current , mA\n",
+ "VBE=0.3; #Base-emitter voltage,V\n",
+ "alpha=0.985; #Current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "beta=alpha/(1-alpha); #Base current amplificatioon factor\n",
+ "IE=IC; #Emitter current, mA\n",
+ "IB=IC/beta; #Base current, mA\n",
+ "VE=IE*RE; #Emitter voltage,(OHM's LAW) V\n",
+ "V2=VBE+VE; #Voltage drop across resistor R2,(Kirchhoff's law) V\n",
+ "V_R1=VCC-V2; #Voltage drop across resistor R1, V\n",
+ "I1=V2/R2; #Current through resistor R2 an R1,(OHM's LAW) mA\n",
+ "R1=V_R1/I1; #Resistor R1,(OHM's LAW) k\u2126\n",
+ "\n",
+ "V_RC=(VCC-VCE-VE); #Voltage across collector resistor, V\n",
+ "RC=V_RC/IC; #Collector resistor,(OHM's LAW) k\u2126\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"R1=%.1f k\u2126 and RC=%d k\u2126.\"%(R1,RC));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "R1=54.4 k\u2126 and RC=3 k\u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 37
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.27 :Page number 222-223\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=15.0; #Collector supply voltage, V\n",
+ "R1=10.0; #Resistor R1, k\u2126 \n",
+ "R2=5.0; #Resistor R2, k\u2126 \n",
+ "RC=1.0; #Collector resistor, k\u2126 \u007f\n",
+ "RE=2.0; #Emitter resistor, k\u2126 \n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=100; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "#Using Thevenin's theorem, calculating Thevenin's voltage and resistance\n",
+ "E0=(VCC*R2)/(R1+R2); #Thevenin's voltage, V\n",
+ "R0=(R1*R2)/(R1+R2); #Thevenin's resistance, k\u2126 \n",
+ "\n",
+ "#Applying Kirchhoff' law along Thevenin's equivalent circuit,\n",
+ "#E0=IB*R0+VBE+IE*RE;\n",
+ "#Since IE~IC and IB=IE/beta,\n",
+ "IE=(E0-VBE)/(R0/beta + RE); #Emitter current , mA\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "print(\"The exact value of emitter current in the circuit = %.2fmA.\"%IE);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The exact value of emitter current in the circuit = 2.11mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 40
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.28: Page number 223-224\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "#Variable declaration\n",
+ "IE=2.0; #Emitter current, mA\n",
+ "IB=50.0; #Base current, mA\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "VBE=0.2; #Base-emitter voltage, V\n",
+ "R2=10.0; #Resistor R2, k\u2126\n",
+ "RE=1.0; #Emitter resistance, k\u2126\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's law from the base to the emitter resistor,\n",
+ "V2=VBE+IE*RE; #Voltage at base terminal, V\n",
+ "I2=V2/R2; #Current through the resistor R2, mA\n",
+ "I1=I2+IB/1000; #Current through the resistor R2, mA\n",
+ "V1=VCC-V2; #Voltage drop across the resistor R2\n",
+ "R1=V1/I1; #Resistor R1, k\u2126\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"The value of the resistor R1=%.2f k\u2126.\"%R1);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of the resistor R1=28.89 k\u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 41
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.30 :Page number 225-226\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=8.0; #Collector supply voltage, V\n",
+ "RB=360.0; #Base resistor, k\u2126\n",
+ "RC=2.0; #Collector resistor, k\u2126\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=100.0; #base current amplification factor\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "IC_max=VCC/RC; #Maximum collector current, mA\n",
+ "VCE_max=VCC; #Maximum collector voltage, V\n",
+ "\n",
+ "#Operating point\n",
+ "#Applying Kirchhoff's law along the input circuit\n",
+ "IB=(VCC-VBE)/RB; #Base current, mA\n",
+ "IC=beta*IB; #Collector current, mA\n",
+ "\n",
+ "#Kirchhoff' law along the output circuit\n",
+ "VCE=VCC-IC*RC; #Collector-emitter voltage, V\n",
+ "\n",
+ "#Results\n",
+ "print(\"VCE=%.2fV, is approximately half of VCC=%dV \\n therefore it is mid-point biased.\"%(VCE,VCC));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "VCE=3.94V, is approximately half of VCC=8V \n",
+ " therefore it is mid-point biased.\n"
+ ]
+ }
+ ],
+ "prompt_number": 42
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.31: page number 226\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=50.0; #Base current amplification factor\n",
+ "R1=12.0; #Resistor R1, k\u2126 \n",
+ "R2=2.7; #Resistor R2, k\u2126 \n",
+ "RC=620.0; #Collector resistor, \u2126 \n",
+ "RE=180.0; #Emitter resistor, \u2126\n",
+ "\n",
+ "\n",
+ "#Calculations\n",
+ "#Voltage divder rule across R1 and R2\n",
+ "V2=round((VCC*R2)/(R1+R2),2); #Voltage drop across resistor R2, V\n",
+ "IE=round(((V2-VBE)/RE)*1000,2); #Emitter current, mA\n",
+ "IC=IE; #Collector current(Approximately equal to emitter current), mA\n",
+ "print(\"IC~IE=%.2fmA.\"%IC);\n",
+ "\n",
+ "#Applying Kirchhoff's law along the output circuit\n",
+ "VCE=VCC-(IC/1000)*(RC+RE); #Collector-emitter voltage, V\n",
+ "\n",
+ "#Results\n",
+ "print(\"VCE=%.2fV, is approximately half of VCC=%dV \\n therefore it is mid-point biased.\"%(VCE,VCC));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "IC~IE=6.33mA.\n",
+ "VCE=4.94V, is approximately half of VCC=10V \n",
+ " therefore it is mid-point biased.\n"
+ ]
+ }
+ ],
+ "prompt_number": 49
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.32 : Page number 227\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import sqrt\n",
+ "\n",
+ "#Variable declaration\n",
+ "VCC=10.0; #Collector supply voltage, V\n",
+ "IC=10.0; #Collector current, mA \n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "R1=1.5; #Resistor R1, k\u2126 \n",
+ "R2=680.0; #Resistor R2, \u2126 \n",
+ "RC=260.0; #Collector resistor, \u2126 \n",
+ "RE=240.0; #Emitter resistor, \u2126 \n",
+ "beta_min=100; #Minimum value of base current amplification factor\n",
+ "beta_max=400; #Maximum value of base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "#Voltage divder rule across R1 and R2\n",
+ "V2=round((VCC*R2/1000)/(R1+R2/1000),2); #Voltage drop across resistor R2, V\n",
+ "IE=round((V2-VBE)/(RE/1000),0); #OHM' LAW, Emitter current, mA\n",
+ "IC=IE; #Collector current(approx. equal to emitter current),mA\n",
+ "beta_avg=sqrt(beta_min*beta_max); #Average value of base current amplification factor\n",
+ "IB=IE/(beta_avg +1); #Base current, mA\n",
+ "IB=IB*1000; #Base current, \ud835\udf07A\n",
+ "\n",
+ "#Results\n",
+ "print(\"Base current= %.2f \ud835\udf07A\"%IB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Base current= 49.75 \ud835\udf07A\n"
+ ]
+ }
+ ],
+ "prompt_number": 51
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.33 : Page number 227-228\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VEE=12.0; #Emitter supply voltage, V\n",
+ "RC=1.5; #Collector resistor, k\u2126\n",
+ "RB=120.0; #Base resistor k\u2126\n",
+ "RE=510.0; #Emitter resistor, \u2126 \n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=60.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's voltage law,\n",
+ "#IB*RB - VBE - IE*RE +VEE=0\n",
+ "#Since IE~IC and IC=beta*IB,\n",
+ "IB=(VEE-VBE)/(RB + beta*RE/1000); #Base current , mA\n",
+ "IC=round(beta*IB,1); #Collector current, mA\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along output circuit,\n",
+ "VCE=VEE-IC*(RC + RE/1000); #Collector-emitter voltage, V\n",
+ "\n",
+ "\n",
+ "#Results\n",
+ "print(\"Operating point : VCE= %.2fV and IC=%.1fmA.\"%(VCE,IC));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point : VCE= 2.96V and IC=4.5mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 60
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.34 : Page number 228-229\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from math import floor\n",
+ "\n",
+ "#Variable declaration\n",
+ "VEE=9.0; #Emitter supply voltage, V\n",
+ "RC=1.2; #Collector resistor, k\u2126\n",
+ "RB=100.0; #Base resistor ,k\u2126\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "beta=45.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "#Applying Kirchhoff's voltage law,\n",
+ "#IB*RB + VBE=VEE\n",
+ "#Since IE~IC and IC=beta*IB,\n",
+ "IB=round((VEE-VBE)/RB,3); #Base current , mA\n",
+ "IC=floor(beta*IB*100)/100; #Collector current, mA\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law along output circuit,\n",
+ "VCE=VEE-IC*RC; #Collector-emitter voltage, V\n",
+ "\n",
+ "#Results\n",
+ "print(\"Operating point : VCE= %.2fV and IC=%.2fmA.\"%(VCE,IC));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Operating point : VCE= 4.52V and IC=3.73mA.\n"
+ ]
+ }
+ ],
+ "prompt_number": 68
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.35 : Page number 229\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "VCC=16.0; #Collector supply voltage, V\n",
+ "VBE=0.7; #Base-emitter voltage, V\n",
+ "IC=1.0; #Collector current, mA\n",
+ "VCE=6.0; #Collector-emitter voltage, V\n",
+ "beta=150.0; #Base current amplification factor\n",
+ "\n",
+ "#Calculations\n",
+ "#For a good design, VE=VCC/10;\n",
+ "VE=VCC/10; #Emitter terminal's voltage, V\n",
+ "#OHM's Law\n",
+ "#And, taking IE~IC\n",
+ "RE=VE/IC; #Emitter resistor, k\u2126\n",
+ "\n",
+ "#Applying Kirchhoff's voltage law alog output circuit:\n",
+ "#VCC=IC*RC + VCE + VE\n",
+ "RC=(VCC-VCE-VE)/IC; #Collector resistor, k\u2126\n",
+ "V2=VE+VBE; #Voltage drop across resistor R2,V\n",
+ "#From the relation I1=10*IB\n",
+ "R2=(beta*RE)/10; #Resistor R2, kilo ohm\n",
+ "\n",
+ "#From voltage divider rule across R1 and R2,\n",
+ "#V2=(VCC*R2)/(R1+R2)\n",
+ "R1=(VCC-V2)*R2/V2; #Resistor R1, k\u2126 \n",
+ "\n",
+ "#Results\n",
+ "print(\"RE=%.1f k\u2126 , RC=%.1f k\u2126, R1=%.0f k\u2126 and R2=%d k\u2126.\"%(RE,RC,R1,R2));\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "RE=1.6 k\u2126 , RC=8.4 k\u2126, R1=143 k\u2126 and R2=24 k\u2126.\n"
+ ]
+ }
+ ],
+ "prompt_number": 69
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.36 : Page number 230-231\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "ICBO=5.0; #Collector to base leakage current, microampere\n",
+ "beta=40.0; #Base current amplification factor\n",
+ "IC_zero_signal=2.0; #Zero signal collector current, mA\n",
+ "op_temp=25.0; #operating temperature, degree celsius\n",
+ "temp_risen=55.0; #Temperature risen, degree celsius\n",
+ "temp_ICBO_doubles=10.0; #Temperature after which ICBO doubles, degree celsius\n",
+ "\n",
+ "#Calculations\n",
+ "\n",
+ "#(i)\n",
+ "ICEO=(beta+1)*ICBO; #Collector to emitter leakage current, microampere\n",
+ "\n",
+ "#(ii)\n",
+ "Number_of_times_ICBO_doubled=(temp_risen - op_temp)/temp_ICBO_doubles; #Number of times ICBO doubles\n",
+ "ICBO_final=ICBO*2**Number_of_times_ICBO_doubled; #Final value of collector to base leakage current, microampere\n",
+ "ICEO_final=ICBO_final*(beta + 1); #Final value of collector to emitter leakage current, microampere\n",
+ "\n",
+ "IC_zero_signal_55=(ICEO_final/1000) +IC_zero_signal; #Zero signal collector current at 55 degree celius\n",
+ "change=(IC_zero_signal_55-IC_zero_signal)*100/IC_zero_signal; #Percentage change in zero signal collector current\n",
+ "\n",
+ "#Result\n",
+ "print(\"(i) The percentage change in the zero signal collector current=%.0f%%. \"%change)\n",
+ "\n",
+ "#(iii)\n",
+ "#For the silicon transistor\n",
+ "ICBO=0.1; #Collector to base leakage current, microampere\n",
+ "\n",
+ "ICEO=(beta+1)*ICBO; #Collector to emitter leakage current, microampere\n",
+ "\n",
+ "Number_of_times_ICBO_doubled=(temp_risen - op_temp)/temp_ICBO_doubles; #Number of times ICBO doubles\n",
+ "ICBO_final=ICBO*2**Number_of_times_ICBO_doubled; #Final value of collector to base leakage current, microampere\n",
+ "ICEO_final=ICBO_final*(beta + 1); #Final value of collector to emitter leakage current, microampere\n",
+ "\n",
+ "IC_zero_signal_55=(ICEO_final/1000) +IC_zero_signal; #Zero signal collector current at 55 degree celius\n",
+ "change=(IC_zero_signal_55-IC_zero_signal)*100/IC_zero_signal; #Percentage change in zero signal collector current\n",
+ "\n",
+ "\n",
+ "#Result\n",
+ "print(\"(ii) The percentage change in the zero signal collector current=%.1f%%. \"%change)\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(i) The percentage change in the zero signal collector current=82%. \n",
+ "(ii) The percentage change in the zero signal collector current=1.6%. \n"
+ ]
+ }
+ ],
+ "prompt_number": 70
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 9.37 : Page number 231\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Variable declaration\n",
+ "ICBO=0.02 #Collector to base leakage current, \ud835\udf07A\n",
+ "alpha=0.99; #Current amplification factor\n",
+ "IE=1.0; #Emitter current, mA\n",
+ "op_temp=27.0; #operating temperature, degree celsius\n",
+ "temp_risen=57.0; #Temperature risen, degree celsius\n",
+ "temp_ICBO_doubles=6.0; #Temperature after which ICBO doubles, degree celsius\n",
+ "\n",
+ "#Calculations\n",
+ "Number_of_times_ICBO_doubled=(temp_risen - op_temp)/temp_ICBO_doubles; #Number of times ICBO doubles\n",
+ "ICBO_55=ICBO*2**Number_of_times_ICBO_doubled; #collector to base leakage current at 55 degree celsius, \ud835\udf07A\n",
+ "IC=alpha*IE + ICBO_55/1000; #Collector current, mA\n",
+ "IB=IE-IC; #Base current, mA\n",
+ "IB=IB*1000; #Base current,\ud835\udf07A\n",
+ "\n",
+ "#Results\n",
+ "print(\"Base current at 57 degree celsius=%.1f \ud835\udf07A \"%IB);\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Base current at 57 degree celsius=9.4 \ud835\udf07A \n"
+ ]
+ }
+ ],
+ "prompt_number": 71
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter10_ac_load_line_1.png b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter10_ac_load_line_1.png
new file mode 100644
index 00000000..d7feffd7
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter10_ac_load_line_1.png
Binary files differ
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter18_clipping_ckt_output_1.png b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter18_clipping_ckt_output_1.png
new file mode 100644
index 00000000..76486c7b
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter18_clipping_ckt_output_1.png
Binary files differ
diff --git a/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter8_dc_load_line_1.png b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter8_dc_load_line_1.png
new file mode 100644
index 00000000..9b26fbe2
--- /dev/null
+++ b/Principles_of_Electronics_____by_V.K._Mehta_and_Rohit_Mehta/screenshots/chapter8_dc_load_line_1.png
Binary files differ
diff --git a/Problems_in_Electrical_Engineering_by_Parker_Smith/Chapter1.ipynb b/Problems_in_Electrical_Engineering_by_Parker_Smith/Chapter1.ipynb
new file mode 100644
index 00000000..566ba120
--- /dev/null
+++ b/Problems_in_Electrical_Engineering_by_Parker_Smith/Chapter1.ipynb
@@ -0,0 +1,3260 @@
+{
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Appendix - Solved problems"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 2 Page 340"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 49,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Voltage Gradients :\n",
+ " for A : 1622 V/cm\n",
+ " for B : 1216 V/cm\n",
+ " for C : 811 V/cm\n",
+ "\n",
+ "Energy stored :\n",
+ " for A : 21.9 uJ\n",
+ " for B : 41.1 uJ\n",
+ " for C : 38.3 uJ\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "# Given\n",
+ "t1=2# # mm \n",
+ "t2=5# # mm \n",
+ "t3=7# # mm \n",
+ "eps1=3 # dielectric constant\n",
+ "eps2=4 # dielectric constant\n",
+ "eps3=6# # dielectric constant\n",
+ "eps0=1/36/pi*10**-9# # dielectric constant\n",
+ "d=10/100 # m\n",
+ "V=1500 # V \n",
+ "#E1*t1+E2*t2+E3*t3=V\n",
+ "#Voltage Gradients : \n",
+ "# using eps1*E1=eps2*E2=eps3*E3\n",
+ "E1=V/(t1+(eps1/eps2)*t2+(eps1/eps3)*t3)# V/mm \n",
+ "E1=E1*10 # V/cm\n",
+ "E2=eps1*E1/eps2 # V/cm\n",
+ "E3=eps1*E1/eps3 # V/cm\n",
+ "print \"Voltage Gradients :\\n for A : %.f V/cm\\n for B : %.f V/cm\\n for C : %.f V/cm\"%(E1,E2,E3)\n",
+ "\n",
+ "A = pi*d**2\n",
+ "W1=1/2*eps0*eps1*E1**2*10**4*A*t1*10**-3# # J\n",
+ "W2=1/2*eps0*eps2*E2**2*10**4*A*t2*10**-3# # J\n",
+ "W3=1/2*eps0*eps3*E3**2*10**4*A*t3*10**-3# # J\n",
+ "W1=W1*10**6 # # uJ\n",
+ "W2=W2*10**6 # # uJ\n",
+ "W3=W3*10**6 # # uJ\n",
+ "print \"\\nEnergy stored :\\n for A : %.1f uJ\\n for B : %.1f uJ\\n for C : %.1f uJ\"%(W1,W2,W3)\n",
+ "\n",
+ "\n",
+ "# Answer in the textbook are not accurate"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 3 Page 341"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 50,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Current required = 1.95 A\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "\n",
+ "# Given\n",
+ "N=680# # turns\n",
+ "fi=1.6*10**3 # Wb\n",
+ "d1=4/100 # m\n",
+ "d2=24/100 # m\n",
+ "l=0.6 # m\n",
+ "mu0=4*pi/10**7 # constant\n",
+ "\n",
+ "\n",
+ "# For air gap : \n",
+ "A=d1**2 # m**2\n",
+ "Bg=fi/A # weber/m**2\n",
+ "Hg=Bg/mu0 # AT/m\n",
+ "mmf1=0.001/mu0 # AT\n",
+ "\n",
+ "# For central limb : \n",
+ "A=d1**2 # m**2\n",
+ "Bc=fi/A # weber/m**2\n",
+ "Hc=900 # AT/m (from magnetization curve)\n",
+ "mmf2=Hc*d2 # AT\n",
+ "\n",
+ "\n",
+ "# For side limb : \n",
+ "fi=1/2*fi # Wb\n",
+ "A=d1**2 # m**2\n",
+ "Bc=fi/A # weber/m**2\n",
+ "Hc=520 # AT/m (from magnetization curve)\n",
+ "mmf3=Hc*l # AT\n",
+ "\n",
+ "mmf_total = mmf1+mmf2+mmf3 # AT\n",
+ "i=mmf_total/N # A\n",
+ "print \"Current required = %0.2f A\"%(i)\n",
+ "\n",
+ "\n",
+ "# Answer in the textbook are not accurate"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 4 Page 343"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 51,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "\t\t\tWithout air gap With air gap\n",
+ "\n",
+ "Exciting current 3.75 A 11.7 A\n",
+ "\n",
+ "Inductance 5.3 mH 1.7 mH\n",
+ "\n",
+ "Stored Energy 0.375 J 1.17 J\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "\n",
+ "# Given\n",
+ "\n",
+ "D=15/100 # m\n",
+ "A=10/10**-4 # m**2\n",
+ "N=200# # turns\n",
+ "fi=1.6*10**3 # Wb\n",
+ "B=1 # weber/m**2\n",
+ "mu0=4*pi/10**7 # constant\n",
+ "mur=500 # constant\n",
+ "lg=2/1000 # m\n",
+ "\n",
+ "\n",
+ "# without air gap\n",
+ "l=pi*D # m\n",
+ "R=l/mu0/mur/A # A/Wb\n",
+ "fi=B*A # Wb\n",
+ "mmf=fi*R # AT\n",
+ "I=mmf/N # A\n",
+ "L=N**2/R/10**6 # mH\n",
+ "E=1/2*L*I**2/100 # J\n",
+ "\n",
+ "\n",
+ "# with air gap\n",
+ "Rg=lg/mu0/A # A/Wb\n",
+ "Rt=R+Rg # A/Wb\n",
+ "fi=B*A # Wb\n",
+ "mmf=fi*Rt # AT\n",
+ "I2=mmf/N # A\n",
+ "L2=N**2/Rt/10**6 # mH\n",
+ "E2=1/2*L2*I2**2/100 # J\n",
+ "\n",
+ "print \"\\t\\t\\tWithout air gap With air gap\"\n",
+ "print \"\\nExciting current %.2f A %.1f A\"%(I,I2)\n",
+ "print \"\\nInductance %.1f mH %.1f mH\"%(L,L2)\n",
+ "print \"\\nStored Energy %.3f J %.2f J\"%(E,E2)\n",
+ "\n",
+ "\n",
+ "# Answer in the textbook are not accurate"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 5 Page 344"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 52,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Voltage acroos 100 ohm = -72.0 V\n",
+ "\n",
+ "R=37.5 ohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from numpy import array\n",
+ "\n",
+ "# Given\n",
+ "\n",
+ "VA=60 # V\n",
+ "I=0.6 # A\n",
+ "# (VB-VA)/20+(VB-VC)/20+VB/20-I=0\n",
+ "#3*VB-VC=72 for node B eqn(1)\n",
+ "#(VC-VA)/50+(VC-VB)/30+(VC-12)/50+VC/100=0\n",
+ "#-5*VB+10*VC=144 eqn(2)\n",
+ "A=array([[3, -1],[-5 ,10]])\n",
+ "B=array([[72],[144]])\n",
+ "X=A**-1*B#\n",
+ "VB=X[0,0] # V\n",
+ "VC=X[0,1] # V\n",
+ "print \"Voltage acroos 100 ohm = %.1f V\"%(VC)\n",
+ "VC=24 # V\n",
+ "VB=(72+VC)/3 # from eqn(1)\n",
+ "# Node C \n",
+ "# (VC-VA)/50+(VC-VB)/20+(VC-12)/50+VC/100+VC/R=0 eqn(3)\n",
+ "R=100*VC/(144+5*VB-10*VC) # ohm\n",
+ "print \"\\nR=%.1f ohm\"%(R)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 6 Page 346"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 53,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "\n",
+ "at f = 2.34 kHz, the above filter will have required attenuation.\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,cosh\n",
+ "\n",
+ "# Given\n",
+ "\n",
+ "Ro=600 # ohm\n",
+ "fc=2*1000 # Hz\n",
+ "alfa=10 # dB\n",
+ "\n",
+ "\n",
+ "L=Ro/pi/fc*1000 # mH\n",
+ "C=1/(pi*Ro*fc)*10**6 # uF\n",
+ "alfa=alfa/8.686 # nepers\n",
+ "f=fc*cosh(alfa/2)/1000 # kHz\n",
+ "print \"\\nat f = %.2f kHz, the above filter will have required attenuation.\"%(f)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 7 Page 347"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 54,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "equation for instant current:\n",
+ "i=2.13*sin(314*t+1.01)\n",
+ "Power consumed = 56.6 W\n",
+ "Voltage across capacitor = 73.3 V(+ve & -ve)\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,atan,sqrt,asin,sin\n",
+ "\n",
+ "# Given\n",
+ "#v=100*sin(314*t)\n",
+ "R=25 # ohm\n",
+ "C=80 # uF\n",
+ "omega=314 # radian\n",
+ "Vm=100 # V\n",
+ "\n",
+ "Xc=1/omega/(C*10**-6) # ohm\n",
+ "Z=sqrt(R**2+Xc**2) # ohm\n",
+ "Im=Vm/Z # A\n",
+ "theta=atan(Xc/R) # radian\n",
+ "print \"equation for instant current:\"\n",
+ "print \"i=%.2f*sin(%d*t+%.2f)\"%(Im,omega,theta)\n",
+ "P=(Im/sqrt(2))**2*R # W\n",
+ "print \"Power consumed = %.1f W\"%(P)\n",
+ "Vcm=Im*Xc # V \n",
+ "#(when i=Im/2)\n",
+ "i=0.5*Im # A\n",
+ "#vc=Vcm*sin(314*t+theta-pi/2)\n",
+ "#i=Im*sin(314*t+theta)\n",
+ "tt=asin(i/Im) # radian tt=314*t+theta\n",
+ "vcm=Vcm*sin(tt-pi/2)\n",
+ "print \"Voltage across capacitor = %.1f V(+ve & -ve)\"%(abs(vcm))"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 8 Page 348"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 55,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Capacitance of XC = 318 uF\n",
+ "Circuit current = 10 A and power = 1 kW\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from numpy import pi,roots\n",
+ "\n",
+ "# Given\n",
+ "\n",
+ "Z1=(6.25+1J*1.25) # ohm\n",
+ "Z2=(5+1J*0) # ohm\n",
+ "#Z3=(5-1J*XC) # ohm\n",
+ "V=100 # V\n",
+ "f=50 # Hz\n",
+ "#Z23=(250+5*Xc**2)/(100+Xc**2)-1J*(25*Xc)/(100+Xc**2)\n",
+ "#for in phase condition imag part must be zero\n",
+ "#5*Xc**2-100*Xc+5*100=0\n",
+ "A=[5 ,-100, 500] # polynomal \n",
+ "XC=roots(A)#\n",
+ "XC=XC[0] # ohm\n",
+ "C=1/(2*pi*f*XC)*10**6 # uF\n",
+ "print \"Capacitance of XC = %.f uF\"%(C)\n",
+ "Z=XC # ohm\n",
+ "I=V/Z # A\n",
+ "P=I**2*Z/1000 # kW\n",
+ "print \"Circuit current = %.f A and power = %.f kW\"%(I,P)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 9 Page 349"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 56,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "L = 10.4 mH\n",
+ " C=267 uF\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "\n",
+ "# Given\n",
+ "\n",
+ "omega_o=600 # rad/s\n",
+ "omega=400 # rad/s\n",
+ "R=3 # ohm\n",
+ "IBYIo=1/2 # ratio\n",
+ "\n",
+ "\n",
+ "fo=omega_o/2/pi # Hz\n",
+ "f=omega/2/pi # Hz\n",
+ "#I/Io=1/(sqrt(1+Q**2*(f/fo-fo/f)**2))\n",
+ "Q=sqrt(1/IBYIo**2-1)/(fo/f-f/fo)\n",
+ "#Q=1/omega_0/R/C\n",
+ "C=1/omega_o/R/Q*10**6 # uF\n",
+ "#Q=omega_0*L/R\n",
+ "L=Q*R/omega_o*1000 # mH\n",
+ "print \"L = %.1f mH\\n C=%.f uF\"%(L,C)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 10 Page 350"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 57,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Star Connection : P=1.6 kW\n",
+ "Delta Connection : P=4.8 kW\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,sqrt\n",
+ "\n",
+ "# Given\n",
+ "\n",
+ "V=400 # V\n",
+ "f=50 # Hz\n",
+ "n=3 # no of phase\n",
+ "R=100 # ohm\n",
+ "\n",
+ "#Star connection\n",
+ "Vph=V/sqrt(n) # V\n",
+ "Iph=Vph/R # A\n",
+ "IL=Iph # A\n",
+ "cos_fi=1 # for only resitor load\n",
+ "P=sqrt(3)*V*IL*cos_fi/1000 # kW\n",
+ "print \"Star Connection : P=%.1f kW\"%(P)\n",
+ "#Delta Connection\n",
+ "\n",
+ "Vph=V # V\n",
+ "Iph=Vph/R # A\n",
+ "IL=sqrt(3)*Iph # A\n",
+ "VL=Vph # V\n",
+ "P=sqrt(3)*VL*IL*cos_fi/1000 # kW\n",
+ "print \"Delta Connection : P=%.1f kW\"%(P)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 11 Page 351"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 58,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Phase Current:\n",
+ "Iab=10 angle=-53.13 degree \n",
+ "Ibc=10 angle=-156.87 degree \n",
+ "Ica=20 angle=156.87 degree \n",
+ "\n",
+ "\n",
+ " Line Current:\n",
+ "Iaa=29 angle=-33.03 degree \n",
+ "Ibb=10 angle=165.00 degree \n",
+ "Icc=15 angle=127.97 degree \n",
+ "\n",
+ "\n",
+ " Total Power, W=3 kW\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from numpy import exp,pi\n",
+ "import cmath as cm\n",
+ "# Given\n",
+ "Rab=6;Rbc=8;Rca=4 # ohm\n",
+ "Vab=100*exp(1J*0) # V\n",
+ "Vbc=100*exp(1J*-120*pi/180) # V\n",
+ "Vca=100*exp(1J*120*pi/180) # V\n",
+ "Zab=6+1J*8 # ohm\n",
+ "Zbc=8+1J*6 # ohm\n",
+ "Zca=4-1J*3 # ohm\n",
+ "\n",
+ "#Phase current\n",
+ "Iab=Vab/Zab # A\n",
+ "Ibc=Vbc/Zbc # A\n",
+ "Ica=Vca/Zca # A\n",
+ "print \"Phase Current:\"\n",
+ "print \"Iab=%.f angle=%.2f degree \"%(abs(Iab),cm.phase(Iab)*180/pi)\n",
+ "print \"Ibc=%.f angle=%.2f degree \"%(abs(Ibc),cm.phase(Ibc)*180/pi)\n",
+ "print \"Ica=%.f angle=%.2f degree \"%(abs(Ica),cm.phase(Ica)*180/pi)\n",
+ "#Line current\n",
+ "Iaa=Iab-Ica # A\n",
+ "Ibb=Ibc-Iab # A\n",
+ "Icc=Ica-Ibc # A\n",
+ "print \"\\n\\n Line Current:\"\n",
+ "print \"Iaa=%.f angle=%.2f degree \"%(abs(Iaa),cm.phase(Iaa)*180/pi)\n",
+ "print \"Ibb=%.f angle=%.2f degree \"%(abs(Iab),cm.phase(Ibb)*180/pi)\n",
+ "print \"Icc=%.f angle=%.2f degree \"%(abs(Icc),cm.phase(Icc)*180/pi)\n",
+ "#Power Consumed\n",
+ "Wab=abs(Iab)**2*Rab # W\n",
+ "Wbc=abs(Ibc)**2*Rbc # W\n",
+ "Wca=abs(Ica)**2*Rca # W\n",
+ "W=Wab+Wbc+Wca # W\n",
+ "W=W/1000 # kW\n",
+ "print \"\\n\\n Total Power, W=%.f kW\"%(W)\n",
+ "#Answer wrong for line current in the textbook."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 12 Page 353"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 59,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Wattmeter W1 reading=0 W\n",
+ "Wattmeter W2 reading=8000 W or 8 kW\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from numpy import exp,pi\n",
+ "import cmath as cm\n",
+ "\n",
+ "# Given\n",
+ "VRY=200*exp(1J*0) # V\n",
+ "VYB=200*exp(1J*-120*pi/180) # V\n",
+ "VBR=200*exp(1J*120*pi/180) # V\n",
+ "\n",
+ "\n",
+ "ZA=10*exp(1J*60*pi/180) # ohm\n",
+ "ZB=10*exp(1J*0*pi/180) # ohm\n",
+ "ZC=10*exp(1J*60*pi/180) # ohm\n",
+ "\n",
+ "#Phase current\n",
+ "IRY=VRY/ZA # A\n",
+ "IYB=VYB/ZB # A\n",
+ "IBR=VBR/ZC # A\n",
+ "\n",
+ "IR=IRY-IBR # A\n",
+ "PVA=(VRY).conjugate()*IR # W\n",
+ "print \"Wattmeter W1 reading=%.f W\"%((PVA.real))\n",
+ "IB=IBR-IYB # A\n",
+ "PVB=(-VYB).conjugate()*IB # W\n",
+ "print \"Wattmeter W2 reading=%.f W or %.f kW\"%((PVB.real),(PVB.real)/1000)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 13 Page 354"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 60,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "expression for current:\n",
+ "i = 9.83*sin(omega*t--38.1)+1.0*sin(3*omega*t-7.0)+0.25*sin(5*omega*t-74.3)\n",
+ "Irms=7 A\n",
+ " Vrms=181 V\n",
+ "Total Power, P=977 W\n",
+ "Power factor = 0.77\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from numpy import exp,pi,sqrt\n",
+ "import cmath as cm\n",
+ "# Given\n",
+ "#v=250*sin(omega*t)+50*sin(3*omega*t+pi/3)+20*sin(5*omega*t+5*pi/6)\n",
+ "V1=250;V3=50;V5=20 # V\n",
+ "fi1=0;fi3=60;fi5=150 # degree\n",
+ "R=20 # omh\n",
+ "L=0.05 # H\n",
+ "omega=314 # rad/s\n",
+ "\n",
+ "X1=omega*L # ohm\n",
+ "Z1=R+1J*X1 # ohm\n",
+ "X3=3*omega*L # ohm\n",
+ "Z3=R+1J*X3 # ohm\n",
+ "X5=5*omega*L # ohm\n",
+ "Z5=R+1J*X5 # ohm\n",
+ "r1=abs(Z1);t1=cm.phase(Z1)\n",
+ "r3=abs(Z3);t3=cm.phase(Z3)\n",
+ "r5=abs(Z5);t5=cm.phase(Z5)\n",
+ "print \"expression for current:\"\n",
+ "print \"i = %.2f*sin(omega*t-%.1f)+%.1f*sin(3*omega*t%.1f)+%.2f*sin(5*omega*t-%.1f)\"%(V1/r1,fi1-t1*180/pi,V3/r3,fi3-t3*180/pi,V5/r5,fi5-t5*180/pi)\n",
+ "\n",
+ "I1m=V1/r1 # A\n",
+ "I3m=V3/r3 # A\n",
+ "I5m=V5/r5 # A\n",
+ "Irms=sqrt(I1m**2/2+I3m**2/2+I5m**2/2) # A\n",
+ "Vrms=sqrt(V1**2/2+V3**2/2+V5**2/2) # A\n",
+ "print \"Irms=%.f A\\n Vrms=%.f V\"%(Irms,Vrms)\n",
+ "P=Irms**2*R # W\n",
+ "print \"Total Power, P=%.f W\"%(P)\n",
+ "cosfi=P/Vrms/Irms # Power factor\n",
+ "print \"Power factor = %.2f\"%(cosfi)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 14 Page 355"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 61,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "expression for current:\n",
+ "i = 12.1*sin(314*t-1.263)+0.95*e**(-100*t)\n",
+ "current after 0.02 sec is : -11.4 A\n",
+ "transient component is : 1.56 A\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,exp,sin,atan\n",
+ "\n",
+ "# Given\n",
+ "f=50 # Hz\n",
+ "Vm=400 # V\n",
+ "R=10 # ohm\n",
+ "L=0.1 # H\n",
+ "t=0.02 # sec\n",
+ "XL=2*pi*f*L # ohm\n",
+ "Z=R+1J*XL # ohm\n",
+ "Im=Vm/abs(Z) # A\n",
+ "fi=atan(XL/R) # degree\n",
+ "lamda=L/R # sec\n",
+ "print \"expression for current:\"\n",
+ "print \"i = %.1f*sin(314*t-%.3f)+0.95*e**(-100*t)\"%(Im,fi)\n",
+ "i = Im*sin(314*t-fi)+0.95*exp(-100*t) # A\n",
+ "print \"current after 0.02 sec is : %0.1f A\"%(i)\n",
+ "i2=Im*(0.95*exp(-100*t)) # A\n",
+ "print \"transient component is : %0.2f A\"%(i2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 15 Page 356"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 62,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Since R<2sqrt(L/C), the circuit is originally oscillatory.\n",
+ "Expression for current :\n",
+ " i = 0.000*exp(-50t)*sin(312.2t)\n",
+ "\n",
+ "\n",
+ " Additional resistance required = 1064 ohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,sqrt,asin,exp,sin\n",
+ "from sympy import Symbol,solve\n",
+ "from scipy.misc import derivative\n",
+ "\n",
+ "# Given\n",
+ "C=5*10**-6 # F\n",
+ "L=2 # H\n",
+ "R=200 # ohm\n",
+ "\n",
+ "if R<2*sqrt(L/C):\n",
+ " print \"Since R<2sqrt(L/C), the circuit is originally oscillatory.\"\n",
+ "\n",
+ "\n",
+ "a=R/2/L\n",
+ "omega = sqrt(1/L/C-R**2/4/L**2) # rad/s\n",
+ "#i=Im*exp(-a*t)*sin(omega*t+fi)\n",
+ "#at t=0 sec\n",
+ "i0=0 # A\n",
+ "vc=10 # V\n",
+ "fi=asin(i0) # degree\n",
+ "#L*di/dt=vc at t=0\n",
+ "Im=Symbol('Im')\n",
+ "def current(t):\n",
+ " i=Im*exp(-a*t)*sin(omega*t+fi)\n",
+ " return i\n",
+ "#i=Im*expm(-a*t)*sin(omega*t+fi)\n",
+ "\n",
+ "\n",
+ "LdiBYdt=L*derivative(current,0)\n",
+ "#temp = coeff(LdiBYdt)\n",
+ "Im=solve(LdiBYdt,Im)[0]\n",
+ "#vc/temp(2)\n",
+ "print \"Expression for current :\\n i = %.3f*exp(-%dt)*sin(%.1ft)\"%(Im,a,omega)\n",
+ "Rn=2*sqrt(L/C) # ohm\n",
+ "Rad=Rn-R # ohm\n",
+ "print \"\\n\\n Additional resistance required = %d ohm\"%(Rad)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 16 Page 357"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 63,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Reading of hot wire instrument = 0.548 A\n",
+ "Reading of electrostatic voltmeter acroos 1000 ohm = 547 V\n",
+ "Reading of electrostatic voltmeter acroos 1 mH inductor = 353 V\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,sqrt\n",
+ "\n",
+ "# Given\n",
+ "#i=0.5+0.3*sin(omega*t)-0.2*sin(2*omega*t)\n",
+ "I0=0.5;I1m=0.3;I2m=-0.2 # from above expression\n",
+ "Iav=I0 # A\n",
+ "R=1000 # ohm\n",
+ "L=1/1000 # H\n",
+ "\n",
+ "Irms=sqrt(I0**2+(I1m/sqrt(2)**2+(I2m/sqrt(2)**2))) # A\n",
+ "print \"Reading of hot wire instrument = %.3f A\"%(Irms)\n",
+ "VR=Irms*R # V\n",
+ "print \"Reading of electrostatic voltmeter acroos 1000 ohm = %d V\"%(VR)\n",
+ "#vl_dash=L*di/dt=300*cos(w*t)-400*cos(2*w*t)\n",
+ "vl1=300;vl2=4 # V\n",
+ "vl=sqrt((300/sqrt(2))**2+(400/sqrt(2))**2)\n",
+ "print \"Reading of electrostatic voltmeter acroos 1 mH inductor = %d V\"%(vl)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 17 Page 358"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 64,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "The limit of error = 48.6 uV\n",
+ "Deflection = 8.2 mm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "R=80 # ohm\n",
+ "V=2 # V\n",
+ "l=50 # cm\n",
+ "vd=.1 # V\n",
+ "emf=1.43 # V\n",
+ "Rc=850 # ohm\n",
+ "sg=17.5 # mm/uA\n",
+ "df=1 # mm\n",
+ "\n",
+ "\n",
+ "I=R/V # A\n",
+ "Rw=vd/I # ohm (Resistance of side wire)\n",
+ "Id=df/sg*10**-6 # A (current for 1mm deflection)\n",
+ "el=1/sg*Rc # uV\n",
+ "print \"The limit of error = %.1f uV\"%(el)\n",
+ "Rw1=0.2/l*Rw # ohm (for 2cm slide wire)\n",
+ "dV=I*Rw1*1000 # mV (Change in voltage from null point)\n",
+ "r1=emf/I # ohm (tapped portion) \n",
+ "r2=r1*22.8/R # ohm\n",
+ "Ig=dV/1000/(Rc+r2) # A\n",
+ "d=dV/1000/(Rc+r2)/Id # mm\n",
+ "print \"Deflection = %.1f mm\"%(d)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 18 Page 359"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 65,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "reading of hot wire ammeter = 0.56 A\n",
+ "reading of moving coil ammeter = 0.30 A\n",
+ "\n",
+ "\n",
+ " Power taken from the mains = 83.3 W\n",
+ "Power dissipated in rectifying device = 67 W\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,sqrt\n",
+ "from sympy.mpmath import quad\n",
+ "\n",
+ "# Given\n",
+ "R=50 # ohm\n",
+ "Vrms=100 # V\n",
+ "Rd1=50 # ohm\n",
+ "Rd2=100 # ohm \n",
+ "\n",
+ "Vm=Vrms/sqrt(2) # V\n",
+ "#v=Vm*sin(theta)\n",
+ "Rf=R+Rd1 # ohm\n",
+ "Rb=R+Rd2 # ohm\n",
+ "#i_f=v/Rf # A\n",
+ "#i_b=v/Rb # A\n",
+ "Irms=1/2/pi*(quad(lambda theta:(sqrt(2)*sin(theta))**2,[0,pi])+quad(lambda theta:(sqrt(2)/3*sin(theta))**2,[pi,2*pi]))\n",
+ "Iav=1/2/pi*(quad(lambda theta:sqrt(2)*sin(theta),[0,pi])+quad(lambda theta:sqrt(2)/3*sin(theta),[pi,2*pi]))\n",
+ "print \"reading of hot wire ammeter = %.2f A\"%(Irms)\n",
+ "print \"reading of moving coil ammeter = %.2f A\"%(Iav)\n",
+ "P=1/2*(Vrms**2/Rf+Vrms**2/Rb) # W\n",
+ "print \"\\n\\n Power taken from the mains = %.1f W\"%(P)\n",
+ "Pc=Irms**2*R # W\n",
+ "Pd=P-Pc # W\n",
+ "print \"Power dissipated in rectifying device = %d W\"%(Pd)\n",
+ "#Answer wrong in the textbook."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 19 Page 361"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 66,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Required potential difference = 500 V\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,sqrt,sin\n",
+ "\n",
+ "# Given\n",
+ "d=1/100 # m\n",
+ "S=-1/100 # m\n",
+ "Ve=2 # kV\n",
+ "theta=30 # degree\n",
+ "e=1.6*10**-19 # C\n",
+ "m=9.67*10**-31 # kg\n",
+ "\n",
+ "u=sqrt(2*e*Ve*1000/m) # m/s\n",
+ "uy=u*sin(pi/180*theta) # m/s\n",
+ "vy=0 # since final velocity =0\n",
+ "#vy**2-uy**2=2*ay*S\n",
+ "ay=(vy**2-uy**2)/2/S # m**2/s\n",
+ "#ay=e/m*V/d\n",
+ "V=ay*m*d/e # V\n",
+ "print \"Required potential difference = %.f V\"%(V)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 20 Page 361"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 67,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Amplification factor, mu = -40\n",
+ "Mutual conductance, gm = 2.74 S\n",
+ "Plate resistance, ra = 14.6 kohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "#Ia=0.0004*(Va+40*Vg)**(3/2) # mA --eqn(1)\n",
+ "Va=250 # V\n",
+ "Vg=-3 # V\n",
+ "#mu=delVa/delVg\n",
+ "#differenciation wrt Vg eqn(1)\n",
+ "#(4*10**-6*3/2*(Va+40*Vg))**(1/2)*(mu+40)=0\n",
+ "mu=-40 # constant\n",
+ "print \"Amplification factor, mu = %.f\"%(mu)\n",
+ "#differenciation wrt Va eqn(1)\n",
+ "#delIa/delVa=(4*10**-6*3/2*(Va+40*Vg))**(1/2)*(0+40)\n",
+ "gm=(4*10**-6*3/2)*(Va+40*Vg)**(1/2)*(0+40)*1000 # mA/V or S\n",
+ "print \"Mutual conductance, gm = %.2f S\"%(gm)\n",
+ "#differenciation wrt Ia eqn(1) keeping Vg constant\n",
+ "#1=(4*10**-6)*3/2*(Va+40*Vg)**(1/2)*(delVa/delIa+0)\n",
+ "#ra=delVa/delIa\n",
+ "ra=1/((4*10**-6)*3/2*(Va+40*Vg)**(1/2))\n",
+ "print \"Plate resistance, ra = %.1f kohm\"%(ra/1000)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 21 Page 363"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 68,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "General equation of FM wave is:\n",
+ "v=4*sin(1.57e+08*t+25*sin(2513*t)\n",
+ "\n",
+ "\n",
+ " General equation of PM wave is:\n",
+ "v=4*sin(1.57e+08*t+25*sin(2513*t)\n",
+ "\n",
+ "\n",
+ " Now equation of FM wave is:\n",
+ "v=4*sin(1.57e+08*t+25*sin(12566*t)\n",
+ "\n",
+ "\n",
+ " Now equation of PM wave is:\n",
+ "v=4*sin(1.57e+08*t+25*sin(12566*t)\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "\n",
+ "# Given\n",
+ "fc=25*10**6 # Hz\n",
+ "fm=400 # Hz\n",
+ "Vm=4 # V\n",
+ "Del=10*10**3 # Hz\n",
+ "wc=2*pi*fc # rad/s\n",
+ "wm=2*pi*fm # rad/s\n",
+ "m=Del/fm # modulation index\n",
+ "mf=m;mp=m # modulation index\n",
+ "print \"General equation of FM wave is:\"\n",
+ "print \"v=%d*sin(%.2e*t+%d*sin(%d*t)\"%(Vm,wc,mf,wm)\n",
+ "print \"\\n\\n General equation of PM wave is:\"\n",
+ "print \"v=%d*sin(%.2e*t+%d*sin(%d*t)\"%(Vm,wc,mp,wm)\n",
+ "# Changing modulating frequency\n",
+ "fm_new=2*10**3 # Hz\n",
+ "a=fm_new/fm # increase in angular frequency\n",
+ "print \"\\n\\n Now equation of FM wave is:\"\n",
+ "print \"v=%d*sin(%.2e*t+%d*sin(%d*t)\"%(Vm,wc,mf,a*wm)\n",
+ "print \"\\n\\n Now equation of PM wave is:\"\n",
+ "print \"v=%d*sin(%.2e*t+%d*sin(%d*t)\"%(Vm,wc,mp,a*wm)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 22 Page 363"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 69,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "modulation index = 0.5\n",
+ "carrier power under modulated condition = 5.06 kW\n",
+ "plate circuit efficiency = 75 percent\n",
+ "plate dissipation under unmodulated condition = 1.5 kW\n",
+ "plate dissipation under modulated condition = 1.69 kW\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "Ebb=300 # V\n",
+ "Ibb=20 # A\n",
+ "Emm=150 # V\n",
+ "Po=4.5*10**3 # W\n",
+ "\n",
+ "m=Emm/Ebb # modulation index\n",
+ "Pbb=Ebb*Ibb\n",
+ "eta=Po/Pbb*100 # %\n",
+ "P=Po*(1+m**2/2) # W\n",
+ "Pdo=Pbb-Po # W\n",
+ "Pd=Pdo*(1+m**2/2) # W\n",
+ "print \"modulation index = %.1f\"%(m)\n",
+ "print \"carrier power under modulated condition = %0.2f kW\"%(P/1000)\n",
+ "print \"plate circuit efficiency = %.f percent\"%(eta)\n",
+ "print \"plate dissipation under unmodulated condition = %.1f kW\"%(Pdo/1000)\n",
+ "print \"plate dissipation under modulated condition = %.2f kW\"%(Pd/1000)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 23 Page 364"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 70,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Series equivalent circuit:\n",
+ "Rs = 77.7 ohm\n",
+ "Xs = 34.3 ohm\n",
+ "\n",
+ "\n",
+ " Parallel equivalent circuit:\n",
+ "Rp = 92.8 ohm\n",
+ "Xp = 211 ohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import cos,pi,sin\n",
+ "# Given\n",
+ "Zo=50 # ohm\n",
+ "VSWR=2 # ratio\n",
+ "#lm=0.2*lamda\n",
+ "lmBYlamda=0.2\n",
+ "betaINTOlamda=2*pi\n",
+ "rho=(VSWR-1)/(VSWR+1) # reflection coefficient\n",
+ "theta=2*betaINTOlamda*lmBYlamda # radian\n",
+ "#exp(j*theta)=cos(theta)+1J*sin(theta)\n",
+ "ZL=Zo*(1-rho*(cos(theta)+1J*sin(theta)))/(1+rho*(cos(theta)+1J*sin(theta))) # ohm\n",
+ "Rs=(ZL.real) # ohm\n",
+ "Xs=abs((ZL.imag)) # ohm(capacitive)\n",
+ "print \"Series equivalent circuit:\"\n",
+ "print \"Rs = %0.1f ohm\"%(Rs)\n",
+ "print \"Xs = %0.1f ohm\"%(Xs)\n",
+ "YL=(1/ZL)*1000 # mS\n",
+ "Rp=1000/(YL.real) # ohm\n",
+ "Xp=1000/(YL.imag) # ohm\n",
+ "print \"\\n\\n Parallel equivalent circuit:\"\n",
+ "print \"Rp = %0.1f ohm\"%(Rp)\n",
+ "print \"Xp = %0.f ohm\"%(Xp)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 24 Page 366"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 71,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "For TE10 mode:\n",
+ "cutoff wavelength = 9 cm\n",
+ "guide wavelength = 3.59 cm\n",
+ "Group velocity = 2.8e+08 m/s\n",
+ "Phase velocity = 3.2e+08 m/s\n",
+ "Characteristic wave impedence = 406 ohm\n",
+ "\n",
+ "\n",
+ " For TM11 mode:\n",
+ "cutoff wavelength = 5 cm\n",
+ "guide wavelength = 4.48 cm\n",
+ "Group velocity = 2.2e+08 m/s\n",
+ "Phase velocity = 4.0e+08 m/s\n",
+ "Characteristic wave impedence = 281 ohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,sqrt\n",
+ "\n",
+ "# Given\n",
+ "b=3 # cm\n",
+ "a=4.5 # cm\n",
+ "f=9*10**9 # Hz\n",
+ "v=3*10**10 # cm/s\n",
+ "lamda=v/f # cm\n",
+ "\n",
+ "print \"For TE10 mode:\"\n",
+ "m=1 # for TE10 mode\n",
+ "lamda_c = 2*a/m # cm\n",
+ "rho=sqrt(1-(lamda/lamda_c)**2)\n",
+ "lamda_g=lamda/rho # cm\n",
+ "vg=rho*v # cm/s\n",
+ "vp=v/rho # cm/s\n",
+ "ZTE=120*pi/rho # ohm\n",
+ "\n",
+ "print \"cutoff wavelength = %.f cm\"%(lamda_c)\n",
+ "print \"guide wavelength = %.2f cm\"%(lamda_g)\n",
+ "print \"Group velocity = %.1e m/s\"%(vg/100)\n",
+ "print \"Phase velocity = %.1e m/s\"%(vp/100)\n",
+ "print \"Characteristic wave impedence = %.f ohm\"%(ZTE)\n",
+ "\n",
+ "print \"\\n\\n For TM11 mode:\"\n",
+ "m=1;n=1# for TE10 mode\n",
+ "lamda_c = 2/sqrt((m/a)**2+(n/b)**2) # cm\n",
+ "rho=sqrt(1-(lamda/lamda_c)**2)\n",
+ "lamda_g=lamda/rho # cm\n",
+ "vg=rho*v # cm/s\n",
+ "vp=v/rho # cm/s\n",
+ "ZTM=120*pi*rho # ohm\n",
+ "print \"cutoff wavelength = %.f cm\"%(lamda_c)\n",
+ "print \"guide wavelength = %.2f cm\"%(lamda_g)\n",
+ "print \"Group velocity = %.1e m/s\"%(vg/100)\n",
+ "print \"Phase velocity = %.1e m/s\"%(vp/100)\n",
+ "print \"Characteristic wave impedence = %.f ohm\"%(ZTM)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 25 Page 367"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 72,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "part(a):\n",
+ "For fo>fs, the range of fo : 965 to 2065 kHz\n",
+ "frequency ratio = 2.14\n",
+ "capacitance ratio = 4.58\n",
+ "\n",
+ "\n",
+ " part(b):\n",
+ "For fo>fs, the range of fo : 35 to 1135 kHz\n",
+ "frequency ratio = 32.4\n",
+ "capacitance ratio = 1051.6\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "fs_max=1600 # kHz\n",
+ "fs_min=500 # kHz\n",
+ "IF=465 # kHz\n",
+ "\n",
+ "fr=fs_max/fs_min # ratio\n",
+ "C_ratio = fr**2 # Cs_max/Cs_min\n",
+ "#Part (a)\n",
+ "fo_min=IF+fs_min # kHz\n",
+ "fo_max=IF+fs_max # kHz\n",
+ "fr_o=fo_max/fo_min # frequency ratio for oscillator\n",
+ "C_ratio_o = fr_o**2 # Cs_max/Cs_min\n",
+ "print \"part(a):\"\n",
+ "print \"For fo>fs, the range of fo : %.f to %.f kHz\"%(fo_min,fo_max)\n",
+ "print \"frequency ratio = %.2f\"%(fr_o)\n",
+ "print \"capacitance ratio = %.2f\"%(C_ratio_o)\n",
+ "\n",
+ "#Part (b)\n",
+ "fo_min=-IF+fs_min # kHz\n",
+ "fo_max=-IF+fs_max # kHz\n",
+ "fr_o=fo_max/fo_min # frequency ratio for oscillator\n",
+ "C_ratio_o = fr_o**2 # Cs_max/Cs_min\n",
+ "print \"\\n\\n part(b):\"\n",
+ "print \"For fo>fs, the range of fo : %.f to %.f kHz\"%(fo_min,fo_max)\n",
+ "print \"frequency ratio = %.1f\"%(fr_o)\n",
+ "print \"capacitance ratio = %.1f\"%(C_ratio_o)\n",
+ "#ans wrong for part b in the book."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 26 Page 368"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 73,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Resistor values are : \n",
+ "RL=1.60 kohm\n",
+ "Re=0.40 kohm\n",
+ "R1=55.60 kohm\n",
+ "R2=9.34 kohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "Ic=3 # mA\n",
+ "hfe=45 # unitless\n",
+ "Vcc=12 # V\n",
+ "VBE=0.5 # V\n",
+ "S=0.05 # stability factor\n",
+ "Beta=45 # unitless\n",
+ "\n",
+ "RR=Vcc/2/(Ic*10**-3) # ohm (let RL+Re=RR)\n",
+ "#Re=20% of (Re+Rl)\n",
+ "Re=RR*20/100 # ohm\n",
+ "RL=RR-Re # ohm\n",
+ "Ve=(Ic+Ic/Beta)*10**-3*Re # V\n",
+ "Vb=Ve+VBE # V\n",
+ "#S=Re/Rb=0.5 => Rb=Re/S\n",
+ "R1=Vcc*Re/S/Vb/1000 # kohm\n",
+ "# Vb/Vcc = R2/(R2+R1)\n",
+ "R2=Vb*R1/(Vcc-Vb) # kohm\n",
+ "print \"Resistor values are : \"\n",
+ "print \"RL=%.2f kohm\"%(RL/1000)\n",
+ "print \"Re=%.2f kohm\"%(Re/1000)\n",
+ "print \"R1=%.2f kohm\"%(R1)\n",
+ "print \"R2=%.2f kohm\"%(R2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 27 Page 369"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 74,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "load presented by transformer = 11.8 ohm\n",
+ "load power output = 67.6 W\n",
+ "conversion efficiency = 62.8 percent\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "\n",
+ "# Given\n",
+ "Vcc=50 # V\n",
+ "Vmin=10 # V\n",
+ "Pd=40 # W\n",
+ "\n",
+ "\n",
+ "Vo=Vcc-Vmin # V\n",
+ "K=Vo/Vcc # constant\n",
+ "Rdash=2*Vcc**2/pi/Pd*(K-pi*K**2/4) # ohm\n",
+ "Po=K**2*Vcc**2/2/Rdash # W\n",
+ "eta=pi*K/4*100 # %\n",
+ "\n",
+ "print \"load presented by transformer = %.1f ohm\"%(Rdash)\n",
+ "print \"load power output = %.1f W\"%(Po)\n",
+ "print \"conversion efficiency = %.1f percent\"%(eta)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 28 Page 370"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 75,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "for 2nd stage(CC stage)\n",
+ "current gain = 48.57\n",
+ "Input impedence = 97.14 kohm\n",
+ "Voltage gain = 1.00\n",
+ "\n",
+ "\n",
+ " for 1st stage(CE stage)\n",
+ "current gain = -47.66\n",
+ "Input impedence = 1.08 kohm\n",
+ "Voltage gain = -86.76\n",
+ "Output impedence = 68.57 kohm\n",
+ "Output impedence taking Rc1 into account = 1.94 kohm\n",
+ "\n",
+ "\n",
+ " for overall amplifier\n",
+ "Output impedence = 34.81 ohm\n",
+ "Output impedence taking Re2 into account = 33.65 ohm\n",
+ "current gain = -46.70\n",
+ "Voltage gain = -86.76\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "Rs=1000 # ohm\n",
+ "Rc1=2*1000 # ohm\n",
+ "Re2=2*1000 # ohm\n",
+ "#CE configuration\n",
+ "hie=1100 # ohm\n",
+ "hre=2.5*10**-4#\n",
+ "hfe=50#\n",
+ "hoe=25*10**-6 # s\n",
+ "#CC configuration\n",
+ "hic=1.1 # kohm\n",
+ "hrc=1#\n",
+ "hfc=-51#\n",
+ "hoc=25*10**-6 # s\n",
+ "\n",
+ "print \"for 2nd stage(CC stage)\"\n",
+ "AI2=-hfc/(1+hoe*Re2) # current gain\n",
+ "Ri2=hic+hrc*AI2*Re2 # kohm\n",
+ "Av2=AI2*Re2/Ri2 # Voltage Gain\n",
+ "print \"current gain = %0.2f\"%(AI2)\n",
+ "print \"Input impedence = %0.2f kohm\"%(Ri2/1000)\n",
+ "print \"Voltage gain = %0.2f\"%(Av2)\n",
+ "\n",
+ "print \"\\n\\n for 1st stage(CE stage)\"\n",
+ "RL1=Rc1*Ri2/(Rc1+Ri2) # kohm\n",
+ "AI1=-hfe/(1+hoe*RL1) # current gain\n",
+ "print \"current gain = %.2f\"%(AI1)\n",
+ "Ri1=hie+hre*AI1*RL1 # kohm\n",
+ "print \"Input impedence = %0.2f kohm\"%(Ri1/1000)\n",
+ "Av1=AI1*RL1/Ri1 # Voltage gain\n",
+ "print \"Voltage gain = %0.2f\"%(Av1)\n",
+ "Ro1=1/(hoe-hfe*hre/(hie+100)) # ohm\n",
+ "print \"Output impedence = %.2f kohm\"%(Ro1/1000)\n",
+ "Ro1dash=Ro1*Rc1/(Ro1+Rc1) # /ohm\n",
+ "print \"Output impedence taking Rc1 into account = %.2f kohm\"%(Ro1dash/1000)\n",
+ "\n",
+ "print \"\\n\\n for overall amplifier\"\n",
+ "Ro=1/(hoc*100-hfc*hrc/(hic+Ro1dash)) # ohm\n",
+ "print \"Output impedence = %.2f ohm\"%(Ro)\n",
+ "Rodash=Ro*Re2*1000/(Ro1+Re2*1000) # /ohm\n",
+ "print \"Output impedence taking Re2 into account = %.2f ohm\"%(Rodash)\n",
+ "AI=AI1*AI2*Rc1/(Ri2+Rc1) # current gain\n",
+ "print \"current gain = %.2f\"%(AI)\n",
+ "Av=Av1*Av2 # voltage gain\n",
+ "print \"Voltage gain = %.2f\"%(Av)\n",
+ "#answer is wrong for overall amplifier in the book."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 29 Page 372"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 76,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Voltage gain upper BW frequency = 0.37 MHz\n",
+ "Current gain = -13.51\n",
+ "Voltage gain = -27.03\n",
+ "Voltage gain BW product = 9.90 MHz\n",
+ "Current gain BW product = 4.95 MHz\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "\n",
+ "# Given\n",
+ "fT=6*10**6 # Hz\n",
+ "hfe=50#\n",
+ "Rs=500 # ohm\n",
+ "gm=0.04 # S\n",
+ "rbb_dash=100 # ohm\n",
+ "Cc=10*10**-12 # F\n",
+ "RL=1 # kohm\n",
+ "\n",
+ "rbe=hfe/gm # ohm\n",
+ "Ce=gm/2/pi/fT # F\n",
+ "C=Ce+Cc*(1+gm*RL) # F\n",
+ "hie=rbb_dash+rbe # ohm\n",
+ "R=(Rs+rbb_dash)*rbe/((Rs+rbb_dash)+rbe) # ohm\n",
+ "f2=1/2/pi/R/C # Hz\n",
+ "print \"Voltage gain upper BW frequency = %.2f MHz\"%(f2/10**6)\n",
+ "AIS=-hfe*Rs/(Rs+hie) # current gain\n",
+ "print \"Current gain = %.2f\"%(AIS)\n",
+ "AVS=-hfe*RL*1000/(Rs+hie) # voltage gain\n",
+ "print \"Voltage gain = %.2f\"%(AVS)\n",
+ "AVSf2=AVS*f2 # Hz\n",
+ "print \"Voltage gain BW product = %.2f MHz\"%(abs(AVSf2/10**6))\n",
+ "AISf2=AIS*f2 # Hz\n",
+ "print \"Current gain BW product = %.2f MHz\"%(abs(AISf2/10**6))\n",
+ "\n",
+ "#answer in the textbook are wrong."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 30 Page 373"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 77,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "VGS=0.05 V\n",
+ "gm = -13.23 mS\n",
+ "Rs = -49 ohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi,sqrt\n",
+ "\n",
+ "# Given\n",
+ "VP=-2 # V\n",
+ "IDSS=1.75/1000 # A\n",
+ "VDD=24 # V\n",
+ "ID=1/1000 # A\n",
+ "VP=0.2 # V (pinch off voltage)\n",
+ "\n",
+ "VGS=(1-sqrt(ID/IDSS))*VP # V\n",
+ "gmo=-2*IDSS/VP # S\n",
+ "gm=gmo*(1-VGS/VP) # S\n",
+ "Rs=-VGS/ID # ohm\n",
+ "\n",
+ "print \"VGS=%.2f V\"%(VGS)\n",
+ "print \"gm = %.2f mS\"%(gm*1000)\n",
+ "print \"Rs = %.f ohm\"%(Rs)\n",
+ "#Ans are wrong in the book."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 31 Page 374"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 78,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Bandwidth of redesigned aplifier, BW=101 kHz\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import sqrt\n",
+ "from __future__ import division\n",
+ "# Given\n",
+ "G=37 # dB\n",
+ "f1=50 # Hz\n",
+ "f2=18.7*1000 # Hz\n",
+ "BW1=f2 # Hz (f2-f1~=f2)\n",
+ "\n",
+ "\n",
+ "A1=10**(G/20) # Gain\n",
+ "A3=sqrt(A1) # Gain\n",
+ "RL1BYRL2=A1/A3 # ratio\n",
+ "RL2BYRL1=A3/A1 # ratio\n",
+ "#BW=2*pi*Cd*RL\n",
+ "BW1BYBW2=RL2BYRL1#\n",
+ "BW2BYBW1=RL1BYRL2#\n",
+ "f2dash=f2*sqrt(sqrt(2)-1)#\n",
+ "BW2=BW2BYBW1*f2dash # Hz\n",
+ "print \"Bandwidth of redesigned aplifier, BW=%.f kHz\"%(BW2/1000)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 32 Page 375"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 79,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "ripple factor = 0.4 percent\n",
+ "Critical inductance, Lc=8.5 H\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import sqrt\n",
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "L=30 # H\n",
+ "C=10*10**-6 # F\n",
+ "RL=8*10**3 # ohm\n",
+ "f=50 # Hz\n",
+ "\n",
+ "r=sqrt(2)/12/(2*pi*f)**2/L/C*100 # %\n",
+ "Lc=2*RL/6/(2*pi*f) # H\n",
+ "print \"ripple factor = %.1f percent\"%(r)\n",
+ "print \"Critical inductance, Lc=%.1f H\"%(Lc)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 33 Page 376"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 80,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Current supplied by the main generator = 7000 A\n",
+ "Current supplied on +ve side = 6000 A\n",
+ "Current supplied on -ve side = 8000 A\n",
+ "out-off balance Current = 2000 A\n",
+ "Current in each armature = 1000 A\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "# Given\n",
+ "V=500 # V\n",
+ "Pp=1500*10**3 # W (+ve side)\n",
+ "Pn=2000*10**3 # W (-ve side)\n",
+ "\n",
+ "P=Pp+Pn # W\n",
+ "I=P/V # A\n",
+ "Ip=Pp/(V/2) # A\n",
+ "In=Pn/(V/2) # A\n",
+ "Iob=In-Ip # A\n",
+ "Ia=Iob/2 # A\n",
+ "print \"Current supplied by the main generator = %.f A\"%(I)\n",
+ "print \"Current supplied on +ve side = %.f A\"%(Ip)\n",
+ "print \"Current supplied on -ve side = %.f A\"%(In)\n",
+ "print \"out-off balance Current = %.f A\"%(Iob)\n",
+ "print \"Current in each armature = %.f A\"%(Ia)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 34 Page 377"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 81,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "regulation = 17 percent\n",
+ "Efficiency = 94 percent\n",
+ "\n",
+ "\n",
+ " regulation = 13.4 percent\n",
+ "Efficiency = 96 percent\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "# Given\n",
+ "l=20 # km\n",
+ "P=10000 # kW\n",
+ "V=11 # kV\n",
+ "pf=0.707 # lagging\n",
+ "R=0.02 # ohm/km/phase\n",
+ "X=0.07 # ohm/km/phase\n",
+ "\n",
+ "#for pf = 0.707\n",
+ "\n",
+ "IL=P*10**3/sqrt(3)/(V*1000)/pf # A\n",
+ "VRphase=V*1000/sqrt(3) # V\n",
+ "R_phase=l*R # ohm\n",
+ "X_phase=l*X # ohm\n",
+ "Z_phase=R_phase+1J*X_phase # ohm\n",
+ "Vd_phase=IL*(pf-1J*pf)*Z_phase # V\n",
+ "VS=(Vd_phase+VRphase) # V\n",
+ "regulation=(VS-VRphase)/VRphase*100 # %\n",
+ "print \"regulation = %.f percent\"%abs(regulation)\n",
+ "PL=3*IL**2*R_phase/1000 # kW\n",
+ "Po=P+PL # kW\n",
+ "eta=P/Po*100 # %\n",
+ "print \"Efficiency = %.f percent\"%(eta)\n",
+ "\n",
+ "#for pf2=0.9 # lagging\n",
+ "pf=0.9 # lagging\n",
+ "IL=P*10**3/sqrt(3)/(V*1000)/pf # A\n",
+ "VRphase=V*1000/sqrt(3) # V\n",
+ "R_phase=l*R # ohm\n",
+ "X_phase=l*X # ohm\n",
+ "Z_phase=R_phase+1J*X_phase # ohm\n",
+ "Vd_phase=IL*(pf-1J*.435)*Z_phase # V\n",
+ "VS=(Vd_phase+VRphase) # V\n",
+ "regulation=(VS-VRphase)/VRphase*100 # %\n",
+ "print \"\\n\\n regulation = %.1f percent\"%abs(regulation)\n",
+ "PL=3*IL**2*R_phase/1000 # kW\n",
+ "Po=P+PL # kW\n",
+ "eta=P/Po*100 # %\n",
+ "print \"Efficiency = %.f percent\"%(eta)\n",
+ "#ans wrong for 2nd part in the book."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 35 Page 378"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 82,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "lamp1 : Total cost/hour = 0.488 paise\n",
+ "lamp2 : Total cost/hour = 0.61 paise\n",
+ "on comparing cost it is clear lamp1 will be more economical. \n",
+ "\n",
+ "\n",
+ " load factor = 28 percent\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "C1=1.2 # Rs\n",
+ "C2=5 # Rs\n",
+ "P1=100 # W\n",
+ "P2=30 # W\n",
+ "t=1000 # hours\n",
+ "Ce=60 # Rs/kW/annum for max demand\n",
+ "Cee=3 # paise/unit for extra\n",
+ "\n",
+ "#first lamp\n",
+ "Cl1=C1*100/t # paise / hour\n",
+ "dmax1=P1/1000 # kW/hour\n",
+ "Cmax1=Ce*100*dmax1/(24*365) # paise/hour\n",
+ "CE1=Cee*dmax1 # /paise / hour\n",
+ "CT1=Cl1+Cmax1+CE1 # paise (total cost per hour)\n",
+ "print \"lamp1 : Total cost/hour = %.3f paise\"%(CT1)\n",
+ "#second lamp\n",
+ "Cl2=C2*100/t # paise / hour\n",
+ "dmax2=P2/1000 # kW/hour\n",
+ "Cmax2=Ce*100*dmax2/(24*365) # paise/hour\n",
+ "CE2=Cee*dmax2 # /paise / hour\n",
+ "CT2=Cl2+Cmax2+CE2 # paise (total cost per hour)\n",
+ "print \"lamp2 : Total cost/hour = %.2f paise\"%(CT2)\n",
+ "print \"on comparing cost it is clear lamp1 will be more economical. \"\n",
+ "#let load factor = x\n",
+ "#Cl1+Cmax1/x+CE1=Cl2+Cmax2/x+CE2\n",
+ "x=(Cmax1-Cmax2)/(Cl2+CE2-Cl1-CE1)*100 # % load factor\n",
+ "print \"\\n\\n load factor = %.f percent\"%(x)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 36 Page 379"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 83,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "(a) extra shunt field turns required = 104\n",
+ "(b) extra shunt field turns required = 52\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "p=4 # pole\n",
+ "I1=143 # A\n",
+ "Z=492 # armature conductors\n",
+ "theta=10 # degree\n",
+ "I2=10 # A\n",
+ "\n",
+ "Ia=I1+I2 # A\n",
+ "Iw=Ia/2 # A for wave sound\n",
+ "Il=Ia/4 # for lap sound\n",
+ "#part(a)\n",
+ "ATw=Z*Iw*theta/360 # AT\n",
+ "nw=ATw/theta # turns \n",
+ "print \"(a) extra shunt field turns required = %d\"%(nw)\n",
+ "\n",
+ "#part(b)\n",
+ "ATl=Z*Il*theta/360 # AT\n",
+ "nl=ATl/theta # turns \n",
+ "print \"(b) extra shunt field turns required = %d\"%(nl)\n",
+ "#answer wrong for part(a) in the boko."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 37 Page 380"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 84,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "New speed will be 570 rpm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from numpy import roots\n",
+ "# Given\n",
+ "Wh=250 # W\n",
+ "We=100 # W\n",
+ "N=1000/60 # rps\n",
+ "\n",
+ "A=Wh/N # constant\n",
+ "B=We/N**2 # constant\n",
+ "Wnew=1/2*(Wh+We) # W\n",
+ "#Wnew=A*N1+B*N1**2\n",
+ "p=[B,A,-Wnew] # polynomial for N1\n",
+ "N1=roots(p) # rps\n",
+ "N1=N1[1]*60 # rpm#discarding -ve vealue\n",
+ "print \"New speed will be %.f rpm\"%(N1)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 38 Page 381"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 85,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Speed of the machine running as shunt motor = 381 rpm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "P=50 # kW\n",
+ "V=250#V\n",
+ "N1=400 # rpm\n",
+ "Ra=0.02 # ohm\n",
+ "Rf=50 # ohm\n",
+ "Pi=50 # kW\n",
+ "Vin=250 # V\n",
+ "Vd=1 # V per Brush\n",
+ "\n",
+ "I=P*10**3/V#A\n",
+ "Ish=V/Rf # A\n",
+ "Ia=I+Ish # A\n",
+ "Va=Ia*Ra # V\n",
+ "Vbd=2*Vd # V\n",
+ "Eb1=V+Va+Vbd # V\n",
+ "\n",
+ "\n",
+ "#as motor\n",
+ "I=P*10**3/V#A\n",
+ "Ish=V/Rf # A\n",
+ "Ia=I-Ish # A\n",
+ "\n",
+ "Va=Ia*Ra # V\n",
+ "Vbd=2*Vd # V\n",
+ "Eb2=V-Va-Vbd # V\n",
+ "N2=(Eb2/Eb1)*N1 # rpm\n",
+ "print \"Speed of the machine running as shunt motor = %.f rpm\"%(N2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 39 Page 383"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 86,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Motor efficiency = 92 percent\n",
+ "Generator efficiency = 92 percent\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "VL=250 # V\n",
+ "Is=50 # A\n",
+ "Ia=380 # A\n",
+ "If1=5 # A\n",
+ "If2=4.2 # A\n",
+ "ra=0.02 # ohm\n",
+ "\n",
+ "#Machine Losses:\n",
+ "ma_cu_loss=Ia**2*ra # W (motor armature cu loss)\n",
+ "ga_cu_loss=(Ia-Is)**2*ra # W (generator armature cu loss)\n",
+ "P=VL*Is # W\n",
+ "stray_loss=P-ma_cu_loss-ga_cu_loss # W\n",
+ "stray_loss_per_machine=stray_loss/2 # W\n",
+ "\n",
+ "#Motor efficiency\n",
+ "field_cu_loss=VL*If2 # W\n",
+ "total_loss=ma_cu_loss+field_cu_loss+stray_loss_per_machine # W\n",
+ "Pin_motor=(VL*Ia)+(VL*ra) # W\n",
+ "Pout_motor=Pin_motor-total_loss # W\n",
+ "Eff=Pout_motor/Pin_motor*100 # %\n",
+ "print \"Motor efficiency = %.f percent\"%(Eff)\n",
+ "\n",
+ "\n",
+ "#Generator efficiency\n",
+ "field_cu_loss=VL*If1 # W\n",
+ "total_loss=ga_cu_loss+field_cu_loss+stray_loss_per_machine # W\n",
+ "Pout_generator=VL*(Ia-Is) # W\n",
+ "Pin_generator=Pout_generator+total_loss # W\n",
+ "Eff=Pout_motor/Pin_motor*100 # %\n",
+ "print \"Generator efficiency = %.f percent\"%(Eff)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 40 Page 384"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 87,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Full load efficiency : \n",
+ "at unity power factor = 96.8 percent\n",
+ "at 0.8 power factor = 96.0 percent\n",
+ "\n",
+ "\n",
+ " Voltage drop at unity pf = 393.8 V\n",
+ "Voltage drop at 0.8 pf lagging = 384.0 V\n",
+ "Voltage drop at 0.8 pf leading = 406 V\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "# Given\n",
+ "KVA=4 # kVA\n",
+ "V1=200#V\n",
+ "V2=400#V\n",
+ "f=50 # Hz\n",
+ "Io1=0.8 # A\n",
+ "P1=70 # W\n",
+ "Vs2=17.5 # V\n",
+ "Is2=9 # A\n",
+ "P2=50 # W\n",
+ "\n",
+ "#full load\n",
+ "I_loss=P1 # W\n",
+ "I2=KVA*1000/V2 # A\n",
+ "Cu_loss=(I2/Is2)**2*P2 # W\n",
+ "Zo2=Vs2/Is2 # ohm\n",
+ "Ro2=P2/Is2**2 # ohm\n",
+ "Xo2=sqrt(Zo2**2-Ro2**2) # ohm\n",
+ "\n",
+ "#(a) \n",
+ "print \"Full load efficiency : \"\n",
+ "#unity pf\n",
+ "pf=1 # power factor\n",
+ "Output=KVA*pf # kW\n",
+ "Losses=Cu_loss+I_loss # W\n",
+ "eta=Output*1000/(Output*1000+Losses)*100 # %\n",
+ "print \"at unity power factor = %.1f percent\"%(eta)\n",
+ "#0.8 pf\n",
+ "pf=0.8 # power factor\n",
+ "Output=KVA*pf # kW\n",
+ "eta=Output*1000/(Output*1000+Losses)*100 # %\n",
+ "print \"at 0.8 power factor = %.1f percent\"%(eta)\n",
+ "\n",
+ "#(b)\n",
+ "#(i) unity pf\n",
+ "Vd=I2*Ro2 # V\n",
+ "V22=V2-Vd # V\n",
+ "print \"\\n\\n Voltage drop at unity pf = %.1f V\"%(V22)\n",
+ "#(i) 0.8 pf lagging\n",
+ "pf=0.8 # power factor\n",
+ "Vd=I2*(Ro2*pf+Xo2*sqrt(1-pf**2)) # V\n",
+ "V22=V2-Vd # V\n",
+ "print \"Voltage drop at 0.8 pf lagging = %.1f V\"%(V22)\n",
+ "#(i) 0.8 pf leading\n",
+ "pf=0.8 # power factor\n",
+ "Vd=I2*(Ro2*pf-Xo2*sqrt(1-pf**2)) # V\n",
+ "V22=V2-Vd # V\n",
+ "print \"Voltage drop at 0.8 pf leading = %.f V\"%(V22)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 41 Page 385"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 88,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "All day efficiency = 97 percent\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "KVA=15 # kVA\n",
+ "pf=1#\n",
+ "eff=98/100 # efficiency\n",
+ "\n",
+ "L1=2 # kW\n",
+ "pf1=0.5 # lagging\n",
+ "t1=12 # hours\n",
+ "L2=12 # kW\n",
+ "pf2=0.8 # lagging\n",
+ "t2=6 # hours\n",
+ "L3=18 # kW\n",
+ "pf3=0.9 # lagging\n",
+ "t3=6 # hours\n",
+ "\n",
+ "Po=KVA*pf # kW\n",
+ "Pin=Po/eff # kW\n",
+ "Losses=Pin-Po # kW\n",
+ "Cu_loss=Losses/2 # kW\n",
+ "I_loss=Losses/2 # kW\n",
+ "\n",
+ "KVA1=L1/pf1 # kVA\n",
+ "KVA2=L2/pf2 # kVA\n",
+ "KVA3=L3/pf3 # kVA\n",
+ "Cu_loss1=Cu_loss*(KVA1/KVA2)**2 # kW\n",
+ "Cu_loss2=Cu_loss*(KVA2/KVA2)**2 # kW\n",
+ "Cu_loss3=Cu_loss*(KVA3/KVA2)**2 # kW\n",
+ "\n",
+ "Cu_loss_t1=Cu_loss1*t1 # kW\n",
+ "Cu_loss_t2=Cu_loss2*t2 # kW\n",
+ "Cu_loss_t3=Cu_loss3*t3 # kW\n",
+ "Cu_loss_total=Cu_loss_t1+Cu_loss_t2+Cu_loss_t3 # kW\n",
+ "I_loss24=I_loss*24 # Wh\n",
+ "\n",
+ "Po24=L1*t1+L2*t2+L3*t3 # kWh\n",
+ "Pi24=Po24+Cu_loss_total+I_loss24 # kWh\n",
+ "eff_allday=Po24/Pi24*100 # %\n",
+ "print \"All day efficiency = %.f percent\"%(eff_allday)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 42 Page 386"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 89,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Current drawn by the transformer=42.67 A\n",
+ "power factor = 0.9 lagging\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "# Given\n",
+ "V1=250 # V\n",
+ "V2=150 # V\n",
+ "Vs1=200 # V\n",
+ "Load1=5 # kW\n",
+ "pf1=0.8 # lagging\n",
+ "Load2=2 # kW\n",
+ "pf2=1 # unity\n",
+ "Vs2=100 # V\n",
+ "\n",
+ "I1=Load1*1000/V1/pf1 # A\n",
+ "t1_ratio=V1/Vs1 # \n",
+ "Ip1=I1*t1_ratio # A at 0.8 pf (current drawn by primary)\n",
+ "\n",
+ "I2=Load2*1000/Vs2/pf2 # A\n",
+ "t2_ratio=Vs2/V2 # \n",
+ "Ip2=I2*t2_ratio # A at 0.8 pf (current drawn by primary)\n",
+ "\n",
+ "Ipx=Ip1*pf1+Ip2 # A\n",
+ "Ipy=Ip1*sqrt(1-pf1**2) # A\n",
+ "I3=sqrt(Ipx**2+Ipy**2) # A\n",
+ "print \"Current drawn by the transformer=%.2f A\"%(I3)\n",
+ "pf=Ipx/I3 # power factor\n",
+ "print \"power factor = %.1f lagging\"%(pf)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 43 Page 387"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 90,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Percentage reduction in stator voltage = 23 percent\n",
+ "power factor = 0.3\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt,atan,cos\n",
+ "# Given\n",
+ "R2=0.03 # ohm\n",
+ "X2=0.18 # ohm\n",
+ "Ns=100 # rpm\n",
+ "s1=3 # %\n",
+ "\n",
+ "\n",
+ "Nfl=(100-s1) # rpm (full load speed)\n",
+ "N2=Nfl/2 # rpm\n",
+ "s2=(Ns-N2)/Ns*100 # %\n",
+ "V1BYV2=sqrt(s2/s1*(R2**2+(s1/100*X2)**2)/(R2**2+(s2/100*X2)**2)) # from torque equation\n",
+ "#let V1=V12BYV1 V2=1\n",
+ "V1=V1BYV2 # V\n",
+ "V2=1 # V\n",
+ "V12BYV1=(V1-1)/V1*100 # % reduction in the stator (V12=V1-V2)\n",
+ "print \"Percentage reduction in stator voltage = %.f percent\"%(V12BYV1)\n",
+ "fi=atan(s2/100*X2/R2) # radian\n",
+ "pf=cos(fi) # power factor\n",
+ "print \"power factor = %.1f\"%(pf)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 44 Page 388"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 91,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "(a) at standstill, To:Ti = 40:1\n",
+ "(b) at s=0.05, To:Ti = 0.4:1\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "\n",
+ "# Given\n",
+ "zo=1+1J*1 # ohm\n",
+ "zi=0.2+1J*4 # ohm\n",
+ "Ri=zi.real # ohm\n",
+ "Ro=(zo).real # ohm\n",
+ "\n",
+ "#at standstill\n",
+ "s=1 # % at standstill\n",
+ "Zo=sqrt((zo).real**2+(zo).imag**2) # ohm\n",
+ "Zi=sqrt((zi).real**2+(zi).imag**2) # ohm\n",
+ "ToBYTi=Ro/Ri*(Zi/Zo)**2 # torque ratio\n",
+ "print \"(a) at standstill, To:Ti = %d:1\"%(ToBYTi)\n",
+ "\n",
+ "#at s=0.5\n",
+ "s=0.05 # %\n",
+ "Zo=sqrt((zo).real**2/s**2+(zo).imag**2) # ohm\n",
+ "Zi=sqrt((zi).real**2/s**2+(zi).imag**2) # ohm\n",
+ "ToBYTi=Ro/Ri*(Zi/Zo)**2 # torque ratio\n",
+ "print \"(b) at s=0.05, To:Ti = %.1f:1\"%(ToBYTi)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 45 Page 389"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 92,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "no. of turns in primary = 582\n",
+ "no. of turns in secondary = 18\n",
+ "\n",
+ "cross section of primary winding=5.24e-04 m**2\n",
+ "cross section of secondary winding=1.7e-05 m**2\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "# Given\n",
+ "Edc=500 # V\n",
+ "fim=.085 # Wb\n",
+ "f=50 # Hz\n",
+ "E1=11000 # V\n",
+ "P=1500 # kW\n",
+ "p=8 # pole\n",
+ "pf=0.9\n",
+ "V=500 # V\n",
+ "J=3 # A/mm**2\n",
+ "\n",
+ "E2=Edc/sqrt(2)#V\n",
+ "N2=E2/4.44/f/fim # no. of turns\n",
+ "N1=E1/E2*N2 # no. of turns\n",
+ "print \"no. of turns in primary = %d\"%(N1)\n",
+ "print \"no. of turns in secondary = %d\"%(N2)\n",
+ "Idc=P*10**3/V # A\n",
+ "eta=1 # because of no loss\n",
+ "ISR=0.472*Idc/(eta*pf)\n",
+ "A1=ISR/J*10**-6 # m**2 (cross section area)\n",
+ "I1=N2/N1*ISR # A\n",
+ "A2=I1/J*10**-6 # m**2 (cross section area of primary winding)\n",
+ "print \"\\ncross section of primary winding=%.2e m**2\"%(A1)\n",
+ "print \"cross section of secondary winding=%.1e m**2\"%(A2)\n",
+ "#ans in the book are not accurate."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 46 Page 391"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 93,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Suitable auto transformation ratio = 77.5\n",
+ "Starting torque Tst = 15 percent of full-load torque\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "\n",
+ "# Given\n",
+ "IscBYIfl=5 # as Isc=5*Ifl\n",
+ "ILByIfl=3 # as IL <= 3*Ifl\n",
+ "sf=5 # %\n",
+ "\n",
+ "#IL=K**2*ISC\n",
+ "#dividing by Ifl\n",
+ "K=sqrt(ILByIfl/IscBYIfl)*100 # %\n",
+ "TstBYTf=(K/100)**2*IscBYIfl*sf/100*100 # % #ratio of torque\n",
+ "print \"Suitable auto transformation ratio = %.1f\"%(K)\n",
+ "print \"Starting torque Tst = %.f percent of full-load torque\"%(TstBYTf)\n",
+ "#ans wrong in the textbook."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 47 Page 391"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 94,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "no of studs = 5 and no. of section = 4\n",
+ "\n",
+ "Resistance of 1st section = 2.24 ohm\n",
+ "Resistance of 2nd section = 1.49 ohm\n",
+ "Resistance of 3rd section = 0.99 ohm\n",
+ "Resistance of 4th section = 0.68 ohm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import log\n",
+ "\n",
+ "# Given\n",
+ "V=500 # V\n",
+ "ns=60 # slots\n",
+ "nc=20 # conductor/slot\n",
+ "ra=1.31 # ohm\n",
+ "Tmax=218 # N-m\n",
+ "fi=23*10**-3 # Wb\n",
+ "\n",
+ "Tmin=Tmax/1.5#N-m\n",
+ "Z=ns*nc # no of conductors\n",
+ "Ia=Tmax/(.159*fi*Z) # A\n",
+ "Imax=1.5*Ia # A\n",
+ "I1=Imax # A\n",
+ "I2=Ia # A\n",
+ "R1=V/I1 # ohm\n",
+ "n= log(R1/ra)/log(I1/I2)+1 # no of studs\n",
+ "N=n-1 # no of section\n",
+ "print \"no of studs = %d and no. of section = %d\"%(n,N)\n",
+ "R2=R1*(I2/I1) # ohm\n",
+ "R3=R2*(I2/I1) # ohm\n",
+ "R4=R3*(I2/I1) # ohm\n",
+ "R1s=R1-R2 # ohm\n",
+ "R2s=R2-R3 # ohm\n",
+ "R3s=R3-R4 # ohm\n",
+ "R4s=R4-ra # ohm\n",
+ "print \"\\nResistance of 1st section = %.2f ohm\"%(R1s)\n",
+ "print \"Resistance of 2nd section = %.2f ohm\"%(R2s)\n",
+ "print \"Resistance of 3rd section = %.2f ohm\"%(R3s)\n",
+ "print \"Resistance of 4th section = %.2f ohm\"%(R4s)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 48 Page 393"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 95,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "temperature rise after 2 hours full load = 55 degree C\n",
+ "temperature rise of cold water after 1 hour = 28 degree C\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import log,exp\n",
+ "\n",
+ "# Given\n",
+ "theta1=20 # degree C\n",
+ "theta2=35 # degree C\n",
+ "t1=0.5 # hour\n",
+ "t2=1 # hour\n",
+ "theta_m_dashBYthetam=80/100 # temperature rise\n",
+ "\n",
+ "#theta=theta_m*(1-e**(-t/alfa))\n",
+ "#theta1/theta2=(1-exp(-t1/alfa))/(1-exp(-t2/alfa))\n",
+ "ee1=theta2/theta1-1 # let ee1=exp(-1/2/alfa)\n",
+ "theta_m=theta1/(1-ee1) # degree C\n",
+ "theta_2=theta_m*(1-ee1**4) # degree C (after 2 hours)\n",
+ "print \"temperature rise after 2 hours full load = %.f degree C\"%(theta_2)\n",
+ "alfa=-1/2/log(ee1) # hour\n",
+ "alfa_dash=theta_m_dashBYthetam*alfa # hour\n",
+ "theta_m_dash=theta_m_dashBYthetam*theta_m\n",
+ "theta_dash=theta_m_dash*(1-exp(-t2/alfa))\n",
+ "print \"temperature rise of cold water after 1 hour = %.f degree C\"%(theta_dash)\n",
+ "#ans of 2nd part is wrong in the book."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 49 Page 394"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 96,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Regulation at no load voltage = 6.7 percent\n",
+ "Regulation at full load voltage = 7.2 percent\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt,cos,pi,sin\n",
+ "\n",
+ "# Given\n",
+ "u=30 # degree \n",
+ "m=3 # no of phases\n",
+ "\n",
+ "#Id=sqrt(2)*Vs*X*(1-cosd(u))*sin(pi/m)\n",
+ "IdBYVs_dash=m/2/pi*(1-cos(pi/180*u))*sin(pi/m)*sqrt(2) # load current/Vs\n",
+ "#where IdBYVs_dash = m/pi*IdX/2\n",
+ "EdoBYVs=sqrt(2)*m/pi*sin(pi/m) # dc output voltage/Vs with no overlap\n",
+ "EduBYVs=EdoBYVs-IdBYVs_dash # dc output voltage/Vs with overlap\n",
+ "#part (a)\n",
+ "Reg1=(EdoBYVs-EduBYVs)/EdoBYVs*100 # % (regulation)\n",
+ "print \"Regulation at no load voltage = %.1f percent\"%(Reg1)\n",
+ "#part (b)\n",
+ "Reg2=(EdoBYVs-EduBYVs)/EduBYVs*100 # % (regulation)\n",
+ "print \"Regulation at full load voltage = %.1f percent\"%(Reg2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 50 Page 395"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 97,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Current for each machine = 370 A & 1630 A \n",
+ "Power output for each machine = 162.3 kW & 716.3 kW\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from numpy import array\n",
+ "# Given\n",
+ "I12=2000 # A (I12=I1+I2)\n",
+ "R1=0.04 # ohm\n",
+ "R2=0.025 # ohm\n",
+ "rf1=25 # ohm\n",
+ "rf2=20 # ohm\n",
+ "E1=440 # V\n",
+ "E2=420 # V\n",
+ "\n",
+ "#E-Vad=V where Vad=I1+V/rf1\n",
+ "#V*(1+R1/rf1)+R1*I1=E1#eqn(1)\n",
+ "#V*(1+R2/rf2)-I1*R2=E2-I12*R2# eqn(2)\n",
+ "A=array([[(1+R1/rf1),R1],[(1+R2/rf2),-R2]])# # matrix for solution\n",
+ "B=array([[E1],[E2-I12*R2]]) # matrix for solution\n",
+ "X=A**-1*B # solution\n",
+ "V=X[0,0] # V\n",
+ "I1=X[1,0] # A\n",
+ "I2=I12-I1 # A\n",
+ "print \"Current for each machine = %.f A & %.f A \"%(I1,I2)\n",
+ "Po1=V*I1 # W\n",
+ "Po2=V*I2 # W\n",
+ "print \"Power output for each machine = %.1f kW & %.1f kW\"%(Po1/1000,Po2/1000)\n",
+ "#ans in the book are wrong."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 51 Page 396"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 98,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "pf transformer A = 0.82 lag\n",
+ "pf transformer B = 0.78 lag\n",
+ "power output transformer A = 6535 W\n",
+ "power output transformer B = 4925 W\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import atan,pi,cos,degrees\n",
+ "# Given\n",
+ "ZA=0.15+0.5*1J # ohm\n",
+ "ZB=0.1+0.6*1J # ohm\n",
+ "EA=207 # V\n",
+ "EB=205 # V\n",
+ "ZL=2+1.5*1J # ohm\n",
+ "\n",
+ "IA=(EA*ZB+(EA-EB)*ZL)/(ZA*ZB+ZL*(ZA+ZB)) # A\n",
+ "IB=(EB*ZA-(EA-EB)*ZL)/(ZA*ZB+ZL*(ZA+ZB)) # A\n",
+ "V2=(IA+IB)*ZL # V\n",
+ "fi_A=degrees(atan((V2).imag/(V2).real)-(atan((IA.imag)/(IA.real))))\n",
+ "pf_A=cos(pi/180*fi_A) # lag\n",
+ "print \"pf transformer A = %.2f lag\"%(pf_A)\n",
+ "fi_B=degrees(atan((V2.imag)/(V2.real))-(atan((IB.imag)/(IB.real))))\n",
+ "pf_B=cos(pi/180*fi_B) # lag\n",
+ "print \"pf transformer B = %.2f lag\"%(pf_B)\n",
+ "PA=abs(V2*IA*pf_A) # W\n",
+ "print \"power output transformer A = %.f W\"%(PA)\n",
+ "PB=abs(V2*IB*pf_B) # W\n",
+ "print \"power output transformer B = %.f W\"%(PB)\n",
+ "#Power output ans are wrong in the book."
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 52 Page 397"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 99,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "filament length = 1.26 m\n",
+ "filament diameter = 20 um\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "# Given\n",
+ "d1=0.05*10**-3 # mm\n",
+ "l1=100*10**-2 # m\n",
+ "i2BYi1=1/4 # current ratio\n",
+ "#(d2/d1)**(3/2)=i2BYi1\n",
+ "d2=(i2BYi1)**(2/3)*d1*10**6 # um\n",
+ "l2=1/2*l1*d1/d2*10**6 # m\n",
+ "print \"filament length = %.2f m\"%(l2)\n",
+ "print \"filament diameter = %.f um\"%(d2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 53 Page 398"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 100,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "filament length = 1.6 m\n",
+ "filament diameter = 48 um\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "# Given\n",
+ "d1=0.10*10**-3 # mm\n",
+ "l1=150*10**-2 # m\n",
+ "i2BYi1=1/3 # current ratio\n",
+ "#(d2/d1)**(3/2)=i2BYi1\n",
+ "d2=(i2BYi1)**(2/3)*d1*10**6 # um\n",
+ "l2=1/2*l1*d1/d2*10**6 # m\n",
+ "print \"filament length = %.1f m\"%(l2)\n",
+ "print \"filament diameter = %.f um\"%(d2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 54 Page 398"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 101,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "(a) at standstill, To:Ti = 8:1\n",
+ "(b) at s=0.05, To:Ti = 3:10\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "# Given\n",
+ "zo=2+1J*2 # ohm\n",
+ "zi=0.5+1J*4 # ohm\n",
+ "Ri=(zi).real # ohm\n",
+ "Ro=(zo).real # ohm\n",
+ "\n",
+ "#at standstill\n",
+ "s=1 # % at standstill\n",
+ "Zo=sqrt((zo.real)**2+(zo.imag)**2) # ohm\n",
+ "Zi=sqrt((zi.real)**2+(zi.imag)**2) # ohm\n",
+ "ToBYTi=Ro/Ri*(Zi/Zo)**2 # torque ratio\n",
+ "print \"(a) at standstill, To:Ti = %d:1\"%(ToBYTi)\n",
+ "\n",
+ "#at s=0.5\n",
+ "s=0.05 # %\n",
+ "Zo=sqrt((zo.real)**2/s**2+(zo.imag)**2) # ohm\n",
+ "Zi=sqrt((zi.real)**2/s**2+(zi.imag)**2) # ohm\n",
+ "ToBYTi=Ro/Ri*(Zi/Zo)**2 # torque ratio\n",
+ "print \"(b) at s=0.05, To:Ti = %.f:10\"%(ToBYTi*10)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 55 Page 400"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 102,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "no. of turns in primary = 415\n",
+ "no. of turns in secondary = 12\n",
+ "\n",
+ "cross section of primary winding=6.56e-04 m**2\n",
+ "cross section of secondary winding=1.9e-05 m**2\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "\n",
+ "# Given\n",
+ "Edc=250 # V\n",
+ "fim=.065 # Wb\n",
+ "f=50 # Hz\n",
+ "E1=6000 # V\n",
+ "P=1500 # kW\n",
+ "p=8 # pole\n",
+ "pf=0.9\n",
+ "V=400 # V\n",
+ "J=3 # A/mm**2\n",
+ "\n",
+ "E2=Edc/sqrt(2)#V\n",
+ "N2=E2/4.44/f/fim # no. of turns\n",
+ "N1=E1/E2*N2 # no. of turns\n",
+ "print \"no. of turns in primary = %d\"%(N1)\n",
+ "print \"no. of turns in secondary = %d\"%(N2)\n",
+ "Idc=P*10**3/V # A\n",
+ "eta=1 # because of no loss\n",
+ "ISR=0.472*Idc/(eta*pf)\n",
+ "A1=ISR/J*10**-6 # m**2 (cross section area)\n",
+ "I1=N2/N1*ISR # A\n",
+ "A2=I1/J*10**-6 # m**2 (cross section area of primary winding)\n",
+ "print \"\\ncross section of primary winding=%.2e m**2\"%(A1)\n",
+ "print \"cross section of secondary winding=%.1e m**2\"%(A2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 56 Page 400"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 103,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Suitable auto transformation ratio = 86.6\n",
+ "Starting torque Tst = 12 percent of full-load torque\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "# Given\n",
+ "IscBYIfl=4 # as Isc=5*Ifl\n",
+ "ILByIfl=3 # as IL <= 3*Ifl\n",
+ "sf=4 # %\n",
+ "\n",
+ "#IL=K**2*ISC\n",
+ "#dividing by Ifl\n",
+ "K=sqrt(ILByIfl/IscBYIfl)*100 # %\n",
+ "TstBYTf=(K/100)**2*IscBYIfl*sf/100*100 # % #ratio of torque\n",
+ "print \"Suitable auto transformation ratio = %.1f\"%(K)\n",
+ "print \"Starting torque Tst = %.f percent of full-load torque\"%(TstBYTf)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 57 Page 401"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 104,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "temperature rise after 2 hours full load = 56 degree C\n",
+ "temperature rise of cold water after 1 hour = 27 degree C\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import log,exp\n",
+ "# Given\n",
+ "theta1=30 # degree C\n",
+ "theta2=45 # degree C\n",
+ "t1=0.5 # hour\n",
+ "t2=1 # hour\n",
+ "theta_m_dashBYthetam=60/100 # temperature rise\n",
+ "\n",
+ "#theta=theta_m*(1-e**(-t/alfa))\n",
+ "#theta1/theta2=(1-exp(-t1/alfa))/(1-exp(-t2/alfa))\n",
+ "ee1=theta2/theta1-1 # let ee1=exp(-1/2/alfa)\n",
+ "theta_m=theta1/(1-ee1) # degree C\n",
+ "theta_2=theta_m*(1-ee1**4) # degree C (after 2 hours)\n",
+ "print \"temperature rise after 2 hours full load = %.f degree C\"%(theta_2)\n",
+ "alfa=-1/2/log(ee1) # hour\n",
+ "alfa_dash=theta_m_dashBYthetam*alfa # hour\n",
+ "theta_m_dash=theta_m_dashBYthetam*theta_m\n",
+ "theta_dash=theta_m_dash*(1-exp(-t2/alfa))\n",
+ "print \"temperature rise of cold water after 1 hour = %.f degree C\"%(theta_dash)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 58 Page 401"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 105,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "at slip=0, To:Ti = 7:1\n",
+ "at s=0.05, To:Ti = 3:10\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt\n",
+ "# Given\n",
+ "zo=2+1J*3 # ohm\n",
+ "zi=0.5+1J*5 # ohm\n",
+ "Ri=(zi.real) # ohm\n",
+ "Ro=(zo.real) # ohm\n",
+ "\n",
+ "#at standstill\n",
+ "s=1 # % at standstill\n",
+ "Zo=sqrt((zo.real)**2+(zo.imag)**2) # ohm\n",
+ "Zi=sqrt((zi.real)**2+(zi.imag)**2) # ohm\n",
+ "ToBYTi=Ro/Ri*(Zi/Zo)**2 # torque ratio\n",
+ "print \"at slip=0, To:Ti = %d:1\"%(ToBYTi)\n",
+ "\n",
+ "#at s=0.5\n",
+ "s=0.05 # %\n",
+ "Zo=sqrt((zo.real)**2/s**2+(zo.imag)**2) # ohm\n",
+ "Zi=sqrt((zi.real)**2/s**2+(zi.imag)**2) # ohm\n",
+ "ToBYTi=Ro/Ri*(Zi/Zo)**2 # torque ratio\n",
+ "print \"at s=0.05, To:Ti = %.f:10\"%(ToBYTi*10)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 59 Page 402"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 106,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "part(a) Regulation at no load voltage = 15 percent\n",
+ "part(b) Regulation at full load voltage = 17 percent\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt,pi,sin,cos\n",
+ "\n",
+ "# Given\n",
+ "u=45 # degree \n",
+ "m=3 # no of phases\n",
+ "\n",
+ "#Id=sqrt(2)*Vs*X*(1-cosd(u))*sin(pi/m)\n",
+ "IdBYVs_dash=m/2/pi*(1-cos(pi/180*u))*sin(pi/m)*sqrt(2) # load current/Vs\n",
+ "#where IdBYVs_dash = m/pi*IdX/2\n",
+ "EdoBYVs=sqrt(2)*m/pi*sin(pi/m) # dc output voltage/Vs with no overlap\n",
+ "EduBYVs=EdoBYVs-IdBYVs_dash # dc output voltage/Vs with overlap\n",
+ "#part (a)\n",
+ "Reg1=(EdoBYVs-EduBYVs)/EdoBYVs*100 # % (regulation)\n",
+ "print \"part(a) Regulation at no load voltage = %.f percent\"%(Reg1)\n",
+ "#part (b)\n",
+ "Reg2=(EdoBYVs-EduBYVs)/EduBYVs*100 # % (regulation)\n",
+ "print \"part(b) Regulation at full load voltage = %.f percent\"%(Reg2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 60 Page 402"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 107,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "length of filament = 1.89 m\n",
+ "diameter of filament = 60 um\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "\n",
+ "# Given\n",
+ "d1=0.15*10**-3 # mm\n",
+ "l1=150*10**-2 # m\n",
+ "i2BYi1=1/4 # current ratio\n",
+ "#(d2/d1)**(3/2)=i2BYi1\n",
+ "d2=(i2BYi1)**(2/3)*d1*10**6 # um\n",
+ "l2=1/2*l1*d1/d2*10**6 # m\n",
+ "print \"length of filament = %.2f m\"%(l2)\n",
+ "print \"diameter of filament = %.f um\"%(d2)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 61 Page 403"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 108,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Potential difference = 1875 V\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import sqrt,sin,pi\n",
+ "# Given\n",
+ "d=5/100 # m\n",
+ "S=-4/100 # m\n",
+ "Ve=3 # kV\n",
+ "theta=45 # degree\n",
+ "e=1.6*10**-19 # C\n",
+ "m=9.67*10**-31 # kg\n",
+ "\n",
+ "u=sqrt(2*e*Ve*1000/m) # m/s\n",
+ "uy=u*sin(pi/180*theta) # m/s\n",
+ "vy=0 # since final velocity =0\n",
+ "#vy**2-uy**2=2*ay*S\n",
+ "ay=(vy**2-uy**2)/2/S # m**2/s\n",
+ "#ay=e/m*V/d\n",
+ "V=ay*m*d/e # V\n",
+ "print \"Potential difference = %.f V\"%(V)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Ex 62 Page 403"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 109,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "reading of ammeter 1= 0.56 A\n",
+ "reading of ammeter 2 = 0.30 A\n",
+ "\n",
+ "\n",
+ "Power taken from the mains = 162.0 W\n",
+ "Power dissipated in rectifying device = 115 W\n"
+ ]
+ }
+ ],
+ "source": [
+ "from __future__ import division\n",
+ "from math import pi\n",
+ "from sympy.mpmath import quad\n",
+ "# Given\n",
+ "R=150 # ohm\n",
+ "Vrms=200 # V\n",
+ "Rd1=65 # ohm\n",
+ "Rd2=140 # ohm \n",
+ "\n",
+ "Vm=Vrms/sqrt(2) # V\n",
+ "#v=Vm*sin(theta)\n",
+ "Rf=R+Rd1 # ohm\n",
+ "Rb=R+Rd2 # ohm\n",
+ "#i_f=v/Rf # A\n",
+ "#i_b=v/Rb # A\n",
+ "Irms=1/2/pi*(quad(lambda theta:(sqrt(2)*sin(theta))**2,[0,pi])+quad(lambda theta:(sqrt(2)/3*sin(theta))**2,[pi,2*pi]))\n",
+ "Iav=1/2/pi*(quad(lambda theta:sqrt(2)*sin(theta),[0,pi])+quad(lambda theta:sqrt(2)/3*sin(theta),[pi,2*pi]))\n",
+ "print \"reading of ammeter 1= %.2f A\"%(Irms)\n",
+ "print \"reading of ammeter 2 = %.2f A\"%(Iav)\n",
+ "P=1/2*(Vrms**2/Rf+Vrms**2/Rb) # W\n",
+ "print \"\\n\\nPower taken from the mains = %.1f W\"%(P)\n",
+ "Pc=Irms**2*R # W\n",
+ "Pd=P-Pc # W\n",
+ "print \"Power dissipated in rectifying device = %d W\"%(Pd)\n",
+ "#Answer wrong in the textbook."
+ ]
+ }
+ ],
+ "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.9"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}
diff --git a/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/VgnES.png b/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/VgnES.png
new file mode 100644
index 00000000..b3fe4a06
--- /dev/null
+++ b/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/VgnES.png
Binary files differ
diff --git a/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/f4att.png b/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/f4att.png
new file mode 100644
index 00000000..429bf068
--- /dev/null
+++ b/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/f4att.png
Binary files differ
diff --git a/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/starNdelta.png b/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/starNdelta.png
new file mode 100644
index 00000000..f39b0c05
--- /dev/null
+++ b/Problems_in_Electrical_Engineering_by_Parker_Smith/screenshots/starNdelta.png
Binary files differ