Exciton formation in quantum wells