{ "metadata": { "name": "chapter2.ipynb" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Chapter 2:Concurrent Forces in A Plane" ] }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 2.2-1, Page No:10" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math\n", "\n", "#Initilization of variables\n", "\n", "P=50 #N\n", "Q=100 #N\n", "beta=150 #degree # angle between P & the horizontal\n", "\n", "#Calculations\n", "\n", "R=(P**2+Q**2-(2*P*Q*cos(beta*(pi/180))))**0.5 # using the Trignometric solution\n", "Alpha=(arcsin(((sin(beta*(pi/180))*Q)/R)))*(180/pi)+15 #Angle in degrees\n", "\n", "#Result\n", "print \"The magnitude of resultant is\",round(R,2),\"N\"\n", "print \"The direction of resultant is\",round(Alpha,2),\"degrees\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The magnitude of resultant is 145.47 N\n", "The direction of resultant is 35.1 degrees\n" ] } ], "prompt_number": 19 } ], "metadata": {} } ] }