summaryrefslogtreecommitdiff
path: root/24/CH7/EX7.4/Example7_4.sce
blob: 00086aca76fddc0983a282f0daee0b6c57369861 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
//Given that
mass = 260  //in kg
d = 2  //in meter
g = 9.8  //on m/^2

//Sample Problem 7-4a
printf("**Sample Problem 7-4a**\n")
//Using definition of work done
Wg = mass* g * (-1) * d
printf("The work done by the force of gravity is %dJ\n", Wg)

//Sample Problem 7-4b
printf("\n**Sample Problem 7-4b**\n")
//Using work energy theorem
Wc = -1 * Wg
printf("The work done by Chemerkins force is %dJ\n", Wc)

//Sample Problem 7-4c
printf("\n**Sample Problem 7-4c**\n")
printf("The Work done in helding the object stationary is 0, as the dispacement is 0\n")

//Sample Problem 7-4d
printf("\n**Sample Problem 7-4d**\n")
Weight = 27900  //in N
d = 1 * 10^-2  //in meter
Wg = Weight * d
printf("The work done by the gravity is %dJ", Wg)