summaryrefslogtreecommitdiff
path: root/75/CH3/EX3.4/ex_4.sce
diff options
context:
space:
mode:
Diffstat (limited to '75/CH3/EX3.4/ex_4.sce')
-rwxr-xr-x75/CH3/EX3.4/ex_4.sce35
1 files changed, 35 insertions, 0 deletions
diff --git a/75/CH3/EX3.4/ex_4.sce b/75/CH3/EX3.4/ex_4.sce
new file mode 100755
index 000000000..56f24481d
--- /dev/null
+++ b/75/CH3/EX3.4/ex_4.sce
@@ -0,0 +1,35 @@
+ // PG (140)
+
+X = [2.0,2.1,2.2,2.3,2.4]
+X1 = X(1,1)
+X2 = X(1,2)
+X3 = X(1,3)
+X4 = X(1,4)
+X5 = X(1,5)
+deff('[y]=f(x)','y=sqrt(x)')
+Y = [f(X1) f(X2) f(X3) f(X4) f(X5)]
+Y1 = Y(1,1)
+Y2 = Y(1,2)
+Y3 = Y(1,3)
+Y4 = Y(1,4)
+Y5 = Y(1,5)
+
+// Difference
+
+// f[X1,X2]
+(f(X2) - f(X1))*10
+// f[X2,X3]
+(f(X3) - f(X2))*10
+// f[X3,X4]
+(f(X4) - f(X3))*10
+// f[X4,X5]
+(f(X5) - f(X4))*10
+
+// D^2 * f[Xi]
+
+((f(X3)-f(X2)) - (f(X2)-f(X1))) * 50
+((f(X4)-f(X3)) - (f(X3)-f(X2))) * 50
+((f(X5)-f(X4)) - (f(X4)-f(X3))) * 50
+
+
+