Modeling electrochemical potential