Nonlinear Schrödinger equation and dissipative quantum dynamics in periodic fields.