diff options
author | hardythe1 | 2014-07-28 14:01:58 +0530 |
---|---|---|
committer | hardythe1 | 2014-07-28 14:01:58 +0530 |
commit | 7876eeaf85f7c020ec1f3530963928cd2bc26a66 (patch) | |
tree | 67f4da564402aeb9869eaaf6f1e83ec7f1f75aa9 /Material_Science_In_Engineering/ch9.ipynb | |
parent | 1c1ea29e3e213559fef5f928df109b7d17c21f24 (diff) | |
download | Python-Textbook-Companions-7876eeaf85f7c020ec1f3530963928cd2bc26a66.tar.gz Python-Textbook-Companions-7876eeaf85f7c020ec1f3530963928cd2bc26a66.tar.bz2 Python-Textbook-Companions-7876eeaf85f7c020ec1f3530963928cd2bc26a66.zip |
adding book
Diffstat (limited to 'Material_Science_In_Engineering/ch9.ipynb')
-rwxr-xr-x | Material_Science_In_Engineering/ch9.ipynb | 105 |
1 files changed, 105 insertions, 0 deletions
diff --git a/Material_Science_In_Engineering/ch9.ipynb b/Material_Science_In_Engineering/ch9.ipynb new file mode 100755 index 00000000..078d890f --- /dev/null +++ b/Material_Science_In_Engineering/ch9.ipynb @@ -0,0 +1,105 @@ +{ + "metadata": { + "name": "" + }, + "nbformat": 3, + "nbformat_minor": 0, + "worksheets": [ + { + "cells": [ + { + "cell_type": "heading", + "level": 1, + "metadata": {}, + "source": [ + "Chapter 9 : Microstructural Examination and Non-Destructive Testing" + ] + }, + { + "cell_type": "heading", + "level": 3, + "metadata": {}, + "source": [ + "Example 9.1 pageno : 228" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "import math \n", + "\n", + "# Variables\n", + "n = 2.**(12-1);\t\t\t#astm no. = 12\n", + "\t\n", + "# Calculations\n", + "#1 sq inch = 645mm**2\n", + "d = 1./math.sqrt((n/645)*10**4);\t\t\t#grain diameter in mm\n", + "\n", + "# Results\n", + "print \"grain diameter for ASTM no. 12 (in mm) = %.4f mm\"%d\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "grain diameter for ASTM no. 12 (in mm) = 0.0056 mm\n" + ] + } + ], + "prompt_number": 1 + }, + { + "cell_type": "heading", + "level": 3, + "metadata": {}, + "source": [ + "Example 9.2 pageno : 228" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "# Variables\n", + "n = 2**(5-1);\t\t\t#astm no. = 5 in grain/inch**2\n", + "\n", + "# Calculations\n", + "#Lineal and Areal magnifications are related as *100 Lineal = *10000 Areal\n", + "x = n/(.01*.01);\t\t\t#in grain/inch**2 at 1 x.\n", + "a = 1./x; \t\t\t#average area in inch**2\n", + "a1 = 2.54*2.54*a;\t\t\t#average area in cm.**2\n", + "l = math.sqrt(x);\t\t\t#grains/inch of length\n", + "s = (1./l)**2; \t\t\t#surface area in sq inch\n", + "s6 = 6.*s;\t\t \t#surface area of 6 surfaces of cubic grain in sq inch\n", + "b = 0.5*s6*(l**3);\t\t\t#total boundary area in sq inch\n", + "b1 = b/(2.54);\t\t\t #total boundary area in sq cm\n", + "\n", + "# Results\n", + "print \"Average area of one grain (in sq cm) = %.2e cm**2\"%a1\n", + "print \"Boundary Area per cubic centimetre of steel (in sq cm) = %.1f cm**2\"%b1\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Average area of one grain (in sq cm) = 4.03e-05 cm**2\n", + "Boundary Area per cubic centimetre of steel (in sq cm) = 472.4 cm**2\n" + ] + } + ], + "prompt_number": 2 + } + ], + "metadata": {} + } + ] +}
\ No newline at end of file |