From 7f60ea012dd2524dae921a2a35adbf7ef21f2bb6 Mon Sep 17 00:00:00 2001 From: prashantsinalkar Date: Tue, 10 Oct 2017 12:27:19 +0530 Subject: initial commit / add all books --- 260/CH13/EX13.1/13_1.sce | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 260/CH13/EX13.1/13_1.sce (limited to '260/CH13/EX13.1/13_1.sce') diff --git a/260/CH13/EX13.1/13_1.sce b/260/CH13/EX13.1/13_1.sce new file mode 100644 index 000000000..848a82c15 --- /dev/null +++ b/260/CH13/EX13.1/13_1.sce @@ -0,0 +1,20 @@ +//Eg-13.1 +//pg-522 + +clear +clc + +//Given equation dy/dx = x. Hence F'(x) = 1 and F''(x) = 0 + +//In the taylor series expnsion, if we write y0 in place of y(x0), we have +// y(1) = y1 = y(x0+h) = y0 + hx0 + h^2/2 + +x0 = 0; +y0 = 0; //Initial condition + +h = 1; //taking the value ourself + +y1 = y0 + h*x0 + h^2/2; + +printf('The value of y at x = 1 is %f\n',y1) +printf(' This is the exact solution since the higher derivatives starting from second order derivative of F vanish\n') \ No newline at end of file -- cgit