From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 2096/CH1/EX1.50.b/ex_1_50_b.sce | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100755 2096/CH1/EX1.50.b/ex_1_50_b.sce (limited to '2096/CH1/EX1.50.b') diff --git a/2096/CH1/EX1.50.b/ex_1_50_b.sce b/2096/CH1/EX1.50.b/ex_1_50_b.sce new file mode 100755 index 000000000..07a9832e6 --- /dev/null +++ b/2096/CH1/EX1.50.b/ex_1_50_b.sce @@ -0,0 +1,25 @@ +//Example 1.50.b // average deviation +clc; +clear; +close; +//given data : +n=8; +a=412; +b=428; +c=423; +d=415; +e=426; +f=411; +g=423; +h=416; +q=(a+b+c+d+e+f+g+h)/n; +d1=a-q; +d2=b-q; +d3=c-q; +d4=d-q; +d5=e-q; +d6=f-q; +d7=g-q; +d8=h-q; +d=(abs(d1)+abs(d2)+abs(d3)+abs(d4)+abs(d5)+abs(d6)+abs(d7)+abs(d8))/n; +disp(d,"the average deviation,d(kHz) = ") -- cgit