{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Chapter 4 - Frequency Meters and Phase Meters" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 1 - pg 4_22" ] }, { "cell_type": "code", "execution_count": 4, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Populating the interactive namespace from numpy and matplotlib\n", "E1 mag E1 rms Ein Rms Eab output\n", "[[ 0. 0. 5. 4.501]\n", " [ 3. 2.121 5.431 4.889]\n", " [ 5. 3.53 6.123 5.513]\n", " [ 7. 4.949 7.035 6.334]\n", " [ 9. 6.363 8.093 7.286]\n", " [ 12. 8.485 9.848 8.867]\n", " [ 15. 10.606 11.726 10.557]\n", " [ 18. 12.727 13.674 12.311]\n", " [ 21. 14.849 15.668 14.106]]\n", "There is a slight error in textbook\n" ] }, { "data": { "image/png": [ "iVBORw0KGgoAAAANSUhEUgAAAYAAAAEZCAYAAACervI0AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\n", "AAALEgAACxIB0t1+/AAAH6JJREFUeJzt3XmUXFW1x/HvLxMECGEQgccUREDAAGF6YQ6KCAISRWUS\n", "EBVQFMUBRJziAE6oKPp4IAQFMSgBQZ6KotjMY4hJFBRUiIwBZRaQIfv9cW5DpdPd6eruW+dW3d9n\n", "rSyqbt2q2l2rOLvOcPdRRGBmZvUzIncAZmaWhxOAmVlNOQGYmdWUE4CZWU05AZiZ1ZQTgJlZTTkB\n", "WNuS1CXpPbnjMGtXTgBWaZLulvS0pCclPSjpbEnLFg9H8S9nfAslLZA0suHYaEkPSVo4wNd4l6Sr\n", "y4vSrHdOAFZ1AewVEeOALYCtgE/nDWkxjwB7NNzfozjWkuQkaVQr3sc6jxOAtY2IuB+4DNik4fAE\n", "SddIekLSryWt3P2ApAskPSDpMUlXStq44bE3SfpT8bx7JX2s4bG9JP1B0qOSrpU0cQmhnQsc0nD/\n", "EOAcQA2vOV7SWZLuL97vi5JGSNoIOA3YtujlPFKcv5Skky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7XoG3ejOh84VtIsYH3gXElzSXMM346IJ4rztiGV9TVrOZeDNmsg6Qrg\n", "oO7d2Ep+rxGkhLBVRLxQ9vuZ9eQegNmiTgbe16L32guY6cbfcnEPwMysptwDMDOrKScAM7OacgIw\n", "M6spJwAzs5pyAjAzqyknADOzmvp/3HLDiPkRzR0AAAAASUVORK5CYII=\n" ], "text/plain": [ "" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "#Chapter-4,Example4_1,pg 4-22\n", "#calculate the value of E1 vs EAB\n", "import math\n", "import numpy\n", "from matplotlib import pyplot\n", "import warnings\n", "warnings.filterwarnings('ignore')\n", "%pylab inline\n", "#given\n", "E1mag=numpy.array([0, 3, 5, 7, 9, 12, 15, 18, 21])\n", "Erms=5#given\n", "#results\n", "E1rms=E1mag/math.sqrt(2)\n", "Einrms=(((E1rms)**2)+((Erms)**2))**(1./2.)\n", "Eab=(2*math.sqrt(2)*Einrms)/math.pi\n", "#results\n", "pyplot.xlabel('E1(Volts)')\n", "pyplot.ylabel('Eab(Volts)')\n", "pyplot.title('Phase Meter')\n", "print\"E1 mag E1 rms Ein Rms Eab output\"\n", "k=numpy.matrix([[0, 0, 5, 4.501],\n", " [3, 2.121, 5.431, 4.889],\n", " [5, 3.53, 6.123, 5.513],\n", " [7, 4.949, 7.035, 6.334],\n", " [9, 6.363, 8.093, 7.286],\n", " [12, 8.485, 9.848, 8.867],\n", " [15, 10.606, 11.726, 10.557],\n", " [18, 12.727, 13.674, 12.311],\n", " [21, 14.849, 15.668, 14.106 ]])\n", "print (k)\n", "pyplot.plot(E1mag,Eab)\n", "print 'There is a slight error in textbook'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 2 - pg 4_24" ] }, { "cell_type": "code", "execution_count": 1, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "output voltage (V) = 6.752\n" ] } ], "source": [ "#Chapter-4,Example4_2,pg 4-24\n", "#calculate the output voltage\n", "import math\n", "from math import sqrt\n", "E1rms=10.\n", "E2rms=15.\n", "#calculations\n", "E1m=E1rms*sqrt(2)\n", "E2m=E2rms*sqrt(2)\n", "#voltage across AB is proportional to E1+E2 in positive half cycle\n", "Ep=(1/(2*math.pi))*(2*E1m+E2m)#output in positive half cycle\n", "#voltage across AB is proportional to E1-E2 in negative half cycle\n", "En=(1/(2*math.pi))*(2*E1m-E2m)#output in negative half cycle\n", "Eab=Ep-En\n", "#results\n", "print\"output voltage (V) = \",round(Eab,3)\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.9" } }, "nbformat": 4, "nbformat_minor": 0 }