We give an explicit formula for the membrane potential of cells in terms of
the intracellular and extracellular ionic concentrations, and derive equat
ions for the ionic currents that flow through channels, exchangers and elec
trogenic pumps. We demonstrate that the work done by the pumps equals the c
hange in potential energy of the cell, plus the energy lost in downhill ion
ic fluxes through the channels and exchangers. The theory is illustrated in
a simple model of spontaneously active cells in the cardiac pacemaker. The
model predicts the experimentally observed intracellular ionic concentrati
on of potassium, calcium and sodium. Likewise, the shapes of the simulated
action potential and five membrane currents are in good agreement with expe
riment. We do not see any drift in the values of the concentrations in a lo
ng time simulation, and we obtain the same asymptotic values when starting
from the full equilibrium situation with equal intracellular and extracellu
lar ionic concentrations.