**5.1 Methane and carbon dioxide**

Biogas is composed mainly of CH4 and CO2. The ratio CH4 to CO2 is normally stable in the digester and any change may be due to the process instability. However, the ratio also depends on the composition of the substrate, the temperature, the pH and the pressure (Hickey & Switzenbaum, 1991). Since the dissolution of CO2 strongly depends on the pH, the fluctuation of the pH can also change the gas composition. A better indicator is thus the production of methane, rather than its composition in the gas (Anderson & Yang, 1992).

The production of methane combines the production of biogas with the measurement of percentage of methane. The production rate of methane (L-CH4/days) was used successfully like an on line indicator to control a CSTR digester (Feitkenhauer & al., 2002)**.**
