# Variables
h = 23070. #cal volt**-1 g equiv**-1
n = 2. #electrons
e = 1.005 #volts
T = 25. #C
e1 = 1.015 #volts
# Calculations
dH = (-n*h*(e-((273.2+T)*(e-e1)/T)))/1000
# Results
print 'Heat change in the cell reaction = %.2f kcal'%(dH)
# Variables
E = -0.344 #volt
E1 = -0.401 #volt
R = 0.05914 #volt
n = 4.
T = 25. #C
H = -7300. #cal
# Calculations
po2 = 10**(-n*(E-E1)/R)
dH = -0.5*n*H+0.5*n*(273+T)
# Results
print 'Pressure of Oxygen = %.1e atm'%(po2)
print ' Change in Enthalpy = %.f cal'%(dH+4)
# Variables
H = -60.15 #kcal
e = 2.924 #volt
v = 23070. #cc
T = 25. #C
Sm = 15.2 #E.U.mole**-1
Sg = 31.2 #E.U.mole**-1
# Calculations
dS = (H*1000-(-e*v))/(273.2+T)
Sk = (dS+Sm)-0.5*Sg
# Results
print 'Standard entropy of pottasium ion = %.1f E.U.g ion**-1'%(Sk)
# Variables
dS = -4.61 #E.Ugm ion**-1
SH = 31.21 #E.U gm ion**-1
Sm = 9.95 #E.U gm ion**-1
# Calculations
Szn = dS-SH+Sm
# Results
print 'Standard entropy of zinc ion = %.1f E.U.g ion**-1'%(Szn)
# Variables
import math
n = 2.
T = 25. #C
R = 4.576
is_ = 9.57*10**-6
n1 = 4.
f = 0.509 #volts
dH = 5970. #cal
SBa = 2.3 #E.U. gm ion**-1
Sba = 31.5 #E.U. gm ion6-1
# Calculations
r = 10**(-n1*f*math.sqrt(n1*is_))
dF = -n*R*(273.2+T)*math.log10(is_*r)
dS = (dH-dF)/(273.2+T)
Sso = Sba-SBa+dS
# Results
print 'Standard entropy of sulfate ion = %.1f E.U.g ion**-1'%(Sso)
# Variables
f1 = 20.66 #kcal
h1 = 21.6 #kcal
e1 = 50.34 #kcal
f2 = 0 #kcal
f3 = -56.70 #kcal
f4 = -26.25 #kcal
h2 = 0 #kcal
h3 = -68.32 #kcal
h4 = -49.5 #kcal
e2 = 49.00 #kcal
e3 = 16.75 #kcal
e4 = 35 #kcal
n1 = 2
n2 = 1.5
n3 = 1
T = 25 #C
# Calculations
dF = n1*f4-(n1*f1+f3)
dH = n1*h4-(n1*h1+h3)
dS = n1*e4-(n1*e1+e3+n2*e2)
dS1 = (dH-dF)*1000/(273.2+T)
# Results
print 'free energy = %.2f kcal'%(dF)
print ' heat of formation = %.1f kcal'%(dH)
print ' Entropy = %.1f E.U'%(dS)
print ' Entropy umath.sing heat of formation and free energy = %.1f E.U'%(dS1)