{ "metadata": { "name": "" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Chapter 13 : Oxidation and Corrosion" ] }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 13.1, Page No 317" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math\n", "#initialisation of variables\n", "j = 15.0\t \t# current density in mA m^-2\n", "m = 0.0243 \t\t# molar mass of magnesium\n", "F = 96490 \t\t# farad charge\n", "n = 2.0 # charge on ion\n", "t = 10.0\t # time in years\n", "\n", "#Calculations\n", "a = m*j*1e-3*(t*365*24*3600)/(n*F)\n", "\n", "#Results\n", "print(\"Amount of magnesium required is %0.1f kg m^-2\" %a)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Amount of magnesium required is 0.6 kg m^-2\n" ] } ], "prompt_number": 1 } ], "metadata": {} } ] }