summaryrefslogtreecommitdiff
path: root/260/CH6
diff options
context:
space:
mode:
authorprashantsinalkar2017-10-10 12:27:19 +0530
committerprashantsinalkar2017-10-10 12:27:19 +0530
commit7f60ea012dd2524dae921a2a35adbf7ef21f2bb6 (patch)
treedbb9e3ddb5fc829e7c5c7e6be99b2c4ba356132c /260/CH6
parentb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (diff)
downloadScilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.gz
Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.bz2
Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.zip
initial commit / add all books
Diffstat (limited to '260/CH6')
-rw-r--r--260/CH6/EX6.1/6_1.sce13
-rw-r--r--260/CH6/EX6.10/6_10.sce15
-rw-r--r--260/CH6/EX6.11/6_11.sce16
-rw-r--r--260/CH6/EX6.12/6_12.sce8
-rw-r--r--260/CH6/EX6.13/6_13.sce30
-rw-r--r--260/CH6/EX6.14/6_14.sce21
-rw-r--r--260/CH6/EX6.15/6_15.sce17
-rw-r--r--260/CH6/EX6.2/6_2.sce8
-rw-r--r--260/CH6/EX6.3/6_3.sce8
-rw-r--r--260/CH6/EX6.4/6_4.sce27
-rw-r--r--260/CH6/EX6.5/6_5.sce28
-rw-r--r--260/CH6/EX6.6/6_6.sce8
-rw-r--r--260/CH6/EX6.7/6_7.sce14
-rw-r--r--260/CH6/EX6.8/6_8.sce8
-rw-r--r--260/CH6/EX6.9/6_9.sce8
15 files changed, 229 insertions, 0 deletions
diff --git a/260/CH6/EX6.1/6_1.sce b/260/CH6/EX6.1/6_1.sce
new file mode 100644
index 000000000..28535e313
--- /dev/null
+++ b/260/CH6/EX6.1/6_1.sce
@@ -0,0 +1,13 @@
+//Eg-6.1
+//pg-277
+
+clear
+clc
+
+p1=.2;
+p2=0.3;
+p3=.4;
+//Sum of probabilities =1
+p4=1-p3-p2-p1;
+disp("probability of getting 4 is ")
+disp(p4)
diff --git a/260/CH6/EX6.10/6_10.sce b/260/CH6/EX6.10/6_10.sce
new file mode 100644
index 000000000..5524edd91
--- /dev/null
+++ b/260/CH6/EX6.10/6_10.sce
@@ -0,0 +1,15 @@
+//Eg-6.10
+//pg-297
+
+clear
+clc
+
+data=[600;420;360;510;600;325;220;299;180;600];
+m=mean(data);
+s=variance(data);
+sd=st_deviation(data);
+
+disp("mean variance and standard deviation are respectively")
+disp(m)
+disp(s)
+disp(sd) \ No newline at end of file
diff --git a/260/CH6/EX6.11/6_11.sce b/260/CH6/EX6.11/6_11.sce
new file mode 100644
index 000000000..dd1f41b1e
--- /dev/null
+++ b/260/CH6/EX6.11/6_11.sce
@@ -0,0 +1,16 @@
+//Eg-6.11
+//pg-299
+
+clear
+clc
+
+
+data=[144.4;152.8;171.9;183;166.5;180.1;156.4;177.4;170.8;169.5;178.6;161.2;182.6;157;166.4;174.8;174.7;163.7;155.1;169.6];
+m=mean(data);
+s=variance(data);
+sd=st_deviation(data);
+
+disp("mean variance and standard deviation are respectively")
+disp(m)
+disp(s)
+disp(sd) \ No newline at end of file
diff --git a/260/CH6/EX6.12/6_12.sce b/260/CH6/EX6.12/6_12.sce
new file mode 100644
index 000000000..f081c94ca
--- /dev/null
+++ b/260/CH6/EX6.12/6_12.sce
@@ -0,0 +1,8 @@
+//Eg-6.12
+//pg-300
+
+clear
+clc
+
+//Theoretical Problem
+disp("The example is theoretically solved.") \ No newline at end of file
diff --git a/260/CH6/EX6.13/6_13.sce b/260/CH6/EX6.13/6_13.sce
new file mode 100644
index 000000000..9c70237fc
--- /dev/null
+++ b/260/CH6/EX6.13/6_13.sce
@@ -0,0 +1,30 @@
+//Eg-6.13
+//pg-302
+
+clear
+clc
+
+//zc-confidence level
+A=[3 99.73;2.33 98;1.96 95;1.65 90;1.28 80;1 68.27];
+
+//mean and standard deviation
+x=24.8;
+s=1.35;
+n=60;//two months
+
+//90% confidence level
+zc=1.65;
+limit1=x-zc*s/n^.5;
+limit2=x+zc*s/n^.5;
+
+//95% confidence level
+zc=2.33;
+lim1=x-zc*s/n^.5;
+lim2=x+zc*s/n^.5;
+
+disp("90% confidencelevel limits")
+disp(limit1)
+disp(limit2)
+disp("95% confidencelevel limits")
+disp(lim1)
+disp(lim2)
diff --git a/260/CH6/EX6.14/6_14.sce b/260/CH6/EX6.14/6_14.sce
new file mode 100644
index 000000000..1af8f9ff7
--- /dev/null
+++ b/260/CH6/EX6.14/6_14.sce
@@ -0,0 +1,21 @@
+//Eg-6.14
+//pg-304
+
+clear
+clc
+
+//mean and standard deviation are given as
+x=1.011;
+s=.108;
+
+n=500;
+a=1;
+
+d=(x-a)/(s/n^.5);
+if d<=1.96 & d>=-1.96 then
+ disp("null hypothesis :Ho:u=1mm is accepted")
+else
+ disp("the value of d lies outside range.Therefore we will reject HO at 0.05 level of significance")
+end
+
+
diff --git a/260/CH6/EX6.15/6_15.sce b/260/CH6/EX6.15/6_15.sce
new file mode 100644
index 000000000..272bc808d
--- /dev/null
+++ b/260/CH6/EX6.15/6_15.sce
@@ -0,0 +1,17 @@
+//Eg-6.15
+//pg-306
+
+clear
+clc
+n=10;
+data=[4.5;6.7;5.5;7.2;4.3;4;5.2;6.3;6.5;7];
+m=mean(data);
+s=st_deviation(data);
+a=5;
+
+d=(m-a)/s*(n-1)^.5;
+if d<=2.26 & d>=-2.26 then
+ disp("null hypothesis :Ho:u=5mm is accepted.Therfore professors hypothesis is correct")
+else
+ disp("the value of d lies outside range.Therefore we will reject HO at 0.05 level of significance")
+end
diff --git a/260/CH6/EX6.2/6_2.sce b/260/CH6/EX6.2/6_2.sce
new file mode 100644
index 000000000..96999ba90
--- /dev/null
+++ b/260/CH6/EX6.2/6_2.sce
@@ -0,0 +1,8 @@
+//Eg-6.2
+//pg-279
+
+clear
+clc
+
+//Theoretical Problem
+disp("given example is Theoretical")
diff --git a/260/CH6/EX6.3/6_3.sce b/260/CH6/EX6.3/6_3.sce
new file mode 100644
index 000000000..c4bdf898c
--- /dev/null
+++ b/260/CH6/EX6.3/6_3.sce
@@ -0,0 +1,8 @@
+//Eg-6.3
+//pg-284
+
+clear
+clc
+
+//Theoretical Problem
+disp("given example is Theoretical") \ No newline at end of file
diff --git a/260/CH6/EX6.4/6_4.sce b/260/CH6/EX6.4/6_4.sce
new file mode 100644
index 000000000..bf2edebdf
--- /dev/null
+++ b/260/CH6/EX6.4/6_4.sce
@@ -0,0 +1,27 @@
+//Eg-6_4
+//pg-284
+
+clear
+clc
+
+s=[9;10;14;16;12];
+n=0;
+m=0;
+for i=1:5
+ if s(i)<=10 then
+ n=n+1;
+ end
+end
+
+for i=1:5
+ if s(i)<15 then
+ m=m+1;
+ end
+end
+
+prob_10=n/5;
+prob_15=m/5;
+
+disp("probability of getting ash content 10 and 15% are")
+disp(prob_10)
+disp(prob_15) \ No newline at end of file
diff --git a/260/CH6/EX6.5/6_5.sce b/260/CH6/EX6.5/6_5.sce
new file mode 100644
index 000000000..61d6eadc0
--- /dev/null
+++ b/260/CH6/EX6.5/6_5.sce
@@ -0,0 +1,28 @@
+//Eg-6_5
+//pg-287
+
+clear
+clc
+
+
+
+//Bottle no -total pesticide(ppb)
+A=[ 1 15;2 23;3 12.2;4 18.8;5 19.5;6 16.6;7 21.7;8 16.8;9 20.2;10 21.3];
+//considering no of intervals as 5
+n=5;
+r=(max(A(:,2))-min(A(:,2)))/n;
+for i=1:5
+ x(i)=min(A(:,2))+i*r;
+ c=0;
+ for j=1:10
+ if A(j,2)<=x(i) then
+ c=c+1;
+ end
+ end
+ f(i)=c/10;
+end
+
+C=[x f];
+
+disp("cumulative distribution function")
+disp(C) \ No newline at end of file
diff --git a/260/CH6/EX6.6/6_6.sce b/260/CH6/EX6.6/6_6.sce
new file mode 100644
index 000000000..52061c3c0
--- /dev/null
+++ b/260/CH6/EX6.6/6_6.sce
@@ -0,0 +1,8 @@
+//Eg-6.6
+//pg-289
+
+clear
+clc
+
+//Theoretical Problem
+disp("given example is Theoretical") \ No newline at end of file
diff --git a/260/CH6/EX6.7/6_7.sce b/260/CH6/EX6.7/6_7.sce
new file mode 100644
index 000000000..6c10c1568
--- /dev/null
+++ b/260/CH6/EX6.7/6_7.sce
@@ -0,0 +1,14 @@
+//Eg-6.7
+//pg-290
+
+clear
+clc
+
+//sorting data in ascending order
+x=[233;216;229;238];
+m1=median(x);
+y=[56;62;51];
+m2=median(y);
+disp("medians of given data are as follows")
+disp(m1)
+disp(m2) \ No newline at end of file
diff --git a/260/CH6/EX6.8/6_8.sce b/260/CH6/EX6.8/6_8.sce
new file mode 100644
index 000000000..9945c8230
--- /dev/null
+++ b/260/CH6/EX6.8/6_8.sce
@@ -0,0 +1,8 @@
+//Eg-6.8
+//pg-291
+
+clear
+clc
+
+//Theoretical Problem
+disp("This example is solved analytically.") \ No newline at end of file
diff --git a/260/CH6/EX6.9/6_9.sce b/260/CH6/EX6.9/6_9.sce
new file mode 100644
index 000000000..bf2c82c1f
--- /dev/null
+++ b/260/CH6/EX6.9/6_9.sce
@@ -0,0 +1,8 @@
+//Eg-6.9
+//pg-294
+
+clear
+clc
+
+//Theoretical Problem
+disp("The example is solved analytically.") \ No newline at end of file