summaryrefslogtreecommitdiff
path: root/3856/CH9/EX9.3/Ex9_3.sce
blob: b95eb85a2a79550a30d90be4e4dd5fea0a87e08e (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
//Calculate the Equilibrium constant for the reaction 2H2(g)+O2(g)=2H2O(l)

//Example 9.3

clc;

clear;

delG1=-237.2; //Standard Gibbs enaergy for H2O in kJ mol^-1

delG2=0; //Standard Gibbs enaergy for H2 in kJ mol^-1

delG3=0;  //Standard Gibbs enaergy for O2 in kJ mol^-1

delG=2*delG1-2*delG2-delG3; //Standard Gibbs enaergy change for the reaction in kJ mol^-1

R=8.314;  //Gas constant in J K^-1 mol^-1

T=298;   //Temperature in K

Kp=exp(-(delG*1000)/(R*T));  //Equilibrium constant 

printf("Equilibrium constant = %.1f*10^83",Kp*10^-83);