summaryrefslogtreecommitdiff
path: root/3843/CH3/EX3.5/Ex3_5.sce
blob: 84f7c2ab9fd38bb4e6715e0ebf7441e816af420b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// Example 3_5
clc;funcprot(0);
// Given data
m=100;// kg
d=3;// m
V=0.002;// m^3
P_gage=100;// The gage pressure in kPa
g=9.81;// m/s^2

// Calculation
F=m*g;// N
W=-(F)*(d);// J
P_abs=200;// The absolute pressure in kPa
W_p=P_abs*10^3*V;// The work done on the system in J
W_net=W+W_p;// The net work done in J
printf("\nThe net work done,W_net=%4.0f J",W_net);