Corrected wrong boundary conditions.