Skip to content

Biogas Production and Energy Recovery ​

Comprehensive biogas modeling for anaerobic digestion processes

Overview ​

The biogas production module calculates biogas yield, composition, and energy recovery potential from anaerobic digestion of wastewater sludge. It integrates with the GHG emissions calculator for carbon footprint assessments.

Services ​

ServicePurpose
BiogasProductionServiceCalculate biogas yield from substrate composition
BiogasCompositionServiceDetermine gas composition and quality
EnergyRecoveryServiceCalculate CHP electricity and heat recovery

Biogas Production ​

Substrate-Specific Yields ​

Based on the Buswell equation, different organic compounds produce different amounts of methane:

SubstrateFormulaCH4 Yield (Nm³/kg VS)CH4 Fraction (%)
Carbohydrates(C6H10O5)n0.41550%
ProteinsC5H7NO20.49670%
LipidsC51H98O61.01470%

Buswell Equation ​

The theoretical biogas composition is calculated using:

$$C_nH_aO_bN_c + \frac{4n-a-2b+3c}{4}H_2O \rightarrow \frac{4n+a-2b-3c}{8}CH_4 + \frac{4n-a+2b+3c}{8}CO_2 + cNH_3$$

For glucose (C6H12O6): C6H12O6 → 3CH4 + 3CO2

Usage ​

typescript
import { calculateBiogasYield, getBiogasProductionService } from '@/flow/services/simulation/carbon';

const result = calculateBiogasYield({
  vsFeedRate: 5000, // kg VS/d
  vsDestructionEfficiency: 55, // %
  substrateComposition: {
    carbohydrates: 60, // %
    proteins: 25, // %
    lipids: 15, // %
  },
  srt: 20, // days
  temperature: 35, // °C
});

console.log(result.totalBiogas); // Nm³/d
console.log(result.methaneFlow); // Nm³ CH4/d
console.log(result.specificYield); // Nm³/kg VS destroyed

Temperature Effects ​

The temperature correction factor uses the Arrhenius equation:

$$k(T) = k(35) \times \theta^{(T-35)}$$

RegimeTemperatureθRate Multiplier
Psychrophilic<20°C-Reduced
Mesophilic30-40°C1.041.0×
Thermophilic50-55°C1.061.3-1.5×

Inhibition Effects ​

The service calculates inhibition from:

FactorThresholdEffect
Ammonia (TAN)>3000 mg/LModerate inhibition
VFA>2000 mg/LReduced hydrolysis
Sulfide (H2S)>200 mg/LMethanogen inhibition
pH<6.5 or >7.6Process upset

Biogas Composition ​

Typical Composition ​

ComponentRangeTypicalUnit
CH455-7065vol %
CO225-4535vol %
H2S100-10,0001000ppm
NH350-200100ppm
H2<10.1vol %
H2O2-74vol %

H2S Estimation ​

H2S is produced from:

  1. Sulfate reduction: SO4²⁻ → H2S (by sulfate-reducing bacteria)
  2. Protein degradation: S-amino acids → H2S
typescript
import { calculateBiogasComposition } from '@/flow/services/simulation/carbon';

const composition = calculateBiogasComposition({
  substrateComposition: { carbohydrates: 60, proteins: 25, lipids: 15 },
  temperature: 35,
  influentSulfate: 50, // mg/L SO4
  ph: 7.0,
});

console.log(composition.h2sContent); // ppm
console.log(composition.lhv); // MJ/Nm³

Heating Values ​

PropertyFormulaTypical Value
LHVCH4% × 35.8 MJ/Nm³~23 MJ/Nm³
HHVCH4% × 39.8 MJ/Nm³~26 MJ/Nm³
Wobbe IndexHHV / √(ρ/ρ_air)~27 MJ/Nm³

Quality Assessment ​

typescript
import { assessBiogasQuality } from '@/flow/services/simulation/carbon';

const quality = assessBiogasQuality(composition);
console.log(quality.suitableForCHP); // boolean
console.log(quality.warnings); // string[]
console.log(quality.recommendations); // string[]

Energy Recovery ​

CHP Performance ​

typescript
import { calculateEnergyRecovery } from '@/flow/services/simulation/carbon';

