summaryrefslogtreecommitdiff
path: root/Engineering_Physics_by_A_Marikani/6-Crystallography.ipynb
diff options
context:
space:
mode:
Diffstat (limited to 'Engineering_Physics_by_A_Marikani/6-Crystallography.ipynb')
-rw-r--r--Engineering_Physics_by_A_Marikani/6-Crystallography.ipynb609
1 files changed, 609 insertions, 0 deletions
diff --git a/Engineering_Physics_by_A_Marikani/6-Crystallography.ipynb b/Engineering_Physics_by_A_Marikani/6-Crystallography.ipynb
new file mode 100644
index 0000000..5a729e8
--- /dev/null
+++ b/Engineering_Physics_by_A_Marikani/6-Crystallography.ipynb
@@ -0,0 +1,609 @@
+{
+"cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Chapter 6: Crystallography"
+ ]
+ },
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.10: Ratio_of_cubic_system.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"// Example No.6.10.\n",
+"// Page No.189.\n",
+"clc;clear;\n",
+"h=1;k=0;l=0;\n",
+"d100=1/sqrt(h^2+k^2+l^2);\n",
+"disp('Interplanar spacing for d100 plane = a');\n",
+"h=1;k=1;l=0;\n",
+"d110=1/sqrt(h^2+k^2+l^2);\n",
+"disp('Interplanar spacing for d110 plane = a/1.414');\n",
+"h=1;k=1;l=1;\n",
+"d111=1/sqrt(h^2+k^2+l^2);\n",
+"disp('Interplanar spacing for d111 plane = a/1.732');\n",
+"x = sqrt(6);\n",
+"y = sqrt(3);\n",
+"z = sqrt(2);\n",
+"printf('\nx = %.3f',x);\n",
+"printf('\ny = %.3f',y);\n",
+"printf('\nz = %.3f',z);\n",
+"printf('\nd100:d110:d111 = %.3f:%.3f:%.3f',x,y,z);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.11: Ratio_of_intercepts.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"// Example No.6.11.\n",
+"// Page No.190.\n",
+"clc;clear;\n",
+"l1 = 6*(1/2);\n",
+"l2 = 6*(1/3);\n",
+"l3 = (6*1/6);\n",
+"disp('For the plane (231) the intercepts are (a/2),(b/3),(c/1)');\n",
+"disp('Ratio of the intercepts made by (231) plane in simple cubic crystal is as follows :');\n",
+"disp('l1:l2:l3 = 3:2:6');\n",
+"\n",
+"//As there are no numerical steps and hence the display statement has been typed directly."
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.12: Length_of_the_intercepts.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"// Example No.6.12.\n",
+"// Page No.190.\n",
+"//To find the lengths of the intercepts.\n",
+"clc;clear;\n",
+"a = 0.8;\n",
+"b = 1.2;\n",
+"c = 1.5;\n",
+"disp('Ratio of the intercepts are as follows : ');\n",
+"disp('I1:I2:I3 = a:b/2:c/3');\n",
+"I1 = 0.8;\n",
+"disp('0.8:I2:I3 = a:b/2:c/3');\n",
+"disp('By substituting values');\n",
+"I2=(1.2/2);\n",
+"printf('\nI2 = %.1f A',I2);\n",
+"I3=(1.5/3);\n",
+"printf('\nI3 = %.1f A',I3);\n",
+"\n",
+"\n",
+"\n",
+"//As there are no numerical steps and hence the display statement has been typed directly."
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.13: Nearest_neighbour_distance.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"// Example No.6.13.\n",
+"// Page No.191.\n",
+"//To find the nearest neighbour distance.\n",
+"clc;clear;\n",
+"disp('i)Simple cubic unit cell');\n",
+"disp('The nearest neighbour distance is a');//nearest neighbour distance.\n",
+"disp('ii)Body-centered cubic unit cell');\n",
+"disp('2r = (0.866)a');\n",
+"disp('iii)Face-centered cubic unit cell');\n",
+"disp('2r = (0.7071)a');\n",
+"\n",
+"//As there are no numerical steps and hence the display statement has been typed directly."
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.14: Interplanar_distance.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.14.\n",
+"//Page No.191.\n",
+"//To find interplanar distance.\n",
+"clc;clear;\n",
+"// (h,k,l) are the miller indices of the given lattice plane (212).\n",
+"h = 2;\n",
+"k = 1;\n",
+"l = 2;\n",
+"a = 2.04;//Lattice constant -[A].\n",
+"d = (a/sqrt(h^2+k^2+l^2));\n",
+"printf('\nThe interplanar distance is %.2f A',d);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.15: Number_of_atoms_per_unit_cell.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"//Example No.6.15.\n",
+"//Page No.191.\n",
+"clc;clear;\n",
+"r = 1.278*10^(-10),'m';\n",
+"M = 63.54;//Atomic weight of copper.\n",
+"Na = 6.022*10^(26);\n",
+"d = 8980;//density\n",
+"a = r*sqrt(8);//Interatomic distance.\n",
+"printf('\n The interatomic distance is %3.3e m',a);\n",
+"n = ((d*a^(3)*Na)/(M));//The number of atoms per unit cell.\n",
+"printf('\n Number of atoms per Cu unit cell is %.f',n);\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.16: Miller_indices_of_the_faces.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"// Example No.6.16.\n",
+"// Page No.192.\n",
+"//To find the miller indices.\n",
+"clc;clear;\n",
+"disp('i)Ratio of the intercepts are 0.214 : 1 : 0.188');\n",
+"disp('Miller indices for the given plane is (212)');\n",
+"disp('ii)Ratio of the intercepts are 0.858 : 1 : 0.754');\n",
+"disp('Miller indices for the given plane is (121)');\n",
+"disp('iii)Ratio of the intercepts are 0.429 : infinity : 0.126');\n",
+"disp('Miller indices for the given plane is (103)');\n",
+"\n",
+"//There are no numerical computations involved in this example and hence the display statement has been typed directly."
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.17: Number_of_atoms_present.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"// Example No.6.13.\n",
+"// Page No.191.\n",
+"//To find the number neighbour distance.\n",
+"clc;clear;\n",
+"disp('i)For (100) plane');\n",
+"disp('Number of atoms per m^2 = 1/4r^2');\n",
+"disp('i)For (110) plane');\n",
+"c1 = 1/(8*sqrt(2));\n",
+"printf('\nc1= %.4f',c1);\n",
+"disp('Number of atoms per m^2 = (0.084/r^2)');\n",
+"disp('i)For (111) plane');\n",
+"c2 = 1/(2*sqrt(3));\n",
+"printf('\nc2= %.4f',c2);\n",
+"disp('Number of atoms per m^2 = (0.2887/r^2)');\n",
+"\n",
+"\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.18: Ionic_packing_factor.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.18\n",
+"//Page No.194.\n",
+"clc;clear;\n",
+"r = 0.97*10^(-10);\n",
+"R = 1.81*10^(-10);\n",
+"Pd = ((%pi)/(3*sqrt(2)));\n",
+"printf('\nThe packing density is %.2f',Pd);\n",
+"//Ionic factor of NaCl//\n",
+"IPF = (4*(4/3)*%pi*(r^(3)+R^(3)))/((2*(r+R))^(3));//Ionic packing factor of NaCl crystal.\n",
+"printf('\nThe ionic packing factor of NaCl crystal is %.3f',IPF);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.1: Density_of_diamond.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.1\n",
+"//Page No.185.\n",
+"clc;clear;\n",
+"Mc = 12;// Mc is the mass of one carbon atom.\n",
+"r = 0.071*10^(-9);//radius -[m].\n",
+"D = ((8*Mc)/(6.022*10^(26)*((8*r)/(sqrt(3)))^(3)));//density of the diamond.\n",
+"printf('\nThe density of diamond is %.1f kg/m^3',D);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.2: percentage_volume.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.2.\n",
+"//Page No.185.\n",
+"clc;clear;\n",
+"a1 = 0.332*10^(-9);//Lattice parameter for BCC structure -[m].\n",
+"a2 = 0.296*10^(-9);//Lattice parameter for HCP structure -[m].\n",
+"c = 0.468*10^(-9);// -[m]\n",
+"disp('BCCv is the volume of BCC unit cell');\n",
+"BCCv = a1^(3);//Volume of BCC unit cell.\n",
+"printf('\nThe volume of BCC unit cell is %3.3e m^-3',BCCv);\n",
+"disp('HCPv is the volume of HCP unit cell');\n",
+"HCPv = (6*(sqrt(3)/4)*a2^(2)*c);//Volume of HCP unit cell.\n",
+"printf('\nThe volume of HCP unit cell is %3.3e m^3',HCPv);\n",
+"Cv = (HCPv-BCCv);\n",
+"printf('\nThe change in volume is %3.3e',Cv);\n",
+"Vp = (Cv/BCCv)*100;\n",
+"printf('\nThe volume change in percentage is %.1f percent',Vp);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.3: Atomic_structure_and_density.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.3\n",
+"//Page No.186.\n",
+"clc;clear;\n",
+"r = 1.278*10^(-10);//Atomic radius of copper -[m].\n",
+"A = 63.54;//Atomic weight of copper.\n",
+"n = 4;\n",
+"Na = 6.022*10^(26);\n",
+"a = (2*sqrt(2)*r);\n",
+"printf('\nThe lattice constant for FCC is %3.3e',a); \n",
+"d = ((n*A)/(Na*a^(3)));//for FCCn=4.\n",
+"d = ((n*A)/(Na*(3.61*10^(-10))^(3)));\n",
+"printf('\nThe density of copper is %.0f kg/m^3',d);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.4: Interatomic_distance_of_NACL.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.4.\n",
+"//Page No.186.\n",
+"clc;clear;\n",
+"Na = 23;//Atomic weight of Na\n",
+"Cl = 35.5;//Atomic weight of Cl\n",
+"d = 2180;//Density of Nacl -[kg/m^3].\n",
+"nA = 6.022*10^(26);\n",
+"NaCl = (Na+Cl)//Molecular weight of NaCl.\n",
+"printf('\n1) Molecular weigth of NaCl is %.1f',NaCl);\n",
+"n = 4;\n",
+"A = 58.5;\n",
+"a = (((n*A)/(nA*d))^(1/3));\n",
+"printf('\n2) The interatomic distance of NaCl crystal is %3.3e m',a); "
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.5: Relation_between_interatomic_and_interplanar.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.5.\n",
+"//Page No.187.\n",
+"clc;clear;\n",
+"a = 0.42;//Lattice constant -[nm].\n",
+"//(h1,k1,l1) are the miller indices of the plane (101).\n",
+"h1 = 1;\n",
+"k1 = 0;\n",
+"l1 = 1;\n",
+"d1 = (a/sqrt(h1^(2)+k1^(2)+l1^(2)));//interplanar and interatomic distance of plane (101)\n",
+"printf('\nFor (101) plane, the interplanar and interatomic distance is %.4f nm',d1);\n",
+"// (h2,k2,l2) are the miller indices of the plane (221).\n",
+"h2 = 2;\n",
+"k2 = 2;\n",
+"l2 = 1;\n",
+"d2 = (a/sqrt(h2^(2)+k2^(2)+l2^(2)));//interplanar and interatomic distance of plane (221)\n",
+"printf('\nFor (221) plane, the interplanar and interatomic distance is %.2f nm',d2);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.6: Axial_intercepts.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"// Example No.6.6.\n",
+"// Page No.187.\n",
+"clc;clear;\n",
+"disp('For the plane (102),the intercepts are (a/1) = a,(b/0) = infinity ,c/2');\n",
+"disp('For the plane (231),the intercepts are a/2 , b/3 and (c/1) = c');\n",
+"disp('For the plane (312),the intercepts are a/3 ,(b/-1) = -b ,c/2');\n",
+"\n",
+"//As there are no numerical steps available and hence the display statement has been typed directly.\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.7: Angle_between_the_planes.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.7\n",
+"//Page No.188.\n",
+"//Find the angle between two planes (111) and (212) in a cubic lattice.\n",
+"clc;clear;\n",
+"// (u1,v1,w1) are the miller indices of the plane (111).\n",
+"u1 = 1;\n",
+"v1 = 1;\n",
+"w1 = 1;\n",
+"// (u2,v2,w2) are the miller indices of the plane (212).\n",
+"u2 = 2;\n",
+"v2 = 1;\n",
+"w2 = 2;\n",
+"u = acosd(((u1*u2)+(v1*v2)+(w1*w2))/((sqrt((u1^2)+(v1^2)+(w1^2))*sqrt((u2^2)+(v2^2)+(w2^2)))));//u is the angle between two planes.\n",
+"printf('\n The angle between the planes (111) and (212) is %.3f degree',u);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.8: Crystallographic_planes.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"// Example No.6.8.\n",
+"// Page No.188.\n",
+"clc;clear;\n",
+"disp('The intercepts of the plane(100) are a ,infinity ,infinity.');\n",
+"disp('The intercepts of the cubic plane(110) are a ,a ,infinity.');\n",
+"disp('The intercepts of the plane(111) are a ,a ,a.');\n",
+"disp('The intercepts of the plane(200) are a/2 ,infinity ,infinity.');\n",
+"disp('The intercepts of the plane(120) are a ,a/2 ,infinity.');\n",
+"disp('The intercepts of the plane(211) are a/2 ,a ,a.');\n",
+"\n",
+"//As there are no numerical steps and hence the display statement has been typed directly.\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 6.9: Lattice_constant.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Example No.6.9.\n",
+"//Page No.189.\n",
+"clc;clear;\n",
+"d = 0.2338;//'d' is the interplanar distance -[nm].\n",
+"// (h,k,l) are the miller indices of the given plane.\n",
+"h = (-1);\n",
+"k = 1;\n",
+"l = 1;\n",
+"a = (d*sqrt(h^2+k^2+l^2));//'a' is the lattice constant\n",
+"printf('\nThe lattice constant is %.4f nm',a); "
+ ]
+ }
+],
+"metadata": {
+ "kernelspec": {
+ "display_name": "Scilab",
+ "language": "scilab",
+ "name": "scilab"
+ },
+ "language_info": {
+ "file_extension": ".sce",
+ "help_links": [
+ {
+ "text": "MetaKernel Magics",
+ "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md"
+ }
+ ],
+ "mimetype": "text/x-octave",
+ "name": "scilab",
+ "version": "0.7.1"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}