Optical beam deflection induced by enthalpy of a chemical reaction and its analytical application