{
 "metadata": {
  "name": "",
  "signature": "sha256:615c987d5bead694f67f7a47e75e92641b71f2464c202bc4e803e1f6cd3c5a16"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 6 Solutions Solutions of Electrolytes"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 6.1 , Page no:126"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "from __future__ import division\n",
      "\n",
      "#initialisation of variables\n",
      "T= 25 #C\n",
      "R= 0.0821 #li-atm per mole per degree\n",
      "M= 0.5 #m\n",
      "n= 2\n",
      "m= 0.680\n",
      "V= 1 #lit\n",
      "\n",
      "#CALCULATIONS\n",
      "P= R*(273+T)*M*n*m/V\n",
      "\n",
      "#RESULTS\n",
      "print\"osmotic pressure=\",round(P,2),\"atm\";"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "osmotic pressure= 16.64 atm\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 6.2 , Page no:127"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "from __future__ import division\n",
      "\n",
      "#initialisation of variables\n",
      "M= 0.001 #molar\n",
      "M1= 0.002 #molar\n",
      "M2= 0.004 #molar\n",
      "n= 1 #moles\n",
      "n1= 2 #moles\n",
      "v= 0.509\n",
      "\n",
      "#CALCULATIONS\n",
      "Is= 0.5*(M*n**2+M1*n**2+M1*n1**2+M2*n**2)\n",
      "r= 10**(-v*n**2*math.sqrt(Is))*M\n",
      "r1= 10**(-v*n1**2*math.sqrt(Is))*M1\n",
      "\n",
      "#RESULTS\n",
      "print\"ionic strength=\",round(Is,3);\n",
      "print\"activity of sodium =\",round(r,4),\"molar\";\n",
      "print\"activity of barium =\",round(r1,4),\"molar\";"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "ionic strength= 0.007\n",
        "activity of sodium = 0.0009 molar\n",
        "activity of barium = 0.0013 molar\n"
       ]
      }
     ],
     "prompt_number": 2
    }
   ],
   "metadata": {}
  }
 ]
}