summaryrefslogtreecommitdiff
path: root/24/CH2/EX2.4/Example2_4.sce
blob: f1c7e2776b7f3117a40bf42483055d4fa3f20170 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//Given that
t = poly(0,'t')
x = t^3  - 27 * t + 4

//Sample Problem 2-4a
printf("**Sample Problem 2-4a**\n")
velocity = derivat(x)
acceleration = derivat(velocity)
printf("The velocity as a function of time in m/s is")
disp(velocity)
printf("The acceleration as a function of time in m/s^2 is")
disp(acceleration)

//Sample Problem 2-4b
printf("\n**Sample Problem 2-4b**\n")
v0 = roots(velocity)
printf("velocity of the particle is zero at times in sec")
disp(v0)