import math
from __future__ import division
#initialisation of variables
x= 0.02 #m
y= 0.4 #m
R= 0.0592
e= -0.771 #V
e1= -1.520 #v
n= 5 #electrons
z= 0.80 #m
z1= 0.5 #m
#CALCULATIONS
E= e-R*math.log10(x/y)
E1= e1-(R/n)*math.log10(z1*z**8/x)
E2= E-E1
#RESULTS
print"Redox potential of sample=",round(E,3),"v";
print"Redox potential of sample=",round(E1,3),"v";
print"Redox potential of sample=",round(E2,3),"v";
import math
from __future__ import division
#initialisation of variables
E= 0.3500 #v
E1= -0.2788 #v
#CALCULATIONS
e= E+E1
#RESULTS
print"Redox potential of sample=",round(e,4),"v";
import math
from __future__ import division
#initialisation of variables
p= 60 #percent
x= 0.030 #v
E= -0.039 #v
#CALCULATIONS
V= E-x*math.log10((1-(p/100))/(p/100))
#RESULTS
print"Redox potential of sample=",round(V,3),"v";