{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Chapter 1: Review of Basic Circuits" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 1 Page No:5" ] }, { "cell_type": "code", "execution_count": 18, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Applying KCL at junction(N),we get I=1+2=3 A\n" ] } ], "source": [ "# Given Data\n", "#Current through Resistor R1 is 1A\n", "#Current through Resistor R2 is 2A\n", "#Display results\n", "print\"Applying KCL at junction(N),we get I=1+2=3 A\" # KCL stands for Kirchoff's Current Law which states\n", " # that sum of all currents at a junction equals to zero\n", " # N is the name of the junction" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 2 Page No:7" ] }, { "cell_type": "code", "execution_count": 19, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "I=0.200000 A\n" ] } ], "source": [ "#Given Data\n", "E1=4.;#EMF in volts\n", "E2=2.;#EMF in volts\n", "r1=2.;#Resistance in ohm\n", "r2=3.;#Resistance in ohm\n", "R=5.;#Resistance in ohm\n", "#Calculations\n", "#Applying KVL to the circuit,we get\n", "I=(E1-E2)/(r1+r2+R);#Current in Amperes\n", "#Display Results\n", "print \"I=%f A\"%I;" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3 Page No:9" ] }, { "cell_type": "code", "execution_count": 20, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The current by the battery I=0.312500 Amperes\n" ] } ], "source": [ "#Given Data\n", "E=10.0;#EMF in volts\n", "R1=20.0;#Resistance in ohm\n", "R2=20.0;#Resistance in ohm\n", "R3=30.0;#Resistance in ohm\n", "#Calculations\n", "Req=R1+(R2*R3/(R2+R3));# Equivalent resistance of the circuit\n", "I=E/Req;#Current through the battery in Amperes\n", "print \"The current by the battery I=%f Amperes\"%I;\n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 4 Page No:12" ] }, { "cell_type": "code", "execution_count": 21, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Current through R=5ohm is 0.277778 Amperes\n" ] } ], "source": [ "#Naming emfs on both sides to be E1,E2 respectively\n", "#and resistances as R1,R2,R3\n", "#Given Data\n", "E1=3.0;# volts\n", "E2=1.0;# volts\n", "R1=4.0;# ohms\n", "R2=Rab=RL=5.0;# ohms\n", "R3=2.0;# ohms\n", "#Calculations\n", "#We apply Thevenins Theorem to solve\n", "#We have to find Vth and Rth\n", "#First Apllying KVL in the outer loop,we get\n", "I=2.0/6;# Amp\n", "Va=3-I*4# volts\n", "#Since 'B' is attached to negative potential\n", "Vth=Vab=Va-0;# volts\n", "#Then we find Rth\n", "Rth=Rab=2*4/(2+4);# ohm\n", "IL=Vth/(Rth+RL);# Load Current in Amp\n", "print \"Current through R=5ohm is %f Amperes\"%IL\n", "\n", "\n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 5 Page No:14" ] }, { "cell_type": "code", "execution_count": 22, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The power delivered to 'R' is maximum when R=r/2\n", "Maximum Power transferred is Pmax=E**2/(2*r)\n" ] } ], "source": [ "from sympy import Symbol\n", "#Given Data\n", "#Two batteries of emf E with internal resistances 'r'\n", "#Calculations\n", "#Case(a)\n", "#Open circuiting the branch containing 'R'\n", "#and short circuiting 'E'\n", "E=Symbol('E');\n", "r=Symbol('r');\n", "Rth=r*r/(r+r);# Thevenin's Eq. Resistance in Ohm\n", "print \"The power delivered to 'R' is maximum when R=%s\"%Rth; #According to the maximum power transform theorem\n", "#case(b)\n", "#Applying Parallel Theorem\n", "Vth=E; # Vth is Thevenin's Voltage\n", "#Pmax=(IL**2)*R\n", "Pmax=(Vth/(2*Rth))**2*Rth;# R=Rth, Pmax is Maximum power tranferred\n", "print \"Maximum Power transferred is Pmax=%s\"%Pmax;\n" ] }, { "cell_type": "markdown", "metadata": { "collapsed": false }, "source": [ "## Solved Questions" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.1 Page No:33" ] }, { "cell_type": "code", "execution_count": 23, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Input Power=444.44 KW\n", "Power Factor=-0.998612\n" ] } ], "source": [ "import math\n", "from numpy import degrees,arctan,cos\n", "#Given\n", "#For a 3ph motor\n", "VL=2000; #in volts\n", "f=50;# Hz\n", "nFL=0.9;#Full load Efficiency\n", "W1=300;#Wattmeter-1 Reading in KW\n", "W2=100;#Wattmeter-2 Reading in KW\n", "#Calculations\n", "#(i)\n", "Po=W1+W2;#Outout Power\n", "Pin=Po/nFL;#Input Power\n", "#(ii)\n", "ph=degrees(arctan(((W2-W1)*math.sqrt(3))/(W1+W2)));\n", "pf=cos(ph);\n", "#Display\n", "print\"Input Power=%.2f KW\"%Pin;\n", "print\"Power Factor=%f\"%pf;" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.2 Page No:34" ] }, { "cell_type": "code", "execution_count": 24, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Line Current=23.09Amperes\n", "Power factor=0.800000\n", "Power=12.800000 KW\n", "Total Volt Ampere=16.00 KVA\n" ] } ], "source": [ "import math\n", "from numpy import arctan2,degrees,cos\n", "#Given\n", "#A balanced star connected load\n", "Zph=8+1j*6;#Ohm\n", "VL=400;#Line voltage inVolts\n", "#Calculations\n", "#(i)\n", "Vph=VL/math.sqrt(3);#Phase Voltage\n", "Iph=Vph/abs(Zph);#Phase Current\n", "IL=Iph;#Line current\n", "#(ii)\n", "pf=cos(arctan2(Zph.imag,Zph.real));#Power factor\n", "#(iii)\n", "P=math.sqrt(3)*VL*IL*pf*10**-3;#Power\n", "#(iv)\n", "VA=math.sqrt(3)*VL*IL*10**(-3);#Volt Ampere\n", "#Display\n", "print\"Line Current=%.2fAmperes\"%IL;\n", "print\"Power factor=%f\"%pf;\n", "print\"Power=%f KW\"%P;\n", "print\"Total Volt Ampere=%.2f KVA\"%VA;" ] }, { "cell_type": "markdown", "metadata": { "collapsed": true }, "source": [ "## Q.3 Page No:35" ] }, { "cell_type": "code", "execution_count": 25, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Line current=3.264397 amp\n", "Power Absorbed=1.600000 KW\n", "Total KVA=2.261641 KVA\n", "Power Factor=0.707451\n" ] } ], "source": [ "import math\n", "from numpy import arctan2,cos,degrees\n", "#Given\n", "#Each phase of a star connected load has\n", "R=100;# Resistance in Ohm\n", "C=31.8*10**(-6);# Capacitance in Farad\n", "#Connected to 3-ph\n", "VL=400;#Volts\n", "f=50;#Hz\n", "#Calculations\n", "Xc=1/(2*math.pi*f*C);#Capacitive Reactance in Ohm\n", "num=R*-1j*Xc;#Ohm\n", "den=(R-1j*Xc);\n", "Z=(num*den.conjugate())/(den*den.conjugate()); #Impedance\n", "#(i)\n", "Vp=VL/math.sqrt(3);#Phase voltage\n", "IL=Vp/abs(Z);#Line current\n", "#(ii)\n", "ph=arctan2(Z.imag,Z.real); #Phase angle\n", "TKVA=math.sqrt(3)*VL*IL*10**(-3);# Total Power\n", "P=TKVA*cos(ph);\n", "pf=cos(ph);#Power factor\n", "#Display\n", "print\"Line current=%f amp\"%IL;\n", "print\"Power Absorbed=%f KW\"%P;\n", "print\"Total KVA=%f KVA\"%TKVA;\n", "print\"Power Factor=%f\"%pf;\n", "#Answer differs slightly from TEXTBOOK" ] }, { "cell_type": "markdown", "metadata": { "collapsed": true }, "source": [ "## Q.4. Page No:36" ] }, { "cell_type": "code", "execution_count": 26, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Line voltage=461.88 volt\n", "Phase voltage=266.67 volt\n", "KVAR input=16.703293 KVAR\n" ] } ], "source": [ "import math\n", "from numpy import arccos,sin\n", "#Given\n", "#The load connectted to a 3-ph supply comprises\n", "Pkva=20;#in KVA\n", "Pkw=11.0;#in KW\n", "IL=25;#Line Current in Amp\n", "#Calculations\n", "ph=arccos(Pkw/Pkva);\n", "Pkvar=Pkva*sin(ph);#in KVAR\n", "VL=20*10**3/(math.sqrt(3)*IL);\n", "Vph=VL/math.sqrt(3);\n", "#Display\n", "print\"Line voltage=%.2f volt\"%VL;\n", "print\"Phase voltage=%.2f volt\"%Vph;\n", "print\"KVAR input=%f KVAR\"%Pkvar;" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.5. Page No:37" ] }, { "cell_type": "code", "execution_count": 27, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Resistance across Delta Circuit=60.000000 Ohm\n", "Current flowing through them=6.67 Amp\n" ] } ], "source": [ "import math\n", "#Given\n", "#A star circuit and a delta circuit\n", "#In star circuit\n", "VL1=400.0;#volts\n", "R1=20.0;#ohm\n", "#In Delta Circuit\n", "VL=400;#volt\n", "#Calculations\n", "Vph1=VL1/math.sqrt(3); #Phase Voltage-1\n", "Iph1=Vph1/R1; #Phase current-1\n", "IL1=Iph1; #Line current-1\n", "#In Delta circuit\n", "IL2=IL1; # Line current-2\n", "VL2=VL1; #line voltage-2\n", "Vph2=VL2; #Phase voltage-2\n", "Iph2=IL2/math.sqrt(3);#Phase current-2\n", "R2=Vph2/Iph2;#Resistance in Ohm\n", "#Display\n", "print\"Resistance across Delta Circuit=%f Ohm\"%R2;\n", "print\"Current flowing through them=%.2f Amp\"%Iph2;\n", "\n" ] }, { "cell_type": "markdown", "metadata": { "collapsed": true }, "source": [ "## Q.6. Page No:37" ] }, { "cell_type": "code", "execution_count": 28, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Phase current=27.712813 A\n", "Power consumed=6.400000 KW\n", "Phasor sum of all line currents= 0\n" ] } ], "source": [ "import math\n", "#Given\n", "#A 3-ph supply connected to balanced delta load\n", "VL=Vph=400; #in volts\n", "Zph=15+1j*20; #Ohm\n", "#Calculations\n", "#(i)\n", "Iph=Vph/abs(Zph); #Phase current\n", "#(ii)\n", "P=Iph**2*abs(Zph)*10**-3; #Power\n", "#(iii)\n", "IL=math.sqrt(3)*Iph; #Line current\n", "#Display\n", "print\"Phase current=%f A\"%IL;\n", "print\"Power consumed=%f KW\"%P;\n", "print\"Phasor sum of all line currents=\",0;\n", "#SOLUTION IN THE TEXTBOOK IS WRONG" ] }, { "cell_type": "markdown", "metadata": { "collapsed": true }, "source": [ "## Q.7 Page No:38" ] }, { "cell_type": "code", "execution_count": 29, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Line Voltage=346.41 V\n", "On reversing the phase connections,Line voltage remains unaffected\n" ] } ], "source": [ "#Given\n", "#In a 3-ph Star connected System\n", "Vp=200;#Phase voltage in volts\n", "#Calculations\n", "#(a)\n", "VL=math.sqrt(3)*Vp; #Line Voltage in volts\n", "#(b)\n", "#Line voltage remains unaffected\n", "#Display\n", "print\"Line Voltage=%.2f V\"%VL;\n", "print\"On reversing the phase connections,Line voltage remains unaffected\";" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.8 Page No:39" ] }, { "cell_type": "code", "execution_count": 30, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Total Power drawn=600.000000 Watts\n" ] } ], "source": [ "import math\n", "from numpy import cos\n", "import cmath\n", "#Given\n", "#A 3-ph supply connected to 3-ph load\n", "Vp=200; #Phase Voltage in volts\n", "Zp=cmath.rect(100,60*math.pi/180); #Phase Impedance\n", "#Calculations\n", "Ip=Vp/abs(Zp); #Phase current in Amp\n", "P=Vp*Ip*cos(cmath.phase(Zp)); #Power in Watts\n", "P3ph=3*P;#3-ph Power\n", "#Display\n", "print\"Total Power drawn=%f Watts\"%P3ph;" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.9 Page No:39" ] }, { "cell_type": "code", "execution_count": 31, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "W1=-4.843135 KW\n", "W2=34.843135 KW\n" ] } ], "source": [ "import math\n", "from numpy import arccos,cos\n", "#Given\n", "#A 3-ph motor\n", "VL=500.0; #Line voltage in watts\n", "pf=0.4; #Power factor\n", "P=30*10**3; #Total power in KW\n", "#Calculations\n", "ph=arccos(pf);\n", "IL=P/(math.sqrt(3)*VL*pf);\n", "W1=VL*IL*cos((30*math.pi/180)+ph)*10**(-3); #Wattmeter-1 in KW\n", "W2=VL*IL*cos((30*math.pi/180)-ph)*10**(-3); #Wattmeter-2 in KW\n", "#Display\n", "print\"W1=%f KW\"%W1;\n", "print\"W2=%f KW\"%W2;\n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.10 Page No:39" ] }, { "cell_type": "code", "execution_count": 32, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Power=6.000000 KW\n", "Power factor=0.654654\n" ] } ], "source": [ "import math\n", "from numpy import arctan\n", "#Given\n", "#In a particular measuremet\n", "W1=5000; #Wattmeter-1 reading\n", "W2=1000;#Wattmeter-2 reading\n", "#Calculations\n", "P=(W1+W2)*10**-3; #Power\n", "pf=cos(arctan(math.sqrt(3)*(W2-W1)/(W1+W2))); #Power Factor\n", "#display\n", "print\"Power=%f KW\"%P;\n", "print\"Power factor=%f\"%pf;\n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.11 Page No:40" ] }, { "cell_type": "code", "execution_count": 33, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "W1=6.380724 watts\n", "W2=50.037023 watts\n" ] } ], "source": [ "import math\n", "from numpy import arctan,arccos,cos\n", "#Given\n", "# A 3-ph motor has\n", "VL=400.0; #Line voltage in volts\n", "pf=0.75; #Power factor\n", "P=26*10**3; #Power\n", "#Calculations\n", "ph=math.degrees(arccos(pf)); #Phase angle\n", "IL=P/(math.sqrt(3)*VL*pf); #Line current\n", "W1=VL*IL*cos(math.radians(30+ph))*10**(-3); #Wattmeter Reading-1\n", "W2=VL*IL*cos(math.radians(30-ph))*10**(-3);#Wattmeter Reading-2\n", "#Display\n", "print\"W1=%f watts\"%W1;\n", "print\"W2=%f watts\"%IL;\n", "#Answers differing from Textbook" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Q.12 Page No:40" ] }, { "cell_type": "code", "execution_count": 34, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Power Factor=-0.804634\n" ] } ], "source": [ "#In 3-ph supply\n", "#Given\n", "W1=1200; #Wattmeter Reading -1\n", "W2=300; #Wattmeter Reading-2\n", "#Calculations\n", "pf=arctan(math.sqrt(3)*(W2-W1)/(W1+W2)); #Power factor\n", "#Display\n", "print\"Power Factor=%f\"%pf;\n" ] } ], "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.11" } }, "nbformat": 4, "nbformat_minor": 0 }