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 --- 557/CH4/EX4.1/1.png | Bin 0 -> 7958 bytes 557/CH4/EX4.1/1.sce | 17 +++++++++++++++++ 2 files changed, 17 insertions(+) create mode 100755 557/CH4/EX4.1/1.png create mode 100755 557/CH4/EX4.1/1.sce (limited to '557/CH4/EX4.1') diff --git a/557/CH4/EX4.1/1.png b/557/CH4/EX4.1/1.png new file mode 100755 index 000000000..7d6e533cd Binary files /dev/null and b/557/CH4/EX4.1/1.png differ diff --git a/557/CH4/EX4.1/1.sce b/557/CH4/EX4.1/1.sce new file mode 100755 index 000000000..617ac9295 --- /dev/null +++ b/557/CH4/EX4.1/1.sce @@ -0,0 +1,17 @@ +clc;funcprot(0); +//Example 4.1 + +//Initializing the variables +y = linspace(0,80,9); +x = [0 23 28 31 32 29 22 14 0]; +xlabel('Velocity (m/s)'); +ylabel('Distance from one side(mm)'); +xgrid(1); + +//Calculations +plot(x,y,'-*'); +mu=[17.5 26.0 29.6 31.9 30.7 25.4 18.1 7.7]; + // mean velocity +disp(mean(mu),"Mean velocity (m/s):"); + +// the plot is attached as 4.1.png \ No newline at end of file -- cgit