summaryrefslogtreecommitdiff
path: root/3821/CH9/EX9.2/Example9_2.sce
blob: b2d9484725d58fe51cb95bd61089fed29150c3d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
///Chapter 9 Law Of Thermodynamics
///Example 9.2 Page No:166
///Find Quantity of heat transferred 
///Input data
clc;
clear;
                      //During compression
W1=-9200;              //Stroke work done by the piston in Nm
Nm1=-9.2;              //Nm of work done
Q1=-50;                //Heat rejected during copression in KJ
                      //During expansion
W2=8400;               //Stroke work done by the piston in Nm
Nm2=8.4;               //Nm of work done

///Calculation;
                      //Quantity of heat transferred
Q2=-((Nm1+Nm2)+Q1);    //-sign for indicate heat is transferred


///Output
printf('Quantity of heat transferred= %f KJ \n',Q2);