summaryrefslogtreecommitdiff
path: root/1415/CH1/EX1.3.6/ex6.sci
diff options
context:
space:
mode:
Diffstat (limited to '1415/CH1/EX1.3.6/ex6.sci')
-rw-r--r--1415/CH1/EX1.3.6/ex6.sci13
1 files changed, 13 insertions, 0 deletions
diff --git a/1415/CH1/EX1.3.6/ex6.sci b/1415/CH1/EX1.3.6/ex6.sci
new file mode 100644
index 000000000..718953fcd
--- /dev/null
+++ b/1415/CH1/EX1.3.6/ex6.sci
@@ -0,0 +1,13 @@
+//Example 6 Page 86
+clc
+clear
+
+function s=S(t)//function for s(t)
+ s=54*t+20
+endfunction
+t=[0 0.5 1 1.5 2]//values of t given in question
+disp(t,'time(h)')//displaying the t values
+s=S(t);//function calling
+disp(s,'marker(mi)')//displaying the s values
+plot(t,s,'blue')//plotting the graph
+xtitle('','Time(hours)','Location(miles)')//naming the axes