Electrochemistry studies chemical reactions at the interface between an electrode and an electrolyte. Oxidation occurs when an element loses electrons and reduction occurs when an element gains electrons. Galvanic cells produce electrical energy from spontaneous redox reactions. The Nernst equation relates cell potential to concentration. Faraday's laws state that the amount of reaction is proportional to charge and equivalent weights determine amounts deposited. Electrolysis is used industrially to refine and deposit metals.