summaryrefslogtreecommitdiff
path: root/539/CH6/EX6.6.a
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /539/CH6/EX6.6.a
downloadScilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip
initial commit / add all books
Diffstat (limited to '539/CH6/EX6.6.a')
-rwxr-xr-x539/CH6/EX6.6.a/Example_6_6a.sce24
1 files changed, 24 insertions, 0 deletions
diff --git a/539/CH6/EX6.6.a/Example_6_6a.sce b/539/CH6/EX6.6.a/Example_6_6a.sce
new file mode 100755
index 000000000..fef18d29c
--- /dev/null
+++ b/539/CH6/EX6.6.a/Example_6_6a.sce
@@ -0,0 +1,24 @@
+//Average Computations
+
+clear;
+clc;
+
+printf("\tExample 6.6a\n");
+
+//First and Last point are arbitary to plot the required 4 points
+n=[0 1 2 3 4 5];
+TS=[510 520 512 515 522 525];
+
+plot(n,TS,'+');
+xtitle('Tensile strength data','Sample no.','Tensile strength');
+
+//Mean Tensile strength
+i=2;
+TSmean=0;
+
+for i=2:5
+ TSmean=TSmean+(TS(i)/4);
+end
+printf("\nMean tensile strength is %d MPa\n",TSmean);
+
+//End