const energy = calculateEnergyRecovery({
  biogasFlow: 2000, // Nm³/d
  ch4Percentage: 65, // %
  chpElectricalEfficiency: 38, // %
  chpThermalEfficiency: 45, // %
  parasiticLoad: 50, // kW
  availabilityFactor: 95, // %
  gridCarbonIntensity: 0.4, // kg CO2/kWh
  electricityPrice: 0.10, // $/kWh
});

console.log(energy.grossElectricity); // kWh/d
console.log(energy.netElectricity); // kWh/d
console.log(energy.carbonCredit); // kg CO2/d avoided
console.log(energy.revenue); // $/d

Energy Balance ​

OutputTypical EfficiencyFormula
Gross Electricity30-42%E_input × η_elec
Net Electricity25-38%Gross - Parasitic
Thermal Recovery40-50%E_input × η_therm
Useful Heat20-40%Thermal × η_util
Losses10-25%E_input - Elec - Thermal

Carbon Credits ​

Carbon Credit (kg CO2/d) = Net Export (kWh/d) × Grid Intensity (kg CO2/kWh)

Typical grid carbon intensities:

Regionkg CO2/kWh
UK0.20-0.25
EU Average0.25-0.35
US Average0.40-0.45
China0.55-0.65

Integration with GHG Calculator ​

The biogas services integrate with the GHG emissions calculator:

typescript
import { calculateBiogasYield, calculateCH4Emissions } from '@/flow/services/simulation/carbon';

// Calculate biogas production
const biogas = calculateBiogasYield(yieldParams);

// Use in GHG calculations
const ch4Emissions = calculateCH4Emissions({
  biogasProduction: biogas.totalBiogas,
  methaneContent: 65,
  biogasCollectionEfficiency: 97,
  biogasLeakageRate: 2,
  dissolvedCH4: 15,
  digestateFlow: 500,
  flareEfficiency: 99.5,
  isFlared: false,
  isUtilized: true,
  gwpHorizon: '100-year',
}, 'advanced');

Sludge-Specific Calculations ​

Primary Sludge ​

typescript
import { calculatePrimarySludgeBiogas } from '@/flow/services/simulation/carbon';

const result = calculatePrimarySludgeBiogas(
  5000, // VS feed rate (kg/d)
  35, // temperature (°C)
  20 // SRT (days)
);

Typical composition: 60% carbs, 25% proteins, 15% lipids

Waste Activated Sludge (WAS) ​

typescript
import { calculateWASSludgeBiogas } from '@/flow/services/simulation/carbon';

const result = calculateWASSludgeBiogas(
  3000, // VS feed rate (kg/d)
  35, // temperature (°C)
  20 // SRT (days)
);

WAS has lower VS destruction (~85% of primary) due to microbial cell walls.

Mixed Sludge ​

typescript
import { calculateMixedSludgeBiogas } from '@/flow/services/simulation/carbon';

const result = calculateMixedSludgeBiogas(
  5000, // Primary VS (kg/d)
  3000, // WAS VS (kg/d)
  35, // temperature (°C)
  20 // SRT (days)
);

API Reference ​

BiogasProductionService ​

MethodDescription
calculate(params)Calculate biogas yield
getLastResult()Get last calculation result
subscribe(listener)Subscribe to updates

BiogasCompositionService ​

MethodDescription
calculate(params)Calculate gas composition
assessQuality()Assess biogas quality for CHP
subscribe(listener)Subscribe to updates

EnergyRecoveryService ​

MethodDescription
calculate(params)Calculate energy recovery
verifyBalance()Verify energy balance
getAnnualTotals(factors)Calculate annual totals
subscribe(listener)Subscribe to updates

Best Practices ​

  1. Substrate Analysis: Determine actual composition via COD fractionation
  2. Temperature Control: Maintain stable temperature (±1°C)
  3. SRT Selection: 15-20 days for mesophilic, 10-15 for thermophilic
  4. H2S Monitoring: Install desulfurization if >500 ppm
  5. H2 Monitoring: Use as early warning for process upset
  6. CHP Sizing: Size for 80-90% of average biogas production

References ​

  1. Buswell, A.M. & Mueller, H.F. (1952). "Mechanism of Methane Fermentation"
  2. Batstone, D.J. et al. (2002). "ADM1 - Anaerobic Digestion Model No. 1"
  3. Metcalf & Eddy (2014). "Wastewater Engineering" Chapter 13