High harmonic generation in periodic systems