blob: 21fd2ead4d0c4dd8dec79e9cd8b9bc215126faf3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
clc
clear
//Input data
T=300;//The given temperature in K
M=28;//Molecular weight of nitrogen in g
R=8.3*10^7;//The Universal gas constant in ergs/g mol-K
//Calculations
E=(3/2)*R*T;//The total random kinetic energy of nitrogen in ergs
E1=E/(M*10^7);//The total random kinetic energy of one gram of nitrogen at 300 K in joule
//Output
printf('The total random kinetic energy of one gram of nitrogen at 300 K is K.E = %3.1f joule ',E1)
|