{ "metadata": { "name": "Chapter 1" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": "Chapter 1:Properties of Fluids" }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": "Example 1.1,Page number 5" }, { "cell_type": "code", "collapsed": false, "input": "#variable initialisation\n\nw=500 #mass of liquid in N\n\ng=9.806 #gravity in m/s*2\n\ng1=3.5 #gravity in m/s*2\n\ng2=18.0 #gravity in m/s*2\n\n\n#Solution\n\nm=w/g #mass\n\nprint \"a)m=\",round(m,2),\"kg\"\n\nw1=m*g1 #weight\n\nw2=m*g2\n\nprint \"b)w1=\",round(w1,2),\"N\"\n\nprint \"w2=\",round(w2,1),\"N\"", "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": "a)m= 50.99 kg\nb)w1= 178.46 N\nw2= 917.8 N\n" } ], "prompt_number": 1 }, { "cell_type": "code", "collapsed": false, "input": "", "language": "python", "metadata": {}, "outputs": [] } ], "metadata": {} } ] }