Avalanche multiplication due to impact ionization in quantum-well infrared photodetectors: A quantitative approach