{ "metadata": { "name": "", "signature": "sha256:f6c02b719e31d1a336f2951e35b5844e0b901d43ada783dc65f4c2528cdc373c" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Chapter 2:Composition and Resolution of Forces" ] }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 2.1, Page no.16" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math\n", "#variable declaration\n", "F_1=100 #First force in N\n", "F_2=150 #Second force in N\n", "theta=45 #Angle between F_1 and F_2 in degree\n", "\n", "#calculation\n", "R=math.sqrt((F_1**2)+(F_2**2)+(2*F_1*F_2*math.cos(theta*math.pi/180)))\n", "\n", "#Result\n", "print\"R=\",int(round(R)),\"N\"\n", "\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "R= 232 N\n" ] } ], "prompt_number": 2 }, { "cell_type": "code", "collapsed": false, "input": [], "language": "python", "metadata": {}, "outputs": [] } ], "metadata": {} } ] }