diff options
Diffstat (limited to 'basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter2_eh02mMg.ipynb')
-rw-r--r-- | basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter2_eh02mMg.ipynb | 1146 |
1 files changed, 0 insertions, 1146 deletions
diff --git a/basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter2_eh02mMg.ipynb b/basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter2_eh02mMg.ipynb deleted file mode 100644 index f4889ecb..00000000 --- a/basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter2_eh02mMg.ipynb +++ /dev/null @@ -1,1146 +0,0 @@ -{ - "cells": [ - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "# Chapter 2:Network Analysis And Network Theorems" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.1:Page number-50" - ] - }, - { - "cell_type": "code", - "execution_count": 2, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "i= 2.5 A\n", - "voltage across 6 ohm resistor= 6.0 V\n", - "voltage across 4 ohm resistor= 4.0 V\n", - "voltage when 4 ohm resistor is connected= 40.0 V\n", - "voltage when both resistors are in series= 100.0 V\n" - ] - } - ], - "source": [ - "import math\n", - "v=10\n", - "r=4\n", - "#case a\n", - "i=v/float(r)\n", - "print \"i=\",format(i,'.1f'),\"A\"\n", - "#case b\n", - "#6ohm resistor is in series with 4 ohm resistor\n", - "i=v/(6+4)\n", - "v1=i*6\n", - "v2=i*4\n", - "print \"voltage across 6 ohm resistor=\",format(v1,'.1f'),\"V\"\n", - "print \"voltage across 4 ohm resistor=\",format(v2,'.1f'),\"V\"\n", - "#case c\n", - "i=10 #constant in both cases\n", - "v4=i*4\n", - "print \"voltage when 4 ohm resistor is connected=\",format(v4,'.1f'),\"V\"\n", - "v6=i*6\n", - "v=v4+v6\n", - "print \"voltage when both resistors are in series=\",format(v,'.1f'),\"V\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.2:Page number-53" - ] - }, - { - "cell_type": "code", - "execution_count": 1, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "rs= 0.5 ohm\n", - "the load voltage is expressed as 36rl/(0.5+rl)\n" - ] - }, - { - "data": { - "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYEAAAEPCAYAAACk43iMAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAGt9JREFUeJzt3XuUVeWd5vHvUyBqokK8NNDLNJcVFJfKRRSJjeSgsUUT\njUbNyDh0vEbtoMloM+poFtjpbuNl1MnNdEdwlDVjJOoYs7BFRz2agGJUQIXYcdJixx5FOyQuRWuJ\n8ps/3lOmrFQVpy777L3PeT5rsTh1rg97FfWr931/+92KCMzMrDW15R3AzMzy4yJgZtbCXATMzFqY\ni4CZWQtzETAza2EuAmZmLSyzIiBpJ0mrJa2VtEHSVZ0eu0DSLyU9L+nqrDKYmVnvhmb1xhHRLml2\nRLwjaSjwc0kzgR2A44FJEbFV0l5ZZTAzs95lOh0UEe/Ubg4DhgC/A84DroqIrbXnvJFlBjMz61mm\nRUBSm6S1wCbgkYhYD+wDzJL0hKSqpIOzzGBmZj3LbDoIICK2AVMkDQdWSKrUPvMTETFD0iHAMmB8\nljnMzKx7mRaBDhHxpqTlwMHAK8Ddtft/IWmbpD0i4redXyPJmxqZmfVRRKgvz8+yO2hPSSNqt3cG\njgLWAPcAR9Tu3wcY1rUAdJgzJzj88ODVV4OI8vxZuHBh7hmcP/8czl/OP2XO3x9ZrgmMBh6urQms\nBn4aEQ8BS4Dxkp4Dbgf+sqc3WL4cjjwSDj4Yfv7zDJOambWoLFtEnwMO6ub+rcC8et6jrQ0WLoRD\nD4WTToLLLoOvfQ3Up8GOmZn1pBRnDM+ZA6tXw9KlMHcuvP123ol6V6lU8o4wIM6fL+fPV9nz95X6\nO4+UNUnRNVt7O8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figure.Figure at 0x7f9cd722d810>" - ] - }, - "metadata": {}, - "output_type": "display_data" - } - ], - "source": [ - "import math\n", - "i=72\n", - "v=36\n", - "rs=v/float(i)\n", - "print \"rs=\",format(rs,'.1f'),\"ohm\"\n", - "print \"the load voltage is expressed as 36rl/(0.5+rl)\"\n", - "%matplotlib inline\n", - "import matplotlib.pyplot as plt\n", - "x=[40,50,60,72]\n", - "y=[36,34,32,30]\n", - "plt.plot(x,y)\n", - "plt.xlabel('il(A)')\n", - "plt.ylabel('vl(V)')\n", - "plt.show()\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.3:Page number-55" - ] - }, - { - "cell_type": "code", - "execution_count": 5, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "ir= 32.0 A\n", - "il= 2.23 A\n" - ] - } - ], - "source": [ - "import math\n", - "v=24\n", - "r=0.75\n", - "ir=v/r\n", - "print \"ir=\",format(ir,'.1f'),\"A\"\n", - "il=v/(10+r) #since 10 is in series with r\n", - "print \"il=\",format(il,'.2f'),\"A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.4:Page number-56" - ] - }, - { - "cell_type": "code", - "execution_count": 7, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "power= 120.0 W\n", - "power dissipated= 30.0 W\n", - "total power supplied by practical source is= 90.0 W\n", - "current source= 40.0 A\n" - ] - } - ], - "source": [ - "import math\n", - "vs=12\n", - "rs=0.3\n", - "il=10\n", - "#case a\n", - "p=vs*il\n", - "print \"power=\",format(p,'.1f'),\"W\"\n", - "#case b\n", - "power=il**2*rs\n", - "print \"power dissipated=\",format(power,'.1f'),\"W\"\n", - "#case c\n", - "totpow=(vs-il*rs)*il\n", - "print \"total power supplied by practical source is=\",format(totpow,'.1f'),\"W\"\n", - "i=vs/rs\n", - "print \"current source=\",format(i,'.1f'),\"A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.5:Page number-58" - ] - }, - { - "cell_type": "code", - "execution_count": 8, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "r2= 15.0 ohm\n", - "req= 15.0 ohm\n", - "0.0291666666667\n", - "req= 15.0 ohm\n", - "0.230833333333\n" - ] - } - ], - "source": [ - "import math\n", - "#case a\n", - "#v0/vs=r2/(r1+r2)=0.4r2=0.6r1\n", - "r1=10\n", - "r2=(0.6*r1)/float(0.4)\n", - "print \"r2=\",format(r2,'.1f'),\"ohm\"\n", - "#case b\n", - "#when r2 is parallel to r3\n", - "r3=200000\n", - "req=(r2*r3)/(r2+r3)\n", - "print \"req=\",format(req,'.1f'),\"ohm\"\n", - "#v0/vs=0.5825\n", - "change=(0.6-0.5825)/float(0.6)\n", - "print change\n", - "r3=20000\n", - "req=(r2*r3)/(r3+r2)\n", - "print \"req=\",format(req,'.1f'),\"ohm\"\n", - "#v0/vs=0.4615\n", - "change=(0.6-0.4615)/0.6\n", - "print change" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.6:Page number-60" - ] - }, - { - "cell_type": "code", - "execution_count": 12, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "req= 1.09 ohm\n", - "vs= 7.66 V\n" - ] - } - ], - "source": [ - "import math\n", - "r=2\n", - "i=2\n", - "i3=3 #obtained by applying current divider rule to figure\n", - "i4=1\n", - "req=1/float(0.5+0.25+0.166) #1/2,1/4,1/6 values are converted to decimal form\n", - "print \"req=\",format(req,'.2f'),\"ohm\"\n", - "i2=(4*i4/float(6))\n", - "i1=(6*i2)/float(req)\n", - "#tracing circuit cabc via 6 ohm resistor and applying ohms law,\n", - "vs=i1*i4+i2*6\n", - "print \"vs=\",format(vs,'.2f'),\"V\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.7:Page number-61" - ] - }, - { - "cell_type": "code", - "execution_count": 13, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "the value of series parallel resistances is 10 ohm\n" - ] - } - ], - "source": [ - "import math\n", - "#combining series parallel series\n", - "#[(2+2+2)||(6+5+2)||10]+5\n", - "#[[6*6/6+6]+7]||10]+5=[10+10/10*10]+5=5+5=10\n", - "print \"the value of series parallel resistances is 10 ohm\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.8" - ] - }, - { - "cell_type": "code", - "execution_count": 20, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "rab= 54.55 ohm\n", - "rab= 54.286 ohm\n", - "rcd= 50.91 ohm\n", - "rab= 50.67 ohm\n" - ] - } - ], - "source": [ - "import math\n", - "#case a\n", - "#rab=(80+40)||(60+40)\n", - "rab=(120*100)/float(120+100)\n", - "print \"rab=\",format(rab,'.2f'),\"ohm\"\n", - "#rab=(80||60)+(40||40)\n", - "rab=(4800/float(140))+(1600/80)\n", - "print \"rab=\",format(rab,'.3f'),\"ohm\"\n", - "#case b\n", - "#(60+80)||(40+40)\n", - "rcd=(140*80)/float(140+80)\n", - "print \"rcd=\",format(rcd,'.2f'),\"ohm\"\n", - "#(60||40)+(80||40)\n", - "rab=float(2400/float(100))+(3200/float(120))\n", - "print \"rab=\",format(rab,'.2f'),\"ohm\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## example 2.9:Page number-65" - ] - }, - { - "cell_type": "code", - "execution_count": 22, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "ceq= 0.83402836 F\n" - ] - } - ], - "source": [ - "import math\n", - "#simplifying the circuit \n", - "ceq=1/float(0.333+0.666+0.2) #converted to decimal form\n", - "print \"ceq=\",format(ceq,'.8f'),\"F\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.10:Page number-67" - ] - }, - { - "cell_type": "code", - "execution_count": 29, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "i= 1.200000 A\n", - "i1= 0.800000 A\n", - "i2= 0.400000 A\n", - "power consumed by 2 ohm resistor= 2.88 W\n", - "power consumed by 12 ohm resistor= 7.68 W\n", - "power consumed by 2 ohm resistor= 3.84 W\n", - "voltage drop= 2.4 V\n" - ] - } - ], - "source": [ - "import math\n", - "#case a\n", - "I=12/(2+((12*24)/float(36))) #values taken from circuit\n", - "I1=I*(24/float(36))\n", - "I2=I*(12/float(36))\n", - "print \"i=\",format(I,'1f'),\"A\"\n", - "print \"i1=\",format(I1,'1f'),\"A\"\n", - "print \"i2=\",format(I2,'1f'),\"A\"\n", - "#case b\n", - "power=(I**2)*2\n", - "print \"power consumed by 2 ohm resistor=\",format(power,'.2f'),\"W\"\n", - "power=(I1**2)*12\n", - "print \"power consumed by 12 ohm resistor=\",format(power,'.2f'),\"W\"\n", - "power=(I2**2)*24\n", - "print \"power consumed by 2 ohm resistor=\",format(power,'.2f'),\"W\"\n", - "#case c\n", - "v=I*2\n", - "print \"voltage drop=\",format(v,'.1f'),\"V\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.11:Page number-69" - ] - }, - { - "cell_type": "code", - "execution_count": 30, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "rab=3.12ohm\n", - "ran=6 ohm\n" - ] - } - ], - "source": [ - "import math\n", - "#case a\n", - "#values taken and calculated from figure\n", - "r1=6\n", - "r2=12\n", - "r3=18\n", - "rab=3.21 #calculating similar to above using parallel in series resistances\n", - "print \"rab=3.12ohm\"\n", - "#case b\n", - "r4=30\n", - "r5=15\n", - "r6=30\n", - "ran=6 #similar as above\n", - "print \"ran=6 ohm\"\n", - "\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.12:Page number-73" - ] - }, - { - "cell_type": "code", - "execution_count": 31, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "v1=0.0769 V\n", - "v2=-0.3846V\n", - "current in 0.5ohm resistance is 0.154A,0.25ohm resistance is 1.846,0.66ohm resistor is -1.154A\n" - ] - } - ], - "source": [ - "import math\n", - "#eqns derived from figure\n", - "#6v1-4v2=2-->1\n", - "#-4v1+7v2=-3-->2\n", - "#eqn 1 and 2 are written in matrix form and solved using cramers rule\n", - "print \"v1=0.0769 V\"\n", - "print \"v2=-0.3846V\"\n", - "print \"current in 0.5ohm resistance is 0.154A,0.25ohm resistance is 1.846,0.66ohm resistor is -1.154A\"\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.13:Page number-74" - ] - }, - { - "cell_type": "code", - "execution_count": 32, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "v1=3.6V\n", - "v2=2.2V\n", - "the current in 0.6 ohm resistor is 10.8A,0.2 ohm resistor is 7A,0.16ohm resistor is 13.2 A\n" - ] - } - ], - "source": [ - "import math\n", - "#from the figure the eqns are written in matrix form and using cramers rule the value of v1 and v2 can be found\n", - "print \"v1=3.6V\"\n", - "print \"v2=2.2V\"\n", - "print \"the current in 0.6 ohm resistor is 10.8A,0.2 ohm resistor is 7A,0.16ohm resistor is 13.2 A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.14:Page number-76 " - ] - }, - { - "cell_type": "code", - "execution_count": 33, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "the voltages of nodes 1 and 3 are 50.29 and 57.71 respectively\n", - "current through 16 ohm resistor is 1.64A\n" - ] - } - ], - "source": [ - "import math\n", - "#kcl is applied to the circuit and the eqns obtained are solved using cramer's rule\n", - "print \"the voltages of nodes 1 and 3 are 50.29 and 57.71 respectively\"\n", - "#i3=v/r\n", - "print \"current through 16 ohm resistor is 1.64A\"\n", - "\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.15:Page number-78" - ] - }, - { - "cell_type": "code", - "execution_count": 34, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "voltage across 3 ohm resistor is= 5.832 V\n" - ] - } - ], - "source": [ - "import math\n", - "#the eqns obtained are converted to matrix form for solving using cramer's rule values are found\n", - "i1=5.224\n", - "i2=0.7463\n", - "i3=3.28\n", - "v=(i1-i3)*3\n", - "print \"voltage across 3 ohm resistor is=\",format(v,'.3f'),\"V\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.16:page number-79" - ] - }, - { - "cell_type": "code", - "execution_count": 35, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "currents obtained are i1=2.013 and i2=1.273\n" - ] - } - ], - "source": [ - "import math\n", - "#kvl eqns are obtained from figure which are solved to obtain currents\n", - "print \"currents obtained are i1=2.013 and i2=1.273\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.17:Page number-80" - ] - }, - { - "cell_type": "code", - "execution_count": 37, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "voltage at node D= 5.68 v\n", - "current in 4 ohm resistor is= 1.47 A\n", - "power supplied by 18V source is= 27.72 W\n" - ] - } - ], - "source": [ - "import math\n", - "#the currents are obtained by solving the eqns\n", - "i1=5.87\n", - "i2=-0.13\n", - "i3=-1.54\n", - "v=18-1.54*8\n", - "print \"voltage at node D=\",format(v,'.2f'),\"v\"\n", - "i=5.86/float(4)\n", - "print \"current in 4 ohm resistor is=\",format(i,'.2f'),\"A\"\n", - "power=18*1.54\n", - "print \"power supplied by 18V source is=\",format(power,'.2f'),\"W\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.18:Page number-82" - ] - }, - { - "cell_type": "code", - "execution_count": 38, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "va=8.33V and vb=4.17V\n", - "current through 8 ohm resistor is= 1.04 A\n" - ] - } - ], - "source": [ - "import math\n", - "#node eqns are obtained form the figure\n", - "print \"va=8.33V and vb=4.17V\"\n", - "i=8.33/float(8)\n", - "print \"current through 8 ohm resistor is=\",format(i,'.2f'),\"A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.19:Page number-83 " - ] - }, - { - "cell_type": "code", - "execution_count": 39, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "i1=-1.363A and i2=-3.4A\n" - ] - } - ], - "source": [ - "import math\n", - "#eqns obtained are calculated just like above problems and are aolved for i1 and i2\n", - "print \"i1=-1.363A and i2=-3.4A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.20:Page number-84" - ] - }, - { - "cell_type": "code", - "execution_count": 40, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "current supplied by dependent source is= -6.0 A\n", - "power supplied by voltage source is= 41.34 W\n" - ] - } - ], - "source": [ - "import math\n", - "#eqns are obtained from the figure and are solved for currents\n", - "i1=6.89\n", - "i2=3.89\n", - "i3=-2.12\n", - "i=2*(i2-i1)\n", - "print \"current supplied by dependent source is=\",format(i,'.1f'),\"A\"\n", - "power=6*i1\n", - "print \"power supplied by voltage source is=\",format(power,'.2f'),\"W\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.21:Page number-86" - ] - }, - { - "cell_type": "code", - "execution_count": 2, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "i8= 0.667 A\n", - "i8'= 1.333 A\n", - "total current= 2.0 A\n" - ] - } - ], - "source": [ - "import math\n", - "#the following problem is based on usage of superposition theorem\n", - "i8=12/float(6+4+8) #current for 8 ohm resistor.the resistances are in series with each other.Hence 6+4+8\n", - "#next when voltage source is short circuited (8+4) total of resistance is obtained.The 4A is distributed in parallel branches as per current divider rule\n", - "i=(4*6)/float(6+12)\n", - "print \"i8=\",format(i8,'.3f'),\"A\"\n", - "print \"i8'=\",format(i,'.3f'),\"A\"\n", - "tot=i8+i\n", - "print \"total current=\",format(tot,'.1f'),\"A\"\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Exampe 2.22:Page number-88" - ] - }, - { - "cell_type": "code", - "execution_count": 8, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "0.972972972973 A\n" - ] - } - ], - "source": [ - "import math\n", - "#kvl is applied to circuit\n", - "i=1\n", - "vth=12-(1*4) #12 is voltage 1 is current and 4 is resistance\n", - "rth=(4*5)/float(4+5)\n", - "i6=vth/float(rth+6) #since current passes through 6 ohm resistor\n", - "print i6,\"A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.23:Page number-89" - ] - }, - { - "cell_type": "code", - "execution_count": 4, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "current through 2 ohm resistor is= 2.45 A\n", - "Note that the same problem is again solved using superposition theorem and hence ignored \n" - ] - } - ], - "source": [ - "import math\n", - "#thevenin's theorem and superposition theorem used here\n", - "#applying mesh eqns to the 2 circuits and after getting the eqns they are solved using cramer's rule to obtain i1 and i2\n", - "i1=-0.6\n", - "i2=-1.2\n", - "#the value of currents indicates that they have assumed to be flowing in directions opposite to the assumed direction\n", - "vth=12-1.2*3 #voltage eqn\n", - "rth=1.425 #(1+2||12)||3=(1+(2*12)/(2+12))||3=19/7||3=19/7*3/19/7+3=1.425\n", - "i2=vth/(rth+2)\n", - "print \"current through 2 ohm resistor is=\",format(i2,'.2f'),\"A\"\n", - "print \"Note that the same problem is again solved using superposition theorem and hence ignored \" " - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.24:Page number-91" - ] - }, - { - "cell_type": "code", - "execution_count": 5, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "current through 5 ohm resistor is= 1.327 A\n" - ] - } - ], - "source": [ - "import math\n", - "#using thevenin's theorem\n", - "#applying kcl at node a va is obtained\n", - "va=12\n", - "rth=1.33 #2||4\n", - "i5=vth/(rth+5)\n", - "print \"current through 5 ohm resistor is=\",format(i5,'.3f'),\"A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.25:Page number-92" - ] - }, - { - "cell_type": "code", - "execution_count": 6, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "rth= 4.997 A\n" - ] - } - ], - "source": [ - "import math\n", - "#applying kvl to circuit\n", - "i=0.414\n", - "vth=12-4*0.414 #using vth formula\n", - "#when terminals a and b are short circuited applying kcl to node a gives isc=5*i\n", - "isc=2.07\n", - "rth=vth/isc\n", - "print \"rth=\",format(rth,'.3f'),\"A\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.26:Page number-93" - ] - }, - { - "cell_type": "code", - "execution_count": 7, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "iab= 1.5 A\n" - ] - } - ], - "source": [ - "import math\n", - "#norton's theorem\n", - "v=10\n", - "#applying kvl to closed circuit \n", - "isc=12/float(2+2) \n", - "rn=4 #resistance obtained by short circuiting v and opening i\n", - "iab=(4*3)/float(4+4) #current through 4 ohm connected across AB\n", - "print \"iab=\",format(iab,'.1f'),\"A\"\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.27:Page number-103" - ] - }, - { - "cell_type": "code", - "execution_count": 8, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "natural frequency= -0.91668 secinverse\n" - ] - } - ], - "source": [ - "import math\n", - "#natural frequency needs to be determined\n", - "#req=[(6+6)||4]+[1||2]=3.6666\n", - "req=3.6667\n", - "l=4 #inductance\n", - "s=-req/float(l)\n", - "print \"natural frequency=\",format(s,'.5f'),\"secinverse\"" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.28" - ] - }, - { - "cell_type": "code", - "execution_count": 9, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "natural frequency= -0.15873 secinverse\n", - "time constant= 6.3 sec\n" - ] - } - ], - "source": [ - "import math\n", - "#req=[10+2+(5||15)]=15.75\n", - "#case a\n", - "c=0.4\n", - "req=15.75\n", - "s=-1/float(c*req)\n", - "print \"natural frequency=\",format(s,'.5f'),\"secinverse\"\n", - "#case b\n", - "tc=req*0.4 #time constant\n", - "print \"time constant=\",format(tc,'.1f'),\"sec\"\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.30:Page number-109" - ] - }, - { - "cell_type": "code", - "execution_count": 11, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "voltage= 1560.0 v\n", - "r=20 ohm\n", - "tc= 0.1667 sec\n", - "balance energy= 2.25 J\n", - "t=0.25 sec\n" - ] - } - ], - "source": [ - "import math\n", - "v=120\n", - "r=40\n", - "i=v/float(r)\n", - "#applying kvl to the closed loop\n", - "v=3*520\n", - "print \"voltage=\",format(v,'.1f'),\"v\"\n", - "#when v=120,R can be found by I*(r+20)=120-->r=20\n", - "r=20\n", - "print \"r=20 ohm\"\n", - "#when r=20 total r=20+20+20=60\n", - "r=60\n", - "l=10\n", - "tc=l/float(r) #time constant\n", - "print \"tc=\",format(tc,'.4f'),\"sec\"\n", - "#i=I0*e^-(t/tc)=3*e^(-6t)\n", - "energy=(10*9)/float(2)\n", - "benergy=0.05*energy\n", - "print \"balance energy=\",format(benergy,'.2f'),\"J\"\n", - "#(L*i^2)/2=2.25-->hence i=0.6708\n", - "#3*e^-6t=0.6708-->e^-6t=0.2236-->applying log on both sides we get t=0.25\n", - "print \"t=0.25 sec\"\n", - "\n" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Example 2.34:Page number-116" - ] - }, - { - "cell_type": "code", - "execution_count": 12, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "R=2.72Mohm\n", - "t=9.16 sec\n" - ] - } - ], - "source": [ - "import math\n", - "v=120\n", - "V=200\n", - "#v=V(1-e^-5/2R)\n", - "#120=200*(1-e^-5/2R)\n", - "#applying log on both sides and solving we get R=2.72 Mohm\n", - "print \"R=2.72Mohm\"\n", - "R=5 \n", - "tc=10\n", - "#applying in the above eqn and solving lograthmically we get t=9.16\n", - "print \"t=9.16 sec\"" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": { - "collapsed": true - }, - "outputs": [], - "source": [] - } - ], - "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.5" - } - }, - "nbformat": 4, - "nbformat_minor": 0 -} |