  A mathematical model for chemical reactions in electrolytes is developed
using an Energy variational method consistent with classical thermodynamics.
Electrostatics and chemical reactions are included in properly defined
energetic and dissipative functionals. The energy variation method is
generalized to deal with open systems with inputs of charge, mass, and energy.
The open systems can transform input energy of one type into output energy of
another type. The generalized method is used to analyze the conversion of
electrical current into proton flow by cytochrome c oxidase, an important
enzyme in mitochondria that helps generate the 'energetic currency of life'
ATP. The structure of the oxidase guides flows of current and mass that
interact according to the energetic and dissipative functionals of the
generalized theory. Kirchhoff's current law provides important coupling when
the enzyme is in its natural setting in the mitochondrial membrane. The natural
function of the enzyme is the result. Electron flows are converted into proton
flows and gradients.
