fixed an error with freeflow boundary condition