summaryrefslogtreecommitdiff
path: root/32/CH3/EX3.01/3_01.sce
blob: c32e266fd513ef62fe5fee5ea956384f8f36e669 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//pathname=get_absolute_file_path('3.01.sce')
//filename=pathname+filesep()+'3.01-data.sci'
//exec(filename)
//Pressure in the gas cylinder(in kPa):
p=689
//Final volume(in m^3):
v2=0.045
//Initial volume(in m^3):
v1=0.04
//Work done by the paddle(in kJ):
Pw=-4.88
//Work done by the system on the piston(in kJ):
w=p*(v2-v1)
//Net Work of the system(in kJ):
wn=w+Pw
printf("\nRESULTS\n")
printf("\nWork done on the piston=%f kJ",w)
printf("\nWork done on the system=%f kJ",-wn)